src/eric7/Plugins/VcsPlugins/vcsMercurial/GpgExtension/HgGpgSignDialog.py

branch
eric7
changeset 9221
bf71ee032bb4
parent 9209
b99e7fd55fd3
child 9413
80c06d472826
--- a/src/eric7/Plugins/VcsPlugins/vcsMercurial/GpgExtension/HgGpgSignDialog.py	Wed Jul 13 11:16:20 2022 +0200
+++ b/src/eric7/Plugins/VcsPlugins/vcsMercurial/GpgExtension/HgGpgSignDialog.py	Wed Jul 13 14:55:47 2022 +0200
@@ -19,11 +19,11 @@
     """
     Class implementing a dialog to enter data for signing a revision.
     """
-    def __init__(self, tagsList, branchesList, bookmarksList=None,
-                 parent=None):
+
+    def __init__(self, tagsList, branchesList, bookmarksList=None, parent=None):
         """
         Constructor
-        
+
         @param tagsList list of tags
         @type list of str
         @param branchesList list of branches
@@ -35,16 +35,14 @@
         """
         super().__init__(parent)
         self.setupUi(self)
-        
-        self.buttonBox.button(
-            QDialogButtonBox.StandardButton.Ok).setEnabled(False)
-        
+
+        self.buttonBox.button(QDialogButtonBox.StandardButton.Ok).setEnabled(False)
+
         project = ericApp().getObject("Project")
         pwl, pel = project.getProjectDictionaries()
         language = project.getProjectSpellLanguage()
-        self.messageEdit.setLanguageWithPWL(
-            language, pwl or None, pel or None)
-        
+        self.messageEdit.setLanguageWithPWL(language, pwl or None, pel or None)
+
         self.tagCombo.addItems(sorted(tagsList))
         self.branchCombo.addItems(["default"] + sorted(branchesList))
         if bookmarksList is not None:
@@ -52,21 +50,21 @@
         else:
             self.bookmarkButton.setHidden(True)
             self.bookmarkCombo.setHidden(True)
-        
+
         # connect various radio buttons and input fields
         self.idButton.toggled.connect(self.__updateOK)
         self.tagButton.toggled.connect(self.__updateOK)
         self.branchButton.toggled.connect(self.__updateOK)
         self.bookmarkButton.toggled.connect(self.__updateOK)
         self.expressionButton.toggled.connect(self.__updateOK)
-        
+
         self.idEdit.textChanged.connect(self.__updateOK)
         self.expressionEdit.textChanged.connect(self.__updateOK)
-        
+
         self.tagCombo.editTextChanged.connect(self.__updateOK)
         self.branchCombo.editTextChanged.connect(self.__updateOK)
         self.bookmarkCombo.editTextChanged.connect(self.__updateOK)
-    
+
     @pyqtSlot()
     def __updateOK(self):
         """
@@ -83,14 +81,13 @@
             enabled = enabled and self.bookmarkCombo.currentText() != ""
         elif self.expressionButton.isChecked():
             enabled = enabled and bool(self.expressionEdit.text())
-        
-        self.buttonBox.button(
-            QDialogButtonBox.StandardButton.Ok).setEnabled(enabled)
-    
+
+        self.buttonBox.button(QDialogButtonBox.StandardButton.Ok).setEnabled(enabled)
+
     def getData(self):
         """
         Public method to retrieve the entered data.
-        
+
         @return tuple giving the revision, a flag indicating not to commit
             the signature, a commit message, an ID of the key to be used,
             a flag indicating a local signature and a flag indicating a forced
@@ -111,12 +108,12 @@
             rev = self.expressionEdit.text()
         else:
             rev = ""
-        
+
         return (
             rev,
             self.nocommitCheckBox.isChecked(),
             self.messageEdit.toPlainText(),
             self.keyEdit.text(),
             self.localCheckBox.isChecked(),
-            self.forceCheckBox.isChecked()
+            self.forceCheckBox.isChecked(),
         )

eric ide

mercurial