Follow the include-order coding conventions
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / internal / controls / scrollable / scroll-view / scroll-view-cube-effect-impl.cpp
index f0c6f7a..bda70a4 100644 (file)
@@ -1,22 +1,24 @@
-//
-// 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>
 
+// INTERNAL INCLUDES
 #include <dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-effect-impl.h>
 #include <dali-toolkit/internal/controls/scrollable/scroll-view/scroll-view-cube-effect-impl.h>
 
@@ -43,7 +45,7 @@ namespace // unnamed namespace
  * When at middle of the screen the position is not altered.
  * When one screen away from middle the position is rotated about it's origin + mAnchor
  */
-class ScrollCubeEffectInfo : public Dali::RefObject
+class ScrollCubeEffectInfo
 {
 public:
 
@@ -284,8 +286,6 @@ public:
   Vector3 mPositionSwing;                                 ///< Maximum amount in X and Y axes to alter position.
 };
 
-typedef IntrusivePtr<ScrollCubeEffectInfo> ScrollCubeEffectInfoPtr;
-
 /**
  * Helper: Applies the 3D scroll cube constraints to the child actor
  *
@@ -296,7 +296,7 @@ typedef IntrusivePtr<ScrollCubeEffectInfo> ScrollCubeEffectInfoPtr;
 void ApplyScrollCubeConstraints(Toolkit::ScrollView scrollView,
                                 Actor child,
                                 Actor parentPage,
-                                ScrollCubeEffectInfoPtr info)
+                                const ScrollCubeEffectInfo& info)
 {
   // Apply constraints to this actor //
   Constraint constraint;
@@ -362,7 +362,7 @@ void ScrollViewCubeEffect::ApplyToActor(Actor child,
                                         const Vector2& angleSwing,
                                         const Vector2& positionSwing)
 {
-  ScrollCubeEffectInfoPtr info(new ScrollCubeEffectInfo(anchor, angleSwing, positionSwing));
+  ScrollCubeEffectInfo info( anchor, angleSwing, positionSwing );
 
   ApplyScrollCubeConstraints( GetScrollView(), child, child.GetParent(), info );
 }
@@ -373,7 +373,7 @@ void ScrollViewCubeEffect::ApplyToActor(Actor child,
                                         const Vector2& angleSwing,
                                         const Vector2& positionSwing)
 {
-  ScrollCubeEffectInfoPtr info(new ScrollCubeEffectInfo(anchor, angleSwing, positionSwing));
+  ScrollCubeEffectInfo info( anchor, angleSwing, positionSwing );
 
   ApplyScrollCubeConstraints( GetScrollView(), child, parentPage, info );
 }