Skip to content

Commit

Permalink
fix: systray icon retry timeout text (#2)
Browse files Browse the repository at this point in the history
  • Loading branch information
ugurcandede authored Oct 29, 2024
1 parent 7a0deff commit 83b72ed
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def get_battery(self):
self.update_systray_icon(None, "USB dongle is connected, but no mouse found", menu=Menu(
MenuItem(device_name, lambda: None, enabled=False),
MenuItem("USB dongle is connected, but no mouse found", lambda: None, enabled=False),
MenuItem(f"Please wait; retrying in {REFRESH_TIMEOUT} seconds", lambda: None, enabled=False),
MenuItem(f"Please wait; retrying in {ERROR_RETRY_TIMEOUT} seconds", lambda: None, enabled=False),
MenuItem('Quit', self.quit_app)
))
time.sleep(1 / 20)
Expand All @@ -59,7 +59,7 @@ def get_battery(self):
self.event.wait(timeout=sleep_time)

except Exception as e:
print(f"Error: {e}\n\n{time.strftime('%H:%M:%S')} | Sleeping for {REFRESH_TIMEOUT} seconds...")
print(f"Error: {e}\n\n{time.strftime('%H:%M:%S')} | Sleeping for {ERROR_RETRY_TIMEOUT} seconds...")
time.sleep(ERROR_RETRY_TIMEOUT)
self.event.set()

Expand Down

0 comments on commit 83b72ed

Please sign in to comment.