[hamster-applet] added help, more info link in applet links to that too
- From: Toms Baugis <tbaugis src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [hamster-applet] added help, more info link in applet links to that too
- Date: Fri, 22 Jan 2010 12:15:58 +0000 (UTC)
commit 6a89b8291d0cf5c68dc2b6218fc202664bae0438
Author: Toms Bauģis <toms baugis gmail com>
Date: Fri Jan 22 11:35:44 2010 +0000
added help, more info link in applet links to that too
data/Hamster_Applet.xml | 1 +
hamster/applet.py | 25 +++----------------------
2 files changed, 4 insertions(+), 22 deletions(-)
---
diff --git a/data/Hamster_Applet.xml b/data/Hamster_Applet.xml
index 706a0d7..9072569 100644
--- a/data/Hamster_Applet.xml
+++ b/data/Hamster_Applet.xml
@@ -3,6 +3,7 @@
<popup name="button3">
<menuitem name="Overview" verb="overview" _label="_Overview"/>
<menuitem name="Preferences" verb="preferences" _label="_Preferences" pixtype="stock" pixname="gtk-preferences"/>
+ <menuitem name="Help" verb="help" _label="_Help" pixtype="stock" pixname="gtk-help"/>
<menuitem name="About" verb="about" _label="_About" pixtype="stock" pixname="gtk-about" />
</popup>
</popups>
diff --git a/hamster/applet.py b/hamster/applet.py
index 4a3a5d1..3fe41b4 100755
--- a/hamster/applet.py
+++ b/hamster/applet.py
@@ -196,6 +196,7 @@ class HamsterApplet(object):
[("about", self.on_about),
("overview", self.show_overview),
("preferences", self.show_preferences),
+ ("help", self.on_more_info_button_clicked),
])
# load window of activity switcher and todays view
@@ -712,26 +713,6 @@ class HamsterApplet(object):
def get_widget(self, name):
return self._gui.get_object(name)
- def on_more_info_button_clicked(self, button):
- def on_response(self, widget):
- self.destroy()
-
- message_dialog = gtk.MessageDialog(buttons = gtk.BUTTONS_OK)
- message_dialog.set_property("title", _("What should be typed in the activity box?"))
- message_dialog.connect("response", on_response)
-
- more_info = _("""There is a simple syntax that enables you to add details to your activities:
-
-"@" symbol marks a category. Example: "watering flowers home" will start tracking the activity "watering flowers" in the category "home".
-
-Commas (",") mark beginning of a description. Example: "watering flowers, begonias and forgetmenots" will start tracking the activity "watering flowers" and add the description "begonias and forgetmenots" to it.
-
-Both can be combined: "watering flowers home, begonias and forgetmenots" will work just fine!
-
-In the tag field, separate tags with a comma. You can use Tab button to autocomplete first tag displayed in the dropdown, as well as click on the tags using mouse.
-Now, start tracking!
- """)
-
- message_dialog.set_markup(more_info)
- message_dialog.show()
+ def on_more_info_button_clicked(self, *args):
+ gtk.show_uri(gtk.gdk.Screen(), "ghelp:hamster-applet", 0L)
return False
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]