#include <inputhandler.h>
Public Member Functions | |
RealInputHandler (MyEventReceiver *receiver) | |
virtual | ~RealInputHandler () |
virtual bool | isKeyDown (GameKeyType k) |
virtual bool | wasKeyDown (GameKeyType k) |
virtual bool | wasKeyPressed (GameKeyType k) |
virtual bool | wasKeyReleased (GameKeyType k) |
virtual float | getJoystickSpeed () |
virtual float | getJoystickDirection () |
virtual bool | cancelPressed () |
virtual void | clearWasKeyPressed () |
virtual void | clearWasKeyReleased () |
virtual void | listenForKey (const KeyPress &keyCode) |
virtual void | dontListenForKeys () |
virtual v2s32 | getMousePos () |
virtual void | setMousePos (s32 x, s32 y) |
virtual s32 | getMouseWheel () |
void | clear () |
void | releaseAllKeys () |
Public Member Functions inherited from InputHandler | |
InputHandler () | |
virtual | ~InputHandler ()=default |
virtual bool | isRandom () const |
virtual void | step (float dtime) |
Private Attributes | |
MyEventReceiver * | m_receiver = nullptr |
v2s32 | m_mousepos |
Additional Inherited Members | |
Public Attributes inherited from InputHandler | |
JoystickController | joystick |
KeyCache | keycache |
|
inline |
References InputHandler::joystick, MyEventReceiver::joystick, and m_receiver.
|
inlinevirtual |
References MyEventReceiver::joystick, and m_receiver.
|
inlinevirtual |
Implements InputHandler.
References KeyType::ESC, and wasKeyDown().
|
inlinevirtual |
Reimplemented from InputHandler.
References JoystickController::clear(), MyEventReceiver::clearInput(), InputHandler::joystick, and m_receiver.
|
inlinevirtual |
Reimplemented from InputHandler.
References MyEventReceiver::clearWasKeyPressed(), and m_receiver.
|
inlinevirtual |
Reimplemented from InputHandler.
References MyEventReceiver::clearWasKeyReleased(), and m_receiver.
|
inlinevirtual |
Reimplemented from InputHandler.
References MyEventReceiver::dontListenForKeys(), and m_receiver.
|
virtual |
Implements InputHandler.
References g_touchcontrols, TouchControls::getJoystickDirection(), TouchControls::getJoystickSpeed(), JoystickController::getMovementDirection(), and InputHandler::joystick.
|
virtual |
Implements InputHandler.
References g_touchcontrols, TouchControls::getJoystickSpeed(), JoystickController::getMovementSpeed(), and InputHandler::joystick.
|
virtual |
Implements InputHandler.
References RenderingEngine::get_raw_device(), and m_mousepos.
|
inlinevirtual |
Implements InputHandler.
References MyEventReceiver::getMouseWheel(), and m_receiver.
|
inlinevirtual |
Implements InputHandler.
References MyEventReceiver::IsKeyDown(), JoystickController::isKeyDown(), InputHandler::joystick, KeyCache::key, InputHandler::keycache, and m_receiver.
|
inlinevirtual |
Reimplemented from InputHandler.
References MyEventReceiver::listenForKey(), and m_receiver.
|
inlinevirtual |
Reimplemented from InputHandler.
References InputHandler::joystick, m_receiver, JoystickController::releaseAllKeys(), and MyEventReceiver::releaseAllKeys().
|
virtual |
Implements InputHandler.
References RenderingEngine::get_raw_device(), and m_mousepos.
|
inlinevirtual |
Implements InputHandler.
References InputHandler::joystick, KeyCache::key, InputHandler::keycache, m_receiver, MyEventReceiver::WasKeyDown(), and JoystickController::wasKeyDown().
Referenced by cancelPressed().
|
inlinevirtual |
Implements InputHandler.
References InputHandler::joystick, KeyCache::key, InputHandler::keycache, m_receiver, MyEventReceiver::WasKeyPressed(), and JoystickController::wasKeyPressed().
|
inlinevirtual |
Implements InputHandler.
References InputHandler::joystick, KeyCache::key, InputHandler::keycache, m_receiver, MyEventReceiver::WasKeyReleased(), and JoystickController::wasKeyReleased().
|
private |
Referenced by getMousePos(), and setMousePos().
|
private |