Dali 3D User Interface Engine
color-controller-impl.h
Go to the documentation of this file.
1 #ifndef __DALI_INTERNAL_COLOR_CONTROLLER_H__
2 #define __DALI_INTERNAL_COLOR_CONTROLLER_H__
3 
4 /*
5  * Copyright (c) 2014 Samsung Electronics Co., Ltd.
6  *
7  * Licensed under the Apache License, Version 2.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
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
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.
18  *
19  */
20 
21 // EXTERNAL INCLUDES
23 
24 // INTERNAL INCLUDES
25 #include <color-controller.h>
26 
27 namespace Dali
28 {
29 
30 namespace Internal
31 {
32 
33 namespace Adaptor
34 {
35 
40 {
41 public:
42 
47 
51  static Dali::ColorController Get();
52 
56  bool RetrieveColor( const std::string& colorCode, Vector4& colorValue );
57 
61  bool RetrieveColor( const std::string& colorCode , Vector4& textColor, Vector4& textOutlineColor, Vector4& textShadowColor);
62 
63 protected:
67  virtual ~ColorController();
68 
69 };
70 
71 } // namespace Adaptor
72 
73 } // namespace Internal
74 
75 // Additional Helpers for public-api forwarding methods
76 inline Internal::Adaptor::ColorController& GetImplementation(Dali::ColorController& controller)
77 {
78  DALI_ASSERT_ALWAYS(controller && "ColorController handle is empty");
79  BaseObject& handle = controller.GetBaseObject();
80  return static_cast<Internal::Adaptor::ColorController&>(handle);
81 }
82 
83 inline const Internal::Adaptor::ColorController& GetImplementation(const Dali::ColorController& controller)
84 {
85  DALI_ASSERT_ALWAYS(controller && "ColorController handle is empty");
86  const BaseObject& handle = controller.GetBaseObject();
87  return static_cast<const Internal::Adaptor::ColorController&>(handle);
88 }
89 
90 } // namespace Dali
91 
92 #endif // __DALI_INTERNAL_COLOR_CONTROLLER_H__
Dali Docs Home
Read more about Dali