Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 0.7, 0.7.1, and 0.7.2

status: activating diff header toggles file selection

Changeset a8150f7cc8b9

Parent 1658302e7e82

by Steve Borho

Changes to one file · Browse files at a8150f7cc8b9 Showing diff from parent 1658302e7e82 Diff from another changeset...

Change 1 of 1 Show Entire File hggtk/​status.py Stacked
 
831
832
833
 
 
 
834
835
836
837
 
 
 
 
838
839
840
841
842
843
844
845
846
847
848
849
850
 
 
 
 
 
851
852
853
 
831
832
833
834
835
836
837
838
839
 
840
841
842
843
844
845
 
 
 
 
 
 
 
 
 
 
 
846
847
848
849
850
851
852
853
@@ -831,23 +831,23 @@
  file = chunk.filename()   if file not in self._filechunks:   return + for fr in self.filemodel: + if fr[FM_PATH] == file: + break   fchunks = self._filechunks[file][1:]   if row[DM_HEADER_CHUNK]:   for n in fchunks: - dmodel[n][DM_REJECTED] = not dmodel[n][DM_REJECTED] + dmodel[n][DM_REJECTED] = fr[FM_CHECKED] + fr[FM_CHECKED] = not fr[FM_CHECKED] + fr[FM_PARTIAL_SELECTED] = False + self._update_check_count()   else:   row[DM_REJECTED] = not row[DM_REJECTED] - - # Determine file's chunk status - rej = [ n for n in fchunks if dmodel[n][DM_REJECTED] ] - nonrej = [ n for n in fchunks if not dmodel[n][DM_REJECTED] ] - newvalue = nonrej and True or False - partial = rej and nonrej and True or False - - # Update file's check status - for fr in self.filemodel: - if fr[FM_PATH] != file: - continue + rej = [ n for n in fchunks if dmodel[n][DM_REJECTED] ] + nonrej = [ n for n in fchunks if not dmodel[n][DM_REJECTED] ] + newvalue = nonrej and True or False + partial = rej and nonrej and True or False + # Update file's check status   fr[FM_PARTIAL_SELECTED] = partial   if fr[FM_CHECKED] != newvalue:   fr[FM_CHECKED] = newvalue