From 9f9783f971a873562fa79e32423d26a030d2dfdf Mon Sep 17 00:00:00 2001 From: Richard Huang Date: Wed, 14 Jan 2015 16:14:22 +0000 Subject: [PATCH] Scroll to the end of overshoot only when overshoot is enabled Change-Id: I9e2881dc5d52c28d13ec7dd132ed3c0cc570baed --- .../internal/controls/scrollable/scroll-view/scroll-view-impl.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/base/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.cpp b/base/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.cpp index 73e3453..7522766 100644 --- a/base/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.cpp +++ b/base/dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-impl.cpp @@ -1578,7 +1578,12 @@ bool ScrollView::SnapWithVelocity(Vector2 velocity) } } } - positionSnap += clampDelta; + + if(IsScrollComponentEnabled(Toolkit::Scrollable::OvershootIndicator)) + { + // Scroll to the end of the overshoot only when overshoot is enabled. + positionSnap += clampDelta; + } bool animating = AnimateTo(positionSnap, positionDuration, alphaFunction, false, -- 2.7.4