Plugins/VcsPlugins/vcsSubversion/SvnDiffDialog.py

branch
Py2 comp.
changeset 2525
8b507a9a2d40
parent 2302
f29e9405c851
child 2677
3d4277929fb3
equal deleted inserted replaced
2523:139f182b72f6 2525:8b507a9a2d40
4 # 4 #
5 5
6 """ 6 """
7 Module implementing a dialog to show the output of the svn diff command process. 7 Module implementing a dialog to show the output of the svn diff command process.
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 QTimer, QFileInfo, QProcess, pyqtSlot, Qt 18 from PyQt4.QtCore import QTimer, QFileInfo, QProcess, pyqtSlot, Qt
13 from PyQt4.QtGui import QWidget, QColor, QLineEdit, QBrush, QTextCursor, QDialogButtonBox 19 from PyQt4.QtGui import QWidget, QColor, QLineEdit, QBrush, QTextCursor, QDialogButtonBox
30 Constructor 36 Constructor
31 37
32 @param vcs reference to the vcs object 38 @param vcs reference to the vcs object
33 @param parent parent widget (QWidget) 39 @param parent parent widget (QWidget)
34 """ 40 """
35 super().__init__(parent) 41 super(SvnDiffDialog, self).__init__(parent)
36 self.setupUi(self) 42 self.setupUi(self)
37 43
38 self.buttonBox.button(QDialogButtonBox.Save).setEnabled(False) 44 self.buttonBox.button(QDialogButtonBox.Save).setEnabled(False)
39 self.buttonBox.button(QDialogButtonBox.Close).setDefault(True) 45 self.buttonBox.button(QDialogButtonBox.Close).setDefault(True)
40 46
438 """ 444 """
439 if self.intercept: 445 if self.intercept:
440 self.intercept = False 446 self.intercept = False
441 evt.accept() 447 evt.accept()
442 return 448 return
443 super().keyPressEvent(evt) 449 super(SvnDiffDialog, self).keyPressEvent(evt)

eric ide

mercurial