APT search can now be disabled via prefs

This commit is contained in:
Clement Lefebvre 2010-09-24 14:52:36 +01:00
parent ba7b48553c
commit d8ae8c10b2
5 changed files with 162 additions and 115 deletions

6
debian/changelog vendored
View File

@ -1,3 +1,9 @@
mintmenu (5.1.3) julia; urgency=low
* APT search can be turned off
-- Clement Lefebvre <root@linuxmint.com> Fri, 24 Sep 2010 14:52:00 +0000
mintmenu (5.1.2) julia; urgency=low
* Many UI improvements

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2010-09-23 09:53+0100\n"
"POT-Creation-Date: 2010-09-24 14:51+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -44,14 +44,10 @@ msgstr ""
msgid "About"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenu.py:747
#: usr/lib/linuxmint/mintMenu/mintMenu.py:737
msgid "Advanced Gnome Menu"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenu.py:750
msgid "Based on USP from S.Chanderbally"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintRemove.py:48
msgid "Please wait, this can take some time"
msgstr ""
@ -126,216 +122,221 @@ msgid "Hover"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:56
msgid "Search for packages to install"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:57
msgid "Swap name and generic name"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:58
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:59
msgid "Border width:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:59
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:60
msgid "pixels"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:61
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:62
msgid "Opacity:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:64
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:65
msgid "Button text:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:65
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:66
msgid "Options"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:66
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:257
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:67
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:236
msgid "Applications"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:68
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:69
msgid "Theme"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:69
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:254
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:255
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:70
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:233
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:234
msgid "Favorites"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:70
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:71
msgid "Main button"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:72
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:73
msgid "Background:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:73
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:74
msgid "Headings:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:74
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:75
msgid "Borders:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:75
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:76
msgid "Theme:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:79
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:80
msgid "Number of columns:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:80
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:81
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:82
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:83
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:84
msgid "Icon size:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:83
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:85
msgid "Hover delay (ms):"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:84
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:86
msgid "Button icon:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:85
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:87
msgid "Search command:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:87
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:89
#: usr/lib/linuxmint/mintMenu/plugins/places.py:40
msgid "Places"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:88
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:100
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:90
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:102
msgid "Allow Scrollbar"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:89
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:91
msgid "Show GTK Bookmarks"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:90
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:101
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:92
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:103
msgid "Height:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:91
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:93
msgid "Toggle Default Places:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:92
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:94
#: usr/lib/linuxmint/mintMenu/plugins/places.py:148
msgid "Computer"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:93
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:95
#: usr/lib/linuxmint/mintMenu/plugins/places.py:155
msgid "Home Folder"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:94
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:96
#: usr/lib/linuxmint/mintMenu/plugins/places.py:162
msgid "Network"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:95
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:97
#: usr/lib/linuxmint/mintMenu/plugins/places.py:182
msgid "Desktop"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:96
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:98
#: usr/lib/linuxmint/mintMenu/plugins/places.py:189
msgid "Trash"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:97
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:99
msgid "Custom Places:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:99
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:101
#: usr/lib/linuxmint/mintMenu/plugins/system_management.py:38
msgid "System"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:102
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:104
msgid "Toggle Default Items:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:103
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:105
#: usr/lib/linuxmint/mintMenu/plugins/system_management.py:134
msgid "Software Manager"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:104
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:106
#: usr/lib/linuxmint/mintMenu/plugins/system_management.py:141
msgid "Package Manager"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:105
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:107
#: usr/lib/linuxmint/mintMenu/plugins/system_management.py:148
msgid "Control Center"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:106
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:108
#: usr/lib/linuxmint/mintMenu/plugins/system_management.py:155
msgid "Terminal"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:107
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:109
#: usr/lib/linuxmint/mintMenu/plugins/system_management.py:162
msgid "Lock Screen"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:108
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:110
msgid "Log Out"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:109
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:111
#: usr/lib/linuxmint/mintMenu/plugins/system_management.py:176
msgid "Quit"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:111
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:113
msgid "Edit Place"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:112
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:114
msgid "New Place"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:113
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:115
msgid "Select a folder"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:115
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:117
msgid "Keyboard shortcut:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:248
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:255
msgid "Name"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:249
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:256
msgid "Path"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:264
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:271
msgid "Desktop theme"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:399
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:433
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:406
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:440
msgid "Name:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:400
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:434
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:407
#: usr/lib/linuxmint/mintMenu/mintMenuConfig.py:441
msgid "Path:"
msgstr ""
@ -343,142 +344,142 @@ msgstr ""
msgid "Recent documents"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:252
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:231
msgid "Search:"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:256
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:235
msgid "All applications"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:619
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:610
#, python-format
msgid "Search Google for %s"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:626
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:617
#, python-format
msgid "Search Wikipedia for %s"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:642
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:633
#, python-format
msgid "Lookup %s in Dictionary"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:649
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:640
#, python-format
msgid "Search Computer for %s"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:711
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:765
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:702
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:756
#, python-format
msgid "Install package '%s'"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:869
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:936
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:860
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:927
msgid "Add to desktop"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:870
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:937
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:861
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:928
msgid "Add to panel"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:872
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:918
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:863
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:909
msgid "Insert space"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:873
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:919
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:864
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:910
msgid "Insert separator"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:875
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:940
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:866
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:931
msgid "Launch when I log in"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:877
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:942
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:868
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:933
msgid "Launch"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:878
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:869
msgid "Remove from favorites"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:880
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:946
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:871
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:937
msgid "Edit properties"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:917
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:908
msgid "Remove"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:939
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:930
msgid "Show in my favorites"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:943
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:934
msgid "Uninstall"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:944
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:935
msgid "Delete from menu"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:997
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:988
msgid "Search Google"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1004
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:995
msgid "Search Wikipedia"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1014
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1005
msgid "Lookup Dictionnary"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1021
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1012
msgid "Search Computer"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1031
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1022
msgid "Find Software"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1038
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1029
msgid "Find Tutorials"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1045
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1036
msgid "Find Hardware"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1052
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1043
msgid "Find Ideas"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1059
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1050
msgid "Find Users"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1533
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1524
msgid ""
"Couldn't save favorites. Check if you have write access to ~/.linuxmint/"
"mintMenu"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1710
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1701
msgid "All"
msgstr ""
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1710
#: usr/lib/linuxmint/mintMenu/plugins/applications.py:1701
msgid "Show all applications"
msgstr ""

View File

@ -593,7 +593,7 @@
<widget class="GtkTable" id="table17">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
<property name="n_rows">6</property>
<property name="n_rows">7</property>
<property name="n_columns">2</property>
<property name="row_spacing">5</property>
<property name="homogeneous">True</property>
@ -744,6 +744,24 @@
<property name="x_padding">5</property>
</packing>
</child>
<child>
<widget class="GtkCheckButton" id="use_apt">
<property name="label" translatable="yes">Search for packages to install</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
<property name="draw_indicator">True</property>
</widget>
<packing>
<property name="right_attach">2</property>
<property name="top_attach">6</property>
<property name="bottom_attach">7</property>
<property name="x_options">GTK_FILL</property>
<property name="y_options"></property>
<property name="x_padding">5</property>
</packing>
</child>
</widget>
</child>
<child>

View File

@ -53,6 +53,7 @@ class mintMenuConfig( object ):
wTree.get_widget("showAppComments").set_label(_("Show application comments"))
wTree.get_widget("showCategoryIcons").set_label(_("Show category icons"))
wTree.get_widget("hover").set_label(_("Hover"))
wTree.get_widget("use_apt").set_label(_("Search for packages to install"))
wTree.get_widget("swapGeneric").set_label(_("Swap name and generic name"))
wTree.get_widget("label11").set_text(_("Border width:"))
@ -117,6 +118,7 @@ class mintMenuConfig( object ):
self.startWithFavorites = wTree.get_widget( "startWithFavorites" )
self.showAppComments = wTree.get_widget( "showAppComments" )
self.useAPT = wTree.get_widget( "use_apt" )
self.showCategoryIcons = wTree.get_widget( "showCategoryIcons" )
self.showRecentPlugin = wTree.get_widget( "showRecentPlugin" )
self.showApplicationsPlugin = wTree.get_widget( "showApplicationsPlugin" )
@ -186,6 +188,7 @@ class mintMenuConfig( object ):
self.bindGconfValueToWidget( self.gconf, "bool", "start_with_favorites", self.startWithFavorites, "toggled", self.startWithFavorites.set_active, self.startWithFavorites.get_active )
self.bindGconfValueToWidget( self.gconfApplications, "bool", "show_application_comments", self.showAppComments, "toggled", self.showAppComments.set_active, self.showAppComments.get_active )
self.bindGconfValueToWidget( self.gconfApplications, "bool", "use_apt", self.useAPT, "toggled", self.useAPT.set_active, self.useAPT.get_active )
self.bindGconfValueToWidget( self.gconfApplications, "bool", "show_category_icons", self.showCategoryIcons, "toggled", self.showCategoryIcons.set_active, self.showCategoryIcons.get_active )
self.bindGconfValueToWidget( self.gconfApplications, "bool", "categories_mouse_over", self.hover, "toggled", self.hover.set_active, self.hover.get_active )
self.bindGconfValueToWidget( self.gconfApplications, "bool", "swap_generic_name", self.swapGeneric, "toggled", self.swapGeneric.set_active, self.swapGeneric.get_active )

View File

@ -208,13 +208,6 @@ class pluginclass( object ):
@print_timing
def __init__( self, mintMenuWin, toggleButton ):
self.apt_cache = None
try:
self.apt_cache = apt.Cache()
except Exception, detail:
print "Could not initialize APT cache"
pass
self.mintMenuWin = mintMenuWin
self.mainMenus = [ ]
@ -284,6 +277,7 @@ class pluginclass( object ):
self.gconf.notifyAdd( "swap_generic_name", self.changeSwapGenericName )
self.gconf.notifyAdd( "show_category_icons", self.changeShowCategoryIcons )
self.gconf.notifyAdd( "show_application_comments", self.changeShowApplicationComments )
self.gconf.notifyAdd( "use_apt", self.switchAPTUsage)
self.gconf.notifyAdd( "fav_cols", self.changeFavCols )
self.gconf.bindGconfEntryToVar( "int", "category_hover_delay", self, "categoryhoverdelay" )
@ -318,6 +312,14 @@ class pluginclass( object ):
#for f in mymenu.directory.AppDirs:
# self.menuFileMonitors.append( filemonitor.addMonitor(f, self.onMenuChanged, mymenu.directory.Filename ) )
self.apt_cache = None
if self.useAPT:
try:
self.apt_cache = apt.Cache()
except Exception, detail:
print "Could not initialize APT cache"
pass
self.suggestions = []
self.current_suggestion = None
self.get_panel()
@ -411,6 +413,19 @@ class pluginclass( object ):
if isinstance( child, FavApplicationLauncher):
child.setIconSize( self.faviconsize )
def switchAPTUsage( self, client, connection_id, entry, args ):
self.useAPT = entry.get_value().get_bool()
if self.useAPT:
try:
apt_cache = apt.Cache()
if apt_cache != None:
self.apt_cache = apt_cache
except Exception, detail:
print "Could not refresh APT cache"
pass
else:
self.apt_cache = None
def changeShowApplicationComments( self, client, connection_id, entry, args ):
self.showapplicationcomments = entry.get_value().get_bool()
for child in self.applicationsBox:
@ -435,13 +450,16 @@ class pluginclass( object ):
self.favoritesPositionOnGrid( fav )
def RegenPlugin( self, *args, **kargs ):
try:
apt_cache = apt.Cache()
if apt_cache != None:
self.apt_cache = apt_cache
except Exception, detail:
print "Could not refresh APT cache"
pass
if self.useAPT:
try:
apt_cache = apt.Cache()
if apt_cache != None:
self.apt_cache = apt_cache
except Exception, detail:
print "Could not refresh APT cache"
pass
else:
self.apt_cache = None
# save old config - this is necessary because the app will notified when it sets the default values and you don't want the to reload itself several times
oldcategories_mouse_over = self.categories_mouse_over
@ -475,6 +493,7 @@ class pluginclass( object ):
self.showcategoryicons = self.gconf.get( "bool", "show_category_icons", True )
self.categoryhoverdelay = self.gconf.get( "int", "category_hover_delay", 150 )
self.showapplicationcomments = self.gconf.get( "bool", "show_application_comments", True )
self.useAPT = self.gconf.get( "bool", "use_apt", True )
self.lastActiveTab = self.gconf.get( "int", "last_active_tab", 0 )
self.defaultTab = self.gconf.get( "int", "default_tab", -1 )