7584: Fix update of active object after merge

This commit is contained in:
Nick Hall 2014-04-05 17:54:38 +01:00
parent 64a5626712
commit 0a5b2e9f6a
9 changed files with 9 additions and 19 deletions

View File

@ -154,8 +154,7 @@ class MergeCitation(ManagedWindow):
titanic = self.citation1 titanic = self.citation1
# Add second handle to history so that when merge is complete, # Add second handle to history so that when merge is complete,
# phoenix is the selected row. # phoenix is the selected row.
self.uistate.viewmanager.active_page.get_history().push( self.uistate.set_active(phoenix.get_handle(), 'Citation')
phoenix.get_handle())
if self.get_widget("page_btn1").get_active() ^ use_handle1: if self.get_widget("page_btn1").get_active() ^ use_handle1:
phoenix.set_page(titanic.get_page()) phoenix.set_page(titanic.get_page())

View File

@ -169,8 +169,7 @@ class MergeEvent(ManagedWindow):
titanic = self.ev1 titanic = self.ev1
# Add second handle to history so that when merge is complete, # Add second handle to history so that when merge is complete,
# phoenix is the selected row. # phoenix is the selected row.
self.uistate.viewmanager.active_page.get_history().push( self.uistate.set_active(phoenix.get_handle(), 'Event')
phoenix.get_handle())
if self.get_widget("type_btn1").get_active() ^ use_handle1: if self.get_widget("type_btn1").get_active() ^ use_handle1:
phoenix.set_type(titanic.get_type()) phoenix.set_type(titanic.get_type())

View File

@ -202,8 +202,7 @@ class MergeFamily(ManagedWindow):
titanic = self.fy1 titanic = self.fy1
# Add second handle to history so that when merge is complete, # Add second handle to history so that when merge is complete,
# phoenix is the selected row. # phoenix is the selected row.
self.uistate.viewmanager.active_page.get_history().push( self.uistate.set_active(phoenix.get_handle(), 'Family')
phoenix.get_handle())
phoenix_fh = phoenix.get_father_handle() phoenix_fh = phoenix.get_father_handle()
phoenix_mh = phoenix.get_mother_handle() phoenix_mh = phoenix.get_mother_handle()

View File

@ -151,8 +151,7 @@ class MergeMedia(ManagedWindow):
titanic = self.mo1 titanic = self.mo1
# Add second handle to history so that when merge is complete, # Add second handle to history so that when merge is complete,
# phoenix is the selected row. # phoenix is the selected row.
self.uistate.viewmanager.active_page.get_history().push( self.uistate.set_active(phoenix.get_handle(), 'Media')
phoenix.get_handle())
if self.get_widget("path_btn1").get_active() ^ use_handle1: if self.get_widget("path_btn1").get_active() ^ use_handle1:
phoenix.set_path(titanic.get_path()) phoenix.set_path(titanic.get_path())

View File

@ -163,8 +163,7 @@ class MergeNote(ManagedWindow):
titanic = self.no1 titanic = self.no1
# Add second handle to history so that when merge is complete, # Add second handle to history so that when merge is complete,
# phoenix is the selected row. # phoenix is the selected row.
self.uistate.viewmanager.active_page.get_history().push( self.uistate.set_active(phoenix.get_handle(), 'Note')
phoenix.get_handle())
if self.get_widget("text_btn1").get_active() ^ use_handle1: if self.get_widget("text_btn1").get_active() ^ use_handle1:
phoenix.set_styledtext(titanic.get_styledtext()) phoenix.set_styledtext(titanic.get_styledtext())

View File

@ -319,8 +319,7 @@ class MergePerson(ManagedWindow):
titanic = self.pr1 titanic = self.pr1
# Add second handle to history so that when merge is complete, # Add second handle to history so that when merge is complete,
# phoenix is the selected row. # phoenix is the selected row.
self.uistate.viewmanager.active_page.get_history().push( self.uistate.set_active(phoenix.get_handle(), 'Person')
phoenix.get_handle())
if self.get_widget("name_btn1").get_active() ^ use_handle1: if self.get_widget("name_btn1").get_active() ^ use_handle1:
swapname = phoenix.get_primary_name() swapname = phoenix.get_primary_name()

View File

@ -191,9 +191,7 @@ class MergePlace(ManagedWindow):
titanic = self.pl1 titanic = self.pl1
# Add second handle to history so that when merge is complete, # Add second handle to history so that when merge is complete,
# phoenix is the selected row. # phoenix is the selected row.
self.uistate.viewmanager.active_page.get_history().push( self.uistate.set_active(phoenix.get_handle(), 'Place')
phoenix.get_handle())
if self.get_widget("title_btn1").get_active() ^ use_handle1: if self.get_widget("title_btn1").get_active() ^ use_handle1:
phoenix.set_title(titanic.get_title()) phoenix.set_title(titanic.get_title())

View File

@ -142,8 +142,7 @@ class MergeRepository(ManagedWindow):
titanic = self.rp1 titanic = self.rp1
# Add second handle to history so that when merge is complete, # Add second handle to history so that when merge is complete,
# phoenix is the selected row. # phoenix is the selected row.
self.uistate.viewmanager.active_page.get_history().push( self.uistate.set_active(phoenix.get_handle(), 'Repository')
phoenix.get_handle())
if self.get_widget("name_btn1").get_active() ^ use_handle1: if self.get_widget("name_btn1").get_active() ^ use_handle1:
phoenix.set_name(titanic.get_name()) phoenix.set_name(titanic.get_name())

View File

@ -163,8 +163,7 @@ class MergeSource(ManagedWindow):
titanic = self.src1 titanic = self.src1
# Add second handle to history so that when merge is complete, # Add second handle to history so that when merge is complete,
# phoenix is the selected row. # phoenix is the selected row.
self.uistate.viewmanager.active_page.get_history().push( self.uistate.set_active(phoenix.get_handle(), 'Source')
phoenix.get_handle())
if self.get_widget("title_btn1").get_active() ^ use_handle1: if self.get_widget("title_btn1").get_active() ^ use_handle1:
phoenix.set_title(titanic.get_title()) phoenix.set_title(titanic.get_title())