diff options
author | jerous <jerous@gmail.com> | 2008-10-16 00:02:54 +0200 |
---|---|---|
committer | jerous <jerous@gmail.com> | 2008-10-16 00:02:54 +0200 |
commit | ca15ecdf6db1c35a9f3d093e985d1544045b9906 (patch) | |
tree | 64884b9dad463f487bf8e7cddbbf46ca8aa188bc /plugins | |
parent | bd543fb9c6683f72019fca66463f033ecb7dff5f (diff) |
Systray: left click shows/hides main, middle button toggles playstate, right click skips song
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/Systray.py | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/plugins/Systray.py b/plugins/Systray.py index 36758fc..a708e80 100644 --- a/plugins/Systray.py +++ b/plugins/Systray.py @@ -20,4 +20,15 @@ class pluginSystray(Plugin): return "Display the montypc icon in the systray." def onSysTrayClick(self, reason): - self.getWinMain().setVisible(not(self.getWinMain().isVisible())) + if reason==3: + # left mouse button + self.getWinMain().setVisible(not(self.getWinMain().isVisible())) + elif reason==1: + # right mouse button + monty.next() + elif reason==4: + # middle mouse button + if monty.isPlaying(): + monty.pause() + else: + monty.resume() |