Details
-
Suggestion
-
Resolution: Unresolved
-
P2: Important
-
None
-
None
-
None
Description
The non-native dialogs in QtQuick.Dialogs are using file selectors for choosing which qml file to use, depending on the QQC2 style that is used by the application, when the qml engine is initialized during runtime.
This makes it impossible to take advantage of qmlcachegen for compiling the qml to C++ (for the increased performance gain), since it won't have enough information during compile time.
The quickcontrols2 module used to have the same problem, but the cmake project structure was changed to use the OPTIONAL_IMPORTS option in qt_internal_add_qml_module() among other things, to make the module friendlier for qmlcachegen.
We should change the cmake project structure of quickdialogs2 to be more similar to the quickcontrols2 module.
The behavioural changes that will result from this, will be that users can write
import QtQuick.Dialogs.Fusion
in their qml files.
This will strictly enfore that particular style, but it will have a much better performance, since that version of the dialog will have been processed by qmlcachegen.
Note that we still want users to be able to write the old
import QtQuick.Dialogs
syntax. Which should pick the style that was dynamically set by the user: https://doc.qt.io/qt-5/qtquickcontrols2-styles.html
We don't want to remove any of the existing feature, but rather simply improve the performance for the developers that want to enforce a particular style.
Attachments
Issue Links
- blocks
-
QTBUG-128868 qmllint prints Warning: Ambiguous type detected. XxxDialog is defined multiple times.
- Closed
- is duplicated by
-
QTBUG-120534 qmllint: warnings when adding QtQuick.Dialogs to qt_add_qml_module DEPENDENCIES
- Closed
- relates to
-
QTBUG-118588 qmllint: Nondeterministic output when multiple files are linted in one invocation
- Closed
-
QTBUG-120056 Make non-native Qt Quick Dialogs styleable like Controls
- Open
Gerrit Reviews
For Gerrit Dashboard: QTBUG-104091 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
476748,58 | WIP: Refactor the QtQuick.Dialogs module | dev | qt/qtdeclarative | Status: NEW | -2 | 0 |
597619,15 | DialogsQuickImpl: Implement ColorInputs as a custom control | dev | qt/qtdeclarative | Status: NEW | 0 | 0 |