diff --git a/src/yscrollview.cc b/src/yscrollview.cc index 03561e196..39f17a9aa 100644 --- a/src/yscrollview.cc +++ b/src/yscrollview.cc @@ -77,8 +77,9 @@ void YScrollView::configure(const YRect2& r) { } bool YScrollView::handleScrollKeys(const XKeyEvent& key) { - return scrollVert->handleScrollKeys(key) - || scrollHoriz->handleScrollKeys(key); + const int v = scrollVert->handleScrollKeys(key); + const int h = scrollHoriz->handleScrollKeys(key); + return bool(v | h); } void YScrollView::handleExpose(const XExposeEvent& expose) {