コード例 #1
0
 void HandleCapsLockKeyPressed(ModifierKeyBase capsLockKey)
 {
     _allLogicalKeys.OfType <CaseSensitiveKey>().ToList().ForEach(x => x.SelectedIndex =
                                                                      capsLockKey.IsInEffect ^ InputSimulator.IsKeyDownAsync(VirtualKeyCode.SHIFT) ? 1 : 0);
 }
コード例 #2
0
 void HandleNumLockKeyPressed(ModifierKeyBase numLockKey)
 {
     _allLogicalKeys.OfType <NumLockSensitiveKey>().ToList().ForEach(x => x.SelectedIndex = numLockKey.IsInEffect ? 1 : 0);
 }
コード例 #3
0
 void HandleShiftKeyPressed(ModifierKeyBase shiftKey)
 {
     _allLogicalKeys.OfType <CaseSensitiveKey>().ToList().ForEach(x => x.SelectedIndex =
                                                                      InputSimulator.IsTogglingKeyInEffect(VirtualKeyCode.CAPITAL) ^ shiftKey.IsInEffect ? 1 : 0);
     _allLogicalKeys.OfType <ShiftSensitiveKey>().ToList().ForEach(x => x.SelectedIndex = shiftKey.IsInEffect ? 1 : 0);
 }