136 |
138 |
137 self.cancelled = False |
139 self.cancelled = False |
138 self.buttonBox.button(QDialogButtonBox.Close).setEnabled(False) |
140 self.buttonBox.button(QDialogButtonBox.Close).setEnabled(False) |
139 self.buttonBox.button(QDialogButtonBox.Cancel).setEnabled(True) |
141 self.buttonBox.button(QDialogButtonBox.Cancel).setEnabled(True) |
140 self.buttonBox.button(QDialogButtonBox.Cancel).setDefault(True) |
142 self.buttonBox.button(QDialogButtonBox.Cancel).setDefault(True) |
|
143 self.checkProgress.setVisible(True) |
141 QApplication.processEvents() |
144 QApplication.processEvents() |
142 |
145 |
143 self.__clearErrors() |
146 self.__clearErrors() |
144 |
147 |
145 if isinstance(fn, list): |
148 if isinstance(fn, list): |
163 |
166 |
164 if (codestring and len(py3files) == 1) or \ |
167 if (codestring and len(py3files) == 1) or \ |
165 (codestring and len(py2files) == 1) or \ |
168 (codestring and len(py2files) == 1) or \ |
166 (not codestring and len(py3files) + len(py2files) > 0): |
169 (not codestring and len(py3files) + len(py2files) > 0): |
167 self.checkProgress.setMaximum(len(py3files) + len(py2files)) |
170 self.checkProgress.setMaximum(len(py3files) + len(py2files)) |
|
171 self.checkProgressLabel.setVisible( |
|
172 len(py3files) + len(py2files) > 1) |
168 QApplication.processEvents() |
173 QApplication.processEvents() |
169 |
174 |
170 ignoreStarImportWarnings = \ |
175 ignoreStarImportWarnings = \ |
171 Preferences.getFlakes("IgnoreStarImportWarnings") |
176 Preferences.getFlakes("IgnoreStarImportWarnings") |
172 |
177 |
285 else: |
290 else: |
286 self.showButton.setEnabled(True) |
291 self.showButton.setEnabled(True) |
287 self.resultList.header().resizeSections(QHeaderView.ResizeToContents) |
292 self.resultList.header().resizeSections(QHeaderView.ResizeToContents) |
288 self.resultList.header().setStretchLastSection(True) |
293 self.resultList.header().setStretchLastSection(True) |
289 |
294 |
|
295 self.checkProgress.setVisible(False) |
|
296 |
290 def on_buttonBox_clicked(self, button): |
297 def on_buttonBox_clicked(self, button): |
291 """ |
298 """ |
292 Private slot called by a button of the button box clicked. |
299 Private slot called by a button of the button box clicked. |
293 |
300 |
294 @param button button that was clicked (QAbstractButton) |
301 @param button button that was clicked (QAbstractButton) |