Merge "fix klocwork issue" into tizen_2.2
[platform/framework/native/uifw.git] / inc / FUiIColorChangeEventListener.h
1 //
2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Apache License, Version 2.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 //     http://www.apache.org/licenses/LICENSE-2.0/
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17
18 /**
19  * @file                FUiIColorChangeEventListener.h
20  * @brief               This is the header file for the %IColorChangeEventListener interface.
21  *
22  * This header file contains the declarations of the %IColorChangeEventListener interface.
23  * If a change event is generated, a method of this interface is called.
24  * So, for tasks related to change events, use the methods of this interface.
25  *
26  */
27 #ifndef _FUI_ICOLOR_CHANGE_EVENT_LISTENER_H_
28 #define _FUI_ICOLOR_CHANGE_EVENT_LISTENER_H_
29
30 #include <FBaseRtIEventListener.h>
31 #include <FBaseObject.h>
32
33 namespace Tizen { namespace Graphics
34 {
35 class Color;
36 }} // Tizen::Graphics;
37
38 namespace Tizen { namespace Ui
39 {
40
41 class Control;
42
43 /**
44  * @interface   IColorChangeEventListener
45  * @brief               This interface implements the listener for the color change events.
46  *
47  * @since               2.0
48  *
49  * The %IColorChangeEventListener interface is the listener interface for receiving color change events.
50  * The class that processes a color change event implements this interface, and the instance created with that class is
51  * registered with a UI control, using the control's AddColorChangeEventListener() method. When the color change event occurs,
52  * the OnColorChanged() method of that instance is invoked.
53  * @n
54  * For more information on the class features, see <a href="../org.tizen.native.appprogramming/html/guide/ui/implementing_colorpicker.htm">ColorPicker</a>.
55  */
56 class IColorChangeEventListener
57         : public Tizen::Base::Runtime::IEventListener
58 {
59 public:
60         /**
61          * This is the destructor for this class.
62          *
63          * @since       2.0
64          */
65         virtual ~IColorChangeEventListener(void) {}
66
67         /**
68          * Called when there is a change in Color. @n
69          * The %Color instance is passed as an input parameter.
70          *
71          * @since               2.0
72          *
73          * @param[in]   source          The source of the event
74          * @param[in]   color           The color
75          */
76         virtual void OnColorChanged(const Tizen::Ui::Control& source, const Tizen::Graphics::Color& color) = 0;
77
78 protected:
79         //
80         // This method is for internal use only.
81         // Using this method can cause behavioral, security-related, and consistency-related issues in the application.
82         //
83         // This method is reserved and may change its name at any time without
84         // prior notice.
85         //
86         // @since      2.0
87         //
88         virtual void IColorChangeEventListener_Reserved1(void) {}
89
90         //
91         // This method is for internal use only.
92         // Using this method can cause behavioral, security-related, and consistency-related issues in the application.
93         //
94         // This method is reserved and may change its name at any time without
95         // prior notice.
96         //
97         // @since      2.0
98         //
99         virtual void IColorChangeEventListener_Reserved2(void) {}
100
101         //
102         // This method is for internal use only.
103         // Using this method can cause behavioral, security-related, and consistency-related issues in the application.
104         //
105         // This method is reserved and may change its name at any time without
106         // prior notice.
107         //
108         // @since      2.0
109         //
110         virtual void IColorChangeEventListener_Reserved3(void) {}
111 };      // IColorChangeEventListener
112
113 }}      // Tizen::Ui
114
115 #endif // _FUI_ICOLOR_CHANGE_EVENT_LISTENER_H_