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

Mac OS X: Saved Application State causes non-modal QDialogs not to appear

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P3: Somewhat important
    • 4.8.x
    • 4.8.4
    • None
    • Mac OS X 10.7, 64 bit
    • macOS
    • f7efbae117595c2503ca85bfca7f27e0b6a92328, b2a91d3a918524f7e45f0f19d3f0efa4db0db709, af9ecedd523e5d41983160a9832bb8d90a1c5391

    Description

      My application uses a number of non-modal QDialogs. On updating to the Cocoa-based Mac OS version of Qt, the application fails to show non-modal QDialogs on the screen. This happens from the second or third invocation of the program. Qt thinks the QDialogs are visible (isVisible). Raising the window again, hiding and reshowing, or changing the position does nothing. If the user clicks on the application icon in the Mac dock bar, the QDialogs appear again. Alternatively, bringing up a modal QDialog causes the windows to appear.

      I have tracked it down to the information stored for the application in ~/Library/Saved Application State/com.mycomp.myapp. If I delete this directory, this fixes the problem.

      I've been unable to replicate the problem using simple test cases. I'm not sure how to proceed to fix this (other than deleting the offending files on every run). I assume it is something to do with Mac OS trying to restore the window states.

      I've attached an XML-converted version of the windows.plist file from the Saved Application State when the app is showing the problem.

      Attachments

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

        Activity

          People

            liaqi Liang Qi
            jeremysanders Jeremy Sanders
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes