Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 1.9.2, 1.9.3, and 2.0

repofilter: disable branchChanged signals while reloading

This was causing the graph to be rebuilt once for every named branch in your
repository, every time you hit the refresh button. Obviously not nice.

Changeset d0aad4e65435

Parent b329d0932b39

by Steve Borho

Changes to one file · Browse files at d0aad4e65435 Showing diff from parent b329d0932b39 Diff from another changeset...

 
124
125
126
 
127
128
129
 
137
138
139
 
140
141
142
143
 
144
145
146
 
155
156
157
158
159
 
 
 
160
161
162
 
124
125
126
127
128
129
130
 
138
139
140
141
142
143
144
145
146
147
148
149
 
158
159
160
 
 
161
162
163
164
165
166
@@ -124,6 +124,7 @@
    self._branchCombo = QComboBox()   self._branchCombo.currentIndexChanged.connect(self._emitBranchChanged) + self._branchReloading = False     self.addWidget(self._branchLabel)   self.addWidget(self._branchCombo) @@ -137,10 +138,12 @@
  else:   branches = self._repo.namedbranches   + self._branchReloading = True   self._branchCombo.clear()   self._branchCombo.addItems([''] + branches)   self._branchLabel.setEnabled(len(branches) > 1)   self._branchCombo.setEnabled(len(branches) > 1) + self._branchReloading = False     self.setBranch(curbranch)   @@ -155,8 +158,9 @@
    @pyqtSlot()   def _emitBranchChanged(self): - self.branchChanged.emit(self.branch(), - self._allparAction.isChecked()) + if not self._branchReloading: + self.branchChanged.emit(self.branch(), + self._allparAction.isChecked())     @pyqtSlot()   def refresh(self):