mirror of
https://github.com/onionshare/onionshare.git
synced 2024-12-27 00:09:50 -05:00
Make systray exit action call OnionShareGui.close() instead of sys.exit(), to give OnionShare a chance to warn users of open servers, and to gracefully shut down
This commit is contained in:
parent
02216f246b
commit
65894e2e44
@ -149,7 +149,7 @@ class OnionShareGui(QtWidgets.QMainWindow):
|
||||
def _initSystemTray(self):
|
||||
menu = QtWidgets.QMenu()
|
||||
exitAction = menu.addAction(strings._('systray_menu_exit', True))
|
||||
exitAction.triggered.connect(sys.exit)
|
||||
exitAction.triggered.connect(self.close)
|
||||
|
||||
self.systemTray = QtWidgets.QSystemTrayIcon(self)
|
||||
self.systemTray.setIcon(QtGui.QIcon(common.get_resource_path('images/logo.png')))
|
||||
|
Loading…
Reference in New Issue
Block a user