Dali 3D User Interface Engine
stage.cpp
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2015 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
20 
21 // INTERNAL INCLUDES
28 
29 namespace Dali
30 {
31 
32 using Internal::Core;
33 
34 const Vector4 Stage::DEFAULT_BACKGROUND_COLOR(0.0f, 0.0f, 0.0f, 1.0f);
35 const Vector4 Stage::DEBUG_BACKGROUND_COLOR(0.2f, 0.5f, 0.2f, 1.0f);
36 
38 {
39 }
40 
42 {
43 }
44 
45 Stage::Stage(const Stage& handle)
46 : BaseHandle(handle)
47 {
48 }
49 
51 {
53  return *this;
54 }
55 
57 : BaseHandle(internal)
58 {
59 }
60 
62 {
64  DALI_ASSERT_ALWAYS( stage && "Stage doesn't exist" );
65  return Stage( stage );
66 }
67 
69 {
71 }
72 
73 void Stage::Add(Actor& actor)
74 {
76 }
77 
78 void Stage::Remove(Actor& actor)
79 {
81 }
82 
84 {
85  return RenderTaskList( &GetImplementation(*this).GetRenderTaskList() );
86 }
87 
89 {
90  return GetImplementation(*this).GetSize();
91 }
92 
93 unsigned int Stage::GetLayerCount() const
94 {
95  return GetImplementation(*this).GetLayerCount();
96 }
97 
98 Layer Stage::GetLayer(unsigned int depth) const
99 {
100  return GetImplementation(*this).GetLayer(depth);
101 }
102 
104 {
105  return GetImplementation(*this).GetRootLayer();
106 }
107 
109 {
110  GetImplementation(*this).SetBackgroundColor(color);
111 }
112 
114 {
115  return GetImplementation(*this).GetBackgroundColor();
116 }
117 
119 {
120  return GetImplementation(*this).GetDpi();
121 }
122 
124 {
126  DALI_ASSERT_ALWAYS( stage && "GetObjectRegistry() : Stage is null" );
127 
128  Internal::ObjectRegistry& internal = stage->GetObjectRegistry();
129  return ObjectRegistry(&internal);
130 }
131 
132 void Stage::KeepRendering( float durationSeconds )
133 {
134  GetImplementation(*this).KeepRendering( durationSeconds );
135 }
136 
138 {
139  return GetImplementation(*this).KeyEventSignal();
140 }
141 
143 {
144  return GetImplementation(*this).EventProcessingFinishedSignal();
145 }
146 
148 {
149  return GetImplementation(*this).TouchedSignal();
150 }
151 
153 {
154  return GetImplementation(*this).WheelEventSignal();
155 }
156 
158 {
159  return GetImplementation(*this).ContextLostSignal();
160 }
161 
163 {
164  return GetImplementation(*this).ContextRegainedSignal();
165 }
166 
168 {
169  return GetImplementation(*this).SceneCreatedSignal();
170 }
171 
172 } // namespace Dali
Dali Docs Home
Read more about Dali