projects
/
platform
/
core
/
uifw
/
dali-toolkit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Scrollview Ensure Overshoot is shown even if Y ruler is the same as Scrollview height
[platform/core/uifw/dali-toolkit.git]
/
base
/
dali-toolkit
/
internal
/
controls
/
scroll-bar
/
scroll-bar-impl.cpp
diff --git
a/base/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.cpp
b/base/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.cpp
index
2a4db69
..
6298e7d
100755
(executable)
--- a/
base/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.cpp
+++ b/
base/dali-toolkit/internal/controls/scroll-bar/scroll-bar-impl.cpp
@@
-284,7
+284,7
@@
void ScrollBar::SetPositionNotifications( const std::vector<float>& positions )
void ScrollBar::OnScrollPositionNotified(PropertyNotification& source)
{
// Emit the signal to notify the scroll position crossing
void ScrollBar::OnScrollPositionNotified(PropertyNotification& source)
{
// Emit the signal to notify the scroll position crossing
- mScrollPositionNotifiedSignal.Emit(mScroll
PositionObject.GetProperty<float>( Toolkit::ScrollConnector::SCROLL_POSITION
));
+ mScrollPositionNotifiedSignal.Emit(mScroll
Connector.GetScrollPosition(
));
}
void ScrollBar::Show()
}
void ScrollBar::Show()
@@
-318,13
+318,9
@@
void ScrollBar::Hide()
bool ScrollBar::OnPanGestureProcessTick()
{
// Update the scroll position property.
bool ScrollBar::OnPanGestureProcessTick()
{
// Update the scroll position property.
- mScrollPositionObject.SetProperty( Toolkit::ScrollConnector::SCROLL_POSITION, mCurrentScrollPosition );
-
- Dali::Toolkit::ItemView itemView = Dali::Toolkit::ItemView::DownCast(Self().GetParent());
- if(itemView)
+ if( mScrollConnector )
{
{
- // Refresh ItemView immediately when the scroll position is changed.
- GetImpl(itemView).DoRefresh(mCurrentScrollPosition, false); // No need to cache extra items.
+ mScrollConnector.SetScrollPosition(mCurrentScrollPosition);
}
return true;
}
return true;
@@
-332,8
+328,10
@@
bool ScrollBar::OnPanGestureProcessTick()
void ScrollBar::OnPan( PanGesture gesture )
{
void ScrollBar::OnPan( PanGesture gesture )
{
- if(mScroll
PositionObject
)
+ if(mScroll
Connector
)
{
{
+ Dali::Toolkit::ItemView itemView = Dali::Toolkit::ItemView::DownCast(Self().GetParent());
+
switch(gesture.state)
{
case Gesture::Started:
switch(gesture.state)
{
case Gesture::Started:
@@
-347,7
+345,7
@@
void ScrollBar::OnPan( PanGesture gesture )
}
Show();
}
Show();
- mScrollStart = mScroll
PositionObject.GetProperty<float>( Toolkit::ScrollConnector::SCROLL_POSITION
);
+ mScrollStart = mScroll
Connector.GetScrollPosition(
);
mGestureDisplacement = Vector3::ZERO;
mIsPanning = true;
mGestureDisplacement = Vector3::ZERO;
mIsPanning = true;
@@
-377,11
+375,16
@@
void ScrollBar::OnPan( PanGesture gesture )
mTimer.Reset();
}
mTimer.Reset();
}
+ if(itemView)
+ {
+ // Refresh the ItemView cache with extra items
+ GetImpl(itemView).DoRefresh(mCurrentScrollPosition, true);
+ }
+
break;
}
}
break;
}
}
- Dali::Toolkit::ItemView itemView = Dali::Toolkit::ItemView::DownCast(Self().GetParent());
if(itemView)
{
// Disable automatic refresh in ItemView during fast scrolling
if(itemView)
{
// Disable automatic refresh in ItemView during fast scrolling