diff --git a/ui/viewgroup.cpp b/ui/viewgroup.cpp index 4105408a8c..9a5bcb3ec2 100644 --- a/ui/viewgroup.cpp +++ b/ui/viewgroup.cpp @@ -538,6 +538,19 @@ void ScrollView::Key(const KeyInput &input) { case NKCODE_EXT_MOUSEWHEEL_DOWN: ScrollRelative(250); break; + case NKCODE_PAGE_DOWN: + ScrollRelative(bounds_.h - 50); + break; + case NKCODE_PAGE_UP: + ScrollRelative(-bounds_.h + 50); + break; + case NKCODE_MOVE_HOME: + ScrollTo(0); + break; + case NKCODE_MOVE_END: + if (views_.size()) + ScrollTo(views_[0]->GetBounds().h); + break; } } ViewGroup::Key(input); diff --git a/ui/viewgroup.h b/ui/viewgroup.h index 86f2667936..60570a5b68 100644 --- a/ui/viewgroup.h +++ b/ui/viewgroup.h @@ -190,7 +190,6 @@ public: orientation_(orientation), scrollPos_(0), scrollStart_(0), - scrollMax_(0), scrollTarget_(0), scrollToTarget_(false), inertia_(0), @@ -222,7 +221,6 @@ private: Orientation orientation_; float scrollPos_; float scrollStart_; - float scrollMax_; float scrollTarget_; bool scrollToTarget_; float inertia_;