Use run_in_executor for the tray icon thread

This commit is contained in:
DevilXD authored and DevilXD committed 2023-06-11 16:58:18 +02:00
1 parent 489c45af11
commit 7a07e1a9e4
1 file changed
+2 -1
+2 -1
View File
@@ -1079,7 +1079,8 @@ class TrayIcon:
pystray.MenuItem(_("gui", "tray", "quit"), bridge(self.quit)),
)
self.icon = pystray.Icon("twitch_miner", self.icon_image, self.get_title(drop), menu)
self.icon.run_detached()
# self.icon.run_detached()
loop.run_in_executor(None, self.icon.run)
def stop(self):
if self.icon is not None: