Skip to content
Snippets Groups Projects
Commit 25c0703f authored by inso's avatar inso
Browse files

Add exit menu

parent 5136291b
No related branches found
No related tags found
No related merge requests found
......@@ -79,6 +79,7 @@ class MainWindowController(QObject):
toolbar.view.button_network.clicked.connect(navigation.open_network_view)
toolbar.view.button_identity.clicked.connect(navigation.open_identities_view)
toolbar.view.button_explore.clicked.connect(navigation.open_wot_view)
toolbar.exit_triggered.connect(main_window.view.close)
#app.version_requested.connect(main_window.latest_version_requested)
#app.account_imported.connect(main_window.import_account_accepted)
#app.account_changed.connect(main_window.change_account)
......
from PyQt5.QtCore import QObject
from PyQt5.QtCore import QObject, pyqtSignal
from PyQt5.QtWidgets import QDialog
from sakia.gui.dialogs.connection_cfg.controller import ConnectionConfigController
from sakia.gui.dialogs.revocation.controller import RevocationController
......@@ -16,6 +16,8 @@ class ToolbarController(QObject):
The navigation panel
"""
exit_triggered = pyqtSignal()
def __init__(self, view, model):
"""
:param sakia.gui.component.controller.ComponentController parent: the parent
......@@ -34,6 +36,7 @@ class ToolbarController(QObject):
self.view.action_about_referentials.triggered.connect(self.open_about_referentials_dialog)
self.view.action_revoke_uid.triggered.connect(self.open_revocation_dialog)
self.view.button_contacts.clicked.connect(self.open_contacts_dialog)
self.view.action_exit.triggered.connect(self.exit_triggered)
@classmethod
def create(cls, app, navigation):
......
......@@ -46,6 +46,9 @@ class ToolbarView(QFrame, Ui_SakiaToolbar):
self.action_about = QAction(self.tr("About Sakia"), tool_menu)
tool_menu.addAction(self.action_about)
self.action_exit = QAction(self.tr("Exit"), tool_menu)
tool_menu.addAction(self.action_exit)
self.setSizePolicy(QSizePolicy.Maximum, QSizePolicy.Minimum)
self.setMaximumHeight(60)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment