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

QStackedWidget continues to retain ownership of widget even after removeWidget() is called.

    XMLWordPrintable

Details

    • 2023b9e76baf8d8a3b1ea59748624e16f3297ac3

    Description

      The documentation of QStackedWidget::removeWidget explains that:
      "Ownership of widget reverts to the application." ;however, QStackedWidget actually continues to retain ownership of widget even after removeWidget() is called.

      Upon adding a widget to a QStackedWidget, the parent of the added widget is set to the QStackedWidget. Once the widget is removed from the stacked widget, the widget continues to be parented to the QStackedWidget.

      This contradicts the bug fix in the documentation for bug 10934.

      Attachments

        Issue Links

          For Gerrit Dashboard: QTBUG-44891
          # Subject Branch Project Status CR V

          Activity

            People

              jbornema Joerg Bornemann
              tyip Terence Yip
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes