Unicode support in GTK bookmarks
This commit is contained in:
parent
d8ae8c10b2
commit
396cda23b5
6
debian/changelog
vendored
6
debian/changelog
vendored
@ -1,3 +1,9 @@
|
||||
mintmenu (5.1.4) julia; urgency=low
|
||||
|
||||
* Unicode support in GTK bookmarks
|
||||
|
||||
-- Clement Lefebvre <root@linuxmint.com> Mon, 25 Oct 2010 12:22:00 +0000
|
||||
|
||||
mintmenu (5.1.3) julia; urgency=low
|
||||
|
||||
* APT search can be turned off
|
||||
|
@ -14,6 +14,7 @@ from easybuttons import *
|
||||
from execute import Execute
|
||||
from easygconf import EasyGConf
|
||||
from user import home
|
||||
from urllib import unquote
|
||||
|
||||
# i18n
|
||||
gettext.install("mintmenu", "/usr/share/linuxmint/locale")
|
||||
@ -206,10 +207,10 @@ class pluginclass( object ):
|
||||
|
||||
def do_gtk_bookmarks( self ):
|
||||
if self.showGTKBookmarks:
|
||||
bookmarks = {}
|
||||
bookmarks = {}
|
||||
with open(os.path.expanduser('~/.gtk-bookmarks'), 'r') as f:
|
||||
for line in f:
|
||||
line = line.replace('file://', '')
|
||||
#line = line.replace('file://', '')
|
||||
line = line.rstrip()
|
||||
parts = line.split(' ')
|
||||
|
||||
@ -219,12 +220,16 @@ class pluginclass( object ):
|
||||
junk = os.path.split(parts[0])
|
||||
bookmarks[junk[len(junk) - 1]] = parts[0]
|
||||
|
||||
for name, path in bookmarks.iteritems():
|
||||
command = ( "nautilus \"" + path + "\"")
|
||||
for name, path in bookmarks.iteritems():
|
||||
name = unquote(name)
|
||||
currentbutton = easyButton( "folder", self.iconsize, [name], -1, -1 )
|
||||
currentbutton.connect( "clicked", self.ButtonClicked, command )
|
||||
currentbutton.connect( "clicked", self.launch_gtk_bookmark, path )
|
||||
currentbutton.show()
|
||||
self.placesBtnHolder.pack_start( currentbutton, False, False )
|
||||
|
||||
def launch_gtk_bookmark (self, widget, path):
|
||||
self.mintMenuWin.hide()
|
||||
os.system("xdg-open %s &" % path)
|
||||
|
||||
def trashPopup( self, widget, event ):
|
||||
if event.button == 3:
|
||||
|
Loading…
Reference in New Issue
Block a user