FifeGUI 0.2.0
A C++ GUI library designed for games.
fcn::ContainerEvent Class Reference

#include <containerevent.hpp>

Inheritance diagram for fcn::ContainerEvent:
fcn::Event

Public Member Functions

 ContainerEvent (Widget *source, Container *container)
ContainergetContainer () const
Public Member Functions inherited from fcn::Event
 Event (Widget *source)
WidgetgetSource () const

Protected Attributes

ContainermContainer
Protected Attributes inherited from fcn::Event
WidgetmSource {nullptr}

Detailed Description

Represents changes within a container (e.g., widget added/removed).

A container event is an event that can be fired by a container when a widget is added or removed.

Any object can listen for actions from a container by implementing the ContainerListener interface.

See also
Container::addContainerListener, Container::removeContainerListener, Container::distributeContainerEvent

Definition at line 30 of file containerevent.hpp.

Constructor & Destructor Documentation

◆ ContainerEvent()

fcn::ContainerEvent::ContainerEvent ( Widget * source,
Container * container )

Constructor.

Parameters
sourceThe source widget of the event.
containerThe container the event concerns.

Definition at line 11 of file containerevent.cpp.

References fcn::Event::Event(), and mContainer.

Member Function Documentation

◆ getContainer()

Container * fcn::ContainerEvent::getContainer ( ) const

Gets the container the event concerns.

Returns
The container the event concerns.

Definition at line 13 of file containerevent.cpp.

References mContainer.

Member Data Documentation

◆ mContainer

Container* fcn::ContainerEvent::mContainer
protected

Holds the container the event concerns.

Definition at line 52 of file containerevent.hpp.

Referenced by ContainerEvent(), and getContainer().


The documentation for this class was generated from the following files: