Follow the include-order coding conventions
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / public-api / controls / cluster / cluster-style.cpp
1 /*
2  * Copyright (c) 2014 Samsung Electronics Co., Ltd.
3  *
4  * Licensed under the Apache License, Version 2.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
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
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.
15  *
16  */
17
18 // CLASS HEADER
19 #include <dali-toolkit/public-api/controls/cluster/cluster-style.h>
20
21 // INTERNAL INCLUDES
22 #include <dali-toolkit/internal/controls/cluster/cluster-style-impl.h>
23
24 using namespace Dali;
25 using namespace Dali::Toolkit;
26
27 namespace Dali
28 {
29
30 namespace Toolkit
31 {
32
33 // ClusterStyle ///////////////////////////////////////////////////////////////
34
35 const unsigned int ClusterStyle::UNLIMITED_CHILDREN = std::numeric_limits<unsigned int>::max();
36
37 ClusterStyle::ClusterStyle()
38 {
39 }
40
41 ClusterStyle::~ClusterStyle()
42 {
43 }
44
45 ClusterStyle::ClusterStyle(Internal::ClusterStyle* internal)
46 : BaseHandle(internal)
47 {
48 }
49
50 unsigned int ClusterStyle::GetMaximumNumberOfChildren() const
51 {
52   return GetImpl(*this).GetMaximumNumberOfChildren();
53 }
54
55 void ClusterStyle::ApplyStyle(Actor child, unsigned int index, AlphaFunction alpha, const TimePeriod& durationSeconds)
56 {
57   GetImpl(*this).ApplyStyle(child, index, alpha, durationSeconds);
58 }
59
60 void ClusterStyle::ApplyStyleToBackground(Actor background, AlphaFunction alpha, const TimePeriod& durationSeconds)
61 {
62   GetImpl(*this).ApplyStyleToBackground(background, alpha, durationSeconds);
63 }
64
65 void ClusterStyle::ApplyStyleToTitle(Actor title, AlphaFunction alpha, const TimePeriod& durationSeconds)
66 {
67   GetImpl(*this).ApplyStyleToTitle(title, alpha, durationSeconds);
68 }
69
70 // ClusterStyleStandard ///////////////////////////////////////////////////////
71
72 ClusterStyleStandard ClusterStyleStandard::New(StyleType style)
73 {
74   Internal::ClusterStylePtr internal = Internal::ClusterStyleStandard::New(style);
75
76   return ClusterStyleStandard(internal.Get());
77 }
78
79 ClusterStyleStandard::ClusterStyleStandard(Internal::ClusterStyle* internal)
80 : ClusterStyle(internal)
81 {
82 }
83
84 // ClusterStyleRandom /////////////////////////////////////////////////////////
85
86 ClusterStyleRandom ClusterStyleRandom::New()
87 {
88   Internal::ClusterStylePtr internal = Internal::ClusterStyleRandom::New();
89
90   return ClusterStyleRandom(internal.Get());
91 }
92
93 ClusterStyleRandom::ClusterStyleRandom(Internal::ClusterStyle* internal)
94 : ClusterStyle(internal)
95 {
96 }
97
98 } // namespace Toolkit
99
100 } // namespace Dali