Plugins/VcsPlugins/vcsMercurial/QueuesExtension/HgQueuesListDialog.py

branch
Py2 comp.
changeset 2525
8b507a9a2d40
parent 2302
f29e9405c851
child 2791
a9577f248f04
equal deleted inserted replaced
2523:139f182b72f6 2525:8b507a9a2d40
4 # 4 #
5 5
6 """ 6 """
7 Module implementing a dialog to show a list of applied and unapplied patches. 7 Module implementing a dialog to show a list of applied and unapplied patches.
8 """ 8 """
9
10 from __future__ import unicode_literals # __IGNORE_WARNING__
11 try:
12 str = unicode
13 except (NameError):
14 pass
9 15
10 import os 16 import os
11 17
12 from PyQt4.QtCore import pyqtSlot, QProcess, Qt, QTimer, QCoreApplication 18 from PyQt4.QtCore import pyqtSlot, QProcess, Qt, QTimer, QCoreApplication
13 from PyQt4.QtGui import QDialog, QDialogButtonBox, QHeaderView, QTreeWidgetItem, \ 19 from PyQt4.QtGui import QDialog, QDialogButtonBox, QHeaderView, QTreeWidgetItem, \
29 Constructor 35 Constructor
30 36
31 @param vcs reference to the vcs object 37 @param vcs reference to the vcs object
32 @param parent parent widget (QWidget) 38 @param parent parent widget (QWidget)
33 """ 39 """
34 super().__init__(parent) 40 super(HgQueuesListDialog, self).__init__(parent)
35 self.setupUi(self) 41 self.setupUi(self)
36 42
37 self.buttonBox.button(QDialogButtonBox.Close).setEnabled(False) 43 self.buttonBox.button(QDialogButtonBox.Close).setEnabled(False)
38 self.buttonBox.button(QDialogButtonBox.Cancel).setDefault(True) 44 self.buttonBox.button(QDialogButtonBox.Cancel).setDefault(True)
39 45
429 """ 435 """
430 if self.intercept: 436 if self.intercept:
431 self.intercept = False 437 self.intercept = False
432 evt.accept() 438 evt.accept()
433 return 439 return
434 super().keyPressEvent(evt) 440 super(HgQueuesListDialog, self).keyPressEvent(evt)

eric ide

mercurial