Skip to content

[Windows] Application::Quit posts WM_QUIT before destroying windows #57

Description

@lijy91

On Windows, Application::Quit() ends in PostQuitMessage() (src/platform/windows/application_windows.cpp) without destroying the application's windows first.

window_manager had the same pattern in destroy(), and there it made apps take several seconds to exit, or stop responding, since Flutter 3.24. The window and the Flutter engine were torn down after the message loop had already stopped.

Expected: destroy the windows (so the Flutter view controller shuts down its engine while messages are still pumped), then post WM_QUIT. Needs checking in a Flutter app, including with a close handler that intercepts the system close button.

Background:

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions