|  | ManaPlus
    | 
#include <eventsmanager.h>
 
  
| Public Member Functions | |
| EventsManager () | |
| ~EventsManager () | |
| void | init () | 
| void | enableEvents () | 
| void | shutdown () | 
| bool | handleEvents () const | 
| bool | handleCommonEvents (const SDL_Event &event) const | 
| void | handleGameEvents () const | 
| void | optionChanged (const std::string &name) | 
|  Public Member Functions inherited from ConfigListener | |
| ConfigListener () | |
| virtual | ~ConfigListener () | 
| Static Public Member Functions | |
| static void | handleActive (const SDL_Event &event) | 
| static void | logEvent (const SDL_Event &event) | 
| Protected Attributes | |
| bool | mLogInput | 
Definition at line 34 of file eventsmanager.h.
| EventsManager::EventsManager | ( | ) | 
Definition at line 57 of file eventsmanager.cpp.
| EventsManager::~EventsManager | ( | ) | 
Definition at line 63 of file eventsmanager.cpp.
References CHECKLISTENERS.
| void EventsManager::enableEvents | ( | ) | 
Definition at line 74 of file eventsmanager.cpp.
References mLogInput.
Referenced by Client::gameInit().
| 
 | static | 
< The application is active
< The app has input focus
< The app has mouse coverage
Definition at line 622 of file eventsmanager.cpp.
References Settings::awayMode, client, config, State::EXIT, KeyboardFocus::Focused, State::GAME, Configuration::getIntValue(), Client::getState(), Settings::inputFocused, Game::instance(), localPlayer, Settings::mouseFocused, LocalPlayer::setHalfAway(), WindowManager::setIsMinimized(), setPriority(), Client::setState(), settings, KeyboardFocus::Unfocused, Game::updateFrameRate(), Being::updateName(), and LocalPlayer::updateStatus().
Referenced by handleCommonEvents().
| bool EventsManager::handleCommonEvents | ( | const SDL_Event & | event | ) | const | 
Definition at line 90 of file eventsmanager.cpp.
References BLOCK_END, BLOCK_START, client, State::EXIT, handleActive(), InputManager::handleEvent(), inputManager, Logger::log1(), logEvent(), logger, mLogInput, WindowManager::resizeVideo(), Client::setState(), and WindowManager::updateScreenKeyboard().
Referenced by handleEvents(), and handleGameEvents().
| bool EventsManager::handleEvents | ( | ) | const | 
Definition at line 142 of file eventsmanager.cpp.
References BLOCK_END, BLOCK_START, client, State::EXIT, Being::getDirection(), Client::getState(), Being::getTileX(), Being::getTileY(), handleCommonEvents(), Game::handleInput(), Game::instance(), localPlayer, Logger::log1(), logger, SDL::PollEvent(), and Client::setState().
Referenced by Client::gameExec().
| void EventsManager::handleGameEvents | ( | ) | const | 
Definition at line 198 of file eventsmanager.cpp.
References BLOCK_END, BLOCK_START, handleCommonEvents(), Game::instance(), and SDL::PollEvent().
Referenced by Game::handleInput().
| void EventsManager::init | ( | ) | 
Definition at line 68 of file eventsmanager.cpp.
References Configuration::addListener(), config, Configuration::getBoolValue(), and mLogInput.
Referenced by Client::gameInit().
| 
 | static | 
Definition at line 226 of file eventsmanager.cpp.
References Logger::assertLog(), CAST_S32, CAST_U32, Logger::log(), logger, mainGraphics, Graphics::mHeight, Graphics::mWidth, and strprintf().
Referenced by handleCommonEvents().
| 
 | virtual | 
Called when an option changed. The config listener will have to be registered to the option name first.
Implements ConfigListener.
Definition at line 220 of file eventsmanager.cpp.
References config, Configuration::getBoolValue(), and mLogInput.
| void EventsManager::shutdown | ( | ) | 
Definition at line 85 of file eventsmanager.cpp.
References config, and Configuration::removeListeners().
Referenced by Client::gameClear().
| 
 | protected | 
Definition at line 67 of file eventsmanager.h.
Referenced by enableEvents(), handleCommonEvents(), init(), and optionChanged().