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

QtQuickView doesn't handle recreation of Activity properly

    XMLWordPrintable

Details

    • Android
    • 6d2db42f7 (dev)

    Description

      If the embedding Activity is recreated, for example due to orientation change, resources don't seem to be properly cleared up, leading to a crash after enough recreations have happened.

      When the Activity is recreated, for example due to not-overridden orientation change, the app gets stuck.

      Before https://codereview.qt-project.org/c/qt/qtbase/+/557217 whenever the Activity got destroyed, we also called system.exit(), hence quitting the whole app, and it just got restarted with the new Activity, making it look like it worked, for a while. However, removing the system.exit() call lead to other issues, like the QtThread instance already being stopped.

      Steps to reproduce:

      • Remove the line android:configChanges="orientation|screenLayout|screenSize" from the example's (qtquickview_java or another embedded QML example) AndroidManifest.xml
      • start the example
      • switch the orientation of the emulator/device

       

      Attachments

        Issue Links

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

          Activity

            People

              tinjapaavoseppa Tinja Paavoseppä
              tinjapaavoseppa Tinja Paavoseppä
              Votes:
              2 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes