diff --git a/Linphone/data/image/power.svg b/Linphone/data/image/power.svg new file mode 100644 index 000000000..caf9f7361 --- /dev/null +++ b/Linphone/data/image/power.svg @@ -0,0 +1,3 @@ + + + diff --git a/Linphone/view/Page/Layout/Main/MainLayout.qml b/Linphone/view/Page/Layout/Main/MainLayout.qml index cd3a28a3e..86460555b 100644 --- a/Linphone/view/Page/Layout/Main/MainLayout.qml +++ b/Linphone/view/Page/Layout/Main/MainLayout.qml @@ -559,6 +559,30 @@ Item { KeyNavigation.up: visibleChildren.length != 0 ? settingsButtons.getPreviousItem(3) : null KeyNavigation.down: visibleChildren.length != 0 ? settingsButtons.getNextItem(3) : null } + IconLabelButton { + id: quitButton + Layout.preferredHeight: 32 * DefaultStyle.dp + Layout.fillWidth: true + focus: !accountButton.visible && !settingsButton.visible && visible + iconSize: 32 * DefaultStyle.dp + text: qsTr("Quitter Linphone") + iconSource: AppIcons.power + onClicked: { + settingsMenuButton.popup.close() + UtilsCpp.getMainWindow().showConfirmationLambdaPopup( + qsTr("Quitter Linphone ?"), + "", + function (confirmed) { + if (confirmed) { + console.info("Exiting App from Top Menu"); + Qt.quit() + } + } + ) + } + KeyNavigation.up: visibleChildren.length != 0 ? settingsButtons.getPreviousItem(4) : null + KeyNavigation.down: visibleChildren.length != 0 ? settingsButtons.getNextItem(4) : null + } Rectangle { Layout.fillWidth: true Layout.preferredHeight: 1 * DefaultStyle.dp diff --git a/Linphone/view/Style/AppIcons.qml b/Linphone/view/Style/AppIcons.qml index c6f52313d..1ec2cdbd9 100644 --- a/Linphone/view/Style/AppIcons.qml +++ b/Linphone/view/Style/AppIcons.qml @@ -117,4 +117,5 @@ QtObject { property string bellDnd: "image://internal/bell-dnd.svg" property string bellRinger: "image://internal/bell-ringer.svg" property string voicemail: "image://internal/voicemail.svg" + property string power: "image://internal/power.svg" }