]> git.proxmox.com Git - mirror_edk2.git/blob - MdeModulePkg/Universal/BdsDxe/Hotkey.h
Update the function headers to Doxygen format.
[mirror_edk2.git] / MdeModulePkg / Universal / BdsDxe / Hotkey.h
1 /** @file
2 Provides a way for 3rd party applications to register themselves for launch by the
3 Boot Manager based on hot key
4
5 Copyright (c) 2007 - 2008, Intel Corporation. <BR>
6 All rights reserved. This program and the accompanying materials
7 are licensed and made available under the terms and conditions of the BSD License
8 which accompanies this distribution. The full text of the license may be found at
9 http://opensource.org/licenses/bsd-license.php
10
11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
13
14 **/
15
16 #ifndef _HOTKEY_H
17 #define _HOTKEY_H
18
19 #include "Bds.h"
20 #include "String.h"
21
22 #define GET_KEY_CODE_COUNT(KeyOptions) (((KeyOptions) & EFI_KEY_CODE_COUNT) >> 8)
23
24 #define BDS_HOTKEY_OPTION_SIGNATURE EFI_SIGNATURE_32 ('B', 'd', 'K', 'O')
25 typedef struct {
26 UINTN Signature;
27 LIST_ENTRY Link;
28
29 EFI_HANDLE NotifyHandle;
30 UINT16 BootOptionNumber;
31 UINT8 CodeCount;
32 UINT8 WaitingKey;
33 EFI_KEY_DATA KeyData[3];
34 } BDS_HOTKEY_OPTION;
35
36 #define BDS_HOTKEY_OPTION_FROM_LINK(a) CR (a, BDS_HOTKEY_OPTION, Link, BDS_HOTKEY_OPTION_SIGNATURE)
37
38 #define VarKeyOrder L"KeyOrder"
39
40 /**
41
42 Create Key#### for the given hotkey.
43
44
45 @param KeyOption - The Hot Key Option to be added.
46 @param KeyOptionNumber - The key option number for Key#### (optional).
47
48 @retval EFI_SUCCESS Register hotkey successfully.
49 @retval EFI_INVALID_PARAMETER The hotkey option is invalid.
50
51 **/
52 EFI_STATUS
53 RegisterHotkey (
54 IN EFI_KEY_OPTION *KeyOption,
55 OUT UINT16 *KeyOptionNumber
56 )
57 ;
58
59 /**
60
61 Delete Key#### for the given Key Option number.
62
63
64 @param KeyOptionNumber - Key option number for Key####
65
66 @retval EFI_SUCCESS Unregister hotkey successfully.
67 @retval EFI_NOT_FOUND No Key#### is found for the given Key Option number.
68
69 **/
70 EFI_STATUS
71 UnregisterHotkey (
72 IN UINT16 KeyOptionNumber
73 )
74 ;
75
76
77 /**
78
79 Process all the "Key####" variables, associate Hotkeys with corresponding Boot Options.
80
81
82 @param VOID
83
84 @retval EFI_SUCCESS Hotkey services successfully initialized.
85
86 **/
87 EFI_STATUS
88 InitializeHotkeyService (
89 VOID
90 )
91 ;
92
93 #endif