Flutter 3.41 is live! Check out theFlutter 3.41 blog post!
Introduction of FlutterEngine::ProcessExternalWindowMessage
External windows should call ProcessExternalWindowMessage to be considered for application lifecycle events.
These breaking change docs are accurate, as of the release under which they are published. Over time, the workarounds described here might become inaccurate. We don't, in general, keep these breaking change docs up to date as of each release.
Thebreaking change index file lists the docs created for each release.
Summary
# When you add any external windows to your Flutter app, you need to include them in the Window's app lifecycle logic. To include the window, itsWndProc function should invokeFlutterEngine::ProcessExternalWindowMessage.
Who is affected
#Windows applications built against Flutter 3.13 or newer that open non-Flutter windows.
Description of change
# Implementing application lifecycle on Windows involves listening for Window messages in order to update the lifecycle state. In order for additional non-Flutter windows to affect the lifecycle state, they must forward their window messages toFlutterEngine::ProcessExternalWindowMessage from theirWndProc functions. This function returns anstd::optional<LRESULT>, which isstd::nullopt when the message is received, but not consumed. When the returned result has a value, the message has been consumed, and further processing inWndProc should cease.
Migration guide
# The following exampleWndProc procedure invokesFlutterEngine::ProcessExternalWindowMessage:
LRESULTWindow::Messagehandler(HWNDhwnd,UINTmsg,WPARAMwparam,LPARAMlparam){std::optional<LRESULT>result=flutter_controller_->engine()->ProcessExternalWindowMessage(hwnd,msg,wparam,lparam);if(result.has_value()){return*result;}// Original contents of WndProc...}Timeline
# Landed in version: 3.14.0-3.0.pre
In stable release: 3.16
References
#Relevant PRs:
Unless stated otherwise, the documentation on this site reflects Flutter 3.38.6. Page last updated on 2025-10-28.View source orreport an issue.