Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions include/webfront/frontend/WebView2.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -563,9 +563,10 @@ class Session : public std::enable_shared_from_this<Session> {
}
}
void finishUnload() noexcept {
stopUnloadTimer();
if (window)
PostMessageW(window, WM_CLOSE, unloadedClose, 0);
// The delay repeats until the close is posted: a full message queue refuses the post, and the next expiry tries
// again instead of leaving the hidden window and its controller until the first window ends.
if (window && PostMessageW(window, WM_CLOSE, unloadedClose, 0))
stopUnloadTimer();
}
void stopUnloadTimer() noexcept {
if (unloadTimer && window)
Expand Down
Loading