diff options
Diffstat (limited to 'src/window.cpp')
-rw-r--r-- | src/window.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/window.cpp b/src/window.cpp index a002de09b..c20bc49f4 100644 --- a/src/window.cpp +++ b/src/window.cpp @@ -502,7 +502,7 @@ static void DispatchMouseWheelEvent(Window *w, const NWidgetCore *nwid, int whee } /* Scroll the widget attached to the scrollbar. */ - Scrollbar *sb = nwid->FindScrollbar(w); + Scrollbar *sb = (nwid->scrollbar_index >= 0 ? w->GetScrollbar(nwid->scrollbar_index) : NULL); if (sb != NULL && sb->GetCount() > sb->GetCapacity()) { sb->UpdatePosition(wheel); w->SetDirty(); |