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

QML modal Dialog does not re-enable mouse responsivity of underlying window if destroyed from within it's own onAccepted() handler

    XMLWordPrintable

Details

    • Bug
    • Resolution: Incomplete
    • Not Evaluated
    • None
    • 5.15.2
    • Quick: Controls 2
    • None
    • Observed with Qt 5.15.2 on both Ubuntu 20.04 on x86 and ARM Yocto linux
    • Linux/Wayland, Linux/X11

    Description

      Initially observed with a modal Dialog created and displayed from within a ListView delegate instance that performed a model change (triggering destruction and recreation of delegate collection), but reproducable with the following simplified fragment.

      Same code worked without problems on Qt 5.9

      
      ....
      import QtQuick.Controls 2.15
      
      ....
      
                      Button {
                          id: btnTestModalDialog
      
                          text: "test"
      
                          onClicked: {
                              var dlg = compModalDialog.createObject(root);
                              dlg.open();
                          }
      
                          Component {
                              id: compModalDialog
      
                              Dialog {
                                  title: "delete self"
      
                                  modal: true
      
                                  standardButtons: Dialog.Ok | Dialog.Cancel
      
                                  onAccepted: {
                                      destroy();
                                  }
                              }
                          }
                      }
      

      Attachments

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

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            richardlang Richard Lang
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes