Skip to content

Commit

Permalink
Fix resetting fields in Refactor Fields algorithm dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed May 21, 2020
1 parent 169ca65 commit 5cc0f09
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion python/plugins/processing/algs/qgis/ui/FieldsMappingPanel.py
Expand Up @@ -163,15 +163,17 @@ def on_downButton_clicked(self, checked=False):
def on_resetButton_clicked(self, checked=False):
"""Load fields from layer"""
if self.layer:
self.fieldsView.setDestinationFields(self.layer.fields())
self.fieldsView.setSourceFields(self.layer.fields())
self.fieldsView.setDestinationFields(self.layer.fields())

@pyqtSlot(bool, name='on_loadLayerFieldsButton_clicked')
def on_loadLayerFieldsButton_clicked(self, checked=False):
layer = self.layerCombo.currentLayer()
if layer is None:
return

self.fieldsView.setSourceFields(layer.fields())
self.fieldsView.setDestinationFields(layer.fields())


class FieldsMappingWidgetWrapper(WidgetWrapper):
Expand Down

0 comments on commit 5cc0f09

Please sign in to comment.