[Tizen] Revert "Use touch consumed return to set whether we process a gesture or...
[platform/core/uifw/dali-core.git] / dali / internal / event / animation / constrainer.h
index e7042b8..21726bb 100644 (file)
@@ -1,8 +1,8 @@
-#ifndef __DALI_INTERNAL_CONSTRAINER_H__
-#define __DALI_INTERNAL_CONSTRAINER_H__
+#ifndef DALI_INTERNAL_CONSTRAINER_H
+#define DALI_INTERNAL_CONSTRAINER_H
 
 /*
- * Copyright (c) 2018 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2021 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.
 
 namespace Dali
 {
-
 namespace Internal
 {
-
-typedef Dali::Vector<Object*>         ObjectContainer;
-typedef ObjectContainer::Iterator     ObjectIter;
+typedef Dali::Vector<Object*> ObjectContainer;
+using ObjectIter = ObjectContainer::Iterator;
 
 /**
  * An abstract base class for constrainers.
@@ -39,7 +37,6 @@ typedef ObjectContainer::Iterator     ObjectIter;
 class Constrainer : public Object, public Object::Observer
 {
 public:
-
   /**
    * Constructor.
    */
@@ -48,27 +45,29 @@ public:
   /**
    * Virtual destructor.
    */
-  virtual ~Constrainer();
+  ~Constrainer() override;
 
 public: // Object::Observer methods
-
   /**
    * @copydoc Object::Observer::SceneObjectAdded()
    */
-  virtual void SceneObjectAdded( Object& object ){}
+  void SceneObjectAdded(Object& object) override
+  {
+  }
 
   /**
    * @copydoc Object::Observer::SceneObjectRemoved()
    */
-  virtual void SceneObjectRemoved( Object& object ){}
+  void SceneObjectRemoved(Object& object) override
+  {
+  }
 
   /**
    * @copydoc Object::Observer::ObjectDestroyed()
    */
-  virtual void ObjectDestroyed( Object& object );
+  void ObjectDestroyed(Object& object) override;
 
 public:
-
   /**
    * @brief Applies the constraint to the target property
 
@@ -77,31 +76,29 @@ public:
    * @param[in] range The range of values in the source property which will be mapped to [0,1]
    * @param[in] wrap Wrapping domain. Source property will be wrapped in the domain [wrap.x,wrap.y] before mapping to [0,1]
    */
-  virtual void Apply( Property target, Property source, const Vector2& range, const Vector2& wrap) = 0;
+  virtual void Apply(Property target, Property source, const Vector2& range, const Vector2& wrap) = 0;
 
   /**
    * @brief Removes the constraint in the target object
    *
    * @param[in] target A handle to an object constrained by the Constrainer
    */
-  void Remove( Dali::Handle& target );
+  void Remove(Dali::Handle& target);
 
 protected:
-
   /**
    * @brief Adds an object to the list of observed objects
    *
    * @param[in] handle A handle to the object to be observed
    */
-  void Observe( Dali::Handle& handle );
+  void Observe(Dali::Handle& handle);
 
 private:
-
-  ObjectContainer   mObservedObjects;   ///< The list of object which have been constrained by the Constrainer
+  ObjectContainer mObservedObjects; ///< The list of object which have been constrained by the Constrainer
 };
 
 } // namespace Internal
 
 } // namespace Dali
 
-#endif // __DALI_INTERNAL_CONSTRAINER_H__
+#endif // DALI_INTERNAL_CONSTRAINER_H