From 89944947575ba7d08d5e30807a282bc00d73687a Mon Sep 17 00:00:00 2001 From: Johnny Sequeira Date: Tue, 16 Jul 2024 14:42:55 -0600 Subject: [PATCH] Moving the checkbox and text filter --- qfieldsync/gui/layers_config_widget.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/qfieldsync/gui/layers_config_widget.py b/qfieldsync/gui/layers_config_widget.py index 1a3c2738..bbf6e248 100644 --- a/qfieldsync/gui/layers_config_widget.py +++ b/qfieldsync/gui/layers_config_widget.py @@ -64,8 +64,9 @@ def __init__(self, project, use_cloud_actions, layer_sources, parent=None): self.textFilterBox = QLineEdit() self.textFilterBox.setPlaceholderText(self.tr("Filter layers...")) # Add to layout - self.gridLayout.addWidget(self.showVisibleLayersOnlyCheckbox) - self.gridLayout.addWidget(self.textFilterBox) + self.gridLayout.addWidget(self.showVisibleLayersOnlyCheckbox, 0, 1) + self.gridLayout.addWidget(self.textFilterBox, 0, 2) + self.gridLayout.addWidget(self.multipleToggleButton, 0, 3) # Add reload project actions self.showVisibleLayersOnlyCheckbox.stateChanged.connect(self.reloadProject) self.textFilterBox.textChanged.connect(self.reloadProject) @@ -179,8 +180,10 @@ def reloadProject(self): def on_current_index_changed(index, layer_source): self.set_layer_action(layer_source, cmb.itemData(index)) - cmb.currentIndexChanged.connect(on_current_index_changed) + def cmb_index_changed(index): + on_current_index_changed(index, layer_source) + cmb.currentIndexChanged.connect(cmb_index_changed) properties_btn = QPushButton() properties_btn.setText(self.tr("Properties")) properties_btn.clicked.connect(self.propertiesBtn_clicked(layer_source))