diff --git a/gramps2/ChangeLog b/gramps2/ChangeLog index 3ae2a8e30..72e892935 100644 --- a/gramps2/ChangeLog +++ b/gramps2/ChangeLog @@ -4,6 +4,8 @@ * src/gedcomimport.glade: allow default when selecting override * src/gramps_main.py: don't lose track of active person after a cancelled Add Person + * src/PeopleView.py: handle changing of surnames if the surname + needs to be removed from the list 2004-10-15 Don Allingham * src/GrampsBSDDB.py: increase cachesize diff --git a/gramps2/src/PeopleView.py b/gramps2/src/PeopleView.py index bf2858b05..49e5deede 100644 --- a/gramps2/src/PeopleView.py +++ b/gramps2/src/PeopleView.py @@ -274,9 +274,12 @@ class PeopleView: def delete_person(self,person): node = person.get_handle() top = person.get_primary_name().get_group_name() - if len(self.person_model.sname_sub[top]) == 1: - path = self.person_model.on_get_path(top) - self.person_model.row_deleted(path) + try: + if len(self.person_model.sname_sub[top]) == 1: + path = self.person_model.on_get_path(top) + self.person_model.row_deleted(path) + except: + pass path = self.person_model.on_get_path(node) self.person_model.row_deleted(path) diff --git a/gramps2/src/gramps_main.py b/gramps2/src/gramps_main.py index 1174a6438..6102bcab3 100755 --- a/gramps2/src/gramps_main.py +++ b/gramps2/src/gramps_main.py @@ -1439,7 +1439,9 @@ class Gramps: def update_after_edit(self,epo,change=1): self.active_person = epo.person - if change: + if epo.orig_surname != self.active_person.get_primary_name().get_surname(): + self.people_view.build_tree() + elif change: self.people_view.update_person_list(epo.person) else: self.people_view.redisplay_person_list(epo.person)