How to change source
I'm using this row
to set the main qml screen. But How can I chage to another file?
If I run
@QtQuick2ApplicationViewer *Quick2ApplicationViewer= new QtQuick2ApplicationViewer(this);
the main screen is under and I want to replace with another new one...
How can I do to load a new qml file?
One way to do this is to use the visible property to hide or show an Item. Do several components ( one for each page ) and use visible to go from one screen to another. If there are too many pages, you can also load them dynamicaly.
I have used Loader to embed in the main qml file the new files, as pages but I don't like so mutch this approach. With Declarative I can change the screen as I want.