* src/EditPerson.py: make a distiction between adding a person

and editing a person.
* src/PeopleView.py: drop unused goto_active_person parameter
* srcgramps_main.py: drop unused goto_active_person parameter


svn: r3517
This commit is contained in:
Don Allingham 2004-08-28 19:49:34 +00:00
parent 9459c36c2e
commit e07ffbcdd4
4 changed files with 14 additions and 5 deletions

View File

@ -1,3 +1,9 @@
2004-08-28 Don Allingham <dallingham@users.sourceforge.net>
* src/EditPerson.py: make a distiction between adding a person
and editing a person.
* src/PeopleView.py: drop unused goto_active_person parameter
* srcgramps_main.py: drop unused goto_active_person parameter
2004-08-27 Tim Waugh <twaugh@redhat.com> 2004-08-27 Tim Waugh <twaugh@redhat.com>
* src/SelectObject.py (SelectObject.redraw): Use GRAMPS ID for * src/SelectObject.py (SelectObject.redraw): Use GRAMPS ID for
user display. user display.

View File

@ -1614,6 +1614,9 @@ class EditPerson:
if self.lists_changed: if self.lists_changed:
self.person.set_source_reference_list(self.srcreflist) self.person.set_source_reference_list(self.srcreflist)
if self.person.get_handle() == None:
self.db.add_person(self.person, trans)
else:
self.db.commit_person(self.person, trans) self.db.commit_person(self.person, trans)
n = self.person.get_primary_name().get_regular_name() n = self.person.get_primary_name().get_regular_name()
self.db.transaction_commit(trans,_("Edit Person (%s)") % n) self.db.transaction_commit(trans,_("Edit Person (%s)") % n)

View File

@ -185,7 +185,7 @@ class PeopleView:
def add_to_person_list(self,person,change=0): def add_to_person_list(self,person,change=0):
self.apply_filter_clicked() self.apply_filter_clicked()
def goto_active_person(self,first=0): def goto_active_person(self):
if not self.parent.active_person: if not self.parent.active_person:
return return
p = self.parent.active_person p = self.parent.active_person

View File

@ -1,4 +1,4 @@
#
# Gramps - a GTK+/GNOME based genealogy program # Gramps - a GTK+/GNOME based genealogy program
# #
# Copyright (C) 2000-2004 Donald N. Allingham # Copyright (C) 2000-2004 Donald N. Allingham
@ -1294,8 +1294,8 @@ class Gramps:
self.people_view.redisplay_person_list(p1) self.people_view.redisplay_person_list(p1)
self.update_display(0) self.update_display(0)
def goto_active_person(self,first=0): def goto_active_person(self):
self.people_view.goto_active_person(first) self.people_view.goto_active_person()
def change_active_person(self,person,force=0): def change_active_person(self,person,force=0):
if person == None: if person == None: