changes requested

pull/389/head
tobymiller1 7 years ago
parent 86b5e9be59
commit 890f179746

@ -60,6 +60,7 @@ void Unicode::start(void) {
void Unicode::input(void) { void Unicode::input(void) {
switch (::HostOS.os()) { switch (::HostOS.os()) {
case hostos::LINUX: case hostos::LINUX:
break;
case hostos::WINDOWS: case hostos::WINDOWS:
case hostos::OSX: case hostos::OSX:
hid::pressRawKey(Key_LeftAlt); hid::pressRawKey(Key_LeftAlt);
@ -100,7 +101,7 @@ void Unicode::typeCode(uint32_t unicode) {
if (on_zero_start == false) { if (on_zero_start == false) {
Key key; Key key;
if (::HostOS.os() == hostos::WINDOWS) { if (::HostOS.os() == hostos::WINDOWS) {
key = hexToKeyWindows(digit); key = hexToKeysWithNumpad(digit);
} }
else { else {
key = hexToKey(digit); key = hexToKey(digit);
@ -115,7 +116,7 @@ void Unicode::typeCode(uint32_t unicode) {
} else { } else {
Key key; Key key;
if (::HostOS.os() == hostos::WINDOWS) { if (::HostOS.os() == hostos::WINDOWS) {
key = hexToKeyWindows(digit); key = hexToKeysWithNumpad(digit);
} }
else { else {
key = hexToKey(digit); key = hexToKey(digit);
@ -153,7 +154,7 @@ __attribute__((weak)) Key hexToKey(uint8_t hex) {
return { m, KEY_FLAGS }; return { m, KEY_FLAGS };
} }
__attribute__((weak)) Key hexToKeyWindows(uint8_t hex) { __attribute__((weak)) Key hexToKeysWithNumpad(uint8_t hex) {
uint8_t m; uint8_t m;
if (hex == 0x0) { if (hex == 0x0) {
return Key_Keypad0; return Key_Keypad0;

@ -38,7 +38,7 @@ class Unicode : public KaleidoscopePlugin {
} }
Key hexToKey(uint8_t hex); Key hexToKey(uint8_t hex);
Key hexToKeyWindows(uint8_t hex); Key hexToKeysWithNumpad(uint8_t hex);
void unicodeCustomStart(void); void unicodeCustomStart(void);
void unicodeCustomEnd(void); void unicodeCustomEnd(void);

Loading…
Cancel
Save