summaryrefslogtreecommitdiff
path: root/IntelFrameworkModulePkg/Universal/BdsDxe/Hotkey.c
diff options
context:
space:
mode:
Diffstat (limited to 'IntelFrameworkModulePkg/Universal/BdsDxe/Hotkey.c')
-rw-r--r--IntelFrameworkModulePkg/Universal/BdsDxe/Hotkey.c20
1 files changed, 12 insertions, 8 deletions
diff --git a/IntelFrameworkModulePkg/Universal/BdsDxe/Hotkey.c b/IntelFrameworkModulePkg/Universal/BdsDxe/Hotkey.c
index 1a3ec1ff8..477411377 100644
--- a/IntelFrameworkModulePkg/Universal/BdsDxe/Hotkey.c
+++ b/IntelFrameworkModulePkg/Universal/BdsDxe/Hotkey.c
@@ -2,7 +2,7 @@
Provides a way for 3rd party applications to register themselves for launch by the
Boot Manager based on hot key
-Copyright (c) 2007 - 2012, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2007 - 2013, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -315,6 +315,7 @@ HotkeyInsertList (
BDS_HOTKEY_OPTION *HotkeyLeft;
BDS_HOTKEY_OPTION *HotkeyRight;
UINTN Index;
+ EFI_BOOT_KEY_DATA KeyOptions;
UINT32 KeyShiftStateLeft;
UINT32 KeyShiftStateRight;
EFI_INPUT_KEY *InputKey;
@@ -327,28 +328,31 @@ HotkeyInsertList (
HotkeyLeft->Signature = BDS_HOTKEY_OPTION_SIGNATURE;
HotkeyLeft->BootOptionNumber = KeyOption->BootOption;
- HotkeyLeft->CodeCount = (UINT8) KEY_OPTION_INPUT_KEY_COUNT (KeyOption);
+
+ KeyOptions = KeyOption->KeyData;
+
+ HotkeyLeft->CodeCount = (UINT8) KeyOptions.Options.InputKeyCount;
//
// Map key shift state from KeyOptions to EFI_KEY_DATA.KeyState
//
KeyShiftStateRight = EFI_SHIFT_STATE_VALID;
- if (KEY_OPTION_SHIFT_PRESSED (KeyOption)) {
+ if (KeyOptions.Options.ShiftPressed) {
KeyShiftStateRight |= EFI_RIGHT_SHIFT_PRESSED;
}
- if (KEY_OPTION_CONTROL_PRESSED (KeyOption)) {
+ if (KeyOptions.Options.ControlPressed) {
KeyShiftStateRight |= EFI_RIGHT_CONTROL_PRESSED;
}
- if (KEY_OPTION_ALT_PRESSED (KeyOption)) {
+ if (KeyOptions.Options.AltPressed) {
KeyShiftStateRight |= EFI_RIGHT_ALT_PRESSED;
}
- if (KEY_OPTION_LOGO_PRESSED (KeyOption)) {
+ if (KeyOptions.Options.LogoPressed) {
KeyShiftStateRight |= EFI_RIGHT_LOGO_PRESSED;
}
- if (KEY_OPTION_MENU_PRESSED (KeyOption)) {
+ if (KeyOptions.Options.MenuPressed) {
KeyShiftStateRight |= EFI_MENU_KEY_PRESSED;
}
- if (KEY_OPTION_SYS_REQ_PRESSED (KeyOption)) {
+ if (KeyOptions.Options.SysReqPressed) {
KeyShiftStateRight |= EFI_SYS_REQ_PRESSED;
}