Skip to content
Permalink
Browse files

[processing] Fix fieldmapper dialog init method

  • Loading branch information
arnaud-morvan committed Oct 27, 2016
1 parent 8c7ca62 commit 925964b2429b908b169f372cf72dafbc51014111
Showing with 8 additions and 2 deletions.
  1. +8 −2 python/plugins/processing/algs/qgis/ui/FieldsMapperDialogs.py
@@ -26,6 +26,8 @@
__revision__ = '$Format:%H$'


from qgis.core import QgsMapLayerRegistry

from qgis.PyQt.QtWidgets import QComboBox, QSpacerItem

from processing.core.parameters import ParameterVector
@@ -93,12 +95,16 @@ def somethingDependsOnThisParameter(self, parent):
class FieldsMapperParametersDialog(AlgorithmDialog):

def __init__(self, alg):
AlgorithmDialogBase.__init__(self, alg)
AlgorithmDialog.__init__(self, alg)

self.alg = alg
QgsMapLayerRegistry.instance().layerWasAdded.disconnect(self.mainWidget.layerAdded)
QgsMapLayerRegistry.instance().layersWillBeRemoved.disconnect(self.mainWidget.layersWillBeRemoved)
self.tabWidget.widget(0).layout().removeWidget(self.mainWidget)

self.mainWidget = FieldsMapperParametersPanel(self, alg)
self.setMainWidget()
QgsMapLayerRegistry.instance().layerWasAdded.connect(self.mainWidget.layerAdded)
QgsMapLayerRegistry.instance().layersWillBeRemoved.connect(self.mainWidget.layersWillBeRemoved)

def setParamValue(self, param, widget, alg=None):
if isinstance(param, ParameterFieldsMapping):

0 comments on commit 925964b

Please sign in to comment.
You can’t perform that action at this time.