2 // Copyright (c) 2014 Samsung Electronics Co., Ltd.
4 // Licensed under the Flora License, Version 1.0 (the License);
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
8 // http://floralicense.org/license/
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an AS IS BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
17 #include <dali-toolkit/public-api/controls/scrollable/scroll-view/scroll-view-effect.h>
18 #include <dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-effect-impl.h>
19 #include <dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-slide-effect-impl.h>
29 const std::string ScrollViewSlideEffect::EFFECT_TIME( "ScrollViewSlideEffect::EFFECT_TIME" );
30 const std::string ScrollViewSlideEffect::EFFECT_REFERENCE( "ScrollViewSlideEffect::EFFECT_REFERENCE" );
31 const std::string ScrollViewSlideEffect::EFFECT_ACTIVE( "ScrollViewSlideEffect::EFFECT_ACTIVE" );
33 ScrollViewSlideEffect ScrollViewSlideEffect::New()
35 return ScrollViewSlideEffect(new Internal::ScrollViewSlideEffect());
38 ScrollViewSlideEffect::ScrollViewSlideEffect()
43 ScrollViewSlideEffect::ScrollViewSlideEffect(Internal::ScrollViewSlideEffect *impl)
44 : ScrollViewEffect(impl)
48 bool ScrollViewSlideEffect::GetSlideDirection() const
50 return GetImpl(*this).GetSlideDirection();
53 void ScrollViewSlideEffect::SetSlideDirection(bool vertical)
55 GetImpl(*this).SetSlideDirection( vertical );
58 Vector3 ScrollViewSlideEffect::GetDelayReferenceOffset() const
60 return GetImpl(*this).GetDelayReferenceOffset();
63 void ScrollViewSlideEffect::SetDelayReferenceOffset(const Vector3& offset)
65 GetImpl(*this).SetDelayReferenceOffset(offset);
68 float ScrollViewSlideEffect::GetMaxDelayDuration() const
70 return GetImpl(*this).GetMaxDelayDuration();
73 void ScrollViewSlideEffect::SetMaxDelayDuration(float offset)
75 GetImpl(*this).SetMaxDelayDuration(offset);
78 ScrollViewSlideEffect ScrollViewSlideEffect::DownCast( BaseHandle handle )
80 return ScrollViewSlideEffect( dynamic_cast<Internal::ScrollViewSlideEffect*>(handle.GetObjectPtr()) );
83 void ScrollViewSlideEffect::ApplyToActor( Actor child,
87 GetImpl(*this).ApplyToActor( child,
92 } // namespace Toolkit