27#include "CUIEventManager.h"
28#include "Components/CComponentSystem.h"
58 class CUIContainer :
public CComponentSystem
63 std::vector<CUIBase*> m_arrayUIObjects;
64 std::vector<CUIBase*> m_raycastUIObjects;
65 std::vector<CUIBase*> m_removed;
74 std::map<int, bool>m_pointerDown;
77 std::function<void(
CUIBase*)> OnPressed;
78 std::function<void(
CUIBase*)> OnHover;
98 virtual ~CUIContainer();
100 virtual void initComponent();
102 virtual void updateComponent();
This class manages GUI components, including creating and deleting images and sprites.
Definition CCanvas.h:79
This is the base object class from which other GUIs inherit. It's an empty GUI and can contain child ...
Definition CGUIElement.h:51
Base wrapper class that connects a UI container and a GUI element.
Definition CUIBase.h:63
virtual void onPointerOut(int pointerId, float x, float y)
Notify container that pointer left the given position.
virtual CUIBase * OnProcessEvent(const SEvent &event, CUIBase *capture)
Process an input event with an explicit capture hint.
bool removeChild(CUIBase *base)
Remove a child UI object from the container.
void removeChildsByGUI(CGUIElement *element)
Remove all children that are backed by the specified GUI element.
virtual void cancelPointerDown(CUIBase *base, int pointerId, float pointerX, float pointerY)
Cancel an active pointer down on a child.
virtual CUIBase * OnProcessEvent(const SEvent &event)
Process an input event and forward it to the appropriate child.
std::function< void()> OnMotionInFinish
Callback invoked when in-motion sequence finishes.
Definition CUIContainer.h:86
std::function< void()> OnMotionOutFinish
Callback invoked when out-motion sequence finishes.
Definition CUIContainer.h:93
CCanvas * getCanvas()
Get the associated canvas.
bool isEnable()
Enable or disable the container processing.
Definition CUIContainer.h:199
void startInMotion()
Start the "in" motion sequence and set internal state.
void startOutMotion()
Start the "out" motion sequence and set internal state.
void addChild(CUIBase *base)
Add a child UI object to the container.
void setEnable(bool b)
Enable or disable the container processing.
Definition CUIContainer.h:187
CUIBase * getChildByGUI(CGUIElement *element)
Find a child by its underlying GUI element.
bool isPointerDown(int id)
Check the pointer id is down.
Classes used to build the User Interface (UI).
Definition CAlphaMotion.h:32
Everything in the Skylicht Engine. You can start by looking at the topics.
Definition AudioDebugLog.h:29
SEvents hold information about an event. See irr::IEventReceiver for details on event handling.
Definition IEventReceiver.h:273