//////////////////////////////////////////////////////////////////////////////////////////////////// // NoesisGUI - http://www.noesisengine.com // Copyright (c) 2013 Noesis Technologies S.L. All Rights Reserved. //////////////////////////////////////////////////////////////////////////////////////////////////// namespace Noesis { //////////////////////////////////////////////////////////////////////////////////////////////////// template T* UICollection::Get(uint32_t index) const { return (T*)BaseCollection::mItems[index].GetPtr(); } //////////////////////////////////////////////////////////////////////////////////////////////////// template void UICollection::Set(uint32_t index, T* item) { BaseCollection::Set(index, item); } //////////////////////////////////////////////////////////////////////////////////////////////////// template int UICollection::Add(T* item) { return BaseCollection::Add(item); } //////////////////////////////////////////////////////////////////////////////////////////////////// template void UICollection::Insert(uint32_t index, T* item) { BaseCollection::Insert(index, item); } //////////////////////////////////////////////////////////////////////////////////////////////////// template bool UICollection::Contains(const T* item) const { return BaseCollection::IndexOfComponent(item) >= 0; } //////////////////////////////////////////////////////////////////////////////////////////////////// template int UICollection::IndexOf(const T* item) const { return BaseCollection::IndexOfComponent(item); } //////////////////////////////////////////////////////////////////////////////////////////////////// template bool UICollection::Remove(const T* item) { return BaseCollection::Remove(item); } //////////////////////////////////////////////////////////////////////////////////////////////////// template const TypeClass* UICollection::GetItemType() const { static_assert(IsDerived::Result, "T must inherit from BaseComponent"); return TypeOf(); } }