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

Qt::WA_QuitOnClose has no effect if other windows that don't have the attribute set are present

    XMLWordPrintable

Details

    • 249c5f0689bf1208a4f1d589de45c20c3ff16de9

    Description

      It seems that the attribute Qt::WA_QuitOnClose has no effect on windows

      Example:

      #include <QWidget>
      #include <QApplication>
      
      int main(int argc, char *argv[])
      { 
          QApplication a(argc, argv);
          QWidget w;
          w.setWindowTitle("Close This");
          w.show();
          QWidget w2;
          w2.setAttribute(Qt::WA_QuitOnClose, false);
          w2.setWindowTitle("This should be closed automatically");
          w2.show();
      
          return a.exec();
      }
      

      Attachments

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

        Activity

          People

            steveire Stephen Kelly (Personal)
            davschul David Schulz
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes