Improve system tray icon click behavior
- Middle click now closes Mirage - A normal click now toggle window visibility
This commit is contained in:
		| @@ -30,10 +30,12 @@ SystemTrayIcon { | ||||
|     tooltip: Qt.application.displayName | ||||
|     icon.source: `../../icons/${iconPack}/tray-icon.png` | ||||
|  | ||||
|     onActivated: | ||||
|         if (reason !== SystemTrayIcon.Context) | ||||
|             window.drawAttention() | ||||
|  | ||||
|     onActivated: { | ||||
|         if (reason === SystemTrayIcon.MiddleClick) | ||||
|             Qt.quit() | ||||
|         else if (reason !== SystemTrayIcon.Context) | ||||
|             window.visible ? window.hide() : window.drawAttention() | ||||
|     } | ||||
|  | ||||
|     menu: Menu { | ||||
|         MenuItem { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	