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

OS X (10.8.5): Sheet (window modal) dialogs rendered "in cascade" (in a row) leave "dead dialog" artifacts

    XMLWordPrintable

Details

    • Bug
    • Resolution: Cannot Reproduce
    • P2: Important
    • None
    • 5.2.1
    • GUI: Window management
    • None
    • Qt 5.2.1 (binary download), OS X 10.8.5 (on OS X 10.9.1 the issue is *not* reproducible!)
    • macOS

    Description

      Scenario: after a given file has been selected with a sheet (window modal) dialog for saving a sheet error dialog is to be displayed immediatelly after in case something went wrong.

      Bug: On OS X 10.8.5 (and possibly below) the initial (file selection) dialog is "left dead" when the new sheet (error) dialog appears. The second dialog can be closed and the application then reacts normally to further mouse/key events, but the initial dialog remains on the screen as a "graphical artifact" and cannot be closed, see attached screenshot.

      Note: On OS X 10.9.1 (Mavericks) the initial dialog is perfectly closed, so this might as well be a Cocoa bug (triggered by some "unusual Qt interaction"?). There is some graphical "flickering" (the second dialog quickly appears over the first dialog before the first dialog is closed), but apart from that the first dialog is then properly closed (hopefully leaving to resource leaks behind - did not check that).

      How to reproduce:

      • Compile and launch the attached example
      • Click on the "Save As..." button and enter any file name (anywhere - nothing is saved here for real)
      • Click on "Save" in the sheet (window modal) file dialog
      • A second info dialog appears, indicating the selected file path
      • Bug: the initial file dialog remains on the screen (on OS X 10.8.5)

      Workaround:

      Using a QTimer with a zero timeout (0 ms) and calling a slot where the second message dialog is eventually shown works perfectly. However the "argument passing" is a bit clumsy, as the single shot timer slot does not take any arguments. E.g. an auxiliary member variable to store the message to be displayed can be used instead.

      Attachments

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

        Activity

          People

            tpochep Timur Pocheptsov
            till213 Oliver Knoll
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes