mirror of
https://github.com/onionshare/onionshare.git
synced 2025-05-17 13:50:28 -04:00
Fix logic that checks if auto-start timer setting is enabled, so that it checks real settings and not widget instantiation. Ensure the auto-start and auto-stop widgets show their datetime widget on start-up if the setting was already enabled.
This commit is contained in:
parent
1c424500f0
commit
a7856d5dcb
4 changed files with 15 additions and 21 deletions
|
@ -269,7 +269,7 @@ class ServerStatus(QtWidgets.QWidget):
|
|||
self.common.gui.css["server_status_button_working"]
|
||||
)
|
||||
self.server_button.setEnabled(True)
|
||||
if self.autostart_timer_datetime:
|
||||
if self.settings.get("general", "autostart_timer"):
|
||||
self.server_button.setToolTip(
|
||||
strings._("gui_start_server_autostart_timer_tooltip").format(
|
||||
self.mode_settings_widget.autostart_timer_widget.dateTime().toString(
|
||||
|
@ -279,15 +279,6 @@ class ServerStatus(QtWidgets.QWidget):
|
|||
)
|
||||
else:
|
||||
self.server_button.setText(strings._("gui_please_wait"))
|
||||
|
||||
if self.settings.get("general", "autostart_timer"):
|
||||
self.server_button.setToolTip(
|
||||
strings._("gui_start_server_autostart_timer_tooltip").format(
|
||||
self.mode_settings_widget.autostart_timer_widget.dateTime().toString(
|
||||
"h:mm AP, MMMM dd, yyyy"
|
||||
)
|
||||
)
|
||||
)
|
||||
else:
|
||||
self.server_button.setStyleSheet(
|
||||
self.common.gui.css["server_status_button_working"]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue