Skip to content

Commit

Permalink
Merge pull request #86 from QGEP/2022-11_fix-logs-next-file
Browse files Browse the repository at this point in the history
fix #82: save logs next to file checkbox not reliable
  • Loading branch information
olivierdalang committed Nov 29, 2022
2 parents 7ceea60 + 595c75e commit c749775
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions qgepqwat2ili/gui/gui_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,7 @@ def __init__(self, parent):

# Remember save next to file checkbox
s = QgsSettings().value("qgep_plugin/logs_next_to_file", False)
self.logs_next_to_file = s == True or s == "true"
self.save_logs_next_to_file_checkbox.setChecked(self.logs_next_to_file)
self.save_logs_next_to_file_checkbox.setChecked(s == True or s == "true")

# Populate the labels list (restoring checked states of scaes)
selected_scales = QgsSettings().value("qgep_plugin/last_selected_scales", "").split(",")
Expand All @@ -53,7 +52,6 @@ def __init__(self, parent):

def on_finish(self):
# Remember save next to file checkbox
self.logs_next_to_file = self.save_logs_next_to_file_checkbox.isChecked()
QgsSettings().setValue("qgep_plugin/logs_next_to_file", self.logs_next_to_file)

# Save checked state of scales
Expand All @@ -64,6 +62,10 @@ def on_finish(self):
selected_scales.append(key)
QgsSettings().setValue("qgep_plugin/last_selected_scales", ",".join(selected_scales))

@property
def logs_next_to_file(self):
return self.save_logs_next_to_file_checkbox.isChecked()

@property
def selected_ids(self):
if self.limit_checkbox.isChecked():
Expand Down

0 comments on commit c749775

Please sign in to comment.