UBports Robot Logo UBports Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Change View?

    Scheduled Pinned Locked Moved App Development
    3 Posts 2 Posters 447 Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
      Reply
      • Reply as topic
      Log in to reply
      This topic has been deleted. Only users with topic management privileges can see it.
      • 0 Offline
        007fred50
        last edited by

        Hello,

        How can i change view? new pages, QML

        i try to this here:

        Item {
               width: 200; height: 200
        
               Loader { id: pageLoader }
        
               Button{
                   id: btn1
                   text: "ChangeView Page2"
                   onClicked: pageLoader.source = "Page2.qml"
               }
        }
        

        But the View will overlap the MainView.
        I have 2 files.
        Main.qml and Page2.qml

        Thanks for your time 🙂

        1 Reply Last reply Reply Quote 0
        • CiberSheepC Offline
          CiberSheep
          last edited by

          Maybe you could use a PageStack:
          https://api-docs.ubports.com/sdk/apps/qml/Ubuntu.Components/PageStack.html

          You can pile pages or clear it and push a single page (not recomended)

          Another planet, another time, another universe!

          0 1 Reply Last reply Reply Quote 0
          • 0 Offline
            007fred50 @CiberSheep
            last edited by

            @CiberSheep Thanks, PageStack works fine 🙂

            1 Reply Last reply Reply Quote 0

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better 💗

            Register Login
            • First post
              Last post