2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
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
9 // http://floralicense.org/license/
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.
19 * @file FUiCtrl_EditDateImpl.h
20 * @brief This is the header file for the _EditDateImpl class.
22 * This header file contains the declarations of the %_EditDateImpl class.
25 #ifndef _FUI_CTRL_INTERNAL_EDITDATE_IMPL_H_
26 #define _FUI_CTRL_INTERNAL_EDITDATE_IMPL_H_
28 #include <FUiCtrlEditDate.h>
29 #include "FUi_ControlImpl.h"
30 #include "FUiCtrl_EditDate.h"
31 #include "FUiCtrl_IDateTimeChangeEventListener.h"
32 #include "FUiCtrl_PublicDateTimeChangeEvent.h"
34 namespace Tizen { namespace Ui { namespace Controls
39 , public _IDateTimeChangeEventListener
40 , virtual public Tizen::Base::Runtime::IEventListener
43 class EditDateSizeInfo : public Tizen::Ui::_ControlImpl::SizeInfo
46 EditDateSizeInfo(void);
47 virtual Tizen::Graphics::Dimension GetDefaultMinimumSize(Tizen::Ui::_ControlOrientation orientation) const;
48 virtual Tizen::Graphics::Dimension GetDefaultMaximumSize(Tizen::Ui::_ControlOrientation orientation) const;
49 void SetTitleStyle(bool titleStyle = false);
56 virtual ~_EditDateImpl(void);
57 static _EditDateImpl* CreateEditDateImplN(EditDate* pControl, const Tizen::Graphics::Point& point, const Tizen::Base::String& title);
59 virtual const char* GetPublicClassName(void) const;
60 virtual const EditDate& GetPublic(void) const;
61 virtual EditDate& GetPublic(void);
62 virtual const _EditDate& GetCore(void) const;
63 virtual _EditDate& GetCore(void);
66 result AddDateChangeEventListener(Tizen::Ui::IDateChangeEventListener& listener);
67 result RemoveDateChangeEventListener(Tizen::Ui::IDateChangeEventListener& listener);
68 Tizen::Base::DateTime GetDate(void) const;
69 int GetDay(void) const;
70 int GetMonth(void) const;
71 int GetYear(void) const;
72 void SetDate(const Tizen::Base::DateTime& date);
73 void SetCurrentDate(void);
74 result SetYear(int year);
75 result SetMonth(int month);
76 result SetDay(int day);
77 void SetDatePickerEnabled(bool enable);
78 bool IsDatePickerEnabled(void) const;
79 result SetYearRange(int minYear, int maxYear);
80 result GetYearRange(int& minYear, int& maxYear) const;
82 virtual void OnDateTimeChanged(const Tizen::Ui::_Control& source, int year, int month, int day, int hour, int minute);
83 virtual void OnDateTimeChangeCanceled(const Tizen::Ui::_Control& source);
86 static _EditDateImpl* GetInstance(EditDate& editDate);
87 static const _EditDateImpl* GetInstance(const EditDate& editDate);
90 _EditDateImpl(EditDate* pPublic, _EditDate* pCore);
92 _EditDateImpl(const _EditDateImpl&);
93 _EditDateImpl& operator =(const _EditDateImpl&);
96 _PublicDateTimeChangeEvent* __pPublicDateChangeEvent;
99 }}} // Tizen::Ui::Controls
101 #endif //_FUI_CTRL_INTERNAL_EDITDATE_IMPL_H_