Skip to content

Commit

Permalink
Adding regular function instead of Lambda function
Browse files Browse the repository at this point in the history
  • Loading branch information
SeqLaz committed Jul 16, 2024
1 parent f1edc7b commit be833ad
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions qfieldsync/gui/layers_config_widget.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ def reloadProject(self):
if show_visible_only and not layer_visible:
continue

if text_filter and text_filter not in layer_name:
if filter_text and filter_text not in layer_name:
continue

count = self.layersTable.rowCount()
Expand All @@ -176,11 +176,10 @@ def reloadProject(self):
)

# Save the current action for the layer
cmb.currentIndexChanged.connect(
lambda index, l_source=layer_source: self.set_layer_action(
l_source, cmb.itemData(index)
)
)
def on_current_index_changed(index, layer_source):
self.set_layer_action(layer_source, cmb.itemData(index))

cmb.currentIndexChanged.connect(on_current_index_changed)

properties_btn = QPushButton()
properties_btn.setText(self.tr("Properties"))
Expand Down

0 comments on commit be833ad

Please sign in to comment.