From 81abc62ace6d51d796a4adbbe63fc0c2a16946f4 Mon Sep 17 00:00:00 2001 From: Don Allingham Date: Sat, 20 Jan 2007 22:49:09 +0000 Subject: [PATCH] 2007-01-20 Don Allingham * src/DataViews/_PersonView.py (PersonView.change_db): apply dirty flag to initial build to prevent forcing of build on load if the view is not in focus. svn: r7943 --- ChangeLog | 5 +++++ src/DataViews/_PersonView.py | 20 ++++---------------- 2 files changed, 9 insertions(+), 16 deletions(-) diff --git a/ChangeLog b/ChangeLog index cccddeb71..8ec8fe91a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2007-01-20 Don Allingham + * src/DataViews/_PersonView.py (PersonView.change_db): apply + dirty flag to initial build to prevent forcing of build on load + if the view is not in focus. + 2007-01-20 Alex Roitman * src/DataViews/_EventView.py (remove): Use reference map to find references to remove. diff --git a/src/DataViews/_PersonView.py b/src/DataViews/_PersonView.py index b9da68f5a..d5c6d28a7 100644 --- a/src/DataViews/_PersonView.py +++ b/src/DataViews/_PersonView.py @@ -280,8 +280,6 @@ class PersonView(PageView.PersonNavView): self.tree.set_headers_visible(True) self.tree.set_fixed_height_mode(True) self.tree.connect('key-press-event', self.key_press) -# self.tree.connect('row-expanded', self.expanded) -# self.tree.connect('test-expand-row', self.start_expand) self.tree.connect('start-interactive-search',self.open_all_nodes) scrollwindow = gtk.ScrolledWindow() @@ -424,21 +422,11 @@ class PersonView(PageView.PersonNavView): db.connect('person-delete', self.person_removed) db.connect('person-rebuild', self.build_tree) -# import hotshot, hotshot.stats - -# pr = hotshot.Profile('mystats.profile') -# print "Start" -# pr.runcall(self.build_tree) -# print "Finished" -# pr.close() -# print "Loading profile" -# stats = hotshot.stats.load('mystats.profile') -# print "done" -# stats.strip_dirs() -# stats.sort_stats('time','calls') -# stats.print_stats(100) + if self.active: + self.build_tree() + else: + self.dirty = True - self.build_tree() self.bookmarks.update_bookmarks(db.get_bookmarks()) if self.active: self.bookmarks.redraw()