2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
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
9 // http://www.apache.org/licenses/LICENSE-2.0/
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 FUiCtrlICustomListElement.h
20 * @brief This is the header file for the %ICustomListElement interface.
22 * This header files contains the declarations of %ICustomListElement interface.
26 #ifndef _FUI_CTRL_ICUSTOM_LIST_ELEMENT_H_
27 #define _FUI_CTRL_ICUSTOM_LIST_ELEMENT_H_
30 #include <FGrpCanvas.h>
32 namespace Tizen { namespace Ui { namespace Controls
37 * @enum CustomListItemStatus
39 * Defines the value of status of the CustomList item.
41 * @brief <i> [Deprecated] </i>
42 * @deprecated This enum is deprecated. Instead of using this enum, use the ListItemStatus enumeration.
46 enum CustomListItemStatus
48 CUSTOM_LIST_ITEM_STATUS_NORMAL = 0, /**< @if OSPDEPREC The status of the item is normal @endif */
49 CUSTOM_LIST_ITEM_STATUS_SELECTED, /**< @if OSPDEPREC The status of the item is selected @endif */
50 CUSTOM_LIST_ITEM_STATUS_FOCUSED /**< @if OSPDEPREC The status of the item is focused @endif */
55 * @interface ICustomListElement
56 * @brief <i> [Deprecated] </i> This interface represents the common behaviors for a CustomList element.
58 * @deprecated This class is deprecated. Instead of using this class, use the ICustomElement class.
62 * The %ICustomListElement interface provides interfaces used for custom drawing
63 * in a custom list item.
65 * If an application wants to draw its own contents in a custom list item, it must
66 * implement %ICustomListElement and add elements by calling SetElement(int elementId,
67 * const %ICustomListElement &element). When the custom list item needs to be redrawn,
68 * DrawElement() is called by the framework.
71 class _OSP_EXPORT_ ICustomListElement
72 : public Tizen::Base::Object
77 * This is the destructor for this class.
79 * @brief <i> [Deprecated] </i>
80 * @deprecated This class is deprecated. Instead of using this class, use the ICustomElement class.
84 virtual ~ICustomListElement(void) {}
90 * Draws a custom element of the item.
92 * @brief <i> [Deprecated] </i>
93 * @deprecated This class is deprecated. Instead of using this class, use the ICustomElement class.
96 * @return An error code
97 * @param[in] canvas The graphic canvas of the list control
98 * @param[in] rect The location and size of the CustomList element
99 * @param[in] itemStatus The status of the item
100 * @exception E_SUCCESS The method is successful.
101 * @exception E_SYSTEM A system error has occurred.
104 virtual result DrawElement(const Tizen::Graphics::Canvas& canvas, const Tizen::Graphics::Rectangle& rect, CustomListItemStatus itemStatus) = 0;
105 }; //ICustomListElement
106 }}} //Tizen::Ui::Controls
107 #endif // _FUI_CTRL_ICUSTOM_LIST_ELEMENT_H_