1 #ifndef __DALI_INTERNAL_PROPERTY_CONDITIONS_H__
2 #define __DALI_INTERNAL_PROPERTY_CONDITIONS_H__
5 // Copyright (c) 2014 Samsung Electronics Co., Ltd.
7 // Licensed under the Flora License, Version 1.0 (the License);
8 // you may not use this file except in compliance with the License.
9 // You may obtain a copy of the License at
11 // http://floralicense.org/license/
13 // Unless required by applicable law or agreed to in writing, software
14 // distributed under the License is distributed on an AS IS BASIS,
15 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 // See the License for the specific language governing permissions and
17 // limitations under the License.
21 #include <dali/public-api/common/dali-common.h>
22 #include <dali/public-api/object/base-object.h>
23 #include <dali/public-api/object/property-conditions.h>
24 #include <dali/public-api/object/property-value.h>
25 #include <dali/public-api/object/property-value.h>
34 * Structure to contain PropertyCondition internal data
37 class PropertyCondition : public Dali::BaseObject
47 False, ///< Result Always False
48 LessThan, ///< Magnitude of type is less than float value (arg0).
49 GreaterThan, ///< Magnitude of type is greater than float value (arg0).
50 Inside, ///< Magnitude of type is within float values (arg0 & arg1).
51 Outside, ///< Magnitude of type is outside float values (arg0 & arg1).
52 Step, ///< Value of type has crossed a step amount
53 VariableStep ///< Similar to step, except user can define a list of steps from reference value
56 typedef Dali::PropertyCondition::ArgumentContainer ArgumentContainer;
57 typedef Dali::PropertyCondition::ArgumentIter ArgumentIter;
58 typedef Dali::PropertyCondition::ArgumentConstIter ArgumentConstIter;
62 virtual ~PropertyCondition();
69 PropertyCondition(const PropertyCondition& rhs);
72 PropertyCondition& operator=(const PropertyCondition& rhs);
76 Type type; ///< The condition Type.
77 ArgumentContainer arguments; ///< The condition Arguments.
81 } // namespace Internal
83 // Helpers for public-api forwarding methods
85 inline Internal::PropertyCondition& GetImplementation(Dali::PropertyCondition& pub)
87 DALI_ASSERT_ALWAYS( pub && "PropertyCondition handle is empty" );
89 BaseObject& handle = pub.GetBaseObject();
91 return static_cast<Internal::PropertyCondition&>(handle);
94 inline const Internal::PropertyCondition& GetImplementation(const Dali::PropertyCondition& pub)
96 DALI_ASSERT_ALWAYS( pub && "PropertyCondition handle is empty" );
98 const BaseObject& handle = pub.GetBaseObject();
100 return static_cast<const Internal::PropertyCondition&>(handle);
105 #endif // __DALI_INTERNAL_PROPERTY_CONDITIONS_H__