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 FUiCtrlTableView.h
20 * @brief This is the header file for the %TableView class.
22 * This header file contains the declarations of the %TableView class and its helper classes.
25 #ifndef _FUI_CTRL_TABLE_VIEW_H_
26 #define _FUI_CTRL_TABLE_VIEW_H_
28 #include <FGrpRectangle.h>
29 #include <FGrpColor.h>
30 #include <FUiContainer.h>
31 #include <FUiCtrlTableViewTypes.h>
32 #include <FUiCtrlScrollPanelTypes.h>
34 namespace Tizen { namespace Ui { namespace Controls
36 class ITableViewItemProvider;
37 class ITableViewItemProviderF;
38 class ITableViewItemEventListener;
39 class IFastScrollListener;
40 class IScrollEventListener;
41 class IScrollEventListenerF;
45 * @brief This class defines common behavior for a %TableView control.
49 * The %TableView class defines common behavior for a %TableView control.
51 //Sample code for TableViewSample.h
55 : public Tizen::Ui::Controls::Form
56 , public Tizen::Ui::Controls::ITableViewItemProvider
57 , public Tizen::Ui::Controls::ITableViewItemEventListener
62 , __pContextItem(null){}
64 bool Initialize(void);
65 virtual result OnInitializing(void);
66 virtual result OnTerminating(void);
68 // ITableViewItemEventListener
69 virtual void OnTableViewItemStateChanged(Tizen::Ui::Controls::TableView& tableView, int itemIndex, Tizen::Ui::Controls::TableViewItem* pItem, Tizen::Ui::Controls::TableViewItemStatus status);
70 virtual void OnTableViewContextItemActivationStateChanged(Tizen::Ui::Controls::TableView& tableView, int itemIndex, Tizen::Ui::Controls::TableViewContextItem* pContextItem, bool activated);
71 virtual void OnTableViewItemReordered(Tizen::Ui::Controls::TableView& tableView, int itemIndexFrom, int itemIndexTo);
73 // ITableViewItemProvider
74 virtual int GetItemCount(void);
75 virtual Tizen::Ui::Controls::TableViewItem* CreateItem(int itemIndex, int itemWidth);
76 virtual bool DeleteItem(int itemIndex, Tizen::Ui::Controls::TableViewItem* pItem);
77 virtual void UpdateItem(int itemIndex, Tizen::Ui::Controls::TableViewItem* pItem);
78 virtual int GetDefaultItemHeight(void);
81 Tizen::Ui::Controls::TableView* __pTableView;
82 Tizen::Ui::Controls::TableViewContextItem* __pContextItem;
87 //Sample code for TableViewSample.cpp
89 #include <FGraphics.h>
91 #include "TableViewSample.h"
93 using namespace Tizen::App;
94 using namespace Tizen::Base;
95 using namespace Tizen::Graphics;
96 using namespace Tizen::Media;
97 using namespace Tizen::Ui::Controls;
100 TableViewSample::Initialize(void)
102 Construct(FORM_STYLE_NORMAL);
107 TableViewSample::OnInitializing(void)
109 result r = E_SUCCESS;
111 // Creates an instance of TableView
112 __pTableView = new TableView();
113 __pTableView->Construct(Rectangle(0, 0, GetClientAreaBounds().width, GetClientAreaBounds().height), true, TABLE_VIEW_SCROLL_BAR_STYLE_FADE_OUT);
114 __pTableView->SetItemProvider(*this);
115 __pTableView->AddTableViewItemEventListener(*this);
117 // Adds the TableView to the form
118 AddControl(*__pTableView);
120 // Creates an instance of TableViewContextItem
121 __pContextItem = new TableViewContextItem();
122 __pContextItem->Construct(Dimension(720, 100));
124 Button* pButton = new Button();
125 pButton->Construct(Rectangle(10, 10, 200, 80), L"Context1");
127 Button* pButton2 = new Button();
128 pButton2->Construct(Rectangle(250, 10, 200, 80), L"Context2");
130 __pContextItem->AddControl(*pButton);
131 __pContextItem->AddControl(*pButton2);
137 TableViewSample::OnTerminating(void)
139 result r = E_SUCCESS;
141 // Deallocates the item context
142 delete __pItemContext;
143 __pItemContext = null;
148 // ITableViewItemEventListener implementation
150 TableViewSample::OnTableViewItemStateChanged(TableView& tableView, int itemIndex, TableViewItem* pItem, TableViewItemStatus status)
156 TableViewSample::OnTableViewContextItemActivationStateChanged(TableView& tableView, int itemIndex, TableViewContextItem* pContextItem, bool activated)
162 TableViewSample::OnTableViewItemReordered(Tizen::Ui::Controls::TableView& tableView, int itemIndexFrom, int itemIndexTo)
167 // ITableViewItemProvider implementation
169 TableViewSample::GetItemCount(void)
175 TableViewSample::GetDefaultItemHeight(void)
181 TableViewSample::CreateItem(int itemIndex, int itemWidth)
183 TableViewAnnexStyle style = TABLE_VIEW_ANNEX_STYLE_NORMAL;
184 TableViewItem* pItem = new TableViewItem();
186 switch (itemIndex % 6)
189 style = TABLE_VIEW_ANNEX_STYLE_NORMAL;
192 style = TABLE_VIEW_ANNEX_STYLE_MARK;
195 style = TABLE_VIEW_ANNEX_STYLE_ONOFF_SLIDING;
198 style = TABLE_VIEW_ANNEX_STYLE_DETAILED;
201 style = TABLE_VIEW_ANNEX_STYLE_RADIO;
204 style = TABLE_VIEW_ANNEX_STYLE_ONOFF_SLIDING_WITH_DIVIDER;
210 pItem->Construct(Dimension(itemWidth, GetDefaultItemHeight()), style);
213 text.Format(30, L"TableViewItem %d", itemIndex);
215 Label* pLabel = new Label();
216 pLabel->Construct(Rectangle(0, 0, itemWidth, GetDefaultItemHeight(), text);
218 pItem->AddControl(*pLabel);
219 pItem->SetContextItem(__pContextItem);
225 TableViewSample::DeleteItem(int itemIndex, Tizen::Ui::Controls::TableViewItem* pItem)
233 TableViewSample::UpdateItem(int itemIndex, Tizen::Ui::Controls::TableViewItem* pItem)
241 class _OSP_EXPORT_ TableView
242 : public Tizen::Ui::Container
246 * The object is not fully constructed after this constructor is called. Hence, the Construct() method must be called after calling this constructor.
253 * This destructor overrides Tizen::Base::Object::~Object().
257 virtual ~TableView(void);
260 * Initializes this instance of %TableView with the specified parameters.
264 * @return An error code
265 * @param[in] rect An instance of the Graphics::Rectangle class
266 * This instance represents the x and y coordinates of the left top corner of the created %TableView along with the width and height.
267 * @param[in] itemDivider Set to @c true to display an item divider, @n
269 * @param[in] scrollStyle The style of %TableView scroll bar style
270 * @exception E_SUCCESS The method is successful.
271 * @exception E_INVALID_ARG A specified input parameter is invalid, or either the rect.width or rect.height parameter has a negative value.
274 result Construct(const Tizen::Graphics::Rectangle& rect, bool itemDivider, TableViewScrollBarStyle scrollStyle);
277 * Initializes this instance of %TableView with the specified parameters.
281 * @return An error code
282 * @param[in] rect An instance of the Graphics::FloatRectangle class
283 * This instance represents the x and y coordinates of the left top corner of the created %TableView along with the width and height.
284 * @param[in] itemDivider Set to @c true to display an item divider, @n
286 * @param[in] scrollStyle The style of %TableView scroll bar style
287 * @exception E_SUCCESS The method is successful.
288 * @exception E_INVALID_ARG A specified input parameter is invalid, or either the rect.width or rect.height parameter has a negative value.
291 result Construct(const Tizen::Graphics::FloatRectangle& rect, bool itemDivider, TableViewScrollBarStyle scrollStyle);
294 * Sets the item provider that creates and deletes items for the simple style table view.
298 * @param[in] pProvider The item provider to create and delete items
299 * @remarks If an item provider is not set for the table view, the table view does not work. The specified provider should be allocated in heap memory.
300 * To reset the item provider, pass @c null to @c pProvider.
302 void SetItemProvider(ITableViewItemProvider* pProvider);
305 * Sets the item provider that creates and deletes items for the simple style table view.
309 * @param[in] pProvider The item provider to create and delete items
310 * @remarks If an item provider is not set for the table view, the table view does not work. The specified provider should be allocated in heap memory.
311 * To reset the item provider, pass @c null to @c pProvider.
313 void SetItemProviderF(ITableViewItemProviderF* pProvider);
316 * Begins the reordering mode.
320 * @see ITableViewViewItemEventListener::OnTableViewItemReordered()
322 void BeginReorderingMode(void);
325 * Ends the reordering mode.
329 * @see ITableViewViewItemEventListener::OnTableViewItemReordered()
331 void EndReorderingMode(void);
334 * Returns whether the %TableView control is in reordering mode or not.
338 * @return @c true if the %TableView is in reordering mode, @n
341 bool IsInReorderingMode(void) const;
344 * Adds a listener instance that listens to state changes of table view items. @n
345 * The added listener can listen to events on the specified event dispatcher's context when they are fired.
349 * @return An error code
350 * @param[in] listener The event listener to add
351 * @exception E_SUCCESS The method is successful.
352 * @exception E_OBJ_ALREADY_EXIST The listener is already added.
353 * @remarks The specified listener should be allocated in heap memory.
355 result AddTableViewItemEventListener(ITableViewItemEventListener& listener);
358 * Removes a listener instance that listens to state changes of table view items. @n
359 * The removed listener cannot listen to events when they are fired.
363 * @return An error code
364 * @param[in] listener The event listener to remove
365 * @exception E_SUCCESS The method is successful.
366 * @exception E_OBJ_NOT_FOUND The listener is not found.
368 result RemoveTableViewItemEventListener(ITableViewItemEventListener& listener);
371 * Adds a listener instance that listens to state changes of a fast scroll. @n
372 * The added listener can listen to events on the specified event dispatcher's context when they are fired.
376 * @return An error code
377 * @param[in] listener The event listener to add
378 * @exception E_SUCCESS The method is successful.
379 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation.
380 * @exception E_OBJ_ALREADY_EXIST The listener is already added.
381 * @remarks The specified listener should be allocated in heap memory.
383 result AddFastScrollListener(IFastScrollListener& listener);
386 * Removes a listener instance that listens to state changes of a fast scroll. @n
387 * The removed listener cannot listen to events when they are fired.
391 * @return An error code
392 * @param[in] listener The event listener to remove
393 * @exception E_SUCCESS The method is successful.
394 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation.
395 * @exception E_OBJ_NOT_FOUND The listener is not found.
397 result RemoveFastScrollListener(IFastScrollListener& listener);
400 * Adds a listener instance that listens to state changes of a scroll event. @n
401 * The added listener can listen to events on the specified event dispatcher's context when they are fired.
405 * @return An error code
406 * @param[in] listener The event listener to add
407 * @see IScrollEventListener::OnScrollEndReached()
408 * @see RemoveScrollEventListener()
409 * @exception E_SUCCESS The method is successful.
410 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation.
411 * @exception E_OBJ_ALREADY_EXIST The listener is already added.
412 * @remarks The specified listener should be allocated in heap memory.
414 result AddScrollEventListener(IScrollEventListener& listener);
417 * Removes a listener instance that listens to state changes of a scroll event. @n
418 * The removed listener cannot listen to events when they are fired.
422 * @return An error code
423 * @param[in] listener The event listener to remove
424 * @see IScrollEventListener::OnScrollEndReached()
425 * @see AddScrollEventListener()
426 * @exception E_SUCCESS The method is successful.
427 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation.
428 * @exception E_OBJ_NOT_FOUND The listener is not found.
430 result RemoveScrollEventListener(IScrollEventListener& listener);
433 * Adds a listener instance that listens to state changes of a scroll event. @n
434 * The added listener can listen to events on the specified event dispatcher's context when they are fired.
438 * @return An error code
439 * @param[in] listener The event listener to add
440 * @see IScrollEventListenerF::OnScrollEndReached()
441 * @see RemoveScrollEventListenerF()
442 * @exception E_SUCCESS The method is successful.
443 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation.
444 * @exception E_OBJ_ALREADY_EXIST The listener is already added.
445 * @remarks The specified listener should be allocated in heap memory.
447 result AddScrollEventListener(IScrollEventListenerF& listener);
450 * Removes a listener instance that listens to state changes of a scroll event. @n
451 * The removed listener cannot listen to events when they are fired.
455 * @return An error code
456 * @param[in] listener The event listener to remove
457 * @see IScrollEventListenerF::OnScrollEndReached()
458 * @see AddScrollEventListenerF()
459 * @exception E_SUCCESS The method is successful.
460 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation.
461 * @exception E_OBJ_NOT_FOUND The listener is not found.
463 result RemoveScrollEventListener(IScrollEventListenerF& listener);
466 * Sets the index table view of the scroll by texts.
470 * @return An error code
471 * @param[in] text The text of the index
472 * @param[in] useSearchIcon Set to @c true to show the magnifying icon, @n
474 * @exception E_SUCCESS The method is successful.
475 * @exception E_INVALID_ARG A specified input parameter is invalid.
476 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation.
478 result SetFastScrollIndex(const Tizen::Base::String& text, bool useSearchIcon);
481 * Gets the group and item indexes of the top item.
485 * @return The item index
486 * @exception E_SUCCESS The method is successful.
487 * @exception E_OBJ_NOT_FOUND Top drawn item is not found.
489 int GetTopDrawnItemIndex(void) const;
492 * Gets the group and item indexes of the bottom item.
496 * @return The item index
497 * @exception E_SUCCESS The method is successful.
498 * @exception E_OBJ_NOT_FOUND Bottom drawn item is not found.
500 int GetBottomDrawnItemIndex(void) const;
503 * Scrolls to the item at the specified index.
504 * The specified item is drawn at the position specified by the item alignment.
508 * @return An error code
509 * @param[in] itemIndex The targeted item index
510 * @param[in] itemAlignment The item alignment
511 * @exception E_SUCCESS The method is successful.
512 * @exception E_OUT_OF_RANGE A specified input parameter is invalid.
513 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation @b Since: @b 2.1.
514 * @remarks This method does not work inside the ITableViewItemProvider callback.
515 * @remarks This method should be called only after TableView items are created. If this method needs to be called early in the lifecycle of the TableView, then UpdateTableView() method should be called explicitly (e.g. during Tizen::Ui::Control::OnInitializing()).
517 result ScrollToItem(int itemIndex, TableViewScrollItemAlignment itemAlignment = TABLE_VIEW_SCROLL_ITEM_ALIGNMENT_TOP);
520 * Checks or unchecks the item at the specified index.
524 * @return An error code
525 * @param[in] itemIndex The item index to check
526 * @param[in] check Set to @c true to select the item, @n
528 * @exception E_SUCCESS The method is successful.
529 * @exception E_OUT_OF_RANGE A specified input parameter is invalid.
530 * @exception E_INVALID_OPERATION The item is disabled or the current state of the instance prohibits the execution of the specified operation.
531 * @remarks This method works only when the annex style of the item allows selection. @n
532 * This method does not work during the ITableViewItemProvider call-back procedure.
533 * @remarks This method should be called only after TableView items are created. If this method needs to be called early in the lifecycle of the TableView, then UpdateTableView() method should be called explicitly (e.g. during Tizen::Ui::Control::OnInitializing()).
535 result SetItemChecked(int itemIndex, bool check);
538 * Returns whether the item at the specified index is selected or not.
542 * @return @c true if the item is selected, @n
544 * @param[in] itemIndex The item itemIndex
545 * @exception E_SUCCESS The method is successful.
546 * @exception E_OUT_OF_RANGE A specified input parameter is invalid.
547 * @remarks This method returns @c false, if the annex style of the item does not allow selection.
548 * @remarks This method should be called only after TableView items are created. If this method needs to be called early in the lifecycle of the TableView, then UpdateTableView() method should be called explicitly (e.g. during Tizen::Ui::Control::OnInitializing()).
550 bool IsItemChecked(int itemIndex) const;
553 * Enables or disables the item at the specified index.
557 * @return An error code
558 * @param[in] itemIndex The item index
559 * @param[in] enable Set to @c true to enable the specified item, @n
561 * @exception E_SUCCESS The method is successful.
562 * @exception E_OUT_OF_RANGE A specified input parameter is invalid.
563 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation @b Since: @b 2.1.
564 * @remarks This method does not work during the ITableViewItemProvider call-back procedure.
565 * @remarks This method should be called only after TableView items are created. If this method needs to be called early in the lifecycle of the TableView, then UpdateTableView() method should be called explicitly (e.g. during Tizen::Ui::Control::OnInitializing()).
567 result SetItemEnabled(int itemIndex, bool enable);
570 * Returns whether the item at the specified index is enabled or disabled.
574 * @return @c true if the item is enabled, @n
576 * @param[in] itemIndex The item index
577 * @exception E_SUCCESS The method is successful.
578 * @exception E_OUT_OF_RANGE A specified input parameter is invalid.
579 * @remarks This method should be called only after TableView items are created. If this method needs to be called early in the lifecycle of the TableView, then UpdateTableView() method should be called explicitly (e.g. during Tizen::Ui::Control::OnInitializing()).
581 bool IsItemEnabled(int itemIndex) const;
584 * Counts all the items of the specified group.
588 * @return The total number of items
590 int GetItemCount(void) const;
593 * Updates the specified item. @n
594 * For instance, TABLE_VIEW_REFRESH_TYPE_ITEM_ADD is used when a new item needs to be added and TABLE_VIEW_REFRESH_TYPE_ITEM_REMOVE is used when an item is deleted from the
595 * table view. Moreover, TABLE_VIEW_REFRESH_TYPE_ITEM_MODIFY is used when the content of an existing item has changed and it needs to be updated.
596 * Note that calling this method with TABLE_VIEW_REFRESH_TYPE_ITEM_MODIFY invokes item provider's UpdateItem() for the given index in sequence.
600 * @return An error code
601 * @param[in] itemIndex The item index
602 * @param[in] type The item to add, remove, or modify
603 * @exception E_SUCCESS The method is successful.
604 * @exception E_OUT_OF_RANGE A specified input parameter is invalid.
605 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation @b Since: @b 2.1.
606 * @remarks If the specified itemIndex. @n
607 * This method does not work during the ITableViewItemProvider call-back procedure.
609 result RefreshItem(int itemIndex, TableViewRefreshType type);
612 * Updates all items of the table view. @n
613 * Note that calling this method invokes its item provider's UpdateItem() for all loaded items.
617 * @return An error code
618 * @exception E_SUCCESS The method is successful.
619 * @exception E_INVALID_OPERATION The %TableView item provider is processing the other request.
621 result RefreshAllItems(void);
624 * Updates all the items of a table view. @n
625 * This method deletes all the items in the table view and invokes the methods of the item provider again to update the table view.
629 * @exception E_SUCCESS The method is successful.
630 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation @b Since: @b 2.1.
631 * @remarks This method will delete all the items and recreate them, so it should not be called from the inside of
632 * OnTableViewItemStateChanged() callback as this leads to self deletion. If you need to update an Item, you should use RefreshItem() method.
633 * @remarks This method should not be called from ITableViewItemProvider implementation because of recursion.
634 * @remarks The specific error code can be accessed using the GetLastResult() method.
636 void UpdateTableView(void);
639 * Gets the index of the item at the specified position.
643 * @return The item index of the item on specified position
644 * @param[in] position The position of the item
645 * @remarks This method returns -1 if no item is found at the given position.
646 * @remarks This method should be called only after TableView items are created. If this method needs to be called early in the lifecycle of the TableView, then UpdateTableView() method should be called explicitly (e.g. during Tizen::Ui::Control::OnInitializing()).
648 int GetItemIndexFromPosition(const Tizen::Graphics::Point& position) const;
651 * Gets the index of the item at the specified position.
655 * @return The item index of the item on specified position
656 * @param[in] position The position of the item
657 * @remarks This method returns -1 if no item is found at the given position.
658 * @remarks This method should be called only after TableView items are created. If this method needs to be called early in the lifecycle of the TableView, then UpdateTableView() method should be called explicitly (e.g. during Tizen::Ui::Control::OnInitializing()).
660 int GetItemIndexFromPosition(const Tizen::Graphics::FloatPoint& position) const;
663 * Sets the color of a division line between items.
667 * @return An error code
668 * @param[in] color The division line color
670 void SetItemDividerColor(const Tizen::Graphics::Color& color);
673 * Gets the color of a division line between items.
677 * @return The color of a division line
679 Tizen::Graphics::Color GetItemDividerColor(void) const;
682 * Sets the background color of this control.
686 * @param[in] color The background color
687 * @remarks The background bitmap has priority over the background color. When both the background bitmap and the background color are specified,
688 * only the bitmap image is displayed.
690 void SetBackgroundColor(const Tizen::Graphics::Color& color);
693 * Gets the background color of this control.
697 * @return The background color
699 Tizen::Graphics::Color GetBackgroundColor(void) const;
702 * Sets the scroll input handling mode.
706 * @param[in] mode The scroll input handling mode
707 * @see GetScrollInputMode()
709 void SetScrollInputMode(ScrollInputMode mode);
713 * Gets the scroll input handling mode.
717 * @return The scroll input handling mode
718 * @see SetScrollInputMode()
720 ScrollInputMode GetScrollInputMode(void) const;
723 * Scrolls the list contents by the specified number of pixels. When it is negative, it scrolls to opposite direction in current scroll style.
727 * @return An error code
728 * @param[in] pixel The amount of pixels to scroll
729 * @exception E_SUCCESS The method is successful.
730 * @exception E_OUT_OF_RANGE The specified @c pixel is out of range.
731 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation
732 * @remarks If you call ScrollByPixel() with negative @c pixel when position of scroll is already top of contents then it will return E_OUT_OF_RANGE.
733 * Likewise, in case of positive @c pixel on the bottom position of scroll it will also return E_OUT_OF_RANGE. @n
734 * This method does not work during the ITableViewItemProvider call-back procedure.
736 result ScrollByPixel(int pixel);
739 * Scrolls the list contents by the specified number of pixels. When it is negative, it scrolls to opposite direction in current scroll style.
743 * @return An error code
744 * @param[in] pixel The amount of pixels to scroll
745 * @exception E_SUCCESS The method is successful.
746 * @exception E_OUT_OF_RANGE The specified @c pixel is out of range.
747 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation
748 * @remarks If you call ScrollByPixel() with negative @c pixel when position of scroll is already top of contents then it will return E_OUT_OF_RANGE.
749 * Likewise, in case of positive @c pixel on the bottom position of scroll it will also return E_OUT_OF_RANGE. @n
750 * This method does not work during the ITableViewItemProvider call-back procedure.
752 result ScrollByPixel(float pixel);
755 * Gets the current scroll position
759 int GetCurrentScrollPosition(void) const;
762 * Gets the current scroll position
766 float GetCurrentScrollPositionF(void) const;
769 * Enables or disables the scroll of TableView items.
773 void SetScrollEnabled(bool enable);
776 * Checks whether the scroll is enabled or disabled.
780 bool IsScrollEnabled(void) const;
783 * Opens the context item at the specified index.
787 * @return An error code
788 * @param[in] itemIndex The item index
789 * @exception E_SUCCESS The method is successful.
790 * @exception E_OUT_OF_RANGE A specified input parameter is invalid.
791 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation.
793 result OpenContextItem(int itemIndex);
796 * Closes the context item at the specified index.
800 * @return An error code
801 * @param[in] itemIndex The item index
802 * @exception E_SUCCESS The method is successful.
803 * @exception E_OUT_OF_RANGE A specified input parameter is invalid.
804 * @exception E_INVALID_OPERATION The current state of the instance prohibits the execution of the specified operation.
806 result CloseContextItem(int itemIndex);
809 * Returns whether the context item at the specified index is opened.
813 * @return @c true if the context item is opened, else @c false
814 * @param[in] itemIndex The item itemIndex
815 * @exception E_SUCCESS The method is successful.
816 * @exception E_OUT_OF_RANGE A specified input parameter is invalid.
818 bool IsContextItemOpened(int itemIndex) const;
821 friend class _TableViewImpl;
823 // The implementation of this copy constructor is intentionally blank and declared as private to prohibit copying of objects.
824 TableView(const TableView& rhs);
826 // The implementation of this copy assignment operator is intentionally blank and declared as private to prohibit copying of objects.
827 TableView& operator =(const TableView& rhs);
830 }}} // Tizen::Ui::Controls
832 #endif // _FUI_CTRL_TABLE_VIEW_H_