Ocular Engine
Keys.hpp
1 
17 #ifndef __H__OCULAR_INPUT_KEYS__H__
18 #define __H__OCULAR_INPUT_KEYS__H__
19 
20 #include <cstdint>
21 
22 //------------------------------------------------------------------------------------------
23 
28 namespace Ocular
29 {
34  namespace Core
35  {
39  enum class KeyState : uint8_t
40  {
41  Released = 0x00,
42  Pressed = 0x01,
43  Undefined = 0x02
44  };
45 
51  enum class MouseButtons : uint8_t
52  {
53  Left = 0x00,
54  Right = 0x01,
55  Middle = 0x02,
56  XButton1 = 0x03,
57  XButton2 = 0x04,
58  Undefined = 0x05
59  };
60 
66  enum class KeyboardKeys : uint8_t
67  {
68  //------------------------------------------------------------
69  // General Keys reserved 0-75
70 
71  Backspace = 0x00,
72  Tab = 0x01,
73  Clear = 0x02,
74  Enter = 0x03,
75  ShiftLeft = 0x04,
76  ShiftRight = 0x05,
77  CtrlLeft = 0x06,
78  CtrlRight = 0x07,
79  AltLeft = 0x08,
80  AltRight = 0x09,
81  Pause = 0x0A,
82  CapsLock = 0x0B,
83  Escape = 0x0C,
84  Space = 0x0D,
85  PageUp = 0x0E,
86  PageDown = 0x0F,
87  End = 0x10,
88  Home = 0x11,
89  LeftArrow = 0x12,
90  RightArrow = 0x13,
91  UpArrow = 0x14,
92  DownArrow = 0x15,
93  Select = 0x16,
94  Execute = 0x17,
95  PrintScreen = 0x18,
96  Insert = 0x19,
97  Delete = 0x1A,
98  Help = 0x1B,
99  OSKey = 0x1C,
100  Subtract = 0x1D,
101  Underscore = 0x1E,
102  Plus = 0x1F,
103  Equals = 0x20,
104  BracketLeft = 0x21,
105  BracketRight = 0x22,
106  CurlyBracketLeft = 0x23,
107  CurlyBracketRight = 0x24,
108  Backslash = 0x25,
109  Pipe = 0x26,
110  Semicolon = 0x27,
111  Colon = 0x28,
112  QuotationSingle = 0x29,
113  QuotationDouble = 0x2A,
114  Comma = 0x2B,
115  Period = 0x2C,
116  AngleBracketLeft = 0x2D,
117  AngleBracketRight = 0x2E,
118  ForwardSlash = 0x2F,
119  QuestionMark = 0x30,
120  Apostrophe = 0x31,
121  Tilde = 0x32,
122  ExclamationMark = 0x33,
123  Ampersat = 0x34,
124  Hash = 0x35,
125  DollarSign = 0x36,
126  PercentSign = 0x37,
127  Caret = 0x38,
128  Ampersand = 0x39,
129  Multiply = 0x3A,
130  ParenthesisLeft = 0x3B,
131  ParenthesisRight = 0x3C,
132 
133  //------------------------------------------------------------
134  // Numpad Keys reserved 76-100
135 
136  Numpad0 = 0x4C,
137  Numpad1 = 0x4D,
138  Numpad2 = 0x4E,
139  Numpad3 = 0x4F,
140  Numpad4 = 0x50,
141  Numpad5 = 0x51,
142  Numpad6 = 0x52,
143  Numpad7 = 0x53,
144  Numpad8 = 0x54,
145  Numpad9 = 0x55,
146  NumpadPlus = 0x56,
147  NumpadSubtract = 0x57,
148  NumpadMultiply = 0x58,
149  NumpadDivide = 0x59,
150  NumpadDecimal = 0x5A,
151  NumpadSeparator = 0x5B,
152  NumpadEnter = 0x5C,
153 
154  //------------------------------------------------------------
155  // Alphanumeric Keys reserved 101-150
156 
157  A = 0x65,
158  B = 0x66,
159  C = 0x67,
160  D = 0x68,
161  E = 0x69,
162  F = 0x6A,
163  G = 0x6B,
164  H = 0x6C,
165  I = 0x6D,
166  J = 0x6E,
167  K = 0x6F,
168  L = 0x70,
169  M = 0x71,
170  N = 0x72,
171  O = 0x73,
172  P = 0x74,
173  Q = 0x75,
174  R = 0x76,
175  S = 0x77,
176  T = 0x78,
177  U = 0x79,
178  V = 0x7A,
179  W = 0x7B,
180  X = 0x7C,
181  Y = 0x7D,
182  Z = 0x7E,
183  Mainpad0 = 0x7F,
184  Mainpad1 = 0x80,
185  Mainpad2 = 0x81,
186  Mainpad3 = 0x82,
187  Mainpad4 = 0x83,
188  Mainpad5 = 0x84,
189  Mainpad6 = 0x85,
190  Mainpad7 = 0x86,
191  Mainpad8 = 0x87,
192  Mainpad9 = 0x88,
193  MainpadEnter = 0x89,
194 
195  //------------------------------------------------------------
196  // Function Keys reserved 151-175
197 
198  F1 = 0x97,
199  F2 = 0x98,
200  F3 = 0x99,
201  F4 = 0x9A,
202  F5 = 0x9B,
203  F6 = 0x9C,
204  F7 = 0x9D,
205  F8 = 0x9E,
206  F9 = 0x9F,
207  F10 = 0xA0,
208  F11 = 0xA1,
209  F12 = 0xA2,
210  F13 = 0xA3,
211  F14 = 0xA4,
212  F15 = 0xA5,
213  F16 = 0xA6,
214  F17 = 0xA7,
215  F18 = 0xA8,
216  F19 = 0xA9,
217  F20 = 0xAA,
218  F21 = 0xAB,
219  F22 = 0xAC,
220  F23 = 0xAD,
221  F24 = 0xAE,
222 
223  //------------------------------------------------------------
224  // Other
225 
226  Undefined = 0xFF
227  };
228  }
232 }
237 //------------------------------------------------------------------------------------------
238 
239 #endif
Note: Once this library is made dynamic, this will no longer be needed.
Definition: Common.hpp:70