/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 revisionview.py

Merged Seahorse integration performance fixes.

Show diffs side-by-side

added added

removed removed

Lines of Context:
33
33
else:
34
34
    has_seahorse = True
35
35
 
 
36
PAGE_GENERAL = 0
 
37
PAGE_RELATIONS = 1
 
38
PAGE_SIGNATURE = 2
 
39
PAGE_BUGS = 3
 
40
 
36
41
def _open_link(widget, uri):
37
42
    subprocess.Popen(['sensible-browser', uri], close_fds=True)
38
43
 
300
305
        )
301
306
    }
302
307
 
303
 
 
304
308
    def __init__(self, branch=None):
305
309
        gtk.Notebook.__init__(self)
306
310
 
314
318
        self._create_file_info_view()
315
319
        self._create_bugs()
316
320
 
317
 
        self.set_current_page(0)
 
321
        self.set_current_page(PAGE_GENERAL)
 
322
        self.connect_after('switch-page', self._switch_page_cb)
318
323
        
319
324
        self._show_callback = None
320
325
        self._clicked_callback = None
430
435
        self._add_tags()
431
436
 
432
437
    def _update_signature(self, widget, param):
433
 
        self.signature_table.set_revision(self._revision)
 
438
        if self.get_current_page() == PAGE_SIGNATURE:
 
439
            self.signature_table.set_revision(self._revision)
434
440
 
435
441
    def _update_bugs(self, widget, param):
436
442
        self.bugs_page.set_revision(self._revision)
442
448
                                      self.children_widgets,
443
449
                                      self.children_table)
444
450
 
 
451
    def _switch_page_cb(self, notebook, page, page_num):
 
452
        if page_num == PAGE_SIGNATURE:
 
453
            self.signature_table.set_revision(self._revision)
 
454
 
 
455
 
 
456
 
445
457
    def _show_clicked_cb(self, widget, revid, parentid):
446
458
        """Callback for when the show button for a parent is clicked."""
447
459
        self._show_callback(revid, parentid)