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.
18 * @file FUiCtrl_CustomListItemFormatImpl.h
19 * @brief This is the header file for the _CustomListItemFormatImpl class.
21 * This header file contains the declarations of the _CustomListItemFormatImpl class and its helper classes.
24 #ifndef _FUI_CTRL_INTERNAL_CUSTOM_LIST_ITEM_FORMAT_IMPL_H_
25 #define _FUI_CTRL_INTERNAL_CUSTOM_LIST_ITEM_FORMAT_IMPL_H_
27 #include <FBaseObject.h>
28 #include <FGrpRectangle.h>
29 #include <FGrpColor.h>
30 #include <FBaseColLinkedList.h>
32 namespace Tizen { namespace Ui { namespace Controls
35 class _ElementFormatData
36 : public Tizen::Base::Object
39 _ElementFormatData(void);
40 ~_ElementFormatData(void);
43 _ElementFormatData(const _ElementFormatData& rhs);
44 _ElementFormatData& operator =(const _ElementFormatData& rhs);
48 Tizen::Graphics::Rectangle rect;
50 Tizen::Graphics::Color normalTextColor;
51 Tizen::Graphics::Color focusedTextColor;
52 Tizen::Graphics::Color highlightedTextColor;
54 }; //_ElementFormatData
57 class _CustomListItemFormatImpl
58 : public Tizen::Base::Object
61 virtual ~_CustomListItemFormatImpl(void);
62 static _CustomListItemFormatImpl* CreateInstanceN(void);
64 result AddElement(int elementId, const Tizen::Graphics::Rectangle& rect);
65 result AddElement(int elementId, const Tizen::Graphics::Rectangle& rect, int textSize);
66 result AddElement(int elementId, const Tizen::Graphics::Rectangle& rect, int textSize, const Tizen::Graphics::Color& normalTextColor, const Tizen::Graphics::Color& focusedTextColor);
67 result AddElement(int elementId, const Tizen::Graphics::Rectangle& rect, int textSize, const Tizen::Graphics::Color& normalTextColor, const Tizen::Graphics::Color& focusedTextColor, const Tizen::Graphics::Color& highlightedTextColor);
69 Tizen::Graphics::Rectangle GetElement(int elementId) const;
70 int GetFirstElementId(void);
71 int GetFirstEnabledElementId(void);
72 int GetNextElementId(int elementId);
73 int GetNextEnabledElementId(int elementId);
74 int GetPreviousEnabledElementId(int elementId);
75 bool IsElementEventEnabled(int elementId);
76 void SetElementEventEnabled(int elementId, bool enable);
78 _ElementFormatData* GetElementFormatById(int elementId);
81 _CustomListItemFormatImpl(void);
82 _CustomListItemFormatImpl(const _CustomListItemFormatImpl& rhs);
83 _CustomListItemFormatImpl& operator =(const _CustomListItemFormatImpl& rhs);
85 _ElementFormatData* CreateElementN(int elementId);
88 Tizen::Base::Collection::LinkedList elementFormatDataList;
89 }; //_CustomListItemFormatImpl
91 }}} //Tizen::Ui::Controls
93 #endif //_FUI_CTRL_INTERNAL_CUSTOM_LIST_ITEM_FORMAT_IMPL_H_