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

QDockWidget not correctly parented/setup if dragged from another floating and tabified QDockWidget

    XMLWordPrintable

Details

    • Linux/X11, macOS, Windows
    • 9ff40b59da (qt/qtbase/dev) 9ff40b59da (qt/tqtc-qtbase/dev) 191faa0626 (qt/tqtc-qtbase/6.2), e6d85cf28 (dev), a884cf6e8 (tqtc/lts-6.5), 9557d1ca9 (6.6)

    Description

      Steps to reproduce:

      In code:

      • create QMainWindow with centralwidget and other stuff
      • add two QDockWidgets (floatable|closeable|moveable)
      • tabify the docks.

      while runtime

      • start application
      • drag the two tabified docks to make them floating (but keep them tabified).
      • drag the other tabified dock out of the floating window
      • situation 3 windows. 

      observations/errors:

      • *QMainWindowLayout::tabPosition called with out-of-bounds value '0'* in console after making the second dock floating, moving that dock or closing. (duplicate of QTBUG-88157 ? )
      • closing the QMainWindow in this state does not close the second QDockWidget. Application hangs. The widget needs to be closed manually (Difficult since  the QDockWidget losses focus completely and gets burried by other open Applications)
      • closing the buggy QDockWidget before QMainWindow hangs the application on closing the QMainWindow without any means of recovery. (Just waits forever in an emit awake() in qeventdispatcher_win.cpp @ line 554)
      • the second QDockWidget is not able to dock the first QDockWidget (but the other way around works; also works if the docks are undocked individually.)
      • sometimes runtime crashes at qdockerlayout.cpp @ line 1270 (access violation; probably has something to do if a layout is missing from the Widget inside the QDockWidget; didn't Encounter it after adding layouts to them)

      Code: (attached)

      Attachments

        1. main.cpp
          2 kB
        2. testing-qt.cpp
          6 kB
        3. testing-qt.hpp
          0.8 kB

        Issue Links

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

          Activity

            People

              axelspoerl Axel Spoerl
              neumann-a Alexander Neumann
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes