QmlApplicationViewer && QtCreator problem



  • Hi all,
    I have a "Qt Quick Application" created by Qt Creator ("New File or Project...") .

    By default it add a QmlApplicationViewer class to show QML files.

    With QmlApplicationViewer I can't show qml file in the application "resource" so I edited it as follow:
    @
    void QmlApplicationViewer::setMainQmlFile(const QString &file)
    {
    d->mainQmlFile = QmlApplicationViewerPrivate::adjustPath(file);
    //setSource(QUrl::fromLocalFile(d->mainQmlFile));
    setSource(QUrl(d->mainQmlFile));
    }
    @

    this way I can "show" QML file with:
    @
    m_qmlViewer->setMainQmlFile("qrc:/qml/myfile.qml");
    @

    The problem is that every time I open the project with QtCreator it show me a message:
    @
    The following files are outdated or has been modified:
    qmlapplicationviewer.cpp
    ...
    ...
    @

    How can I remove this warning?


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.