/b-gtk/fix-viz

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/b-gtk/fix-viz

« back to all changes in this revision

Viewing changes to olive/menu.py

  • Committer: Vincent Ladeuil
  • Date: 2008-10-22 07:56:53 UTC
  • mto: This revision was merged to the branch mainline in revision 617.
  • Revision ID: v.ladeuil+lp@free.fr-20081022075653-10v8wlpmisbotnjg
Fix bug #286834 bu handling 'missing' files corner case.

* tests/test_diff.py:
(Test_IterChangesToStatus.test_status_missing_file, )
(Test_IterChangesToStatus.test_status_removed): Add tests.

* diff.py:
(iter_changes_to_status): Handle 'missing' files corner case.

Show diffs side-by-side

added added

removed removed

Lines of Context:
282
282
    
283
283
    def commit(self, action):
284
284
        """ Right context menu -> Commit """
285
 
        from bzrlib.plugins.gtk.commit import CommitDialog
 
285
        from commit import CommitDialog
286
286
        branch = None
287
287
        try:
288
288
            wt, path = WorkingTree.open_containing(self.path)
310
310
        wt = WorkingTree.open_containing(self.path)[0]
311
311
        window = DiffWindow(self.app)
312
312
        parent_tree = wt.branch.repository.revision_tree(wt.branch.last_revision())
313
 
        window.set_diff(wt.branch._get_nick(local=True), wt, parent_tree)
 
313
        window.set_diff(wt.branch.nick, wt, parent_tree)
314
314
        window.set_file(wt.relpath(self.path + os.sep + self.selected))
315
315
        window.show()
316
316
    
367
367
        wt = WorkingTree.open_containing(self.path)[0]
368
368
        window = DiffWindow(self.app)
369
369
        parent_tree = wt.branch.repository.revision_tree(wt.branch.last_revision())
370
 
        window.set_diff(wt.branch._get_nick(local=True), wt, parent_tree)
 
370
        window.set_diff(wt.branch.nick, wt, parent_tree)
371
371
        window.show()
372
372
    
373
373
    def view_remote(self, action):