openMSX
|
This class is responsible for translating host events into MSX events. More...
#include <EventDelay.hh>
Public Member Functions | |
EventDelay (Scheduler &scheduler, CommandController &commandController, EventDistributor &eventDistributor, MSXEventDistributor &msxEventDistributor, ReverseManager &reverseManager) | |
~EventDelay () | |
void | sync (EmuTime::param curEmu) |
void | flush () |
This class is responsible for translating host events into MSX events.
It also translates host event timing into EmuTime. To better do this we introduce a small delay (default 0.03s) in this translation.
Definition at line 26 of file EventDelay.hh.
openmsx::EventDelay::EventDelay | ( | Scheduler & | scheduler, |
CommandController & | commandController, | ||
EventDistributor & | eventDistributor, | ||
MSXEventDistributor & | msxEventDistributor, | ||
ReverseManager & | reverseManager | ||
) |
Definition at line 21 of file EventDelay.cc.
References openmsx::JOY_AXIS_MOTION, openmsx::JOY_BUTTON_DOWN, openmsx::JOY_BUTTON_UP, openmsx::JOY_HAT, openmsx::KEY_DOWN, openmsx::KEY_UP, openmsx::MOUSE_BUTTON_DOWN, openmsx::MOUSE_BUTTON_UP, openmsx::MOUSE_MOTION, openmsx::EventDistributor::MSX, openmsx::ReverseManager::registerEventDelay(), and openmsx::EventDistributor::registerEventListener().
openmsx::EventDelay::~EventDelay | ( | ) |
Definition at line 44 of file EventDelay.cc.
References openmsx::JOY_AXIS_MOTION, openmsx::JOY_BUTTON_DOWN, openmsx::JOY_BUTTON_UP, openmsx::JOY_HAT, openmsx::KEY_DOWN, openmsx::KEY_UP, openmsx::MOUSE_BUTTON_DOWN, openmsx::MOUSE_BUTTON_UP, openmsx::MOUSE_MOTION, and openmsx::EventDistributor::unregisterEventListener().
void openmsx::EventDelay::flush | ( | ) |
Definition at line 163 of file EventDelay.cc.
References openmsx::MSXEventDistributor::distributeEvent(), openmsx::Schedulable::getCurrentTime(), and openmsx::Schedulable::removeSyncPoints().
void openmsx::EventDelay::sync | ( | EmuTime::param | curEmu | ) |
Definition at line 63 of file EventDelay.cc.
References end(), ranges::find(), openmsx::FloatSetting::getDouble(), openmsx::Timer::getTime(), openmsx::getType(), openmsx::KEY_DOWN, openmsx::KEY_UP, move_pop_back(), and openmsx::Schedulable::setSyncPoint().