Initialize Tizen 2.3
[apps/osp/Internet.git] / inc / IntSettingToggleCustomItem.h
1 //
2
3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Flora License, Version 1.1 (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 //!Internet SettingToggleCustomItem class
19 /*@file:        SettingToggleCustomItem.h
20  *@brief:       The SettingToggleCustomItem used to toggle the item.
21  *
22  */
23
24 #ifndef _INT_SETTING_TOGGLE_CUSTOM_ITEM_H_
25 #define _INT_SETTING_TOGGLE_CUSTOM_ITEM_H_
26
27 #include <FBase.h>
28 #include <FGraphics.h>
29 #include "IntTypes.h"
30
31 class SettingToggleCustomItem
32         : public Tizen::Ui::Controls::CustomItem
33 {
34
35 public:
36         /**
37          * @brief The Default constructor
38          */
39         SettingToggleCustomItem(void);
40
41         /**
42          * @brief The Default destructor
43          */
44         virtual ~SettingToggleCustomItem(void);
45
46         /**
47          * @brief Initializes this instance of %DropDownCustomItem.
48          *
49          * @return              An error code
50          * @param[in]   void                            An instance of the Rectangle class @n
51          *                                                                      This instance represents the x and y coordinates of the top-left corner of the created window along with
52          *                                                                      the width and height of the window.
53          * @exception   E_SUCCESS                       The method is successful.
54          * @exception   E_INVALID_STATE         This instance has already been constructed.
55          * @exception   E_INVALID_ARG       A specified input parameter is invalid.
56          * @exception   E_OUT_OF_MEMORY     The memory is insufficient.
57          * @exception   E_SYSTEM                        A system error has occurred.
58          *
59          */
60         result Construct(int width, int height);
61
62         //getter and setter methods for __text
63
64         /**
65          * @brief The method used to get the text of CustomItem
66          *
67          * @return              A String
68          */
69         Tizen::Base::String GetText(void);
70
71         /**
72          * @brief Add all the required elements and create the Custom Item.
73          *
74          * @return              An error code
75          * @param[in]   void                            An instance of the Rectangle class @n
76          *                                                                      This instance represents the x and y coordinates of the top-left corner of the created window along with
77          *                                                                      the width and height of the window.
78          * @exception   E_SUCCESS                       The method is successful.
79          * @exception   E_INVALID_STATE         This instance has already been constructed.
80          * @exception   E_INVALID_ARG       A specified input parameter is invalid.
81          * @exception   E_OUT_OF_MEMORY     The memory is insufficient.
82          * @exception   E_SYSTEM                        A system error has occurred.
83          *
84          */
85         result Make(void);
86
87         /**
88          * @brief The method used to set the text of CustomItem
89          */
90
91         void SetText(Tizen::Base::String& text);
92
93
94
95 private:
96         int __height;               ///Height of the SettingToggleCustomItem Instance
97         int __width;                ///Width of the SettingToggleCustomItem Instance
98
99         Tizen::Base::String __text;   ///The Text for the Toggle Button
100         int __fontSize;                                 ///fontsize from settings
101
102 };
103
104 #endif /* _INT_SETTING_TOGGLE_CUSTOM_ITEM_H_ */