eric6/VirtualEnv/VirtualenvNameDialog.py

changeset 8143
2c730d5fd177
parent 7923
91e843545d9a
child 8218
7c09585bd960
--- a/eric6/VirtualEnv/VirtualenvNameDialog.py	Mon Mar 01 17:48:43 2021 +0100
+++ b/eric6/VirtualEnv/VirtualenvNameDialog.py	Tue Mar 02 17:17:09 2021 +0100
@@ -36,7 +36,7 @@
         self.envsList.addItems(environments)
         self.nameEdit.setText(currentName)
         
-        self.nameEdit.setFocus(Qt.OtherFocusReason)
+        self.nameEdit.setFocus(Qt.FocusReason.OtherFocusReason)
         self.nameEdit.selectAll()
     
     @pyqtSlot(str)
@@ -47,8 +47,8 @@
         @param txt contens of the name edit
         @type str
         """
-        items = self.envsList.findItems(txt, Qt.MatchExactly)
-        self.buttonBox.button(QDialogButtonBox.Ok).setEnabled(
+        items = self.envsList.findItems(txt, Qt.MatchFlag.MatchExactly)
+        self.buttonBox.button(QDialogButtonBox.StandardButton.Ok).setEnabled(
             bool(txt) and len(items) == 0)
     
     def getName(self):

eric ide

mercurial