Skip to content

Commit

Permalink
Applied patch for macos JIS keyboard.
Browse files Browse the repository at this point in the history
  • Loading branch information
saburahu committed Jul 7, 2020
1 parent 55ec310 commit edbc29f
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/lib/platform/OSXKeyState.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,11 @@ static const UInt32 s_brightnessDown = 145;
static const UInt32 s_missionControlVK = 160;
static const UInt32 s_launchpadVK = 131;

// for JIS Keybaord
static const UInt32 s_kanaVK = 104;
static const UInt32 s_eisuVK = 102;
static const UInt32 s_yenVK = 93;

static const UInt32 s_osxNumLock = 1 << 16;

struct KeyEntry {
Expand Down Expand Up @@ -115,6 +120,12 @@ static const KeyEntry s_controlKeys[] = {
{ kKeyMeta_L, s_superVK },
{ kKeyMeta_R, s_superVK }, // 61

// for JIS Keyboard
{ kKeyHenkan, s_kanaVK },
//{ kKeyHiraganaKatakana, s_kanaVK },
{ kKeyZenkaku, s_eisuVK },
{ 0x005c, s_yenVK},

// toggle modifiers
{ kKeyNumLock, s_numLockVK },
{ kKeyCapsLock, s_capsLockVK },
Expand Down

0 comments on commit edbc29f

Please sign in to comment.