3175: Crash when undoing a family edit- part of undo being slow

svn: r14676
This commit is contained in:
Benny Malengier 2010-03-07 19:38:48 +00:00
parent 9da1431b6c
commit cb7227f692
2 changed files with 54 additions and 33 deletions

View File

@ -566,9 +566,12 @@ class PedigreeView(NavigationView):
self.bookmarks.redraw()
def person_rebuild(self,dummy=None):
if self.active:
self.format_helper.clear_cache()
self.dirty = True
self.rebuild_trees(self.get_active())
else:
self.dirty = True
def request_resize(self):
self.size_request_cb(self.notebook.parent,None,None)

View File

@ -211,12 +211,15 @@ class RelationshipView(NavigationView):
self.redraw()
def person_update(self, handle_list):
if self.active:
person = self.get_active()
if person:
while not self.change_person(person):
pass
else:
self.change_person(None)
else:
self.dirty = True
def person_rebuild(self):
"""Large change to person database"""
@ -228,38 +231,52 @@ class RelationshipView(NavigationView):
pass
else:
self.change_person(None)
else:
self.dirty = True
def family_update(self, handle_list):
if self.active:
person = self.get_active()
if person:
while not self.change_person(person):
pass
else:
self.change_person(None)
else:
self.dirty = True
def family_add(self, handle_list):
if self.active:
person = self.get_active()
if person:
while not self.change_person(person):
pass
else:
self.change_person(None)
else:
self.dirty = True
def family_delete(self, handle_list):
if self.active:
person = self.get_active()
if person:
while not self.change_person(person):
pass
else:
self.change_person(None)
else:
self.dirty = True
def family_rebuild(self):
if self.active:
person = self.get_active()
if person:
while not self.change_person(person):
pass
else:
self.change_person(None)
else:
self.dirty = True
def change_page(self):
NavigationView.change_page(self)
@ -553,6 +570,7 @@ class RelationshipView(NavigationView):
self.uistate.modify_statusbar(self.dbstate)
self.order_action.set_sensitive(self.reorder_sensitive)
self.dirty = False
return True