MyGUI: MyGUI_IItemContainer.h Source File

MyGUI 3.4.2

- Main Page
- Related Pages
- Namespaces
- Data Structures
- Files
- Examples

- File List
- Globals

MyGUI_IItemContainer.h
Go to the documentation of this file.
1/*
2 * This source file is part of MyGUI. For the latest info, see http://mygui.info/
3 * Distributed under the MIT License
4 * (See accompanying file COPYING.MIT or copy at http://opensource.org/licenses/MIT)
5 */
6
7#ifndef MYGUI_I_ITEM_CONTAINER_H_
8#define MYGUI_I_ITEM_CONTAINER_H_
9
10#include "MyGUI_Prerequest.h"
11#include "MyGUI_Constants.h"
12
13namespace MyGUI
14{
15
16 class IItem;
17
18 class MYGUI_EXPORT IItemContainer
19 {
20 public:
21 virtual ~IItemContainer() { }
22
23 virtual size_t _getItemCount() const
24 {
25 return 0;
26 }
27
28 virtual void _addItem(const MyGUI::UString& /*_name*/) { }
29
30 virtual void _removeItemAt(size_t /*_index*/) { }
31
32 virtual Widget* _getItemAt(size_t _index) const
33 {
34 return nullptr;
35 }
36
37 virtual void _setItemNameAt(size_t /*_index*/, const UString& /*_name*/) { }
38 virtual const UString& _getItemNameAt(size_t _index) const
39 {
40 return Constants::getEmptyUString();
41 }
42
43 virtual void _setItemSelected(IItem* /*_item*/) { }
44 };
45
46} // namespace MyGUI
47
48#endif // MYGUI_I_ITEM_CONTAINER_H_
MyGUI_Constants.h
MYGUI_EXPORT
#define MYGUI_EXPORT
Definition MyGUI_Platform.h:77
MyGUI_Prerequest.h
MyGUI::IItemContainer
Definition MyGUI_IItemContainer.h:19
MyGUI::IItemContainer::_removeItemAt
virtual void _removeItemAt(size_t)
Definition MyGUI_IItemContainer.h:30
MyGUI::IItemContainer::_getItemCount
virtual size_t _getItemCount() const
Definition MyGUI_IItemContainer.h:23
MyGUI::IItemContainer::_setItemNameAt
virtual void _setItemNameAt(size_t, const UString &)
Definition MyGUI_IItemContainer.h:37
MyGUI::IItemContainer::_getItemAt
virtual Widget * _getItemAt(size_t _index) const
Definition MyGUI_IItemContainer.h:32
MyGUI::IItemContainer::~IItemContainer
virtual ~IItemContainer()
Definition MyGUI_IItemContainer.h:21
MyGUI::IItemContainer::_addItem
virtual void _addItem(const MyGUI::UString &)
Definition MyGUI_IItemContainer.h:28
MyGUI::IItemContainer::_setItemSelected
virtual void _setItemSelected(IItem *)
Definition MyGUI_IItemContainer.h:43
MyGUI::IItemContainer::_getItemNameAt
virtual const UString & _getItemNameAt(size_t _index) const
Definition MyGUI_IItemContainer.h:38
MyGUI::IItem
Definition MyGUI_IItem.h:18
MyGUI::UString
A UTF-16 string with implicit conversion to/from std::string and std::wstring.
Definition MyGUI_UString.h:145
MyGUI::Widget
widget description should be here.
Definition MyGUI_Widget.h:37
MyGUI
Definition MyGUI_ActionController.h:15