MPMA Framework 0.4
Namespaces | Functions
Keyboard.cpp File Reference

Keyboard input platform-common code. More...

Namespaces

namespace  INPUT
 

Input.


namespace  INPUT::KEYBOARD
 

Keyboard-specific input.


Functions

const std::string & INPUT::KEYBOARD::GetFriendlyName (uint8 key)
 Returns the friendly name for a key value.
const std::string & INPUT::KEYBOARD::GetPersistentIdentifier (uint8 key)
 Returns an string that can be used to uniquely identify the key again after the program has exited.
uint8 INPUT::KEYBOARD::FindKey (const std::string &persistentIdentifier)
 Finds a key given a persistent identifier. Returns 0 if not found;.
bool INPUT::KEYBOARD::IsKeyDown (uint8 key)
 Returns whether the specified key is currently down.
const std::vector< uint8 > & INPUT::KEYBOARD::GetCurrentlyPressedKeys ()
 Returns a list of keys that are currently pressed down.
const std::vector< uint8 > & INPUT::KEYBOARD::GetNewlyPressedKeys ()
 Returns a list of keys that were newly pressed within the last frame.
bool INPUT::KEYBOARD::UpdateTypedText (std::string &textToEdit)
 Updates a string with text typed by the user. If the user had pressed backspace, the last character is removed. Enter is also stored in the string as
. Returns true if the text was changed.
void INPUT::KEYBOARD::SetCaptureMode (bool captureTypedText, bool captureKeyState)
 Sets the capture mode for keyboard input. This controls whether typed text or key state is captured and made available to the app. By default both are captured.
bool INPUT::KEYBOARD::IsCapturingText ()
 Returns whether typed text is currently being captured.
bool INPUT::KEYBOARD::IsCapturingState ()
 Returns whether key state is currently being captured.

Detailed Description

Keyboard input platform-common code.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends