mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 17:17:44 +00:00
LibWeb+WebContent+headless-browser: Use CSSPixels for PageClient events
...and also for hit testing, which is involved in most of them. Much of this is temporary conversions and other awkwardness, which should resolve itself as the rest of LibWeb is converted to these new types. Hopefully. :thousandyakstare:
This commit is contained in:
parent
045aa8530c
commit
3c7bd5a317
27 changed files with 169 additions and 159 deletions
|
@ -157,27 +157,27 @@ void ConnectionFromClient::flush_pending_paint_requests()
|
|||
|
||||
void ConnectionFromClient::mouse_down(Gfx::IntPoint position, unsigned int button, unsigned int buttons, unsigned int modifiers)
|
||||
{
|
||||
report_finished_handling_input_event(page().handle_mousedown(position, button, buttons, modifiers));
|
||||
report_finished_handling_input_event(page().handle_mousedown(position.to_type<Web::DevicePixels>(), button, buttons, modifiers));
|
||||
}
|
||||
|
||||
void ConnectionFromClient::mouse_move(Gfx::IntPoint position, [[maybe_unused]] unsigned int button, unsigned int buttons, unsigned int modifiers)
|
||||
{
|
||||
report_finished_handling_input_event(page().handle_mousemove(position, buttons, modifiers));
|
||||
report_finished_handling_input_event(page().handle_mousemove(position.to_type<Web::DevicePixels>(), buttons, modifiers));
|
||||
}
|
||||
|
||||
void ConnectionFromClient::mouse_up(Gfx::IntPoint position, unsigned int button, unsigned int buttons, unsigned int modifiers)
|
||||
{
|
||||
report_finished_handling_input_event(page().handle_mouseup(position, button, buttons, modifiers));
|
||||
report_finished_handling_input_event(page().handle_mouseup(position.to_type<Web::DevicePixels>(), button, buttons, modifiers));
|
||||
}
|
||||
|
||||
void ConnectionFromClient::mouse_wheel(Gfx::IntPoint position, unsigned int button, unsigned int buttons, unsigned int modifiers, i32 wheel_delta_x, i32 wheel_delta_y)
|
||||
{
|
||||
report_finished_handling_input_event(page().handle_mousewheel(position, button, buttons, modifiers, wheel_delta_x, wheel_delta_y));
|
||||
report_finished_handling_input_event(page().handle_mousewheel(position.to_type<Web::DevicePixels>(), button, buttons, modifiers, wheel_delta_x, wheel_delta_y));
|
||||
}
|
||||
|
||||
void ConnectionFromClient::doubleclick(Gfx::IntPoint position, unsigned int button, unsigned int buttons, unsigned int modifiers)
|
||||
{
|
||||
report_finished_handling_input_event(page().handle_doubleclick(position, button, buttons, modifiers));
|
||||
report_finished_handling_input_event(page().handle_doubleclick(position.to_type<Web::DevicePixels>(), button, buttons, modifiers));
|
||||
}
|
||||
|
||||
void ConnectionFromClient::key_down(i32 key, unsigned int modifiers, u32 code_point)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue