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 FUiCtrlGroupedList.h
20 * @brief This is the header file for the %GroupedList class.
22 * This header file contains the declarations of the %GroupedList class and its helper classes.
25 #ifndef _FUI_CTRL_GROUPED_LIST_H_
26 #define _FUI_CTRL_GROUPED_LIST_H_
28 #include <FBaseObject.h>
29 #include <FBaseTypes.h>
30 #include <FGrpRectangle.h>
31 #include <FUiControl.h>
32 #include <FUiContainer.h>
33 #include <FUiCtrlCustomList.h>
34 #include <FUiCtrlControlsTypes.h>
35 #include <FUiIFastScrollEventListener.h>
36 #include <FUiIGroupedItemEventListener.h>
37 #include <FUiCtrlListTypes.h>
39 namespace Tizen { namespace Ui { namespace Controls {
44 * @brief <i> [Deprecated] </i> This class defines the common behavior of a %GroupedList control.
46 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
49 * The %GroupedList class represents grouped items in a list. List items of
50 * %GroupedList consist of groups and items. A group represents grouped items and is
51 * inserted into the first level as items are inserted into List. Items which are
52 * CustomListItem are inserted under related groups. So, items are uniquely identified
53 * with two indices: group index and item index.
55 * If an application wants to perform tasks when the state of a list item is changed,
56 * it must implement IGroupedItemEventListener and register it to the grouped list,
57 * It will then receive related events from %GroupedList.
59 * Unlike ExpandableList which is also a list with a hierarchy of depth 2, group
60 * item itself does not have many functions.
62 * A typical use case of %GroupedList would be a list which groups all items alphabetically.
64 * Note that CustomListItem and CustomListItemFormat need to be created on a heap. CustomListItems will be deleted automatically
65 * when the %GroupedList itself is destroyed. If you want to remove certain list items, you must use RemoveItemAt(). CustomListItemFormat
66 * must be deleted by the application.
68 * Refer to CustomListItem and CustomListItemFormat.
72 * @image html ui_controls_groupedlist.png
74 * This is the simple UI application that uses a %GroupedList control.
77 // Sample code for GroupedListSample.h
81 class GroupedListSample
82 :public Tizen::Ui::Controls::Form
83 , public Tizen::Ui::ICustomItemEventListener
86 GroupedListSample(void)
87 : __pGroupedList(null)
88 , __pCustomListItemFormat(null){}
90 bool Initialize(void);
91 result AddListItem(Tizen::Ui::Controls::GroupedList& groupedList, int groupId, Tizen::Base::String itemText,
92 Tizen::Graphics::Bitmap* pBitmapNormal, Tizen::Graphics::Bitmap* pBitmapFocused);
94 virtual result OnInitializing(void);
95 virtual result OnTerminating(void);
97 // ICustomItemEventListener
98 virtual void OnItemStateChanged(const Tizen::Ui::Control& source, int index, int itemId, Tizen::Ui::ItemStatus status);
99 virtual void OnItemStateChanged(const Tizen::Ui::Control& source, int index, int itemId, int elementId, Tizen::Ui::ItemStatus status);
102 static const int ID_LIST_ = 101;
103 static const int ID_LIST_TEXT = 102;
104 static const int ID_LIST_BITMAP = 103;
106 Tizen::Ui::Controls::GroupedList* __pGroupedList;
107 Tizen::Ui::Controls::CustomListItemFormat* __pCustomListItemFormat;
112 // Sample code for CutomListSample.cpp
114 #include <FGraphics.h>
116 #include "GroupedListSample.h"
118 using namespace Tizen::App;
119 using namespace Tizen::Base;
120 using namespace Tizen::Graphics;
121 using namespace Tizen::Ui;
122 using namespace Tizen::Ui::Controls;
125 GroupedListSample::Initialize(void)
127 Construct(FORM_STYLE_NORMAL);
132 GroupedListSample::OnInitializing(void)
134 result r = E_SUCCESS;
136 // Creates an instance of GroupedList
137 __pGroupedList = new GroupedList();
138 __pGroupedList->Construct(Rectangle(0,0,GetClientAreaBounds().width,GetClientAreaBounds().height), CUSTOM_LIST_STYLE_NORMAL);
140 // Creates an instance of CustomListItemFormat of the grouped list
141 __pCustomListItemFormat = new CustomListItemFormat();
142 __pCustomListItemFormat->Construct();
143 __pCustomListItemFormat->AddElement(ID_LIST_TEXT, Rectangle(10, 25, 200, 80));
144 __pCustomListItemFormat->AddElement(ID_LIST_BITMAP, Rectangle(220, 10, 70, 80));
146 // Adds the groups to the grouped list
147 __pGroupedList->AddGroup(L"Group_1", null);
148 __pGroupedList->AddGroup(L"Group_2", null);
149 __pGroupedList->AddGroup(L"Group_3", null);
151 // Gets instances of Bitmap
152 AppResource *pAppResource = Application::GetInstance()->GetAppResource();
153 Bitmap *pBitmapNormal = pAppResource->GetBitmapN(L"tizen.png");
154 Bitmap *pBitmapFocused = pAppResource->GetBitmapN(L"tizen.png");
156 // Adds the items to the grouped list
157 for (int i = 0; i < __pGroupedList->GetGroupCount(); i++ )
159 AddListItem(*__pGroupedList, i, L"SubItem1", pBitmapNormal, pBitmapFocused);
160 AddListItem(*__pGroupedList, i, L"SubItem2", pBitmapNormal, pBitmapFocused);
161 AddListItem(*__pGroupedList, i, L"SubItem3", pBitmapNormal, pBitmapFocused);
162 AddListItem(*__pGroupedList, i, L"SubItem4", pBitmapNormal, pBitmapFocused);
165 // Adds the grouped list to the form
166 AddControl(*__pGroupedList);
168 // Deallocates bitmaps
169 delete pBitmapNormal;
170 delete pBitmapFocused;
176 GroupedListSample::OnTerminating(void)
178 result r = E_SUCCESS;
180 // Deallocates the item format
181 delete __pCustomListItemFormat;
187 GroupedListSample::AddListItem(GroupedList& groupedList, int groupId, String itemText, Bitmap* pBitmapNormal, Bitmap* pBitmapFocused)
189 result r = E_SUCCESS;
191 // Creates an instance of CustomListItem of the grouped list
192 CustomListItem* pItem = new CustomListItem();
193 pItem->Construct(100);
194 pItem->SetItemFormat(*__pCustomListItemFormat);
195 pItem->SetElement(ID_LIST_TEXT, itemText);
196 pItem->SetElement(ID_LIST_BITMAP, *pBitmapNormal, pBitmapFocused);
198 // Adds the item to the grouped list
199 groupedList.AddItem(groupId, *pItem, ID_LIST_);
204 // ICustomItemEventListener implementation
206 GroupedListSample::OnItemStateChanged(const Control& source, int index, int itemId, ItemStatus status)
221 GroupedListSample::OnItemStateChanged(const Control& source, int index, int itemId, int elementId, ItemStatus status)
251 class _OSP_EXPORT_ GroupedList
252 : public Tizen::Ui::Control
257 * The object is not fully constructed after this constructor is called. For full construction, the Construct() method must be called right after calling this constructor.
259 * @brief <i> [Deprecated] </i>
260 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
268 * This polymorphic destructor should be overridden if required. This way, the destructors of the derived classes are called when the destructor of this interface is called.
270 * @brief <i> [Deprecated] </i>
271 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
275 virtual ~GroupedList(void);
279 * Initializes this instance of %GroupedList with the specified parameters.
281 * @brief <i> [Deprecated] </i>
282 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
285 * @return An error code
286 * @param[in] rect An instance of the Graphics::Rectangle class @n
287 * This instance represents the X, Y coordinates of the top-left corner of the created %GroupedList along with the width and
289 * @param[in] style The style of the %GroupedList control
290 * @param[in] itemDivider Set to @c true to display an item divider, @n
292 * @param[in] fastScroll Set to @c true if to use a fast scroll, @n
294 * @exception E_SUCCESS The method is successful.
295 * @exception E_INVALID_ARG A specified input parameter is invalid.
296 * @exception E_SYSTEM A system error has occurred.
297 * @remarks The size of the control must be within the range as defined by the minimum and maximum size.
298 * @remarks The minimum size of this control is 274 x 148 on a WVGA screen, 180 x 96 on a HVGA screen and 137 x 74 on a WQVGA screen.
301 result Construct(const Tizen::Graphics::Rectangle& rect, CustomListStyle style, bool itemDivider = true, bool fastScroll = false);
305 * Adds the group to the %GroupedList control.
307 * @brief <i> [Deprecated] </i>
308 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
311 * @return An error code
312 * @param[in] text The string of the group to be appended
313 * @param[in] pBackgroundBitmap The background bitmap of the group
314 * @param[in] groupId The ID of the group
315 * @exception E_SUCCESS The method is successful.
316 * @exception E_SYSTEM A system error has occurred.
319 result AddGroup(const Tizen::Base::String& text, const Tizen::Graphics::Bitmap* pBackgroundBitmap, int groupId = LIST_ITEM_UNSPECIFIED_ID);
323 * Inserts the group of the %GroupedList control at the specified index.
325 * @brief <i> [Deprecated] </i>
326 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
329 * @return An error code
330 * @param[in] groupIndex The group index
331 * @param[in] text The name of the group item
332 * @param[in] pBackgroundBitmap The background bitmap of the group item
333 * @param[in] groupId The ID of the group item
334 * @exception E_SUCCESS The method is successful.
335 * @exception E_INVALID_ARG The @c groupIndex is out of bounds.
336 * @exception E_SYSTEM A system error has occurred.
339 result InsertGroupAt(int groupIndex, const Tizen::Base::String& text, const Tizen::Graphics::Bitmap* pBackgroundBitmap, int groupId = LIST_ITEM_UNSPECIFIED_ID);
343 * Sets the contents of the group of the %GroupedList control at the index.
345 * @brief <i> [Deprecated] </i>
346 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
349 * @return An error code
350 * @param[in] groupIndex The group index
351 * @param[in] text The string of the group to be appended
352 * @param[in] pBackgroundBitmap The bitmap of the group
353 * @param[in] groupId The ID of the group
354 * @exception E_SUCCESS The method is successful.
355 * @exception E_INVALID_ARG The specified @c groupIndex is invalid.
356 * @exception E_SYSTEM A system error has occurred.
359 result SetGroupAt(int groupIndex, const Tizen::Base::String& text, const Tizen::Graphics::Bitmap* pBackgroundBitmap, int groupId = LIST_ITEM_UNSPECIFIED_ID);
363 * Removes the group of the %GroupedList control at the index.
365 * @brief <i> [Deprecated] </i>
366 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
369 * @return An error code
370 * @param[in] groupIndex The group index
371 * @exception E_SUCCESS The method is successful.
372 * @exception E_INVALID_ARG The specified @c groupIndex is invalid.
373 * @exception E_SYSTEM A system error has occurred.
374 * @remarks When the specified group is removed, all the items in the group are also removed. @n
375 * The removed list items are deleted from the memory.
378 result RemoveGroupAt(int groupIndex);
382 * Removes all the groups of the %GroupedList control.
384 * @brief <i> [Deprecated] </i>
385 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
388 * @return An error code
389 * @exception E_SUCCESS The method is successful.
390 * @exception E_SYSTEM A system error has occurred.
391 * @remarks When the specified group is removed, all the items in the group are also removed. @n
392 * The removed list items are deleted from the memory.
395 result RemoveAllGroups(void);
399 * Counts all the groups of the %GroupedList control.
401 * @brief <i> [Deprecated] </i>
402 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
405 * @return The count of all the groups
408 int GetGroupCount(void) const;
412 * Adds the item to the specified group.
414 * @brief <i> [Deprecated] </i>
415 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
418 * @return An error code
419 * @param[in] groupIndex The group index
420 * @param[in] item The custom list item object to be added
421 * @param[in] itemId The specified item ID for this item
422 * @exception E_SUCCESS The method is successful.
423 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemId is invalid.
424 * @exception E_SYSTEM A system error has occurred.
425 * @remarks The added item is deleted automatically when the list is destroyed. @n
426 * Do not add, insert, or set an item that already belongs to a %GroupedList control.
429 result AddItem(int groupIndex, const CustomListItem& item, int itemId = LIST_ITEM_UNSPECIFIED_ID);
433 * Inserts the item to the specified group.
435 * @brief <i> [Deprecated] </i>
436 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
439 * @return An error code
440 * @param[in] groupIndex The group index
441 * @param[in] itemIndex The item index in the specified group
442 * @param[in] item The custom list item to be inserted
443 * @param[in] itemId The item ID for this item
444 * @exception E_SUCCESS The method is successful.
445 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemId is invalid.
446 * @exception E_SYSTEM A system error has occurred.
447 * @remarks The inserted item is deleted automatically when the list is destroyed.
448 * Do not add, insert, or set an item that already belongs to a %GroupedList control.
451 result InsertItemAt(int groupIndex, int itemIndex, const CustomListItem& item, int itemId = LIST_ITEM_UNSPECIFIED_ID);
455 * Sets the contents of the item in the specified group.
457 * @brief <i> [Deprecated] </i>
458 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
461 * @return An error code
462 * @param[in] groupIndex The group index
463 * @param[in] itemIndex The item index in the specified group
464 * @param[in] item The custom list item to be set
465 * @param[in] itemId The item ID for this item
466 * @exception E_SUCCESS The method is successful.
467 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemId is invalid.
468 * @exception E_SYSTEM A system error has occurred.
469 * @remarks Do not add, insert, or set an item that already belongs to a %GroupedList control.
472 result SetItemAt(int groupIndex, int itemIndex, const CustomListItem& item, int itemId = LIST_ITEM_UNSPECIFIED_ID);
476 * Sets the checked status for the specified item.
478 * @brief <i> [Deprecated] </i>
479 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
482 * @return An error code
483 * @param[in] groupIndex The group index of the item
484 * @param[in] itemIndex The item index
485 * @param[in] check Set to @c true to check the item, @n
487 * @exception E_SUCCESS The method is successful.
488 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemIndex is invalid.
489 * @exception E_SYSTEM A system error has occurred.
492 result SetItemChecked(int groupIndex, int itemIndex, bool check);
496 * Enables or disables the item at the specified index of the %GroupedList.
498 * @brief <i> [Deprecated] </i>
499 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
502 * @return An error code
503 * @param[in] groupIndex The group index of the item
504 * @param[in] itemIndex The item index
505 * @param[in] enable Set to @c true to enable the item, @n
507 * @exception E_SUCCESS The method is successful.
508 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemIndex is invalid.
509 * @exception E_SYSTEM A system error has occurred.
512 result SetItemEnabled(int groupIndex, int itemIndex, bool enable);
516 * Sets the background color of this control.
518 * @brief <i> [Deprecated] </i>
519 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
522 * @param[in] color The background color
525 void SetBackgroundColor(const Tizen::Graphics::Color& color);
529 * Sets the text that is displayed when %GroupedList is empty.
531 * @brief <i> [Deprecated] </i>
532 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
535 * @param[in] text The empty list test
538 void SetTextOfEmptyList(const Tizen::Base::String& text);
542 * Sets the color of the text that is displayed when %GroupedList is empty.
544 * @brief <i> [Deprecated] </i>
545 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
548 * @param[in] color The color of the text to be displayed
551 void SetTextColorOfEmptyList(const Tizen::Graphics::Color& color);
555 * Gets the color of the text that is displayed when %GroupedList is empty.
557 * @brief <i> [Deprecated] </i>
558 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
561 * @return The color of the text to be displayed
564 Tizen::Graphics::Color GetTextColorOfEmptyList(void) const;
568 * Checks whether the item at the specified index of this grouped list is checked.
570 * @brief <i> [Deprecated] </i>
571 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
574 * @return @c true if the item is checked, @n
576 * @param[in] groupIndex The group index of the item
577 * @param[in] itemIndex The item index
578 * @exception E_SUCCESS The method is successful.
579 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemIndex is invalid.
580 * @exception E_SYSTEM A system error has occurred.
581 * @remarks This method can only be used when the style of the list allows selection.
584 bool IsItemChecked(int groupIndex, int itemIndex) const;
588 * Checks whether the item at the specified index is enabled.
590 * @brief <i> [Deprecated] </i>
591 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
594 * @return @c true if the item is enabled, @n
596 * @param[in] groupIndex The group index of the item
597 * @param[in] itemIndex The item index
598 * @exception E_SUCCESS The method is successful.
599 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemIndex is invalid.
600 * @exception E_SYSTEM A system error has occurred.
603 bool IsItemEnabled(int groupIndex, int itemIndex) const;
607 * Removes an item in the specified group.
609 * @brief <i> [Deprecated] </i>
610 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
613 * @return An error code
614 * @param[in] groupIndex The group index
615 * @param[in] itemIndex The item index
616 * @exception E_SUCCESS The method is successful.
617 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemIndex is invalid.
618 * @exception E_SYSTEM A system error has occurred.
619 * @remarks The removed list item is deleted from the memory.
622 result RemoveItemAt(int groupIndex, int itemIndex);
626 * Removes all the items in the specified group.
628 * @brief <i> [Deprecated] </i>
629 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
632 * @return An error code
633 * @param[in] groupIndex The group index
634 * @exception E_SUCCESS The method is successful.
635 * @exception E_INVALID_ARG The specified @c groupIndex is invalid.
636 * @exception E_SYSTEM A system error has occurred.
637 * @remarks The removed list items are deleted from the memory.
640 result RemoveAllItemsAt(int groupIndex);
644 * Removes all the checked items in the specified group.
646 * @brief <i> [Deprecated] </i>
647 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
650 * @return An error code
651 * @param[in] groupIndex The group index
652 * @exception E_SUCCESS The method is successful.
653 * @exception E_INVALID_ARG The specified @c groupIndex is invalid.
654 * @exception E_SYSTEM A system error has occurred.
655 * @remarks The removed list items are deleted from the memory.
658 result RemoveAllCheckedItemsAt(int groupIndex);
662 * Counts all items of the %GroupedList instance.
664 * @brief <i> [Deprecated] </i>
665 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
668 * @return The item count of the specified group
669 * @param[in] groupIndex The group index
670 * @exception E_SUCCESS The method is successful.
671 * @exception E_INVALID_ARG The specified @c groupIndex is invalid.
672 * @exception E_SYSTEM A system error has occurred.
675 int GetItemCountAt(int groupIndex) const;
679 * Gets the item ID of the item at the specified index.
681 * @brief <i> [Deprecated] </i>
682 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
685 * @return The item ID
686 * @param[in] groupIndex The group index
687 * @param[in] itemIndex The item index in the specified group
688 * @exception E_SUCCESS The method is successful.
689 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemIndex is invalid.
690 * @exception E_SYSTEM A system error has occurred.
693 int GetItemIdAt(int groupIndex, int itemIndex) const;
697 * Gets the item index by the specified item ID.
699 * @brief <i> [Deprecated] </i>
700 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
703 * @return An error code
704 * @param[in] itemId The item ID
705 * @param[out] groupIndex The group index
706 * @param[out] itemIndex The item index in the specified group
707 * @exception E_SUCCESS The method is successful.
708 * @exception E_SYSTEM A system error has occurred.
711 result GetItemIndexFromItemId(int itemId, int& groupIndex, int& itemIndex) const;
715 * Gets the group ID at the specified index.
717 * @brief <i> [Deprecated] </i>
718 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
721 * @return The group ID
722 * @param[in] groupIndex The group index
723 * @exception E_SUCCESS The method is successful.
724 * @exception E_INVALID_ARG The specified @c groupIndex is invalid.
725 * @exception E_SYSTEM A system error has occurred.
728 int GetGroupIdAt(int groupIndex) const;
732 * Gets the group index from the specified group ID.
734 * @brief <i> [Deprecated] </i>
735 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
738 * @return The group index
739 * @param[in] groupId The ID of the group
740 * @exception E_SUCCESS The method is successful.
741 * @exception E_SYSTEM A system error has occurred.
744 int GetGroupIndexFromGroupId(int groupId) const;
748 * Gets the index of the last item checked.
750 * @brief <i> [Deprecated] </i>
751 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
754 * @return An error code
755 * @param[out] groupIndex The group index
756 * @param[out] itemIndex The item index in the specified group
757 * @exception E_SUCCESS The method is successful.
758 * @exception E_SYSTEM A system error has occurred.
761 result GetLastCheckedItemIndex(int& groupIndex, int& itemIndex) const;
765 * Gets the index of the next checked item.
767 * @brief <i> [Deprecated] </i>
768 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
771 * @return An error code
772 * @param[in,out] groupIndex The group index
773 * @param[in,out] itemIndex The item index in the specified group
774 * @exception E_SUCCESS The method is successful.
775 * @exception E_SYSTEM A system error has occurred.
778 result GetNextCheckedItemIndexAfter(int& groupIndex, int& itemIndex) const;
782 * Gets the index of the item at the specified item position.
784 * @brief <i> [Deprecated] </i>
785 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
788 * @return An error code
789 * @param[in] x The x position of the point
790 * @param[in] y The y position of the point
791 * @param[out] groupIndex The index of the group which the item belongs to
792 * @param[out] itemIndex The index of the item
793 * @exception E_SUCCESS The method is successful.
794 * @exception E_SYSTEM A system error has occurred. @n
795 * There is no item at the specified position.
798 result GetItemIndexFromPosition(int x, int y, int& groupIndex, int& itemIndex) const;
802 * Gets the index of the item at the specified item position.
804 * @brief <i> [Deprecated] </i>
805 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
808 * @return An error code
809 * @param[in] position The position of the point
810 * @param[out] groupIndex The index of the group which the item belongs to
811 * @param[out] itemIndex The index of the item
812 * @exception E_SUCCESS The method is successful.
813 * @exception E_SYSTEM A system error has occurred. @n
814 * There is no item at the specified position.
817 result GetItemIndexFromPosition(const Tizen::Graphics::Point& position, int& groupIndex, int& itemIndex) const;
821 * Gets the index of the current top drawn list item.
823 * @brief <i> [Deprecated] </i>
824 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
827 * @return An error code
828 * @param[out] groupIndex The group index of the item
829 * @param[out] itemIndex The item index of the item
830 * @exception E_SUCCESS The method is successful.
831 * @exception E_SYSTEM A system error has occurred.
834 result GetTopDrawnItemIndex(int& groupIndex, int& itemIndex) const;
838 * Removes all the items of the %GroupedList control.
840 * @brief <i> [Deprecated] </i>
841 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
844 * @return An error code
845 * @exception E_SUCCESS The method is successful.
846 * @exception E_SYSTEM A system error has occurred.
847 * @remarks The removed list items are deleted from the memory.
850 result RemoveAllItems(void);
854 * Removes all the checked items of the %GroupedList control.
856 * @brief <i> [Deprecated] </i>
857 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
860 * @return An error code
861 * @exception E_SUCCESS The method is successful.
862 * @exception E_SYSTEM A system error has occurred.
863 * @remarks The removed list items are deleted from the memory.
866 result RemoveAllCheckedItems(void);
870 * Gets the specified item of the %GroupedList control.
872 * @brief <i> [Deprecated] </i>
873 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
876 * @return A custom list item
877 * @param[in] groupIndex The index of the group which the item belongs to
878 * @param[in] itemIndex The index of the item
879 * @exception E_SUCCESS The method is successful.
880 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemIndex is invalid.
881 * @exception E_SYSTEM A system error has occurred.
884 const CustomListItem* GetItemAt(int groupIndex, int itemIndex) const;
888 * Scrolls to the bottom of the %GroupedList control.
890 * @brief <i> [Deprecated] </i>
891 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
895 void ScrollToBottom(void);
899 * Scrolls to the top of the %GroupedList.
901 * @brief <i> [Deprecated] </i>
902 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
906 void ScrollToTop(void);
910 * Scrolls to the item at the specified index. @n
911 * The specified item is drawn at the top of the %GroupedList control.
913 * @brief <i> [Deprecated] </i>
914 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
917 * @return An error code
918 * @param[in] groupIndex The group index
919 * @param[in] itemIndex The item index
920 * @exception E_SUCCESS The method is successful.
921 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemIndex is invalid.
922 * @exception E_SYSTEM A system error has occurred.
925 result ScrollToTop(int groupIndex, int itemIndex);
929 * Scrolls to the group at the specified index. @n
930 * The specified group is drawn at the top of the %GroupedList control.
932 * @brief <i> [Deprecated] </i>
933 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
936 * @return An error code
937 * @param[in] groupIndex The group index
938 * @exception E_SUCCESS The method is successful.
939 * @exception E_INVALID_ARG The specified @c groupIndex is invalid.
940 * @exception E_SYSTEM A system error has occurred.
943 result ScrollToTop(int groupIndex);
947 * Sets the first index list of scroll by text.
949 * @brief <i> [Deprecated] </i>
950 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
953 * @return An error code
954 * @param[in] text The text of the first index
955 * @exception E_SUCCESS The method is successful.
956 * @exception E_SYSTEM A system error has occurred.
959 result SetFastScrollMainIndex(const Tizen::Base::String& text);
963 * Adds the fast scroll event listener.
965 * @brief <i> [Deprecated] </i>
966 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
969 * @param[in] listener The listener to be added
972 void AddFastScrollEventListener(Tizen::Ui::IFastScrollEventListener& listener);
976 * Removes the fast scroll event listener.
978 * @brief <i> [Deprecated] </i>
979 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
982 * @param[in] listener The listener to be removed
985 void RemoveFastScrollEventListener(Tizen::Ui::IFastScrollEventListener& listener);
989 * Adds the grouped list item event listener.
991 * @brief <i> [Deprecated] </i>
992 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
995 * @param[in] listener The listener to be added
998 void AddGroupedItemEventListener(Tizen::Ui::IGroupedItemEventListener& listener);
1002 * Removes the grouped list item event listener.
1004 * @brief <i> [Deprecated] </i>
1005 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
1008 * @param[in] listener The listener to be removed
1011 void RemoveGroupedItemEventListener(Tizen::Ui::IGroupedItemEventListener& listener);
1015 * Gets the index of the first checked list item.
1017 * @brief <i> [Deprecated] </i>
1018 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
1021 * @return An error code
1022 * @param[out] groupIndex The group index of the item
1023 * @param[out] itemIndex The item index of the item
1024 * @exception E_SUCCESS The method is successful.
1025 * @exception E_SYSTEM A system error has occurred.
1028 result GetFirstCheckedItemIndex(int& groupIndex, int& itemIndex) const;
1032 * Sets the checked status of all the items of the specified group with the given value.
1034 * @brief <i> [Deprecated] </i>
1035 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
1038 * @return An error code
1039 * @param[in] groupIndex The group index of the item
1040 * @param[in] check Set to @c true to check all the items, @n
1042 * @exception E_SUCCESS The method is successful.
1043 * @exception E_INVALID_ARG The specified @c groupIndex is invalid.
1044 * @exception E_SYSTEM A system error has occurred.
1047 result SetAllItemsChecked(int groupIndex, bool check);
1051 * Gets the index of the current bottom drawn list item.
1053 * @brief <i> [Deprecated] </i>
1054 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
1057 * @return An error code
1058 * @param[out] groupIndex The group index of the item
1059 * @param[out] itemIndex The item index of the item
1060 * @exception E_SUCCESS The method is successful.
1061 * @exception E_SYSTEM A system error has occurred.
1064 result GetBottomDrawnItemIndex(int& groupIndex, int& itemIndex) const;
1068 * Draws and shows the item of %GroupedList control.
1070 * @brief <i> [Deprecated] </i>
1071 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
1074 * @return An error code
1075 * @param[in] groupIndex The group index
1076 * @param[in] itemIndex The item index
1077 * @exception E_SUCCESS The method is successful.
1078 * @exception E_INVALID_ARG The specified @c groupIndex or @c itemIndex is invalid.
1079 * @exception E_INVALID_OPERATION The item has never been drawn before calling this method.
1080 * @exception E_SYSTEM A system error has occurred.
1083 result RefreshItem(int groupIndex, int itemIndex);
1087 * Draws and shows the group of %GroupedList control.
1089 * @brief <i> [Deprecated] </i>
1090 * @deprecated This class is deprecated. Instead of using this class, use GroupedListView class.
1093 * @return An error code
1094 * @param[in] groupIndex The group index
1095 * @exception E_SUCCESS The method is successful.
1096 * @exception E_INVALID_ARG The specified @c groupIndex is invalid.
1097 * @exception E_SYSTEM A system error has occurred.
1100 result RefreshGroup(int groupIndex);
1104 // The implementation of this copy constructor is intentionally blank and declared as private to prohibit copying of objects.
1106 GroupedList(const GroupedList& rhs);
1109 // The implementation of this copy assignment operator is intentionally blank and declared as private to prohibit copying of objects.
1111 GroupedList& operator =(const GroupedList& rhs);
1113 friend class _GroupedListImpl;
1115 }}} // Tizen::Ui::Controls
1116 #endif // _FUI_CTRL_GROUPED_LIST_H_