Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 0.8.1, 0.8.2, and 0.8.3

status: limit auto_check to a single invocation

There is logic in do_reload() to auto-select files, so auto_check() is generally
redundant (and in fact counter-productive). The only time it is needed is when
the user has selected clean or ignored files for deletion via the shell context
menu and we would like those files initially checked.

Auto-checking files after a refresh would confuse the hunk/file selection state.
The files would look like they were selected until the user clicked on them, then
the file selection state would toggle off.

Fixes #355

Changeset 68f26fac56b9

Parent 496db85409ef

by Steve Borho

Changes to one file · Browse files at 68f26fac56b9 Showing diff from parent 496db85409ef Diff from another changeset...

Change 1 of 1 Show Entire File hggtk/​status.py Stacked
 
87
88
89
90
 
 
91
92
93
 
94
95
96
 
87
88
89
 
90
91
92
93
94
95
96
97
98
@@ -87,10 +87,12 @@
  self.filechunks = {}     def auto_check(self): - if self.pats or self.opts.get('check'): + # Only auto-check files once, and only if a pattern was given. + if self.pats and self.opts.get('check'):   for entry in self.filemodel:   entry[FM_CHECKED] = True   self.update_check_count() + self.opts['check'] = False     def get_menu_info(self):   """Returns menu info in this order: