From 568068e47b5a9f48ddc06063128a5b6016421ea8 Mon Sep 17 00:00:00 2001 From: Alex Roitman Date: Fri, 11 Jul 2003 01:12:22 +0000 Subject: [PATCH] * src/GrampsCfg.py (GrampsPreferences.select): Conditional get_path(). * src/Plugins.py (PluginDialog.on_node_selected): Likewise. svn: r1858 --- gramps2/ChangeLog | 4 ++++ gramps2/src/GrampsCfg.py | 5 +++-- gramps2/src/Plugins.py | 3 ++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/gramps2/ChangeLog b/gramps2/ChangeLog index 79d681218..ee716c9e1 100644 --- a/gramps2/ChangeLog +++ b/gramps2/ChangeLog @@ -1,3 +1,7 @@ +2003-07-10 Alex Roitman + * src/GrampsCfg.py (GrampsPreferences.select): Conditional get_path(). + * src/Plugins.py (PluginDialog.on_node_selected): Likewise. + 2003-07-10 Tim Waugh * src/Relationship.py: Fix '[...]teenth' relationship name typos. * src/RelLib.py: Fix for probablyAlive(). If there is no date, but diff --git a/gramps2/src/GrampsCfg.py b/gramps2/src/GrampsCfg.py index aadc9e2a9..70586b59b 100644 --- a/gramps2/src/GrampsCfg.py +++ b/gramps2/src/GrampsCfg.py @@ -1,7 +1,7 @@ # # Gramps - a GTK+/GNOME based genealogy program # -# Copyright (C) 2000 Donald N. Allingham +# Copyright (C) 2000-2003 Donald N. Allingham # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -765,7 +765,8 @@ class GrampsPreferences: def select(self,obj): store,iter = self.selection.get_selected() - path = store.get_path(iter) + if iter: + path = store.get_path(iter) if iter and self.imap.has_key(path): self.panel.set_current_page(self.imap[path]) diff --git a/gramps2/src/Plugins.py b/gramps2/src/Plugins.py index 2d000c0c3..679d4d848 100644 --- a/gramps2/src/Plugins.py +++ b/gramps2/src/Plugins.py @@ -179,7 +179,8 @@ class PluginDialog: the dialog box with the description of the selected report""" store,iter = self.selection.get_selected() - path = store.get_path(iter) + if iter: + path = store.get_path(iter) if not iter or not self.imap.has_key(path): self.statbox.hide() return