mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-26 18:09:45 +00:00
LibWeb: Implement pinch-to-zoom support
Adds pinch event handling that adjusts the VisualViewport scale and offset. VisualViewport's (offset, scale) is then used to construct a transformation matrix which is applied before display list execution.
This commit is contained in:
parent
b477c6bfc4
commit
9862d8b4a6
Notes:
github-actions[bot]
2025-10-10 13:39:26 +00:00
Author: https://github.com/kalenikaliaksandr
Commit: 9862d8b4a6
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6430
Reviewed-by: https://github.com/gmta
Reviewed-by: https://github.com/konradekk
14 changed files with 149 additions and 40 deletions
|
|
@ -291,8 +291,8 @@ void EventLoop::process_input_events() const
|
|||
[&](Web::DragEvent& drag_event) {
|
||||
return page.handle_drag_and_drop_event(drag_event.type, drag_event.position, drag_event.screen_position, drag_event.button, drag_event.buttons, drag_event.modifiers, move(drag_event.files));
|
||||
},
|
||||
[&](Web::PinchEvent&) {
|
||||
return EventResult::Dropped;
|
||||
[&](Web::PinchEvent& pinch_event) {
|
||||
return page.handle_pinch_event(pinch_event.position, pinch_event.scale_delta);
|
||||
});
|
||||
|
||||
for (size_t i = 0; i < event.coalesced_event_count; ++i)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue