3#include "DefaultCVScrollView.hpp"
4#include "../Components/CVVList.hpp"
5#include "../../Pool/ObjectPool.hpp"
6#include "../../Utils/Event.hpp"
12 using namespace UnityEngine;
13 using namespace UnityEngine::UI;
34 t_CellMemoryPool::Ptr m_ListCellPool;
35 std::vector<_v::MonoPtr<Data::IListCell>> m_VisibleListCells;
36 std::vector<Data::IListItem::Ptr> m_ListItems;
37 Data::IListItem::Ptr m_SelectedListItem;
95 DECLARE_INSTANCE_METHOD(
void, Update);
100 void ClearVisibles(
bool p_ScrollToTop);
102 float GetListCellPerPage();
104 void UpdateForCurrentScroll();
108 DECLARE_INSTANCE_METHOD(
void, OnRectTransformDimensionsChange);
Vector based object pool.
Abstract List Cell component.
Default CVVList component.
void SortListItems_Impl(_v::CFuncRef< int, const Data::IListItem::Ptr &, const Data::IListItem::Ptr & > p_Functor)
Sort list items by a functor.
void SetListItems_Impl(const std::vector< Data::IListItem::Ptr > &p_ListItems)
Set list items.
void AddListItem_Impl(const Data::IListItem::Ptr &p_ListItem)
Add a list item.
void OnListCellClicked_Impl(Data::IListCell *p_ListCell)
On list cell clicked.
void SetSelectedListItem_Impl(const Data::IListItem::Ptr &p_ListItem, bool p_Notify=true)
Set selected list item.
void SetListCellPrefab_Impl(Data::IListCell *p_Prefab)
Set list cell prefab.
void OnListItemSelected_Impl(_v::CActionRef< const Data::IListItem::Ptr & > p_Functor, bool p_Add=true)
On list item selected event.
_v::Event Init
On component creation.
void RemoveListItem_Impl(const Data::IListItem::Ptr &p_ListItem)
Remove a list item.
void ScrollTo_Impl(float p_TargetPosition, bool p_Animated)
Scroll to position.
void Init_DefaultCVVList()
On component creation.
const Data::IListItem::Ptr & GetSelectedItem_Impl()
Get selected item.
Default generic components implementation.
Various platform utils like Delegate/Action/Function/Event system.