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

Cannot dismiss QtQuick popups in QQuickWidget, misplaced QQuickOverlay

    XMLWordPrintable

Details

    • Linux/Wayland, Linux/X11
    • 92000ffe9 (dev), bde88b584 (6.8)

    Description

      When using a QQuickWidget and showing a popup the popup can only be dismissed if the user clicks in the top left of the window:

      The reason for this is because startup ordering is as follows:

       - When a QQuickOverlay is created, this is positioned to be the size of the contentItem, positioned to be centered within the window

       - It updates when the size of the contentItem changes

       - QQuickWidget creates the contentItem at the right size before assigning it to the window

       - At the time QQuickOverlay is created the window is of a null size
       - It has no reason to re-update until the window is resized

      I've attached a screenshot from gammaray and a tiny app reproducing the issue.

      Attachments

        1. gammaray.png
          gammaray.png
          359 kB
        2. qtquicktest.zip
          3.99 MB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            hurlevent Oliver Eftevaag
            davidedmundson David Edmundson
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes