From 148314b2191cdb1924635e6c7ab818ffb78a046d Mon Sep 17 00:00:00 2001 From: Erik De Richter Date: Wed, 10 Mar 2010 18:38:38 +0000 Subject: [PATCH] help connection to wiki page svn: r14741 --- src/gui/editors/editeventref.py | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/gui/editors/editeventref.py b/src/gui/editors/editeventref.py index 10e6d2289..9fce2993d 100644 --- a/src/gui/editors/editeventref.py +++ b/src/gui/editors/editeventref.py @@ -33,6 +33,7 @@ from gen.ggettext import gettext as _ # gramps modules # #------------------------------------------------------------------------- +import const import gen.lib from glade import Glade from displaytabs import (SourceEmbedList, NoteTab, GalleryTab, @@ -43,6 +44,15 @@ from editreference import RefTab, EditReference from objectentries import PlaceEntry + +#------------------------------------------------------------------------- +# +# Constants +# +#------------------------------------------------------------------------- +WIKI_HELP_PAGE = '%s_-_Entering_and_Editing_Data:_Detailed_-_part_2' % const.URL_MANUAL_PAGE +WIKI_HELP_SEC = _('manual|Editing_Event_References') + #------------------------------------------------------------------------- # # EditEventRef class @@ -91,7 +101,7 @@ class EditEventRef(EditReference): def _connect_signals(self): self.define_ok_button(self.top.get_object('ok'),self.ok_clicked) self.define_cancel_button(self.top.get_object('cancel')) - self.define_help_button(self.top.get_object('help')) + self.define_help_button(self.top.get_object('help'),self.on_help_button_clicked) def _connect_db_signals(self): """ @@ -249,6 +259,10 @@ class EditEventRef(EditReference): self.close() + def on_help_button_clicked(self, obj): + """Display the relevant portion of GRAMPS manual""" + GrampsDisplay.help(webpage=WIKI_HELP_PAGE, section=WIKI_HELP_SEC) + class EditFamilyEventRef(EditEventRef): def __init__(self, state, uistate, track, event, event_ref, update):