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

    Is there are support for Qt dialog?

    Scheduled Pinned Locked Moved App Development
    7 Posts 4 Posters 1.6k Views 1 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.
      • X Offline
        xqqy
        last edited by

        As the title, I didn't found this from api document.And seems module "QtQuick.Controls" version 1.2 is not installed(from log info)

        K 1 Reply Last reply Reply Quote 0
        • K Online
          kugiigi @xqqy
          last edited by

          @xqqy not sure about 1.2 but QtQuick.Controls 2.2 is available in UT 🙂

          1 Reply Last reply Reply Quote 0
          • dobeyD Offline
            dobey
            last edited by

            It's QtQuick.Dialogs you need to import. I'm not sure if qml-module-qtquick-dialogs is seeded though. It might be problematic to use this module, under Unity8, due to how windowing works.

            X 1 Reply Last reply Reply Quote 0
            • X Offline
              xqqy @dobey
              last edited by

              @dobey But when I using "import QtQuick.Dialogs 1.2" in qml, the page will not load.
              Logs are:

              QQmlComponent: Component is not ready
              file:///opt/click.ubuntu.com/appname.yourname/1.0.0/qml/main.qml:61:5: QML StackView: push: file:///opt/click.ubuntu.com/appname.yourname/1.0.0/qml/Page2Form.qml:188 Type Dialog unavailable
              file:///usr/lib/arm-linux-gnueabihf/qt5/qml/QtQuick/Dialogs/DefaultDialogWrapper.qml:41 module "QtQuick.Controls" version 1.2 is not installed

              seems the QtQuick.Dialogs 1.2 not load due to QtQuick.Controls version 1.2 not installed.

              1 Reply Last reply Reply Quote 0
              • K Online
                kugiigi
                last edited by

                maybe you need to import a different version of QtQuick Dialogs? perhaps 2.2?
                but like dobey said, I would not suggest using that since its more of a desktop app dialog.
                You should just use QtQuick.Controls 2.2

                lduboeufL 1 Reply Last reply Reply Quote 0
                • lduboeufL Offline
                  lduboeuf @kugiigi
                  last edited by lduboeuf

                  @xqqy you can see a working example with QQC2 Gallery App, source code here : https://gitlab.com/ubports/apps/qqc2-gallery/blob/master/qml/Main.qml#L293
                  app here :
                  https://open-store.io/app/qqc2-gallery.ubad

                  X 1 Reply Last reply Reply Quote 0
                  • X Offline
                    xqqy @lduboeuf
                    last edited by

                    @lduboeuf Thanks, I have found the dialog in QtQuick. Thanks to all people helped me.

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post