Fix: Windows flags and raise behaviour. Also fix OSX quit issues.

This commit is contained in:
Filippo Scognamiglio 2014-12-22 20:50:17 +01:00
parent 1ed4d271c7
commit 56d366116a
2 changed files with 16 additions and 2 deletions

View File

@ -9,6 +9,8 @@ Window{
width: 600
height: 400
modality: Qt.ApplicationModal
ColumnLayout{
anchors.fill: parent
anchors.margins: 15

View File

@ -68,12 +68,16 @@ ApplicationWindow{
id: quitAction
text: qsTr("Quit")
shortcut: "Ctrl+Shift+Q"
onTriggered: terminalWindow.close();
onTriggered: Qt.quit();
}
Action{
id: showsettingsAction
text: qsTr("Settings")
onTriggered: settingswindow.show();
onTriggered: {
settingswindow.show();
settingswindow.requestActivate();
settingswindow.raise();
}
}
Action{
id: copyAction
@ -102,6 +106,8 @@ ApplicationWindow{
text: qsTr("About")
onTriggered: {
aboutDialog.show();
aboutDialog.requestActivate();
aboutDialog.raise();
}
}
ApplicationSettings{
@ -134,4 +140,10 @@ ApplicationWindow{
}
}
Component.onCompleted: appSettings.handleFontChanged();
onClosing: {
// OSX Since we are currently supporting only one window
// quit the application when it is closed.
if (Qt.platform.os === "osx")
Qt.quit()
}
}