IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)

QTP0001

':/qt/qml/' is the default resource prefix for QML modules.

Article lu   fois.

L'auteur

Liens sociaux

Viadeo Twitter Facebook Share on Google+   

QTP0001

':/qt/qml/' is the default resource prefix for QML modules.

This policy was introduced in Qt 6.5. It changes where qt_add_qml_module() stores QML resources in the resource system.

Enabling this policy ensures that your QML module is placed under a default import path, and its types can be found without manual calls to QQmlEngine::addImportPath.

The OLD behavior of this policy is that, the RESOURCE_PREFIX argument for qt_add_qml_module() defaults to ":/".

The NEW behavior of this policy is that the RESOURCE_PREFIX argument for qt_add_qml_module() defaults to ":/qt/qml/". The new behavior ensures that modules are put into the QML Import Path and can be found without further setup.

Qt 6.5 issues warnings if you do not pass any of the following arguments to the qt_add_qml_module command: RESOURCE_PREFIX, NO_RESOURCE_TARGET_PATH. Use the qt_policy command to suppress the warning by explicitly setting the policy to OLD or NEW.

The OLD behavior of a policy is deprecated, and may be removed in the future.

I. See Also

Vous avez aimé ce tutoriel ? Alors partagez-le en cliquant sur les boutons suivants : Viadeo Twitter Facebook Share on Google+