Remove dead slide effect code and incorrect ref-objects from scroll effects
[platform/core/uifw/dali-toolkit.git] / base / dali-toolkit / internal / controls / scrollable / scroll-view / scroll-view-carousel-effect-impl.cpp
index ea5c6eb..fd352cb 100644 (file)
@@ -1,18 +1,19 @@
-//
-// Copyright (c) 2014 Samsung Electronics Co., Ltd.
-//
-// Licensed under the Flora License, Version 1.0 (the License);
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-//     http://floralicense.org/license/
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an AS IS BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
+/*
+ * Copyright (c) 2014 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
 
 // EXTERNAL INCLUDES
 #include <boost/bind.hpp>
@@ -62,7 +63,7 @@ Property::Index SafeRegisterProperty( Handle& handle, const std::string& name, P
  * move the Actor's edge visually away from the neighboring actor, as they rotate
  * around their default anchor point.
  */
-class ScrollCarouselEffectInfo : public Dali::RefObject
+class ScrollCarouselEffectInfo
 {
 public:
 
@@ -211,8 +212,6 @@ public:
   Vector2 mVisibilityThreshold;                           ///< Threshold for when to to switch off visibility of Actor (for performance)
 };
 
-typedef IntrusivePtr<ScrollCarouselEffectInfo> ScrollCarouselEffectInfoPtr;
-
 /**
  * Helper: Applies the 3D scroll carousel constraints to the child actor
  *
@@ -222,7 +221,7 @@ typedef IntrusivePtr<ScrollCarouselEffectInfo> ScrollCarouselEffectInfoPtr;
  */
 void ApplyScrollCarouselConstraints(Toolkit::ScrollView scrollView,
                                     Actor child,
-                                    ScrollCarouselEffectInfoPtr info)
+                                    ScrollCarouselEffectInfo& info)
 {
   // Apply constraints to this actor //
   Constraint constraint;
@@ -283,7 +282,7 @@ ScrollViewCarouselEffect::~ScrollViewCarouselEffect()
 
 void ScrollViewCarouselEffect::ApplyToActor(Actor child, const Vector2& angleSwing)
 {
-  ScrollCarouselEffectInfoPtr info(new ScrollCarouselEffectInfo(angleSwing));
+  ScrollCarouselEffectInfo info( angleSwing );
 
   ApplyScrollCarouselConstraints( GetScrollView(), child, info );
 }