Skip to content

Commit

Permalink
Moving the checkbox and text filter
Browse files Browse the repository at this point in the history
  • Loading branch information
SeqLaz committed Jul 16, 2024
1 parent be833ad commit 8994494
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions qfieldsync/gui/layers_config_widget.py
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down Expand Up @@ -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))
Expand Down

0 comments on commit 8994494

Please sign in to comment.