Commit Graph

10 Commits

Author SHA1 Message Date
Ulf Hermann
cc9e5c3816 Wizards: Handle errors more elegantly in Qt Quick application template
By monitoring the objectCreated() signal of QQmlApplicationEngine we can
also catch errors if the components are instantiated asynchronously.

Task-number: QTBUG-39469
Change-Id: I796eb5561fc8d48ab5aa74d37b0964b118a1ba7e
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-01-18 09:46:27 +00:00
Alessandro Portale
3f757998b5 Revert "Wizards: Accept asynchronous root components for qqapplication"
This reverts commit dcb8681cb7.

The effort to handle asynchronous loading is not required for the
qmllivepreview (for which it had been introduced).

Task-number: QTCREATORBUG-19648
Change-Id: I20cbd318dedb3da43d4993c0c0a1910ffe6d5761
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2018-02-06 09:50:02 +00:00
Eike Ziller
469edcdde3 Merge remote-tracking branch 'origin/4.5'
Conflicts:
	qbs/modules/qtc/qtc.qbs
	qtcreator.pri

Change-Id: Ic1ab71d0d40fa6c90e337c8ee9d9558e8f103eaa
2017-12-12 10:53:51 +01:00
Alessandro Portale
a53df3892a Qt Quick Application wizards: No AA_EnableHighDpiScaling on Simulator
Avoid setting Qt::AA_EnableHighDpiScaling when running in the simulator.
Simulator detection is done by testing whether environment variable
QTGLESSTREAM_DISPLAY is set.

This amends 8c3bd61594 where all platforms
except Windows were excluded from setting the flag.

Task-number: QTBUG-64815
Change-Id: I8ab7ba9f24217915dc1d01e1f2eb5c37923c5504
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Rainer Keller <Rainer.Keller@qt.io>
2017-12-11 10:16:25 +00:00
Eike Ziller
e2baa116ca Merge remote-tracking branch 'origin/4.5'
Change-Id: I86852d289c22210a0439e8e297819dc7276a96de
2017-11-29 09:56:22 +01:00
Alessandro Portale
8c3bd61594 Qt Quick Application wizards: Qt::AA_EnableHighDpiScaling only on WIN
Setting Qt::AA_EnableHighDpiScaling causes a few graphics backends to
malfunction. This patch reduced the setting of the flag to happen only
on Windows (it is automatically set on macOS with retina).

Task-number: QTBUG-64815
Change-Id: I08fa5d1bd2c93e7a39c23487b684bd3f7b358783
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Sami Nurmenniemi <sami.nurmenniemi@qt.io>
2017-11-28 13:36:29 +00:00
Ulf Hermann
dcb8681cb7 Wizards: Accept asynchronous root components for qtquickapplication
There are a number of reasons why the root component of a QtQuick
application may be loaded asynchronously. It might, for example, be
derived from a component loaded over the network.

In that case, checking that there is a root object right after calling
load() is misleading. The object is only created later. Therefore, we
need to listen for the objectCreated signal to decide if the root
component was correctly created.

As calling qApp->exit(-1) does nothing while the event loop isn't
running, we always connect the check with Qt::QueuedConnection.

Change-Id: Ie2814894b79bb3e467c5a838c7ec419291fcf591
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2017-10-06 10:37:55 +00:00
Alessandro Portale
dbf9bd444b Wizards: Refresh the basic Qt Quick Application wizard
It now really creates an empty project.
Also, adapt the QtQuickPrototype template accordingly.

Change-Id: I0749805211df080c88cad1b9c2d476d56836c18a
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
2017-08-02 17:00:52 +00:00
Friedemann Kleint
cf807253e4 QML application wizards: Add code to bail out on load errors
When something goes wrong with deployment or there is a syntax
error in the QML files, the old code would enter the main
loop not showing any windows. Worse, the binary is then locked
on Windows and cannot be overwritten. Add a clause checking
whether there are any root objects and bail out on failure.

Task-number: QTBUG-60764
Change-Id: I3620a09ec4331dc04a5194dfd2ece2ff44bdc429
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2017-05-16 14:04:03 +00:00
Jake Petroules
b0229acd54 Clean up projects wizards and support for Qbs+CMake+qmake to all
Task-number: QTCREATORBUG-17308
Change-Id: I5d320a52f2cc5c0adbaf513985e4be0d75219a7d
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-02-10 18:19:57 +00:00