1
0
mirror of https://github.com/MatMoul/g810-led.git synced 2024-12-23 17:26:11 +00:00

Add semicolon for US Keyboard

This commit is contained in:
MatMoul 2016-08-09 17:14:20 +02:00
parent 15b4e8dbf9
commit 658975aab4
2 changed files with 3 additions and 2 deletions

View File

@ -161,6 +161,7 @@ bool Keyboard::getKeyAddress(Key key, KeyAddress &keyAddress) {
case Key::unknown: keyAddress.id = 0x31; break; // * case Key::unknown: keyAddress.id = 0x31; break; // *
case Key::dollar: keyAddress.id = 0x32; break; // * case Key::dollar: keyAddress.id = 0x32; break; // *
case Key::eaigu: keyAddress.id = 0x33; break; // * case Key::eaigu: keyAddress.id = 0x33; break; // *
case Key::semicolon: keyAddress.id = 0x33; break; // *
case Key::agrave: keyAddress.id = 0x34; break; // * case Key::agrave: keyAddress.id = 0x34; break; // *
case Key::degree: keyAddress.id = 0x35; break; // * case Key::degree: keyAddress.id = 0x35; break; // *
case Key::comma: keyAddress.id = 0x36; break; case Key::comma: keyAddress.id = 0x36; break;
@ -294,7 +295,7 @@ bool Keyboard::parseKey(std::string key, KeyAddress &keyAddress) {
else if (key == "close_bracket" || key == "closebracket" || key == "¨" || key == "!") parsedKey = Key::close_bracket; else if (key == "close_bracket" || key == "closebracket" || key == "¨" || key == "!") parsedKey = Key::close_bracket;
else if (key == "unknown") parsedKey = Key::unknown; // Not on my keyboard else if (key == "unknown") parsedKey = Key::unknown; // Not on my keyboard
else if (key == "$" || key == "dollar") parsedKey = Key::dollar; else if (key == "$" || key == "dollar") parsedKey = Key::dollar;
else if (key == "é" || key == "ö") parsedKey = Key::eaigu; else if (key == ";" || key == "semicolon" || key == "é" || key == "ö") parsedKey = Key::semicolon;
else if (key == "à" || key == "ä") parsedKey = Key::agrave; else if (key == "à" || key == "ä") parsedKey = Key::agrave;
else if (key == "§" || key == "°") parsedKey = Key::degree; else if (key == "§" || key == "°") parsedKey = Key::degree;
else if (key == "," || key == "comma") parsedKey = Key::comma; else if (key == "," || key == "comma") parsedKey = Key::comma;

View File

@ -23,7 +23,7 @@ class Keyboard {
n1, n2, n3, n4, n5, n6, n7, n8, n9, n0, n1, n2, n3, n4, n5, n6, n7, n8, n9, n0,
tab, caps_lock, space, backspace, enter, tab, caps_lock, space, backspace, enter,
a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z,
unknown, egrave, eaigu, agrave, dollar, apostrophe, degree, backslash, // Need best names unknown, egrave, eaigu, semicolon, agrave, dollar, apostrophe, degree, backslash, // Need best names
comma, dot, minus, open_bracket, close_bracket, tidle comma, dot, minus, open_bracket, close_bracket, tidle
}; };
enum class KeyGroup { logo, indicators, multimedia, fkeys, modifiers, arrows, numeric, functions, keys}; enum class KeyGroup { logo, indicators, multimedia, fkeys, modifiers, arrows, numeric, functions, keys};