Tizen 2.1 base
[framework/osp/uifw.git] / inc / FUiIDateChangeEventListener.h
1 //
2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Flora License, Version 1.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://floralicense.org/license/
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  * @file                FUiIDateChangeEventListener.h
19  * @brief               This is the header file for the %IDateChangeEventListener interface.
20  *
21  * This header file contains the declarations of the %IDateChangeEventListener interface.
22  * If a change event is generated, a method of this interface is called.
23  * So, for tasks related to the change events, use the methods of this interface.
24  *
25  */
26 #ifndef _FUI_IDATE_CHANGE_EVENT_LISTENER_H_
27 #define _FUI_IDATE_CHANGE_EVENT_LISTENER_H_
28
29 // Includes
30 #include <FBaseRtIEventListener.h>
31 #include <FBaseObject.h>
32
33 namespace Tizen { namespace Ui
34 {
35 class Control;
36 } }
37
38 namespace Tizen {namespace Ui
39 {
40
41 /**
42  * @interface   IDateChangeEventListener
43  * @brief               This interface implements the listener for Date change events.
44  *
45  * @since               2.0
46  *
47  * The %IDateChangeEventListener interface is the listener interface for receiving date change events.
48  * The class that processes a date change event implements this interface, and the instance created with that class is registered
49  * with a UI control, using the control's AddDateChangeEventListener() method. When the date change event occurs, the
50  * OnDateChanged() method of that instance is invoked.
51  * @n
52  * For more information on the class features, see <a href="../org.tizen.native.appprogramming/html/guide/ui/implementing_edittime_editdate.htm">EditDate and EditTime</a> and <a href="../org.tizen.native.appprogramming/html/guide/ui/implementing_datepicker.htm">DatePicker, TimePicker, and DateTimePicker</a>.
53  */
54 class _OSP_EXPORT_ IDateChangeEventListener
55         : public Tizen::Base::Runtime::IEventListener
56 {
57 // Operation
58 public:
59         /**
60          * This is the destructor for this class.
61          *
62          * @since                       2.0
63          */
64         virtual ~IDateChangeEventListener(void) {}
65
66         /**
67          * Called when there is a change in the date. @n
68          * The changed values of the year, month, and day are passed as input parameters.
69          *
70          * @since               2.0
71          *
72          * @param[in]   source          The source of the event
73          * @param[in]   year            The year
74          * @param[in]   month           The month
75          * @param[in]   day                     The day
76          */
77         virtual void OnDateChanged(const Tizen::Ui::Control& source, int year, int month, int day) = 0;
78
79
80         /**
81         * Called when the change in date is canceled.
82         *
83         * @since                2.0
84         *
85         * @param[in]    source          The source of the event
86         */
87         virtual void OnDateChangeCanceled(const Tizen::Ui::Control& source) = 0;
88
89 protected:
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 IDateChangeEventListener_Reserved1(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 IDateChangeEventListener_Reserved2(void) {}
111
112         //
113         // This method is for internal use only.
114         // Using this method can cause behavioral, security-related, and consistency-related issues in the application.
115         //
116         // This method is reserved and may change its name at any time without
117         // prior notice.
118         //
119         // @since      2.0
120         //
121         virtual void IDateChangeEventListener_Reserved3(void) {}
122
123 }; // IDateChangeEventListener
124
125 }}  // Tizen::Ui
126
127 #endif // _FUI_IDATE_CHANGE_EVENT_LISTENER_H_