25#include "guillaume/ecs/system_filler.hpp"
27#include "guillaume/components/snackbar.hpp"
Stores every component of a scene, per component type and per entity identifier, and knows which ones...
std::size_t Identifier
The key under which an entity's components are stored. Systems and components refer to entities by th...
The base class to derive a system from: a System whose signature is the list of component types given...
static void dismiss(ecs::ComponentRegistry &componentRegistry, const ecs::Entity::Identifier &entityIdentifier)
Close the snackbar as the timeout, Escape or its action would.
static void pressAction(ecs::ComponentRegistry &componentRegistry, const ecs::Entity::Identifier &entityIdentifier)
Activate the action as a press on it would.
Snackbar(void)
Create the system in the Layout phase.
static void install(ecs::ComponentRegistry &componentRegistry, const ecs::Entity::Identifier &entityIdentifier)
Give a snackbar its accessibility semantics and connect its dismissal.
static void apply(ecs::ComponentRegistry &componentRegistry, const ecs::Entity::Identifier &entityIdentifier)
Style one snackbar and arrange its children.
static void show(ecs::ComponentRegistry &componentRegistry, const ecs::Entity::Identifier &entityIdentifier)
Show the snackbar and restart its auto-dismiss countdown.
static void hide(ecs::ComponentRegistry &componentRegistry, const ecs::Entity::Identifier &entityIdentifier)
Hide the snackbar without telling anyone.
~Snackbar(void) override=default
Default destructor.
static void installAction(ecs::ComponentRegistry &componentRegistry, const ecs::Entity::Identifier &entityIdentifier)
Make the action child a button that calls pressAction().
void update(const ecs::Entity::Identifier &entityIdentifier) override
Run apply() on one snackbar; called by the frame loop.
Rules. Every class here runs each frame on the entities that have the components it declares.