From c9594feff0700d7c6bfc08dcba408c2d30dadfad Mon Sep 17 00:00:00 2001 From: Sebastian Heinlein Date: Sun, 12 Mar 2006 13:26:54 +0100 Subject: * only show the help button if a help viewer is installed (currently only yelp is supported - have not found anyone who could help me on khelpcenter yet) * do not run the help viewer as root * do not depend on the gnome python module anymore --- SoftwareProperties/SoftwareProperties.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'SoftwareProperties') diff --git a/SoftwareProperties/SoftwareProperties.py b/SoftwareProperties/SoftwareProperties.py index 690b30dd..f8fd45b9 100644 --- a/SoftwareProperties/SoftwareProperties.py +++ b/SoftwareProperties/SoftwareProperties.py @@ -34,6 +34,7 @@ import os #sys.path.append("@prefix/share/update-manager/python") from UpdateManager.Common.SimpleGladeApp import SimpleGladeApp +from UpdateManager.Common.HelpViewer import HelpViewer import aptsources import dialog_add import dialog_edit @@ -165,6 +166,10 @@ class SoftwareProperties(SimpleGladeApp): else: self.checkbutton_unattended.set_active(False) + self.help_viewer = HelpViewer("update-manager#setting-preferences") + if self.help_viewer.check() == False: + self.button_help.set_sensitive(False) + # apt-key stuff self.apt_key = apt_key() self.init_keyslist() @@ -392,9 +397,7 @@ class SoftwareProperties(SimpleGladeApp): self.quit() def on_help_button(self, widget): - gnome.help_display_desktop(self.gnome_program, - "update-manager", "update-manager", - "setting-preferences") + self.help_viewer.run() def on_button_add_cdrom_clicked(self, widget): #print "on_button_add_cdrom_clicked()" -- cgit v1.2.3