Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-38658

Android: dialogs and menubar conspire to make ApplicationWindow resize in an infinite loop

    XMLWordPrintable

Details

    • Bug
    • Resolution: Cannot Reproduce
    • P1: Critical
    • None
    • 5.3.0 RC1
    • Quick: Dialogs
    • None
    • Android

    Description

      import QtQuick 2.2
      import QtQuick.Controls 1.1
      import QtQuick.Dialogs 1.1
      
      ApplicationWindow {
          id: mainWindow
      
          visible: true
          title: "Hello World"
      
          onHeightChanged: console.log("aw height " + height)
      
          menuBar: MenuBar {
              Menu {
                  title: qsTr("File")
      
                  MenuItem {
                      id: showDialogItem
                      text: qsTr("File dialog")
                      onTriggered: {
                          fileOpenDialog.visible = true;
                      }
                  }
      
      
                  MenuItem {
                      text: qsTr("Exit")
                      onTriggered: Qt.quit();
                  }
              }
          }
      
          FileDialog {
              id: fileOpenDialog;
          }
      
          MessageDialog {
              id: messageDialog
              title: "May I have your attention please"
              text: "It's so cool that you are using Qt Quick."
              onAccepted: {
                  console.log("And of course you could only agree.")
              }
          }
      
          Text {
              text: qsTr("Hello World")
              anchors.centerIn: parent
          }
      
          Button {
              text: "Open file..."
              anchors.bottom: parent.bottom
              onClicked: fileOpenDialog.visible = true
          }
      
          Button {
              text: "say hi"
              anchors.bottom: parent.bottom
              anchors.right: parent.right
              onClicked: messageDialog.visible = true
          }
      }
      

      Not doing bottom anchors on the buttons probably helps.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              srutledg Shawn Rutledge
              srutledg Shawn Rutledge
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes