mirror of
https://github.com/qgis/QGIS.git
synced 2025-12-15 00:07:25 -05:00
parent
f8f25289d3
commit
8884c37b6f
@ -71,6 +71,7 @@ class ScriptAlgorithm(GeoAlgorithm):
|
||||
GeoAlgorithm.__init__(self)
|
||||
self.script = script
|
||||
self.allowEdit = True
|
||||
self.noCRSWarning = False
|
||||
self.descriptionFile = descriptionFile
|
||||
if script is not None:
|
||||
self.defineCharacteristicsFromScript()
|
||||
@ -120,6 +121,12 @@ class ScriptAlgorithm(GeoAlgorithm):
|
||||
except:
|
||||
pass
|
||||
|
||||
def checkInputCRS(self):
|
||||
if self.noCRSWarning:
|
||||
return True
|
||||
else:
|
||||
return GeoAlgorithm.checkInputCRS(self)
|
||||
|
||||
def createDescriptiveName(self, s):
|
||||
return s.replace('_', ' ')
|
||||
|
||||
@ -137,6 +144,9 @@ class ScriptAlgorithm(GeoAlgorithm):
|
||||
if line == "nomodeler":
|
||||
self.showInModeler = False
|
||||
return
|
||||
if line == "nocrswarning":
|
||||
self.noCRSWarning = True
|
||||
return
|
||||
tokens = line.split('=', 1)
|
||||
desc = self.createDescriptiveName(tokens[0])
|
||||
if tokens[1].lower().strip() == 'group':
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user