-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Remove unused hack #20618
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
base: main
Are you sure you want to change the base?
Remove unused hack #20618
Conversation
Introduced back in 798c1f1 and unused since 5992e66, this is no longer an appropriate way to perform type checks in QML by modern Qt standards. Just use instanceof operator instead, if needed; it works since Qt 5.10 Source: https://doc.qt.io/qt-6/qtqml-javascript-hostenvironment.html
Strictly speaking, removing this function constitutes a major SDK version change, which is a pain because it means that all Marketplace plugins (whether they use the function or not) need to be changed and resubmitted. Please see if there is a way to keep the function, but make it use the |
Oh, I was under an impression that it was some kind of entry point for the whole application like what would be
No can do. The function expects a string, but you can't just resolve a string back to a type that it represents. Unfortunately, as of Qt 6.10 QML still lacks any sort of dedicated deprecation syntax/API either, you'd just have to console.warn() or something. |
Points taken. Then it is up to the Cura team to decide if this is minor enough to skip the SDK version update. To be honest, I don't know if any plugin is using the call from their QML. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot wasn't able to review any files in this pull request.
Files not reviewed (1)
- resources/qml/Cura.qml: Language not supported
Sooo… now what? If it's gonna stuck forever, I'd rather just close and delete the branch honestly. |
Description
Introduced back in 798c1f1 and unused since 5992e66, this is no longer an appropriate way to perform type checks in QML by modern Qt standards. Just use instanceof operator instead, if needed; it works since Qt 5.10
Source: https://doc.qt.io/qt-6/qtqml-javascript-hostenvironment.html
Type of change
How Has This Been Tested?
Checklist: