1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 22:27:35 +00:00

Ladybird+LibWebView: Migrate scrolling changes to LibWebView callbacks

This commit is contained in:
Timothy Flynn 2023-08-23 10:57:09 -04:00 committed by Tim Flynn
parent 00fe122b0a
commit 78d9339aa9
10 changed files with 73 additions and 98 deletions

View file

@ -224,7 +224,7 @@ struct HideCursor {
[[self tab] onFaviconChange:favicon];
};
m_web_view_bridge->on_scroll = [self](auto position) {
m_web_view_bridge->on_scroll_to_point = [self](auto position) {
[self scrollToPoint:Ladybird::gfx_point_to_ns_point(position)];
[[self scrollView] reflectScrolledClipView:self];
[self updateViewportRect:Ladybird::WebViewBridge::ForResize::No];