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

quitOnLastWindowClosed handling

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P3: Somewhat important
    • None
    • 6.6.2
    • GUI: Other
    • None
    • All

    Description

      I got confused when debugging in qguiapplication.cpp line 3731:

      bool QGuiApplicationPrivate::canQuitAutomatically()
      {
          if (quitOnLastWindowClosed && !lastWindowClosed())
              return false;
      
          return QCoreApplicationPrivate::canQuitAutomatically();
      }
      

      As I understand it, this method should return false prematurely if quitOnLastWindowClosed is false or lastWindowClosed is false. But this translates to:

      bool QGuiApplicationPrivate::canQuitAutomatically()
      {
          if (!quitOnLastWindowClosed || !lastWindowClosed())
              return false;
      
          return QCoreApplicationPrivate::canQuitAutomatically();
      }
      

      Or do I misunderstand it?

      Attachments

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

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            wolf.seifert Wolfgang Seifert
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes