Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make libmaia compatible with Qt6 #21

Merged
merged 3 commits into from
May 26, 2023
Merged

Conversation

msarehn
Copy link
Contributor

@msarehn msarehn commented Sep 29, 2022

Makes the Qt version that's looked for in CMake configurable.

Adjusts the source code to differences in Qt6.

Some functionality that is used in libmaia is deprecated in Qt6, but it continues to work. Some follow-up PR will need to fix the deprecations.

The method `QVariant::Type QVariant::type() const` has been deprecated
since Qt 6.0. The recommended replacement is `typeId()` or `metaType()`,
but these are not available under Qt5. So choose to use `userType()`
instead, which is available under both and should cover the use cases as
well.
The method `int QMetaType::type(const QByteArray &typeName)` has been
deprecated since Qt 6.0. The only replacement is the new method
`fromName()` introduced in Qt6, so the only solution is to use dedicated
code for each Qt version until we stop supporting Qt5.
Copy link
Owner

@wiedi wiedi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry for the long delay. I was hoping to try this myself but never got to it... :/

The code looks good - thanks for keeping it backwards compatible :)

@wiedi wiedi merged commit 26659a1 into wiedi:master May 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants