More key codes. Explain (sort of) raw key codes in the manual.
authorJoe Wreschnig <joe.wreschnig@gmail.com>
Tue, 12 Mar 2013 14:37:57 +0000 (15:37 +0100)
committerJoe Wreschnig <joe.wreschnig@gmail.com>
Tue, 12 Mar 2013 14:37:57 +0000 (15:37 +0100)
Classes/NJKeyInputField.m
Enjoyable.xcodeproj/project.pbxproj
Info.plist
Resources/English.lproj/Localizable.strings
Resources/Help/Contents/Resources/English.lproj/pgs/keyboard.html

index 02896a8..791911b 100644 (file)
@@ -12,6 +12,9 @@
 
 enum {
     kVK_RightCommand = kVK_Command - 1,
+    kVK_Insert = 0x72,
+    kVK_Power = 0x7f,
+    kVK_ApplicationMenu = 0x6e,
     kVK_MAX = 0xFFFF,
 };
 
@@ -191,8 +194,17 @@ const CGKeyCode NJKeyInputFieldEmpty = kVK_MAX;
             return NSLocalizedString(@"Key Pad ,", @"numeric pad key");
         case kVK_JIS_Eisu: return @"英数";
         case kVK_JIS_Kana: return @"かな";
+            
+        case kVK_Power: return @"⌽";
+        case kVK_VolumeUp: return @"🔊";
+        case kVK_VolumeDown: return @"🔉";
+            
+        case kVK_Insert:
+            return NSLocalizedString(@"Insert", "keyboard key");
+        case kVK_ApplicationMenu:
+            return NSLocalizedString(@"Menu", "keyboard key");
 
-
+            
         case kVK_MAX: // NJKeyInputFieldEmpty
             return @"";
         default:
index ef109f0..f1bf0ff 100644 (file)
                29B97317FDCFA39411CA2CEA /* Resources */ = {
                        isa = PBXGroup;
                        children = (
-                               EE1F3CE816EF4182008C6426 /* Localizable.strings */,
                                EE3D897D16EA817E00596D1F /* Status Menu Icon Disabled.png */,
                                EE3D897E16EA817E00596D1F /* Status Menu Icon.png */,
                                EE3D897B16EA806E00596D1F /* Status Menu Icon Disabled@2x.png */,
                                EE3D897916EA7EFC00596D1F /* Status Menu Icon@2x.png */,
                                EE6A122D16E8F46300EDBD32 /* Icon.icns */,
                                EEF17D2116E8E24400D7DC4D /* Help */,
+                               EE1F3CE816EF4182008C6426 /* Localizable.strings */,
                                EEF17D1B16E8E23A00D7DC4D /* InfoPlist.strings */,
                                EEF17D1D16E8E23A00D7DC4D /* MainMenu.xib */,
                                EEF17D1716E8E21A00D7DC4D /* com.yukkurigames.Enjoyable.mapping.icns */,
index c72bc22..c4a9347 100644 (file)
@@ -46,7 +46,7 @@
        <key>CFBundleSignature</key>
        <string>????</string>
        <key>CFBundleVersion</key>
-       <string>185</string>
+       <string>187</string>
        <key>LSApplicationCategoryType</key>
        <string>public.app-category.utilities</string>
        <key>NSHumanReadableCopyright</key>
index 91f6bf7..63e6dc4 100644 (file)
Binary files a/Resources/English.lproj/Localizable.strings and b/Resources/English.lproj/Localizable.strings differ
index dca6136..522cf96 100644 (file)
 
     <h3><a name="clear_key"></a>Clearing the Selection</h3>
     <p>
-      To clear a mapped key either select the <b>Do nothing</b>
-      option or press â\8c¥⌫ when the key input field is selected.
+      To clear a mapped key select the <b>Do nothing</b>
+      option or press â\8c\98⌫ when the key input field is selected.
     </p>
 
     <h3><a name="cancel_key"></a>Cancelling the Selection</h3>
     <p>
-      If you select the key input field by mistake you can press ⌥⎋
-      to cancel the selection without changing the current setting.
+      If you select the key input field by mistake you can press ⌘⎋ or
+      click on the field to cancel the selection without changing the
+      current setting.
+    </p>
+
+    <h3><a name="raw_key"></a>Raw Key Codes</h3>
+    <p>
+      Hold ⌘ and click on the field to enter a raw key code. Key codes
+      are hexadecimal numbers associated with each key on a
+      keyboard. For example, if you need to map something to the Windows Menu
+      key and your keyboard doesn't have one, enter <kbd>0x6E</kbd> here.
     </p>
   </body>
 </html>