Merge remote-tracking branch 'origin/dev' into dev

This commit is contained in:
Johannes Theiner 2019-11-21 11:36:18 +01:00
commit 26a49cd79b
2 changed files with 46 additions and 22 deletions

View File

@ -1,11 +0,0 @@
#include "KeyCode.hpp"
namespace vkvm {
KeyCode::KeyCode(int value) noexcept : value(value) {}
auto KeyCode::getValue() -> int {
return value;
}
}

View File

@ -5,18 +5,53 @@
namespace vkvm { namespace vkvm {
class KeyCode { enum KeyCode {
private: Backspcce = 32,
int value; Tab = 33,
public: Enter = 37,
explicit KeyCode(int value) noexcept; ShiftLeft = 249,
ShiftRight = 249,
auto getValue() -> int; Ctrl = 251,
Alt = 257,
Delete = 279,
Space = -65224,
Zero = -65208,
One = -65207,
Two = -65206,
Three = -65205,
Four = -65204,
Five = -65203,
Six = -65202,
Seven = -65201,
Eight = -65200,
Nine = -65199,
A = -65159,
B = -65158,
C = -65157,
D = -65156,
E = -65155,
F = -65154,
G = -65153,
H = -65152,
I = -65151,
J = -65150,
K = -65149,
L = -65148,
M = -65147,
N = -65146,
O = -65145,
P = -65144,
Q = -65143,
R = -65142,
S = -65141,
T = -65140,
U = -65139,
V = -65138,
W = -65137,
X = -65136,
Y = -65135,
Z = -65134,
}; };
const static KeyCode Backspace = KeyCode(8);
const static KeyCode tabulator = KeyCode(9);
} }
#endif #endif