Adding OK button, bugfixes

This commit is contained in:
2024-01-16 11:46:36 +01:00
parent 506bb45dda
commit c04ec20704
5 changed files with 30 additions and 6 deletions

View File

@@ -622,6 +622,15 @@ class Preferences:
subprocess.Popen(["xdg-open", "https://github.com/TobiZog/cinnamon-dynamic-wallpaper/issues/new"])
def on_ok(self, *args):
""" Callback for the OK button in the top bar
"""
self.on_apply()
# Close the window
self.on_destroy()
def on_apply(self, *args):
""" Callback for the Apply button in the top bar
"""
@@ -632,9 +641,6 @@ class Preferences:
loop = Loop()
loop.exchange_image()
# Close the window
self.on_destroy()
if __name__ == "__main__":
Preferences().show()