~ubuntu-branches/ubuntu/utopic/gramps/utopic

« back to all changes in this revision

Viewing changes to src/Merge/mergerepository.py

  • Committer: Package Import Robot
  • Author(s): James A. Treacy
  • Date: 2012-05-22 17:18:36 UTC
  • mfrom: (39.1.4 sid)
  • Revision ID: package-import@ubuntu.com-20120522171836-35fi62lp4w7jnrd7
Tags: 3.4.0-1
* New upstream version
* Updated desktop file. Closes: #667472

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
19
19
#
20
20
 
21
 
# $Id$
 
21
# $Id: mergerepository.py 18669 2011-12-31 18:47:05Z m_d_n $
22
22
 
23
23
"""
24
24
Provide merge capabilities for repositories.
136
136
        if use_handle1:
137
137
            phoenix = self.rp1
138
138
            titanic = self.rp2
139
 
            unselect_path = (1,)
140
139
        else:
141
140
            phoenix = self.rp2
142
141
            titanic = self.rp1
143
 
            unselect_path = (0,)
 
142
            # Add second handle to history so that when merge is complete, 
 
143
            # phoenix is the selected row.
 
144
            self.uistate.viewmanager.active_page.get_history().push(
 
145
                    phoenix.get_handle())
144
146
 
145
147
        if self.get_widget("name_btn1").get_active() ^ use_handle1:
146
148
            phoenix.set_name(titanic.get_name())
151
153
 
152
154
        query = MergeRepoQuery(self.dbstate, phoenix, titanic)
153
155
        query.execute()
154
 
        if self.uistate.viewmanager.active_page.selection:
155
 
            self.uistate.viewmanager.active_page.selection.unselect_path(
156
 
                    unselect_path)
157
156
        self.uistate.set_busy_cursor(False)
158
157
        self.close()
159
158