diff options
author | Elyse <kevincristian@outlook.com> | 2021-10-31 12:27:52 -0600 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-12-30 14:31:50 +0100 |
commit | 086615535f00b2406a053a99038cfa2c768c42b0 (patch) | |
tree | 3331e4506f20c3a6a335a9d238ff89d278dc07d9 /Userland/Applications/PDFViewer | |
parent | d53e1fa1fa62cdbb5ead03c5a52f5690d86235a6 (diff) | |
download | serenity-086615535f00b2406a053a99038cfa2c768c42b0.zip |
Everywhere: Use 'decrease_slider_by()' method from AbstractSlider
The same idea as 'increase_slider_by()', it helps us to avoid repeating
the pattern 'set_value(value() - delta)'.
Diffstat (limited to 'Userland/Applications/PDFViewer')
-rw-r--r-- | Userland/Applications/PDFViewer/PDFViewer.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Applications/PDFViewer/PDFViewer.cpp b/Userland/Applications/PDFViewer/PDFViewer.cpp index 57ff4ab869..f377466ca8 100644 --- a/Userland/Applications/PDFViewer/PDFViewer.cpp +++ b/Userland/Applications/PDFViewer/PDFViewer.cpp @@ -106,7 +106,7 @@ void PDFViewer::mousewheel_event(GUI::MouseEvent& event) scrollbar.set_value(scrollbar.max()); } } else { - scrollbar.set_value(scrollbar.value() - 20); + scrollbar.decrease_slider_by(20); } } } |