]>
Commit | Line | Data |
---|---|---|
1 | /** @file\r | |
2 | This protocol provides services to display a popup window.\r | |
3 | The protocol is typically produced by the forms browser and consumed by a driver callback handler.\r | |
4 | \r | |
5 | Copyright (c) 2017-2018, Intel Corporation. All rights reserved.<BR>\r | |
6 | SPDX-License-Identifier: BSD-2-Clause-Patent\r | |
7 | \r | |
8 | @par Revision Reference:\r | |
9 | This Protocol was introduced in UEFI Specification 2.7.\r | |
10 | \r | |
11 | **/\r | |
12 | \r | |
13 | #ifndef __HII_POPUP_H__\r | |
14 | #define __HII_POPUP_H__\r | |
15 | \r | |
16 | #define EFI_HII_POPUP_PROTOCOL_GUID \\r | |
17 | {0x4311edc0, 0x6054, 0x46d4, {0x9e, 0x40, 0x89, 0x3e, 0xa9, 0x52, 0xfc, 0xcc}}\r | |
18 | \r | |
19 | #define EFI_HII_POPUP_PROTOCOL_REVISION 1\r | |
20 | \r | |
21 | typedef struct _EFI_HII_POPUP_PROTOCOL EFI_HII_POPUP_PROTOCOL;\r | |
22 | \r | |
23 | typedef enum {\r | |
24 | EfiHiiPopupStyleInfo,\r | |
25 | EfiHiiPopupStyleWarning,\r | |
26 | EfiHiiPopupStyleError\r | |
27 | } EFI_HII_POPUP_STYLE;\r | |
28 | \r | |
29 | typedef enum {\r | |
30 | EfiHiiPopupTypeOk,\r | |
31 | EfiHiiPopupTypeOkCancel,\r | |
32 | EfiHiiPopupTypeYesNo,\r | |
33 | EfiHiiPopupTypeYesNoCancel\r | |
34 | } EFI_HII_POPUP_TYPE;\r | |
35 | \r | |
36 | typedef enum {\r | |
37 | EfiHiiPopupSelectionOk,\r | |
38 | EfiHiiPopupSelectionCancel,\r | |
39 | EfiHiiPopupSelectionYes,\r | |
40 | EfiHiiPopupSelectionNo\r | |
41 | } EFI_HII_POPUP_SELECTION;\r | |
42 | \r | |
43 | /**\r | |
44 | Displays a popup window.\r | |
45 | \r | |
46 | @param This A pointer to the EFI_HII_POPUP_PROTOCOL instance.\r | |
47 | @param PopupStyle Popup style to use.\r | |
48 | @param PopupType Type of the popup to display.\r | |
49 | @param HiiHandle HII handle of the string pack containing Message\r | |
50 | @param Message A message to display in the popup box.\r | |
51 | @param UserSelection User selection.\r | |
52 | \r | |
53 | @retval EFI_SUCCESS The popup box was successfully displayed.\r | |
54 | @retval EFI_INVALID_PARAMETER HiiHandle and Message do not define a valid HII string.\r | |
55 | @retval EFI_INVALID_PARAMETER PopupType is not one of the values defined by this specification.\r | |
56 | @retval EFI_OUT_OF_RESOURCES There are not enough resources available to display the popup box.\r | |
57 | \r | |
58 | **/\r | |
59 | typedef\r | |
60 | EFI_STATUS\r | |
61 | (EFIAPI * EFI_HII_CREATE_POPUP) (\r | |
62 | IN EFI_HII_POPUP_PROTOCOL *This,\r | |
63 | IN EFI_HII_POPUP_STYLE PopupStyle,\r | |
64 | IN EFI_HII_POPUP_TYPE PopupType,\r | |
65 | IN EFI_HII_HANDLE HiiHandle,\r | |
66 | IN EFI_STRING_ID Message,\r | |
67 | OUT EFI_HII_POPUP_SELECTION *UserSelection OPTIONAL\r | |
68 | );\r | |
69 | \r | |
70 | typedef struct _EFI_HII_POPUP_PROTOCOL {\r | |
71 | UINT64 Revision;\r | |
72 | EFI_HII_CREATE_POPUP CreatePopup;\r | |
73 | } EFI_HII_POPUP_PROTOCOL;\r | |
74 | \r | |
75 | extern EFI_GUID gEfiHiiPopupProtocolGuid;\r | |
76 | \r | |
77 | #endif\r | |
78 | \r |