summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibGUI/Scrollbar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Userland/Libraries/LibGUI/Scrollbar.cpp')
-rw-r--r--Userland/Libraries/LibGUI/Scrollbar.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/Userland/Libraries/LibGUI/Scrollbar.cpp b/Userland/Libraries/LibGUI/Scrollbar.cpp
index c6867e7d94..4d9bf7c5c7 100644
--- a/Userland/Libraries/LibGUI/Scrollbar.cpp
+++ b/Userland/Libraries/LibGUI/Scrollbar.cpp
@@ -123,12 +123,12 @@ bool Scrollbar::has_scrubber() const
return max() != min();
}
-int Scrollbar::unclamped_scrubber_size() const
+float Scrollbar::unclamped_scrubber_size() const
{
- int pixel_range = length(orientation()) - button_size() * 2;
- int value_range = max() - min();
+ float pixel_range = length(orientation()) - button_size() * 2;
+ float value_range = max() - min();
- int scrubber_size = 0;
+ float scrubber_size { 0 };
if (value_range > 0) {
// Scrubber size should be proportional to the visible portion
// (page) in relation to the content (value range + page)