aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTim Jenssen <tim.jenssen@qt.io>2022-09-21 15:53:24 +0200
committerTim Jenssen <tim.jenssen@qt.io>2022-09-21 14:05:07 +0000
commit39e3ae033896d35119365f7a676eacd251817bba (patch)
tree0c4417d1fc6b8bf591e308374df7c155fbade7a4
parenta527ceff605bb73685ecbe5cedfddf31d8a8be85 (diff)
qds: add feature to Key_Escape the splashscreen
Change-Id: I815b15a9234e693518feb1ff6b218dc607bd3578 Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
-rw-r--r--src/plugins/studiowelcome/qml/splashscreen/main.qml8
-rw-r--r--src/plugins/studiowelcome/studiowelcomeplugin.cpp1
2 files changed, 9 insertions, 0 deletions
diff --git a/src/plugins/studiowelcome/qml/splashscreen/main.qml b/src/plugins/studiowelcome/qml/splashscreen/main.qml
index ee68681ab5..533c29a17a 100644
--- a/src/plugins/studiowelcome/qml/splashscreen/main.qml
+++ b/src/plugins/studiowelcome/qml/splashscreen/main.qml
@@ -27,6 +27,14 @@ import QtQuick 2.0
Item {
id: root
+
+ focus: true
+ Keys.onPressed: (event)=> {
+ if (event.key == Qt.Key_Escape)
+ root.doNotShowAgain = false
+ root.closeClicked()
+ }
+
width: 600 * root.mainScale
height: 720 * root.mainScale
diff --git a/src/plugins/studiowelcome/studiowelcomeplugin.cpp b/src/plugins/studiowelcome/studiowelcomeplugin.cpp
index b9df286c2a..584bab8bf0 100644
--- a/src/plugins/studiowelcome/studiowelcomeplugin.cpp
+++ b/src/plugins/studiowelcome/studiowelcomeplugin.cpp
@@ -576,6 +576,7 @@ void StudioWelcomePlugin::extensionsInitialized()
s_view->show();
s_view->raise();
+ s_view->setFocus();
});
}
}