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

Merged an approved request (single clicking bookmark).

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
 
23
23
import gtk
24
24
 
25
 
class StatusDialog(gtk.MessageDialog):
 
25
class StatusDialog(gtk.Dialog):
26
26
    """ Display Status window and perform the needed actions. """
27
27
    def __init__(self, wt, wtpath):
28
28
        """ Initialize the Status window. """
29
 
        super(StatusDialog, self).__init__(flags=gtk.DIALOG_MODAL, buttons=gtk.BUTTONS_OK)
 
29
        super(StatusDialog, self).__init__(flags=gtk.DIALOG_MODAL, buttons=(gtk.STOCK_OK, gtk.RESPONSE_ACCEPT))
30
30
        self.set_title("Working tree changes")
31
 
        self.set_image(gtk.Label("Working tree status"))
32
31
        self._create()
33
32
        self.wt = wt
34
33
        self.wtpath = wtpath
39
38
 
40
39
    def _create(self):
41
40
        self.set_default_size(400, 300)
 
41
        scrolledwindow = gtk.ScrolledWindow()
 
42
        scrolledwindow.set_policy(gtk.POLICY_AUTOMATIC, gtk.POLICY_AUTOMATIC)
42
43
        self.treeview = gtk.TreeView()
43
 
        self.vbox.pack_start(self.treeview, True, True)
 
44
        scrolledwindow.add(self.treeview)
 
45
        self.vbox.pack_start(scrolledwindow, True, True)
44
46
        self.vbox.show_all()
45
47
 
46
48
    def row_diff(self, tv, path, tvc):
109
111
 
110
112
        self.treeview.expand_all()
111
113
    
112
 
    def display(self):
113
 
        """ Display the Diff window. """
114
 
        self.window.show_all()
115
 
 
116
114
    def close(self, widget=None):
117
115
        self.window.destroy()