Whenever qqc release a new version the version need to be updated.
Otherwise the feature is not available to user. This change tries
to use real qml code to detect the version by creating object until
success, force to use a minimal qpa platform when running it.
Details
- Reviewers
rizzitello davidedmundson apol mart - Group Reviewers
Plasma - Commits
- R858:aa57b34f75f0: Detect QQC2 version at build time with actual detection.
Run the cmake under a env without display server and version is detected
correctly.
Diff Detail
- Repository
- R858 Qt Quick Controls 2: Desktop Style
- Branch
- master
- Lint
No Linters Available - Unit
No Unit Test Coverage - Build Status
Buildable 25293 Build 25311: arc lint + arc unit
I don't understand.
We're still running this at compile time, so what's the practical difference?
The old implement hard-codes it to (minor_version - 7), which is the old contract.
This commit message says it will ties the version with minor version. (I don't think this will change anymore, because patch version will not introduce new API anyway).
https://github.com/qt/qtquickcontrols2/commit/3c7bfc156797b2f3ef08a8cf620b79da80e4b061
In order to cover both cases, this code is doing the check simply checking minor , minor - 1.... until it finds the highest available version.
So the problem we're solving is that we want to go
Qt5.12 - QQC2.5
Qt5.13 - QQC2.6
Qt5.14 - QQC2.7
Qt5.15 - QQC2.15
correct?
We now know all Qt5 versions, and we know that Qt6 won't have versions.
I don't see why need this complicated thing instead of an "if" statement on Qt5QuickControls2_VERSION_MINOR