mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 12:48:10 +00:00
LibWeb: Handle scrolling an OutOfProcessWebView
When a mousewheel scroll event isn't handled by the web content itself (e.g. an overflowed box or similar), the event needs to get passed back up to the OutOfProcessWebView.
This commit is contained in:
parent
e9c1d9c89a
commit
0e881bc5d7
9 changed files with 24 additions and 0 deletions
|
@ -245,6 +245,11 @@ void OutOfProcessWebView::notify_server_did_change_title(Badge<WebContentClient>
|
|||
on_title_change(title);
|
||||
}
|
||||
|
||||
void OutOfProcessWebView::notify_server_did_request_scroll(Badge<WebContentClient>, int wheel_delta)
|
||||
{
|
||||
vertical_scrollbar().set_value(vertical_scrollbar().value() + wheel_delta * 20);
|
||||
}
|
||||
|
||||
void OutOfProcessWebView::notify_server_did_request_scroll_into_view(Badge<WebContentClient>, const Gfx::IntRect& rect)
|
||||
{
|
||||
scroll_into_view(rect, true, true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue