eric6/Plugins/DocumentationPlugins/Ericapi/EricapiConfigDialog.py

changeset 8143
2c730d5fd177
parent 7923
91e843545d9a
child 8218
7c09585bd960
equal deleted inserted replaced
8141:27f636beebad 8143:2c730d5fd177
44 "API files (*.api);;All files (*)")) 44 "API files (*.api);;All files (*)"))
45 45
46 self.ignoreDirPicker.setMode(E5PathPickerModes.DirectoryMode) 46 self.ignoreDirPicker.setMode(E5PathPickerModes.DirectoryMode)
47 self.ignoreDirPicker.setDefaultDirectory(project.getProjectPath()) 47 self.ignoreDirPicker.setDefaultDirectory(project.getProjectPath())
48 48
49 self.buttonBox.button(QDialogButtonBox.Ok).setEnabled(False) 49 self.buttonBox.button(
50 QDialogButtonBox.StandardButton.Ok).setEnabled(False)
50 for language in sorted( 51 for language in sorted(
51 DocumentationTools.supportedExtensionsDictForApis.keys()): 52 DocumentationTools.supportedExtensionsDictForApis.keys()):
52 self.languagesList.addItem(language) 53 self.languagesList.addItem(language)
53 54
54 self.ppath = project.getProjectPath() 55 self.ppath = project.getProjectPath()
80 for language in self.parameters['languages']: 81 for language in self.parameters['languages']:
81 if language == "Python": 82 if language == "Python":
82 # convert Python to the more specific Python3 83 # convert Python to the more specific Python3
83 language = "Python3" 84 language = "Python3"
84 items = self.languagesList.findItems( 85 items = self.languagesList.findItems(
85 language, Qt.MatchFlags(Qt.MatchExactly)) 86 language, Qt.MatchFlags(Qt.MatchFlag.MatchExactly))
86 items and items[0].setSelected(True) 87 items and items[0].setSelected(True)
87 88
88 def __initializeDefaults(self): 89 def __initializeDefaults(self):
89 """ 90 """
90 Private method to set the default values. 91 Private method to set the default values.
213 """ 214 """
214 Private slot to enable/disable the "OK" button. 215 Private slot to enable/disable the "OK" button.
215 216
216 @param filename name of the file (string) 217 @param filename name of the file (string)
217 """ 218 """
218 self.buttonBox.button(QDialogButtonBox.Ok).setEnabled(filename != "") 219 self.buttonBox.button(
220 QDialogButtonBox.StandardButton.Ok).setEnabled(filename != "")
219 221
220 @pyqtSlot(str) 222 @pyqtSlot(str)
221 def on_ignoreDirPicker_pathSelected(self, path): 223 def on_ignoreDirPicker_pathSelected(self, path):
222 """ 224 """
223 Private slot handling the selection of a directory to be ignored. 225 Private slot handling the selection of a directory to be ignored.

eric ide

mercurial