From 11b177bd6447f7e12909bc6d9096e7acb73106c3 Mon Sep 17 00:00:00 2001 From: Don Allingham Date: Thu, 3 Jul 2003 03:32:46 +0000 Subject: [PATCH] * src/AddSpouse.py: handle adding of new person callback correctly svn: r1811 --- gramps2/src/AddSpouse.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/gramps2/src/AddSpouse.py b/gramps2/src/AddSpouse.py index 09c8f9adf..545f41d0f 100644 --- a/gramps2/src/AddSpouse.py +++ b/gramps2/src/AddSpouse.py @@ -145,12 +145,18 @@ class AddSpouse: person.setGender(gen) EditPerson.EditPerson(person,self.db,self.update_list) - def update_list(self,person): + def update_list(self,epo,list): """ Updates the potential spouse list after a person has been added to database. Called by the QuickAdd class when the dialog has been closed. """ + person = epo.person + if person.getId() == "": + self.db.addPerson(person) + else: + self.db.addPersonNoMap(person,person.getId()) + self.db.buildPersonDisplay(person.getId()) self.addperson(person) self.update_data(person.getId()) self.slist.center_selected()