mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 07:30:19 +00:00
Ladybird: Pass Gfx::IntPoint by value
This commit is contained in:
parent
4709f5961b
commit
d768abffa0
Notes:
sideshowbarker
2024-07-17 05:19:06 +09:00
Author: https://github.com/MacDue Commit: https://github.com/SerenityOS/serenity/commit/d768abffa0 Pull-request: https://github.com/SerenityOS/serenity/pull/16583 Reviewed-by: https://github.com/ADKaster Reviewed-by: https://github.com/awesomekling ✅ Reviewed-by: https://github.com/linusg
2 changed files with 16 additions and 16 deletions
|
@ -743,7 +743,7 @@ void WebContentView::notify_server_did_request_scroll(Badge<WebContentClient>, i
|
|||
verticalScrollBar()->setValue(verticalScrollBar()->value() + y_delta);
|
||||
}
|
||||
|
||||
void WebContentView::notify_server_did_request_scroll_to(Badge<WebContentClient>, Gfx::IntPoint const& scroll_position)
|
||||
void WebContentView::notify_server_did_request_scroll_to(Badge<WebContentClient>, Gfx::IntPoint scroll_position)
|
||||
{
|
||||
horizontalScrollBar()->setValue(scroll_position.x());
|
||||
verticalScrollBar()->setValue(scroll_position.y());
|
||||
|
@ -761,7 +761,7 @@ void WebContentView::notify_server_did_request_scroll_into_view(Badge<WebContent
|
|||
}
|
||||
}
|
||||
|
||||
void WebContentView::notify_server_did_enter_tooltip_area(Badge<WebContentClient>, Gfx::IntPoint const& content_position, DeprecatedString const& tooltip)
|
||||
void WebContentView::notify_server_did_enter_tooltip_area(Badge<WebContentClient>, Gfx::IntPoint content_position, DeprecatedString const& tooltip)
|
||||
{
|
||||
auto widget_position = to_widget(content_position);
|
||||
QToolTip::showText(
|
||||
|
@ -828,20 +828,20 @@ void WebContentView::notify_server_did_request_refresh(Badge<WebContentClient>)
|
|||
emit refresh();
|
||||
}
|
||||
|
||||
void WebContentView::notify_server_did_request_context_menu(Badge<WebContentClient>, Gfx::IntPoint const& content_position)
|
||||
void WebContentView::notify_server_did_request_context_menu(Badge<WebContentClient>, Gfx::IntPoint content_position)
|
||||
{
|
||||
// FIXME
|
||||
(void)content_position;
|
||||
}
|
||||
|
||||
void WebContentView::notify_server_did_request_link_context_menu(Badge<WebContentClient>, Gfx::IntPoint const& content_position, AK::URL const& url, DeprecatedString const&, unsigned)
|
||||
void WebContentView::notify_server_did_request_link_context_menu(Badge<WebContentClient>, Gfx::IntPoint content_position, AK::URL const& url, DeprecatedString const&, unsigned)
|
||||
{
|
||||
// FIXME
|
||||
(void)content_position;
|
||||
(void)url;
|
||||
}
|
||||
|
||||
void WebContentView::notify_server_did_request_image_context_menu(Badge<WebContentClient>, Gfx::IntPoint const& content_position, AK::URL const& url, DeprecatedString const&, unsigned, Gfx::ShareableBitmap const& bitmap)
|
||||
void WebContentView::notify_server_did_request_image_context_menu(Badge<WebContentClient>, Gfx::IntPoint content_position, AK::URL const& url, DeprecatedString const&, unsigned, Gfx::ShareableBitmap const& bitmap)
|
||||
{
|
||||
// FIXME
|
||||
(void)content_position;
|
||||
|
@ -991,7 +991,7 @@ void WebContentView::notify_server_did_request_restore_window()
|
|||
emit restore_window();
|
||||
}
|
||||
|
||||
Gfx::IntPoint WebContentView::notify_server_did_request_reposition_window(Gfx::IntPoint const& position)
|
||||
Gfx::IntPoint WebContentView::notify_server_did_request_reposition_window(Gfx::IntPoint position)
|
||||
{
|
||||
return emit reposition_window(position);
|
||||
}
|
||||
|
|
|
@ -54,10 +54,10 @@ public:
|
|||
void load(AK::URL const&);
|
||||
void load_html(StringView html, AK::URL const&);
|
||||
|
||||
Function<void(Gfx::IntPoint const& screen_position)> on_context_menu_request;
|
||||
Function<void(Gfx::IntPoint screen_position)> on_context_menu_request;
|
||||
Function<void(const AK::URL&, DeprecatedString const& target, unsigned modifiers)> on_link_click;
|
||||
Function<void(const AK::URL&, Gfx::IntPoint const& screen_position)> on_link_context_menu_request;
|
||||
Function<void(const AK::URL&, Gfx::IntPoint const& screen_position, Gfx::ShareableBitmap const&)> on_image_context_menu_request;
|
||||
Function<void(const AK::URL&, Gfx::IntPoint screen_position)> on_link_context_menu_request;
|
||||
Function<void(const AK::URL&, Gfx::IntPoint screen_position, Gfx::ShareableBitmap const&)> on_image_context_menu_request;
|
||||
Function<void(const AK::URL&, DeprecatedString const& target, unsigned modifiers)> on_link_middle_click;
|
||||
Function<void(const AK::URL&)> on_link_hover;
|
||||
Function<void(DeprecatedString const&)> on_title_change;
|
||||
|
@ -115,9 +115,9 @@ public:
|
|||
virtual void notify_server_did_request_cursor_change(Badge<WebContentClient>, Gfx::StandardCursor cursor) override;
|
||||
virtual void notify_server_did_change_title(Badge<WebContentClient>, DeprecatedString const&) override;
|
||||
virtual void notify_server_did_request_scroll(Badge<WebContentClient>, i32, i32) override;
|
||||
virtual void notify_server_did_request_scroll_to(Badge<WebContentClient>, Gfx::IntPoint const&) override;
|
||||
virtual void notify_server_did_request_scroll_to(Badge<WebContentClient>, Gfx::IntPoint) override;
|
||||
virtual void notify_server_did_request_scroll_into_view(Badge<WebContentClient>, Gfx::IntRect const&) override;
|
||||
virtual void notify_server_did_enter_tooltip_area(Badge<WebContentClient>, Gfx::IntPoint const&, DeprecatedString const&) override;
|
||||
virtual void notify_server_did_enter_tooltip_area(Badge<WebContentClient>, Gfx::IntPoint, DeprecatedString const&) override;
|
||||
virtual void notify_server_did_leave_tooltip_area(Badge<WebContentClient>) override;
|
||||
virtual void notify_server_did_hover_link(Badge<WebContentClient>, const AK::URL&) override;
|
||||
virtual void notify_server_did_unhover_link(Badge<WebContentClient>) override;
|
||||
|
@ -128,9 +128,9 @@ public:
|
|||
virtual void notify_server_did_request_navigate_back(Badge<WebContentClient>) override;
|
||||
virtual void notify_server_did_request_navigate_forward(Badge<WebContentClient>) override;
|
||||
virtual void notify_server_did_request_refresh(Badge<WebContentClient>) override;
|
||||
virtual void notify_server_did_request_context_menu(Badge<WebContentClient>, Gfx::IntPoint const&) override;
|
||||
virtual void notify_server_did_request_link_context_menu(Badge<WebContentClient>, Gfx::IntPoint const&, const AK::URL&, DeprecatedString const& target, unsigned modifiers) override;
|
||||
virtual void notify_server_did_request_image_context_menu(Badge<WebContentClient>, Gfx::IntPoint const&, const AK::URL&, DeprecatedString const& target, unsigned modifiers, Gfx::ShareableBitmap const&) override;
|
||||
virtual void notify_server_did_request_context_menu(Badge<WebContentClient>, Gfx::IntPoint) override;
|
||||
virtual void notify_server_did_request_link_context_menu(Badge<WebContentClient>, Gfx::IntPoint, const AK::URL&, DeprecatedString const& target, unsigned modifiers) override;
|
||||
virtual void notify_server_did_request_image_context_menu(Badge<WebContentClient>, Gfx::IntPoint, const AK::URL&, DeprecatedString const& target, unsigned modifiers, Gfx::ShareableBitmap const&) override;
|
||||
virtual void notify_server_did_request_alert(Badge<WebContentClient>, DeprecatedString const& message) override;
|
||||
virtual void notify_server_did_request_confirm(Badge<WebContentClient>, DeprecatedString const& message) override;
|
||||
virtual void notify_server_did_request_prompt(Badge<WebContentClient>, DeprecatedString const& message, DeprecatedString const& default_) override;
|
||||
|
@ -150,7 +150,7 @@ public:
|
|||
virtual void notify_server_did_update_cookie(Badge<WebContentClient>, AK::URL const& url, Web::Cookie::Cookie const& cookie) override;
|
||||
virtual void notify_server_did_update_resource_count(i32 count_waiting) override;
|
||||
virtual void notify_server_did_request_restore_window() override;
|
||||
virtual Gfx::IntPoint notify_server_did_request_reposition_window(Gfx::IntPoint const&) override;
|
||||
virtual Gfx::IntPoint notify_server_did_request_reposition_window(Gfx::IntPoint) override;
|
||||
virtual Gfx::IntSize notify_server_did_request_resize_window(Gfx::IntSize) override;
|
||||
virtual Gfx::IntRect notify_server_did_request_maximize_window() override;
|
||||
virtual Gfx::IntRect notify_server_did_request_minimize_window() override;
|
||||
|
@ -171,7 +171,7 @@ signals:
|
|||
void navigate_forward();
|
||||
void refresh();
|
||||
void restore_window();
|
||||
Gfx::IntPoint reposition_window(Gfx::IntPoint const&);
|
||||
Gfx::IntPoint reposition_window(Gfx::IntPoint);
|
||||
Gfx::IntSize resize_window(Gfx::IntSize);
|
||||
Gfx::IntRect maximize_window();
|
||||
Gfx::IntRect minimize_window();
|
||||
|
|
Loading…
Reference in a new issue