LibWebView+WebContent: Make it possible to change the painting interval

This allows us to paint at the refresh rate of the screen. The default
is 60, as before, in case it never gets set by anything.
This commit is contained in:
Luke Wilde 2025-07-25 13:10:00 +01:00 committed by Alexander Kalenik
commit c93c30d596
Notes: github-actions[bot] 2025-07-26 14:10:40 +00:00
7 changed files with 31 additions and 1 deletions

View file

@ -1158,6 +1158,12 @@ void ConnectionFromClient::set_device_pixels_per_css_pixel(u64 page_id, float de
page->set_device_pixels_per_css_pixel(device_pixels_per_css_pixel);
}
void ConnectionFromClient::set_maximum_frames_per_second(u64 page_id, double maximum_frames_per_second)
{
if (auto page = this->page(page_id); page.has_value())
page->set_maximum_frames_per_second(maximum_frames_per_second);
}
void ConnectionFromClient::set_window_position(u64 page_id, Web::DevicePixelPoint position)
{
if (auto page = this->page(page_id); page.has_value())