32 @param vcs reference to the vcs object |
32 @param vcs reference to the vcs object |
33 @param parent parent widget (QWidget) |
33 @param parent parent widget (QWidget) |
34 """ |
34 """ |
35 super().__init__(parent, Qt.WindowFlags(Qt.Window)) |
35 super().__init__(parent, Qt.WindowFlags(Qt.Window)) |
36 self.setupUi(self) |
36 self.setupUi(self) |
|
37 |
|
38 if vcs.version < (2, 2): |
|
39 self.amendCheckBox.setEnabled(False) |
37 |
40 |
38 def showEvent(self, evt): |
41 def showEvent(self, evt): |
39 """ |
42 """ |
40 Public method called when the dialog is about to be shown. |
43 Public method called when the dialog is about to be shown. |
41 |
44 |
62 .value('Mercurial/CommitMessages', 20)) |
65 .value('Mercurial/CommitMessages', 20)) |
63 del self.recentCommitMessages[no:] |
66 del self.recentCommitMessages[no:] |
64 Preferences.Prefs.settings.setValue('Mercurial/Commits', |
67 Preferences.Prefs.settings.setValue('Mercurial/Commits', |
65 self.recentCommitMessages) |
68 self.recentCommitMessages) |
66 return msg |
69 return msg |
|
70 |
|
71 def amend(self): |
|
72 """ |
|
73 Public method to retrieve the state of the amend flag. |
|
74 |
|
75 @return state of the amend flag (boolean) |
|
76 """ |
|
77 return self.amendCheckBox.isChecked() |
67 |
78 |
68 def on_buttonBox_clicked(self, button): |
79 def on_buttonBox_clicked(self, button): |
69 """ |
80 """ |
70 Private slot called by a button of the button box clicked. |
81 Private slot called by a button of the button box clicked. |
71 |
82 |