fix: minimize on close
This commit is contained in:
parent
b43122d7f3
commit
fd8a84eb9d
|
@ -34,6 +34,15 @@ Item {
|
|||
onClicked: fleetModal.open()
|
||||
}
|
||||
|
||||
StatusSettingsLineButton {
|
||||
text: qsTr("Minimize on close")
|
||||
isSwitch: true
|
||||
switchChecked: !appSettings.quitOnClose
|
||||
onClicked: function (checked) {
|
||||
appSettings.quitOnClose = !checked
|
||||
}
|
||||
}
|
||||
|
||||
Item {
|
||||
id: spacer1
|
||||
height: Style.current.bigPadding
|
||||
|
|
|
@ -102,6 +102,7 @@ RowLayout {
|
|||
property int fontSize: Constants.fontSizeM
|
||||
property bool hideSignPhraseModal: false
|
||||
property bool onlyShowContactsProfilePics: true
|
||||
property bool quitOnClose: true
|
||||
|
||||
// Browser settings
|
||||
property bool showBrowserSelector: true
|
||||
|
|
11
ui/main.qml
11
ui/main.qml
|
@ -74,8 +74,14 @@ ApplicationWindow {
|
|||
}
|
||||
|
||||
onClosing: {
|
||||
applicationWindow.visible = false;
|
||||
close.accepted = false;
|
||||
if(loader.sourceComponent == app){
|
||||
if(loader.item.appSettings.quitOnClose){
|
||||
Qt.quit();
|
||||
} else {
|
||||
applicationWindow.visible = false;
|
||||
close.accepted = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Component.onCompleted: {
|
||||
|
@ -234,6 +240,7 @@ ApplicationWindow {
|
|||
Loader {
|
||||
id: loader
|
||||
anchors.fill: parent
|
||||
property var appSettings
|
||||
}
|
||||
|
||||
Component {
|
||||
|
|
Loading…
Reference in New Issue