29 @param parent parent widget (QWidget) |
29 @param parent parent widget (QWidget) |
30 """ |
30 """ |
31 super(HgRevisionSelectionDialog, self).__init__(parent) |
31 super(HgRevisionSelectionDialog, self).__init__(parent) |
32 self.setupUi(self) |
32 self.setupUi(self) |
33 |
33 |
34 self.buttonBox.button(QDialogButtonBox.Ok).setEnabled(False) |
34 self.buttonBox.button( |
|
35 QDialogButtonBox.StandardButton.Ok).setEnabled(False) |
35 |
36 |
36 self.tagCombo.addItems(sorted(tagsList)) |
37 self.tagCombo.addItems(sorted(tagsList)) |
37 self.branchCombo.addItems(["default"] + sorted(branchesList)) |
38 self.branchCombo.addItems(["default"] + sorted(branchesList)) |
38 if bookmarksList is not None: |
39 if bookmarksList is not None: |
39 self.bookmarkCombo.addItems(sorted(bookmarksList)) |
40 self.bookmarkCombo.addItems(sorted(bookmarksList)) |
59 elif self.branchButton.isChecked(): |
60 elif self.branchButton.isChecked(): |
60 enabled = self.branchCombo.currentText() != "" |
61 enabled = self.branchCombo.currentText() != "" |
61 elif self.bookmarkButton.isChecked(): |
62 elif self.bookmarkButton.isChecked(): |
62 enabled = self.bookmarkCombo.currentText() != "" |
63 enabled = self.bookmarkCombo.currentText() != "" |
63 |
64 |
64 self.buttonBox.button(QDialogButtonBox.Ok).setEnabled(enabled) |
65 self.buttonBox.button( |
|
66 QDialogButtonBox.StandardButton.Ok).setEnabled(enabled) |
65 |
67 |
66 @pyqtSlot(bool) |
68 @pyqtSlot(bool) |
67 def on_idButton_toggled(self, checked): |
69 def on_idButton_toggled(self, checked): |
68 """ |
70 """ |
69 Private slot to handle changes of the ID select button. |
71 Private slot to handle changes of the ID select button. |