mirror of
https://github.com/RGBCube/serenity
synced 2025-07-08 06:47:34 +00:00
Everywhere: Use 'increase_slider_by()' method from AbstractSlider
This method help us to avoid repeating the pattern 'set_value(value() + delta)'.
This commit is contained in:
parent
8b8f404146
commit
d53e1fa1fa
12 changed files with 19 additions and 19 deletions
|
@ -243,8 +243,8 @@ void OutOfProcessWebView::notify_server_did_change_title(Badge<WebContentClient>
|
|||
|
||||
void OutOfProcessWebView::notify_server_did_request_scroll(Badge<WebContentClient>, i32 x_delta, i32 y_delta)
|
||||
{
|
||||
horizontal_scrollbar().set_value(horizontal_scrollbar().value() + x_delta);
|
||||
vertical_scrollbar().set_value(vertical_scrollbar().value() + y_delta);
|
||||
horizontal_scrollbar().increase_slider_by(x_delta);
|
||||
vertical_scrollbar().increase_slider_by(y_delta);
|
||||
}
|
||||
|
||||
void OutOfProcessWebView::notify_server_did_request_scroll_to(Badge<WebContentClient>, Gfx::IntPoint const& scroll_position)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue