Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 0.4rc2, 0.4rc3, and 0.4rc4

hggtk/history: show progress bar when populating diff chunks

Changeset e2b03522d571

Parent 4c5a64b79885

by TK Soh

Changes to 2 files · Browse files at e2b03522d571 Showing diff from parent 4c5a64b79885 Diff from another changeset...

 
23
24
25
 
26
27
28
29
30
 
 
 
 
31
32
33
 
105
106
107
 
 
108
109
110
 
176
177
178
 
179
180
181
 
513
514
515
516
 
 
 
 
 
 
 
 
 
 
 
 
 
517
518
519
 
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
 
110
111
112
113
114
115
116
117
 
183
184
185
186
187
188
189
 
521
522
523
 
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
@@ -23,11 +23,16 @@
 from gdialog import *  from hgcmd import CmdDialog  from hglib import toutf, fromutf +from gtklib import StatusBar      class ChangeSet(GDialog):   """GTK+ based dialog for displaying repository logs   """ + def __init__(self, ui, repo, cwd, pats, opts, main, stbar=None): + GDialog.__init__(self, ui, repo, cwd, pats, opts, main) + self.stbar = stbar +   def get_title(self):   title = os.path.basename(self.repo.root) + ' changeset '   title += self.opts['rev'][0] @@ -105,6 +110,8 @@
  self.textview.thaw_child_notify()     def _fill_buffer(self, buf, rev, ctx, filelist): + self.stbar.begin('Retrieving changeset data...') +   def title_line(title, text, tag):   pad = ' ' * (12 - len(title))   utext = toutf(title + pad + text) @@ -176,6 +183,7 @@
  try:   status, file, txt = iterator.next()   except StopIteration: + self.stbar.end()   return False     lines = txt.splitlines() @@ -513,7 +521,19 @@
  self._hpaned.pack1(list_frame, True, True)   self._hpaned.pack2(details_frame, True, True)   self._hpaned.set_position(self._setting_hpos) - return self._hpaned + + if self.stbar: + # embedded by changelog browser + return self._hpaned + else: + # add status bar for main app + vbox = gtk.VBox() + vbox.pack_start(self._hpaned, True, True) + self.stbar = StatusBar() + self.stbar.show() + vbox.pack_start(gtk.HSeparator(), False, False) + vbox.pack_start(self.stbar, False, False) + return vbox     def setup_tags(self):   """Creates the tags to be used inside the TextView"""
Change 1 of 1 Show Entire File hggtk/​history.py Stacked
 
236
237
238
239
 
240
241
242
 
236
237
238
 
239
240
241
242
@@ -236,7 +236,7 @@
    # Allocate ChangeSet instance to use internally   self.changeview = ChangeSet(self.ui, self.repo, self.cwd, [], - self.opts, False) + self.opts, False, self.stbar)   self.changeview.display(False)   self.changeview.glog_parent = self