mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-15 00:04:00 -04:00
[processing] restore script collection creator (fix #17649)
This commit is contained in:
parent
3b8905209e
commit
d58053d486
@ -40,6 +40,7 @@ initTemplate = '''from .plugin import ProcessingScriptCollectionPlugin
|
||||
def classFactory(iface):
|
||||
return ProcessingScriptCollectionPlugin()
|
||||
'''
|
||||
|
||||
metadataTemplate = '''[general]
|
||||
name=$name$
|
||||
description=$description$
|
||||
|
@ -59,7 +59,7 @@ class ScriptSelector(BASE, WIDGET):
|
||||
scriptItem.setFlags(scriptItem.flags() | Qt.ItemIsUserCheckable)
|
||||
scriptItem.setCheckState(0, Qt.Checked)
|
||||
scriptItem.script = script
|
||||
scriptItem.setText(0, script.name)
|
||||
scriptItem.setText(0, script.name())
|
||||
groupItem.addChild(scriptItem)
|
||||
self.scriptsTree.addTopLevelItem(groupItem)
|
||||
|
||||
@ -74,7 +74,7 @@ class ScriptSelector(BASE, WIDGET):
|
||||
self.buttonBox.rejected.connect(self.cancelPressed)
|
||||
|
||||
def selectFolder(self):
|
||||
folder = QFileDialog.getExistingDirectory(self, 'Select folder')
|
||||
folder = QFileDialog.getExistingDirectory(self, "Select folder")
|
||||
if folder:
|
||||
self.folderBox.setText(folder)
|
||||
|
||||
@ -95,7 +95,7 @@ class ScriptSelector(BASE, WIDGET):
|
||||
if value:
|
||||
return value
|
||||
textBox.setStyleSheet("QLineEdit{background: yellow}")
|
||||
raise Exception("wrong parameter value")
|
||||
raise Exception("Wrong parameter value")
|
||||
|
||||
def okPressed(self):
|
||||
self.scripts = []
|
||||
@ -113,4 +113,5 @@ class ScriptSelector(BASE, WIDGET):
|
||||
self.email = self._getValue(self.emailBox)
|
||||
except:
|
||||
return
|
||||
|
||||
self.close()
|
||||
|
Loading…
x
Reference in New Issue
Block a user