mirror of
https://github.com/EDCD/EDMarketConnector.git
synced 2025-06-07 10:53:26 +03:00
EDMarketConnector.py: Guard platform specific func
Some callback functions are only used on windows, but defined for everyone, this causes mypy to fail in fun ways.
This commit is contained in:
parent
490bd9dbdd
commit
f94072a99e
@ -1617,6 +1617,7 @@ class AppWindow(object):
|
||||
monitor.system and
|
||||
tk.NORMAL or tk.DISABLED)
|
||||
|
||||
if sys.platform == 'win32':
|
||||
def ontop_changed(self, event=None) -> None:
|
||||
"""Set main window 'on top' state as appropriate."""
|
||||
config.set('always_ontop', self.always_ontop.get())
|
||||
@ -1760,6 +1761,7 @@ class AppWindow(object):
|
||||
with open(f, 'wb') as h:
|
||||
h.write(str(companion.session.capi_raw_data).encode(encoding='utf-8'))
|
||||
|
||||
if sys.platform == 'win32':
|
||||
def exit_tray(self, systray: 'SysTrayIcon') -> None:
|
||||
"""Tray icon is shutting down."""
|
||||
exit_thread = threading.Thread(
|
||||
|
Loading…
x
Reference in New Issue
Block a user