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

Modeless window on Mac behind its parent window

    XMLWordPrintable

    Details

      Description

      Clicking outside the modeless window (the child window in my example), hides this window under its parent.
      The following sample demonstrates the problem. This problem does not exist in Windows.

      Changing Qt::Window for Qt::Tool allows the window to float, but above all main windows and not only the parent window.

      #include <QtCore>
      #include <QtGui>
      #include <QtWidgets>
      
      int main(int argc, char * argv[])
      {
      	QApplication app(argc, argv);
      
      	QMainWindow* mw = new QMainWindow(0);
      	mw->show();
      	QMainWindow* mw2 = new QMainWindow(0);
      	mw2->show();
      
      	QDialog* d = new QDialog(mw, Qt::Window);
      	d->show();
          return app.exec();
      }
      

        Attachments

        1. main.cpp
          0.4 kB
          Philippe Goutier

          Issue Links

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

            Activity

              People

              Assignee:
              vestbo Tor Arne Vestbø
              Reporter:
              philippe Philippe Goutier
              Votes:
              14 Vote for this issue
              Watchers:
              21 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes