From 8ec50f800bdbb096167bfeaa1f328f9175c8ee1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20M=C3=BCller?= Date: Mon, 13 Dec 2021 17:48:12 +0100 Subject: [PATCH] increase scrollbar handle size for small scrollbars --- src/game/client/ui_ex.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/game/client/ui_ex.cpp b/src/game/client/ui_ex.cpp index 774fdea3d..6340ec19d 100644 --- a/src/game/client/ui_ex.cpp +++ b/src/game/client/ui_ex.cpp @@ -52,7 +52,7 @@ float CUIEx::DoScrollbarV(const void *pID, const CUIRect *pRect, float Current) pRect->Margin(5.0f, &Rail); CUIRect Handle; - Rail.HSplitTop(clamp(33.0f, Rail.w, Rail.h / 8.0f), &Handle, 0); + Rail.HSplitTop(clamp(33.0f, Rail.w, Rail.h / 3.0f), &Handle, 0); Handle.y = Rail.y + (Rail.h - Handle.h) * Current; // logic @@ -132,7 +132,7 @@ float CUIEx::DoScrollbarH(const void *pID, const CUIRect *pRect, float Current, pRect->HMargin(5.0f, &Rail); CUIRect Handle; - Rail.VSplitLeft(pColorInner ? 8.0f : clamp(33.0f, Rail.h, Rail.w / 8.0f), &Handle, 0); + Rail.VSplitLeft(pColorInner ? 8.0f : clamp(33.0f, Rail.h, Rail.w / 3.0f), &Handle, 0); Handle.x += (Rail.w - Handle.w) * Current; // logic