Skip to content

Commit 3f7b182

Browse files
committed
[processing] correctly handle multiple vector layers
1 parent ffd2f26 commit 3f7b182

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

python/plugins/processing/gui/AlgorithmDialog.py

+4-2
Original file line numberDiff line numberDiff line change
@@ -123,10 +123,12 @@ def setParamValue(self, param, widget, alg=None):
123123
if param.datatype == ParameterMultipleInput.TYPE_FILE:
124124
return param.setValue(widget.selectedoptions)
125125
else:
126-
if param.datatype == ParameterMultipleInput.TYPE_VECTOR_ANY:
126+
if param.datatype == ParameterMultipleInput.TYPE_RASTER:
127+
options = dataobjects.getRasterLayers(sorting=False)
128+
elif param.datatype == ParameterMultipleInput.TYPE_VECTOR_ANY:
127129
options = dataobjects.getVectorLayers(sorting=False)
128130
else:
129-
options = dataobjects.getRasterLayers(sorting=False)
131+
options = dataobjects.getVectorLayers([param.datatype], sorting=False)
130132
return param.setValue([options[i] for i in widget.selectedoptions])
131133
elif isinstance(param, (ParameterNumber, ParameterFile, ParameterCrs,
132134
ParameterExtent)):

0 commit comments

Comments
 (0)