The Battle for Wesnoth  1.15.2+dev
Public Member Functions | Public Attributes | List of all members
events::context Class Reference

#include <events.hpp>

Public Member Functions

 context ()
 
 ~context ()
 
 context (const context &)=delete
 
void add_handler (sdl_handler *ptr)
 
bool has_handler (const sdl_handler *ptr) const
 Returns true if ptr is found in either the handlers or staging_handlers lists. More...
 
bool remove_handler (sdl_handler *ptr)
 
void cycle_focus ()
 
void set_focus (const sdl_handler *ptr)
 
void add_staging_handlers ()
 

Public Attributes

handler_list handlers
 
handler_list::iterator focused_handler
 
std::vector< sdl_handler * > staging_handlers
 

Detailed Description

Definition at line 39 of file events.hpp.

Constructor & Destructor Documentation

◆ context() [1/2]

events::context::context ( )
inline

◆ ~context()

events::context::~context ( )

Definition at line 191 of file events.cpp.

References h.

Referenced by context().

◆ context() [2/2]

events::context::context ( const context )
delete

Member Function Documentation

◆ add_handler()

void events::context::add_handler ( sdl_handler ptr)

Definition at line 80 of file events.cpp.

Referenced by context(), events::sdl_handler::join(), and events::sdl_handler::sdl_handler().

◆ add_staging_handlers()

void events::context::add_staging_handlers ( )

Definition at line 185 of file events.cpp.

Referenced by context().

◆ cycle_focus()

void events::context::cycle_focus ( )

Definition at line 144 of file events.cpp.

Referenced by context().

◆ has_handler()

bool events::context::has_handler ( const sdl_handler ptr) const

Returns true if ptr is found in either the handlers or staging_handlers lists.

Definition at line 89 of file events.cpp.

References gui2::event::find().

Referenced by context(), events::sdl_handler::join_same(), events::sdl_handler::operator=(), and events::sdl_handler::sdl_handler().

◆ remove_handler()

bool events::context::remove_handler ( sdl_handler ptr)

Definition at line 97 of file events.cpp.

References gui2::event::find(), and i.

Referenced by context(), and events::sdl_handler::leave().

◆ set_focus()

void events::context::set_focus ( const sdl_handler ptr)

Definition at line 177 of file events.cpp.

References gui2::event::find(), and i.

Referenced by context().

Member Data Documentation

◆ focused_handler

handler_list::iterator events::context::focused_handler

Definition at line 62 of file events.hpp.

◆ handlers

handler_list events::context::handlers

◆ staging_handlers

std::vector<sdl_handler*> events::context::staging_handlers

Definition at line 63 of file events.hpp.


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