summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-04-19 01:00:04 +0200
committerQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2019-04-19 01:00:04 +0200
commit53bd6b8111eb0d7f23b3b0ca95bef4735f7a952c (patch)
treef4b1407fa828e4d6ac608dbef97b4b9f3203a7cc /tools
parent2bdbf216fe7b6cf9d404b80ac405bd3969f5c07f (diff)
parentc018df5b4075ae962966d4df7653d476dab02840 (diff)
Merge remote-tracking branch 'origin/5.12' into 5.13
Diffstat (limited to 'tools')
-rw-r--r--tools/qml/main.cpp7
-rw-r--r--tools/qml/qml.icnsbin196156 -> 0 bytes
-rw-r--r--tools/qml/qml.pro10
-rw-r--r--tools/qml/qml.qrc1
-rw-r--r--tools/qml/resources/Info.plist (renamed from tools/qml/Info.plist)0
-rw-r--r--tools/qml/resources/qml-64.pngbin0 -> 2304 bytes
-rw-r--r--tools/qml/resources/qml.icnsbin0 -> 194026 bytes
-rw-r--r--tools/qml/resources/qml.icobin0 -> 124455 bytes
-rw-r--r--tools/qmlscene/main.cpp6
9 files changed, 18 insertions, 6 deletions
diff --git a/tools/qml/main.cpp b/tools/qml/main.cpp
index 166c6aabdf..8cfc0eaaac 100644
--- a/tools/qml/main.cpp
+++ b/tools/qml/main.cpp
@@ -78,6 +78,7 @@ static QQmlApplicationEngine *qae = nullptr;
static int exitTimerId = -1;
#endif
bool verboseMode = false;
+static const QString iconResourcePath(QStringLiteral(":/qt-project.org/QmlRuntime/resources/qml-64.png"));
static void loadConf(const QString &override, bool quiet) // Terminates app on failure
{
@@ -135,7 +136,10 @@ void noFilesGiven();
class LoaderApplication : public QGuiApplication
{
public:
- LoaderApplication(int& argc, char **argv) : QGuiApplication(argc, argv) {}
+ LoaderApplication(int& argc, char **argv) : QGuiApplication(argc, argv)
+ {
+ setWindowIcon(QIcon(iconResourcePath));
+ }
bool event(QEvent *ev) override
{
@@ -448,6 +452,7 @@ int main(int argc, char *argv[])
#ifdef QT_WIDGETS_LIB
case QmlApplicationTypeWidget:
app = new QApplication(argc, argv);
+ static_cast<QApplication *>(app)->setWindowIcon(QIcon(iconResourcePath));
break;
#endif // QT_WIDGETS_LIB
#endif // QT_GUI_LIB
diff --git a/tools/qml/qml.icns b/tools/qml/qml.icns
deleted file mode 100644
index c76051626a..0000000000
--- a/tools/qml/qml.icns
+++ /dev/null
Binary files differ
diff --git a/tools/qml/qml.pro b/tools/qml/qml.pro
index 3f41707275..f086b7bff9 100644
--- a/tools/qml/qml.pro
+++ b/tools/qml/qml.pro
@@ -8,10 +8,14 @@ RESOURCES += qml.qrc
QMAKE_TARGET_DESCRIPTION = QML Runtime
+ICON = resources/qml64.png
+win32 {
+ RC_ICONS = resources/qml.ico
+}
mac {
- OTHER_FILES += Info.plist
- QMAKE_INFO_PLIST = Info.plist
- ICON = qml.icns
+ OTHER_FILES += resources/Info.plist
+ QMAKE_INFO_PLIST = resources/Info.plist
+ ICON = resources/qml.icns
}
qtConfig(qml-debug): DEFINES += QT_QML_DEBUG_NO_WARNING
diff --git a/tools/qml/qml.qrc b/tools/qml/qml.qrc
index 1f0ffdace2..e4be1793d4 100644
--- a/tools/qml/qml.qrc
+++ b/tools/qml/qml.qrc
@@ -2,5 +2,6 @@
<qresource prefix="qt-project.org/QmlRuntime">
<file>conf/configuration.qml</file>
<file>conf/qtquick.qml</file>
+ <file>resources/qml-64.png</file>
</qresource>
</RCC>
diff --git a/tools/qml/Info.plist b/tools/qml/resources/Info.plist
index 567c5bf8fd..567c5bf8fd 100644
--- a/tools/qml/Info.plist
+++ b/tools/qml/resources/Info.plist
diff --git a/tools/qml/resources/qml-64.png b/tools/qml/resources/qml-64.png
new file mode 100644
index 0000000000..83dbeab9af
--- /dev/null
+++ b/tools/qml/resources/qml-64.png
Binary files differ
diff --git a/tools/qml/resources/qml.icns b/tools/qml/resources/qml.icns
new file mode 100644
index 0000000000..b092ffd943
--- /dev/null
+++ b/tools/qml/resources/qml.icns
Binary files differ
diff --git a/tools/qml/resources/qml.ico b/tools/qml/resources/qml.ico
new file mode 100644
index 0000000000..09ec5ccece
--- /dev/null
+++ b/tools/qml/resources/qml.ico
Binary files differ
diff --git a/tools/qmlscene/main.cpp b/tools/qmlscene/main.cpp
index 867267c821..d64272d417 100644
--- a/tools/qmlscene/main.cpp
+++ b/tools/qmlscene/main.cpp
@@ -499,6 +499,9 @@ int main(int argc, char ** argv)
QCoreApplication::setOrganizationDomain(QStringLiteral("qt-project.org"));
QCoreApplication::setApplicationVersion(QLatin1String(QT_VERSION_STR));
+ if (qEnvironmentVariableIsSet("QMLSCENE_CORE_PROFILE"))
+ options.coreProfile = true;
+
const QStringList arguments = QCoreApplication::arguments();
for (int i = 1, size = arguments.size(); i < size; ++i) {
if (!arguments.at(i).startsWith(QLatin1Char('-'))) {
@@ -525,8 +528,7 @@ int main(int argc, char ** argv)
options.resizeViewToRootItem = true;
else if (lowerArgument == QLatin1String("--multisample"))
options.multisample = true;
- else if (lowerArgument == QLatin1String("--core-profile")
- || qEnvironmentVariableIsSet("QMLSCENE_CORE_PROFILE"))
+ else if (lowerArgument == QLatin1String("--core-profile"))
options.coreProfile = true;
else if (lowerArgument == QLatin1String("--verbose"))
options.verbose = true;