headless-browser: Update visibility after minimizing/restoring windows

This commit is contained in:
Timothy Flynn 2024-11-12 11:22:40 -05:00 committed by Andreas Kling
parent e094712e3a
commit 13b7c26e9f
Notes: github-actions[bot] 2024-11-13 10:01:59 +00:00

View file

@ -53,6 +53,14 @@ HeadlessWebView::HeadlessWebView(Core::AnonymousBuffer theme, Web::DevicePixelSi
client().async_did_update_window_rect(m_client_state.page_index);
};
on_restore_window = [this]() {
client().async_set_system_visibility_state(m_client_state.page_index, true);
};
on_minimize_window = [this]() {
client().async_set_system_visibility_state(m_client_state.page_index, false);
};
on_maximize_window = [this]() {
m_viewport_size = screen_rect.size();