Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Skip already closing widgets when checking whether application can quit
QApplication tries to close all windows on quit using closeAllWindows, but closeAllWindows skips windows that are already closing. This can happen when calling quit() from a close event for example. QApplication then tries to verify that all windows have been closed, and that logic should skip the same kind of windows as closeAllWindows does. The fact that these two logics diverge was identified earlier in 5af73cd, but aligning them required further work. As that commit notes, the right fix to align them is building on top of tryCloseAllWidgetWindows(), which already returns true/false based on whether it could close all windows or not. But, unlike the existing logic in QApplication::event(), it doesn't skip Popups or Dialogs, so that discrepancy needs further research. Pick-to: 6.0 Fixes: QTBUG-89580 Change-Id: I87bff56f2eb8a539f1c859c957f5f239dc1eb93d Reviewed-by: Andy Shaw <[email protected]> Reviewed-by: Kai Koehne <[email protected]> Reviewed-by: Volker Hilsheimer <[email protected]>
- Loading branch information