]>
Commit | Line | Data |
---|---|---|
79964ac8 | 1 | /** @file\r |
5259c97d | 2 | This file defines the Human Interface Infrastructure protocol, which is\r |
3 | used by resources that want to publish IFR/Font/String data and have it\r | |
f7590642 | 4 | collected by the Configuration engine.\r |
79964ac8 | 5 | \r |
2b3687db | 6 | Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>\r |
f22f941e | 7 | This program and the accompanying materials are licensed and made available under \r |
8 | the terms and conditions of the BSD License that accompanies this distribution. \r | |
9 | The full text of the license may be found at\r | |
10 | http://opensource.org/licenses/bsd-license.php. \r | |
11 | \r | |
12 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r | |
13 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r | |
79964ac8 | 14 | \r |
f7590642 | 15 | @par Revision Reference:\r |
16 | This protocol is defined in Framework for EFI Human Interface Infrastructure\r | |
17 | Specification Version 0.92.\r | |
18 | \r | |
79964ac8 | 19 | **/\r |
20 | \r | |
7c6d55db | 21 | #ifndef _FRAMEWORK_HII_H_\r |
22 | #define _FRAMEWORK_HII_H_\r | |
23 | \r | |
24 | //\r | |
5259c97d | 25 | // EFI_GRAPHICS_OUTPUT_BLT_PIXEL is defined in MdePkg/Protocol/GraphicsOutput.h\r |
7c6d55db | 26 | //\r |
27 | #include <Protocol/GraphicsOutput.h>\r | |
d9fdf2ca | 28 | ///\r |
f22f941e | 29 | /// In both EDK and EDK II, there is an incompatbile change in the Framework HII protocol.\r |
30 | /// This change should cause a change of GUID in both of code and HII specification. But we\r | |
31 | /// updated the GUID in code in EDK and EDK II. The 0.92 specification is not updated. This\r | |
d9fdf2ca | 32 | /// is a known issue.\r |
33 | ///\r | |
34 | ///\r | |
35 | /// Note that EFI_HII_PROTOCOL_GUID is different from that defined in the Framework HII\r | |
f22f941e | 36 | /// 0.92 specification because the specification changed part of HII interfaces but did not update the protocol\r |
d9fdf2ca | 37 | /// GUID.\r |
38 | ///\r | |
39 | #define EFI_HII_PROTOCOL_GUID \\r | |
79964ac8 | 40 | { \\r |
41 | 0xd7ad636e, 0xb997, 0x459b, {0xbf, 0x3f, 0x88, 0x46, 0x89, 0x79, 0x80, 0xe1} \\r | |
42 | }\r | |
43 | \r | |
c39940b5 | 44 | #define EFI_HII_COMPATIBILITY_PROTOCOL_GUID \\r |
45 | { \\r | |
46 | 0x5542cce1, 0xdf5c, 0x4d1b, { 0xab, 0xca, 0x36, 0x4f, 0x77, 0xd3, 0x99, 0xfb } \\r | |
47 | }\r | |
48 | \r | |
73449862 | 49 | typedef UINT32 RELOFST;\r |
50 | \r | |
79964ac8 | 51 | typedef struct _EFI_HII_PROTOCOL EFI_HII_PROTOCOL;\r |
52 | \r | |
06a098c4 | 53 | ///\r |
f22f941e | 54 | /// Note: Name difference between code and the Framework HII 0.92 specificaiton.\r |
55 | /// Add FRAMEWORK_ prefix to avoid a name confict with EFI_HII_HANDLE, defined in the\r | |
56 | /// UEFI 2.1d specification.\r | |
06a098c4 | 57 | ///\r |
dc7b4a5c | 58 | typedef UINT16 FRAMEWORK_EFI_HII_HANDLE;\r |
59 | \r | |
06a098c4 | 60 | ///\r |
61 | /// HII package type values\r | |
62 | ///\r | |
79964ac8 | 63 | #define EFI_HII_FONT 1\r |
64 | #define EFI_HII_STRING 2\r | |
65 | #define EFI_HII_IFR 3\r | |
66 | #define EFI_HII_KEYBOARD 4\r | |
67 | #define EFI_HII_HANDLES 5\r | |
68 | #define EFI_HII_VARIABLE 6\r | |
69 | #define EFI_HII_DEVICE_PATH 7\r | |
70 | \r | |
06a098c4 | 71 | //\r |
79964ac8 | 72 | // References to string tokens must use this macro to enable scanning for\r |
73 | // token usages.\r | |
74 | //\r | |
75 | #define STRING_TOKEN(t) t\r | |
76 | \r | |
77 | //\r | |
78 | // The following types are currently defined:\r | |
409f118c | 79 | // EFI_FORM_ID has been defined in UEFI spec.\r |
79964ac8 | 80 | //\r |
79964ac8 | 81 | typedef UINT16 EFI_FORM_LABEL;\r |
82 | \r | |
83 | #pragma pack(1)\r | |
84 | \r | |
06a098c4 | 85 | ///\r |
86 | /// The header found at the start of each package.\r | |
87 | ///\r | |
79964ac8 | 88 | typedef struct {\r |
06a098c4 | 89 | UINT32 Length; ///< The size of the package in bytes.\r |
90 | UINT16 Type; ///< The type of the package.\r | |
79964ac8 | 91 | } EFI_HII_PACK_HEADER;\r |
92 | \r | |
d9fdf2ca | 93 | ///\r |
f22f941e | 94 | /// The IFR package structure.\r |
d9fdf2ca | 95 | /// Immediately following the EFI_HII_IFR_PACK structure will be a series of IFR opcodes.\r |
96 | ///\r | |
97 | typedef struct {\r | |
06a098c4 | 98 | EFI_HII_PACK_HEADER Header; ///< Header of the IFR package.\r |
79964ac8 | 99 | } EFI_HII_IFR_PACK;\r |
100 | \r | |
06a098c4 | 101 | ///\r |
102 | /// HII Handle package structure.\r | |
d9fdf2ca | 103 | ///\r |
79964ac8 | 104 | typedef struct {\r |
d9fdf2ca | 105 | ///\r |
106 | /// Header of the package.\r | |
107 | ///\r | |
f22f941e | 108 | EFI_HII_PACK_HEADER Header; ///< Must be filled in.\r |
d9fdf2ca | 109 | ///\r |
110 | /// The image handle of the driver to which the package is referring.\r | |
111 | ///\r | |
f22f941e | 112 | EFI_HANDLE ImageHandle; ///< Must be filled in.\r |
d9fdf2ca | 113 | ///\r |
06a098c4 | 114 | /// The handle of the device that is being described by this package.\r |
115 | ///\r | |
f22f941e | 116 | EFI_HANDLE DeviceHandle; ///< Optional.\r |
06a098c4 | 117 | ///\r |
118 | /// The handle of the parent of the device that is being described by this package.\r | |
119 | ///\r | |
f22f941e | 120 | EFI_HANDLE ControllerHandle; ///< Optional.\r |
06a098c4 | 121 | ///\r |
122 | /// The handle that was registered to receive EFI_FORM_CALLBACK_PROTOCOL calls from other drivers.\r | |
123 | ///\r | |
f22f941e | 124 | EFI_HANDLE CallbackHandle; ///< Optional.\r |
06a098c4 | 125 | ///\r |
f22f941e | 126 | /// Note this field is not defined in the Framework HII 0.92 specificaiton.\r |
06a098c4 | 127 | /// Unused. Reserved for source code compatibility.\r |
128 | ///\r | |
f22f941e | 129 | EFI_HANDLE COBExportHandle; ///< Optional.\r |
79964ac8 | 130 | } EFI_HII_HANDLE_PACK;\r |
131 | \r | |
06a098c4 | 132 | ///\r |
f22f941e | 133 | /// The variable package structure.\r |
d9fdf2ca | 134 | ///\r |
79964ac8 | 135 | typedef struct {\r |
06a098c4 | 136 | ///\r |
f22f941e | 137 | /// The header of the package.\r |
06a098c4 | 138 | ///\r |
79964ac8 | 139 | EFI_HII_PACK_HEADER Header;\r |
06a098c4 | 140 | ///\r |
f22f941e | 141 | /// The GUID of the EFI variable.\r |
06a098c4 | 142 | ///\r |
79964ac8 | 143 | EFI_GUID VariableGuid;\r |
06a098c4 | 144 | ///\r |
f22f941e | 145 | /// The length in bytes of the EFI variable.\r |
06a098c4 | 146 | ///\r |
79964ac8 | 147 | UINT32 VariableNameLength;\r |
06a098c4 | 148 | ///\r |
f22f941e | 149 | /// The unique value for this variable.\r |
06a098c4 | 150 | ///\r |
79964ac8 | 151 | UINT16 VariableId;\r |
152 | //\r | |
153 | // CHAR16 VariableName[]; //Null-terminated\r | |
154 | //\r | |
155 | } EFI_HII_VARIABLE_PACK;\r | |
156 | \r | |
06a098c4 | 157 | ///\r |
f22f941e | 158 | /// The device path package structure.\r |
06a098c4 | 159 | ///\r |
79964ac8 | 160 | typedef struct {\r |
06a098c4 | 161 | ///\r |
f22f941e | 162 | /// The header of the package.\r |
06a098c4 | 163 | ///\r |
79964ac8 | 164 | EFI_HII_PACK_HEADER Header;\r |
165 | //\r | |
166 | // EFI_DEVICE_PATH DevicePath[];\r | |
167 | //\r | |
168 | } EFI_HII_DEVICE_PATH_PACK;\r | |
169 | \r | |
79964ac8 | 170 | typedef struct {\r |
06a098c4 | 171 | ///\r |
f22f941e | 172 | /// A unique value that correlates to the original HII handle.\r |
06a098c4 | 173 | ///\r |
dc7b4a5c | 174 | FRAMEWORK_EFI_HII_HANDLE HiiHandle;\r |
06a098c4 | 175 | ///\r |
176 | /// If an IFR pack exists in a data table that does not contain strings,\r | |
d9fdf2ca | 177 | /// then the strings for that IFR pack are located in another data table\r |
178 | /// that contains a string pack and has a matching HiiDataTable.PackageGuid.\r | |
06a098c4 | 179 | ///\r |
180 | EFI_GUID PackageGuid;\r | |
181 | ///\r | |
f22f941e | 182 | /// The size of the EFI_HII_DATA_TABLE in bytes.\r |
06a098c4 | 183 | ///\r |
184 | UINT32 DataTableSize;\r | |
185 | ///\r | |
f22f941e | 186 | /// The byte offset from the start of this structure to the IFR data.\r |
06a098c4 | 187 | /// If the offset value is 0, then no IFR data is enclosed.\r |
188 | ///\r | |
189 | UINT32 IfrDataOffset;\r | |
190 | ///\r | |
f22f941e | 191 | /// The byte offset from the start of this structure to the string data.\r |
06a098c4 | 192 | /// If the offset value is 0, then no string data is enclosed.\r |
193 | ///\r | |
194 | UINT32 StringDataOffset;\r | |
195 | ///\r | |
f22f941e | 196 | /// The byte offset from the start of this structure to the variable data.\r |
06a098c4 | 197 | /// If the offset value is 0, then no variable data is enclosed.\r |
198 | ///\r | |
199 | UINT32 VariableDataOffset;\r | |
200 | ///\r | |
f22f941e | 201 | /// The byte offset from the start of this structure to the device path data.\r |
06a098c4 | 202 | /// If the offset value is 0, then no DevicePath data is enclosed.\r |
203 | ///\r | |
204 | UINT32 DevicePathOffset;\r | |
205 | ///\r | |
f22f941e | 206 | /// The number of VariableData[] elements in the array.\r |
06a098c4 | 207 | ///\r |
208 | UINT32 NumberOfVariableData;\r | |
209 | ///\r | |
210 | /// The number of language string packages.\r | |
211 | ///\r | |
212 | UINT32 NumberOfLanguages;\r | |
79964ac8 | 213 | //\r |
214 | // EFI_HII_DEVICE_PATH_PACK DevicePath[];\r | |
215 | // EFI_HII_VARIABLE_PACK VariableData[];\r | |
216 | // EFI_HII_IFR_PACK IfrData;\r | |
217 | // EFI_HII_STRING_PACK StringData[];\r | |
218 | //\r | |
219 | } EFI_HII_DATA_TABLE;\r | |
220 | \r | |
06a098c4 | 221 | ///\r |
f22f941e | 222 | /// The structure defining the format for exporting data from the HII Database.\r |
06a098c4 | 223 | ///\r |
79964ac8 | 224 | typedef struct {\r |
06a098c4 | 225 | ///\r |
226 | /// Number of EFI_HII_DATA_TABLE entries.\r | |
227 | ///\r | |
79964ac8 | 228 | UINT32 NumberOfHiiDataTables;\r |
06a098c4 | 229 | ///\r |
230 | /// Defines the revision of the EFI_HII_DATA_TABLE structure.\r | |
231 | ///\r | |
79964ac8 | 232 | EFI_GUID Revision;\r |
233 | //\r | |
234 | // EFI_HII_DATA_TABLE HiiDataTable[];\r | |
235 | //\r | |
236 | } EFI_HII_EXPORT_TABLE;\r | |
237 | \r | |
06a098c4 | 238 | ///\r |
f22f941e | 239 | /// The structure used to pass data to update a form or form package\r |
06a098c4 | 240 | /// that has previously been registered with the EFI HII database.\r |
241 | ///\r | |
79964ac8 | 242 | typedef struct {\r |
06a098c4 | 243 | ///\r |
d9fdf2ca | 244 | /// If TRUE, indicates that the FormCallbackHandle value will\r |
06a098c4 | 245 | /// be used to update the contents of the CallBackHandle entry in the form set.\r |
246 | ///\r | |
247 | BOOLEAN FormSetUpdate;\r | |
248 | ///\r | |
249 | /// This parameter is valid only when FormSetUpdate is TRUE.\r | |
d9fdf2ca | 250 | /// The value in this parameter will be used to update the contents\r |
06a098c4 | 251 | /// of the CallbackHandle entry in the form set.\r |
252 | ///\r | |
253 | EFI_PHYSICAL_ADDRESS FormCallbackHandle;\r | |
254 | ///\r | |
d9fdf2ca | 255 | /// If TRUE, indicates that the FormTitle contents will be\r |
06a098c4 | 256 | /// used to update the FormValue's title.\r |
257 | ///\r | |
258 | BOOLEAN FormUpdate;\r | |
259 | ///\r | |
260 | /// Specifies which form is to be updated if the FormUpdate value is TRUE.\r | |
261 | ///\r | |
262 | UINT16 FormValue;\r | |
263 | ///\r | |
264 | /// This parameter is valid only when the FormUpdate parameter is TRUE.\r | |
d9fdf2ca | 265 | /// The value in this parameter will be used to update the contents of the form title.\r |
06a098c4 | 266 | ///\r |
267 | STRING_REF FormTitle;\r | |
268 | ///\r | |
269 | /// The number of Data entries in this structure.\r | |
270 | UINT16 DataCount;\r | |
271 | ///\r | |
272 | /// An array of 1+ opcodes, specified by DataCount.\r | |
273 | ///\r | |
274 | UINT8 *Data;\r | |
275 | } EFI_HII_UPDATE_DATA;\r | |
79964ac8 | 276 | \r |
277 | //\r | |
278 | // String attributes\r | |
279 | //\r | |
280 | #define LANG_RIGHT_TO_LEFT 0x00000001\r | |
281 | \r | |
d9fdf2ca | 282 | ///\r |
283 | /// A string package is used to localize strings to a particular\r | |
284 | /// language. The package is associated with a particular driver\r | |
285 | /// or set of drivers. Tools are used to associate tokens with\r | |
286 | /// string references in forms and in programs. These tokens are\r | |
287 | /// language agnostic. When paired with a language pack (directly\r | |
288 | /// or indirectly), the string token resolves into an actual\r | |
f22f941e | 289 | /// UNICODE string. NumStringPointers determines how many\r |
290 | /// StringPointers (offset values) there are, as well as the total\r | |
d9fdf2ca | 291 | /// number of Strings that are defined.\r |
292 | ///\r | |
293 | typedef struct {\r | |
06a098c4 | 294 | ///\r |
f22f941e | 295 | /// The header of the package.\r |
06a098c4 | 296 | ///\r |
79964ac8 | 297 | EFI_HII_PACK_HEADER Header;\r |
06a098c4 | 298 | ///\r |
299 | /// The string containing one or more ISO 639-2 three-character designator(s)\r | |
300 | /// of the language or languages whose translations are contained in this language pack.\r | |
f22f941e | 301 | /// The first designator indicates the primary language, while the others are secondary languages.\r |
06a098c4 | 302 | ///\r |
79964ac8 | 303 | RELOFST LanguageNameString;\r |
06a098c4 | 304 | ///\r |
305 | /// Contains the offset into this structure of a printable name of the language\r | |
306 | /// for use when prompting the user. The language printed is to be the primary language.\r | |
307 | ///\r | |
79964ac8 | 308 | RELOFST PrintableLanguageName;\r |
06a098c4 | 309 | ///\r |
310 | /// The number of Strings and StringPointers contained within the string package.\r | |
311 | ///\r | |
79964ac8 | 312 | UINT32 NumStringPointers;\r |
06a098c4 | 313 | ///\r |
314 | /// Indicates the direction the language is to be printed.\r | |
315 | ///\r | |
79964ac8 | 316 | UINT32 Attributes;\r |
317 | //\r | |
318 | // RELOFST StringPointers[];\r | |
319 | // EFI_STRING Strings[];\r | |
320 | //\r | |
321 | } EFI_HII_STRING_PACK;\r | |
322 | \r | |
79964ac8 | 323 | \r |
06a098c4 | 324 | ///\r |
325 | /// A font list consists of a font header followed by a series\r | |
326 | /// of glyph structures. Note that fonts are not language specific.\r | |
327 | ///\r | |
79964ac8 | 328 | typedef struct {\r |
06a098c4 | 329 | ///\r |
f22f941e | 330 | /// The header of the package.\r |
06a098c4 | 331 | ///\r |
79964ac8 | 332 | EFI_HII_PACK_HEADER Header;\r |
06a098c4 | 333 | ///\r |
334 | /// The number of NarrowGlyphs that are included in the font package.\r | |
335 | ///\r | |
79964ac8 | 336 | UINT16 NumberOfNarrowGlyphs;\r |
06a098c4 | 337 | ///\r |
338 | /// The number of WideGlyphs that are included in the font package.\r | |
339 | ///\r | |
79964ac8 | 340 | UINT16 NumberOfWideGlyphs;\r |
06a098c4 | 341 | //EFI_NARROW_GLYPH NarrowGlyphs[];\r |
342 | //EFI_WIDE_GLYPH WideGlyphs[];\r | |
79964ac8 | 343 | } EFI_HII_FONT_PACK;\r |
344 | \r | |
d9fdf2ca | 345 | ///\r |
346 | /// The definition of a specific physical key\r | |
347 | ///\r | |
f22f941e | 348 | /// Note: The name difference between code and the Framework HII 0.92 specification.\r |
d9fdf2ca | 349 | /// Add FRAMEWORK_ prefix to avoid name confict with EFI_KEY_DESCRIPTOR defined in the\r |
f22f941e | 350 | /// UEFI 2.1d specification.\r |
d9fdf2ca | 351 | ///\r |
352 | typedef struct {\r | |
06a098c4 | 353 | ///\r |
354 | /// Used to describe a physical key on a keyboard.\r | |
355 | ///\r | |
79964ac8 | 356 | EFI_KEY Key;\r |
06a098c4 | 357 | ///\r |
f22f941e | 358 | /// The Unicode value for the Key.\r |
79964ac8 | 359 | CHAR16 Unicode;\r |
06a098c4 | 360 | ///\r |
f22f941e | 361 | /// The Unicode value for the key with the shift key being held down.\r |
06a098c4 | 362 | ///\r |
79964ac8 | 363 | CHAR16 ShiftedUnicode;\r |
06a098c4 | 364 | ///\r |
f22f941e | 365 | /// The Unicode value for the key with the Alt-GR being held down.\r |
06a098c4 | 366 | ///\r |
79964ac8 | 367 | CHAR16 AltGrUnicode;\r |
06a098c4 | 368 | ///\r |
f22f941e | 369 | /// The Unicode value for the key with the Alt-GR and shift keys being held down.\r |
06a098c4 | 370 | ///\r |
79964ac8 | 371 | CHAR16 ShiftedAltGrUnicode;\r |
06a098c4 | 372 | ///\r |
d9fdf2ca | 373 | /// Modifier keys are defined to allow for special functionality that\r |
374 | /// is not necessarily accomplished by a printable character.\r | |
06a098c4 | 375 | ///\r |
79964ac8 | 376 | UINT16 Modifier;\r |
dc7b4a5c | 377 | } FRAMEWORK_EFI_KEY_DESCRIPTOR;\r |
79964ac8 | 378 | \r |
d9fdf2ca | 379 | ///\r |
380 | /// This structure allows a sparse set of keys to be redefined\r | |
381 | /// or a complete redefinition of the keyboard layout. Most\r | |
382 | /// keyboards have a lot of commonality in their layouts, therefore\r | |
383 | /// only defining those keys that need to change from the default\r | |
384 | /// minimizes the passed in information.\r | |
385 | ///\r | |
386 | /// Additionally, when an update occurs, the active keyboard layout\r | |
387 | /// will be switched to the newly updated keyboard layout. This\r | |
388 | /// allows for situations that when a keyboard layout driver is\r | |
389 | /// loaded as part of system initialization, the system will default\r | |
390 | /// the keyboard behavior to the new layout.\r | |
391 | ///\r | |
392 | typedef struct {\r | |
06a098c4 | 393 | ///\r |
f22f941e | 394 | /// The header of the package.\r |
06a098c4 | 395 | EFI_HII_PACK_HEADER Header;\r |
396 | ///\r | |
397 | /// A pointer to a buffer containing an array of EFI_KEY_DESCRIPTOR entries.\r | |
398 | /// Each entry will reflect the definition of a specific physical key.\r | |
399 | ///\r | |
dc7b4a5c | 400 | FRAMEWORK_EFI_KEY_DESCRIPTOR *Descriptor;\r |
06a098c4 | 401 | ///\r |
402 | /// The number of Descriptor entries being described.\r | |
403 | ///\r | |
404 | UINT8 DescriptorCount;\r | |
79964ac8 | 405 | } EFI_HII_KEYBOARD_PACK;\r |
406 | \r | |
06a098c4 | 407 | ///\r |
408 | /// The packages structure that will be used to pass contents into the HII database.\r | |
409 | ///\r | |
410 | /// The EFI_HII_PACKAGES can contain various number of packages of different types just\r | |
411 | /// after the structure as inline data.\r | |
412 | ///\r | |
79964ac8 | 413 | typedef struct {\r |
06a098c4 | 414 | ///\r |
415 | /// The number of packages being defined in this structure.\r | |
416 | ///\r | |
79964ac8 | 417 | UINTN NumberOfPackages;\r |
06a098c4 | 418 | ///\r |
419 | /// The GUID to be used to identify this set of packages that are being exported\r | |
420 | /// to the HII database.\r | |
421 | ///\r | |
79964ac8 | 422 | EFI_GUID *GuidId;\r |
423 | //\r | |
424 | // EFI_HII_HANDLE_PACK *HandlePack; // Only one pack.\r | |
425 | // EFI_HII_IFR_PACK *IfrPack; // Only one pack.\r | |
426 | // EFI_HII_FONT_PACK *FontPack[]; // Multiple packs ok\r | |
427 | // EFI_HII_STRING_PACK *StringPack[]; // Multiple packs ok\r | |
428 | // EFI_HII_KEYBOARD_PACK *KeyboardPack[]; // Multiple packs ok\r | |
429 | //\r | |
430 | } EFI_HII_PACKAGES;\r | |
431 | \r | |
06a098c4 | 432 | ///\r |
f22f941e | 433 | /// The packed link list that contains all the discernable defaults of variables\r |
06a098c4 | 434 | /// for the opcodes that are defined in this Handle's domain of data.\r |
435 | ///\r | |
79964ac8 | 436 | typedef struct _EFI_HII_VARIABLE_PACK_LIST {\r |
06a098c4 | 437 | ///\r |
d9fdf2ca | 438 | /// A pointer points to the next data structure of type\r |
06a098c4 | 439 | /// EFI_HII_VARIABLE_PACK_LIST in the packed link list.\r |
440 | ///\r | |
79964ac8 | 441 | struct _EFI_HII_VARIABLE_PACK_LIST *NextVariablePack;\r |
06a098c4 | 442 | ///\r |
443 | /// A pointer points to the content of the variable entry defined by GUID/name/data.\r | |
444 | ///\r | |
79964ac8 | 445 | EFI_HII_VARIABLE_PACK *VariablePack;\r |
06a098c4 | 446 | //EFI_HII_VARIABLE_PACK Content\r |
79964ac8 | 447 | } EFI_HII_VARIABLE_PACK_LIST;\r |
448 | \r | |
61a30832 | 449 | \r |
79964ac8 | 450 | #pragma pack()\r |
451 | \r | |
452 | /**\r | |
453 | Registers the various packs that are passed in via the Packages parameter.\r | |
454 | \r | |
455 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
456 | @param Packages A pointer to an EFI_HII_PACKAGES package instance.\r | |
534b8251 | 457 | @param Handle A pointer to the FRAMEWORK_EFI_HII_HANDLE instance.\r |
79964ac8 | 458 | \r |
459 | @retval EFI_SUCCESS Data was extracted from Packages, the database\r | |
460 | was updated with the data, and Handle returned successfully.\r | |
461 | @retval EFI_INVALID_PARAMETER The content of Packages was invalid.\r | |
462 | \r | |
463 | **/\r | |
464 | typedef\r | |
465 | EFI_STATUS\r | |
06a098c4 | 466 | (EFIAPI *EFI_HII_NEW_PACK)(\r |
467 | IN EFI_HII_PROTOCOL *This,\r | |
468 | IN EFI_HII_PACKAGES *Packages,\r | |
469 | OUT FRAMEWORK_EFI_HII_HANDLE *Handle\r | |
79964ac8 | 470 | );\r |
471 | \r | |
472 | /**\r | |
473 | Removes a package from the HII database.\r | |
474 | \r | |
475 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
f22f941e | 476 | @param Handle The handle that was registered to the data that \r |
477 | is requested for removal.\r | |
79964ac8 | 478 | \r |
479 | @retval EFI_SUCCESS The data associated with the Handle was removed\r | |
480 | from the HII database.\r | |
481 | @retval EFI_INVALID_PARAMETER The Handle was not valid.\r | |
482 | \r | |
483 | **/\r | |
484 | typedef\r | |
485 | EFI_STATUS\r | |
06a098c4 | 486 | (EFIAPI *EFI_HII_REMOVE_PACK)(\r |
487 | IN EFI_HII_PROTOCOL *This,\r | |
488 | IN FRAMEWORK_EFI_HII_HANDLE Handle\r | |
79964ac8 | 489 | );\r |
490 | \r | |
491 | /**\r | |
492 | Determines the handles that are currently active in the database.\r | |
493 | \r | |
494 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
495 | @param HandleBufferLength On input, a pointer to the length of the handle\r | |
496 | buffer. On output, the length of the handle buffer that is required\r | |
497 | for the handles found.\r | |
dc7b4a5c | 498 | @param Handle An array of FRAMEWORK_EFI_HII_HANDLE instances returned.\r |
79964ac8 | 499 | \r |
500 | @retval EFI_SUCCESS Handle was updated successfully.\r | |
501 | @retval EFI_BUFFER_TOO_SMALL The HandleBufferLength parameter indicates\r | |
502 | that Handle is too small to support the number of handles.\r | |
503 | \r | |
504 | **/\r | |
505 | typedef\r | |
506 | EFI_STATUS\r | |
06a098c4 | 507 | (EFIAPI *EFI_HII_FIND_HANDLES)(\r |
508 | IN EFI_HII_PROTOCOL *This,\r | |
509 | IN OUT UINT16 *HandleBufferLength,\r | |
510 | OUT FRAMEWORK_EFI_HII_HANDLE *Handle\r | |
79964ac8 | 511 | );\r |
512 | \r | |
513 | /**\r | |
514 | Exports the contents of the database into a buffer.\r | |
515 | \r | |
516 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
5259c97d | 517 | @param Handle A FRAMEWORK_EFI_HII_HANDLE that corresponds to the desired\r |
79964ac8 | 518 | handle to export. If the value is 0, the entire database will be exported.\r |
5259c97d | 519 | The data is exported in a format described by the\r |
79964ac8 | 520 | structure definition of EFI_HII_EXPORT_TABLE.\r |
521 | @param BufferSize\r | |
522 | On input, a pointer to the length of the buffer. On output, the length\r | |
523 | of the buffer that is required for the export data.\r | |
524 | @param Buffer A pointer to a buffer that will contain the results of the export function.\r | |
525 | \r | |
526 | @retval EFI_SUCCESS The buffer was successfully filled with BufferSize amount of data.\r | |
527 | @retval EFI_BUFFER_TOO_SMALL The value in BufferSize was too small to contain the export data.\r | |
528 | \r | |
529 | **/\r | |
530 | typedef\r | |
531 | EFI_STATUS\r | |
06a098c4 | 532 | (EFIAPI *EFI_HII_EXPORT)(\r |
533 | IN EFI_HII_PROTOCOL *This,\r | |
534 | IN FRAMEWORK_EFI_HII_HANDLE Handle,\r | |
535 | IN OUT UINTN *BufferSize,\r | |
536 | OUT VOID *Buffer\r | |
79964ac8 | 537 | );\r |
538 | \r | |
539 | /**\r | |
540 | Remove any new strings that were added after the initial string export\r | |
541 | for this handle.\r | |
542 | \r | |
543 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
544 | @param Handle The handle on which the string resides.\r | |
545 | \r | |
5259c97d | 546 | @retval EFI_SUCCESS Successfully removed strings from the handle.\r |
79964ac8 | 547 | @retval EFI_INVALID_PARAMETER The Handle was unknown.\r |
548 | \r | |
549 | **/\r | |
550 | typedef\r | |
551 | EFI_STATUS\r | |
06a098c4 | 552 | (EFIAPI *EFI_HII_RESET_STRINGS)(\r |
553 | IN EFI_HII_PROTOCOL *This,\r | |
554 | IN FRAMEWORK_EFI_HII_HANDLE Handle\r | |
79964ac8 | 555 | );\r |
556 | \r | |
557 | /**\r | |
558 | Tests if all of the characters in a string have corresponding font characters.\r | |
559 | \r | |
560 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
561 | @param StringToTest A pointer to a Unicode string.\r | |
562 | @param FirstMissing A pointer to an index into the string. On input,\r | |
f22f941e | 563 | the index of the first character in the StringToTest \r |
564 | to examine. On exit, the index of the first character \r | |
565 | encountered for which a glyph is unavailable.\r | |
566 | If all glyphs in the string are available, the \r | |
567 | index is the index of the terminator of the string.\r | |
79964ac8 | 568 | @param GlyphBufferSize A pointer to a value. On output, if the function\r |
f22f941e | 569 | returns EFI_SUCCESS, it contains the amount of \r |
570 | memory that is required to store the string's \r | |
571 | glyph equivalent.\r | |
79964ac8 | 572 | \r |
573 | @retval EFI_SUCCESS All glyphs are available. Note that an empty string\r | |
574 | always returns this value.\r | |
575 | @retval EFI_NOT_FOUND A glyph was not found for a character.\r | |
576 | \r | |
577 | **/\r | |
578 | typedef\r | |
579 | EFI_STATUS\r | |
e7be5d90 | 580 | (EFIAPI *EFI_HII_TEST_STRING)(\r |
79964ac8 | 581 | IN EFI_HII_PROTOCOL *This,\r |
582 | IN CHAR16 *StringToTest,\r | |
583 | IN OUT UINT32 *FirstMissing,\r | |
584 | OUT UINT32 *GlyphBufferSize\r | |
585 | );\r | |
586 | \r | |
587 | /**\r | |
588 | Translates a Unicode character into the corresponding font glyph.\r | |
589 | \r | |
f22f941e | 590 | Note that this function prototype name is different from that in the Framework HII 0.92 specification\r |
591 | to avoid name confict with EFI_HII_GET_GLYPH defined in the UEFI 2.1d specification.\r | |
06a098c4 | 592 | \r |
79964ac8 | 593 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r |
594 | @param Source A pointer to a Unicode string.\r | |
f22f941e | 595 | @param Index On input, the offset into the string from which to \r |
596 | fetch the character. On successful completion, the \r | |
597 | index is updated to the first character past the \r | |
598 | character(s) making up the just extracted glyph.\r | |
79964ac8 | 599 | @param GlyphBuffer Pointer to an array where the glyphs corresponding\r |
f22f941e | 600 | to the characters in the source may be stored. \r |
601 | GlyphBuffer is assumed to be wide enough to accept \r | |
602 | a wide glyph character.\r | |
79964ac8 | 603 | @param BitWidth If EFI_SUCCESS was returned, the UINT16 pointed to by\r |
f22f941e | 604 | this value is filled with the length of the glyph in\r |
605 | pixels. It is unchanged if the call was unsuccessful.\r | |
79964ac8 | 606 | @param InternalStatus The cell pointed to by this parameter must be\r |
f22f941e | 607 | initialized to zero prior to invoking the call the \r |
608 | first time for any string.\r | |
79964ac8 | 609 | \r |
f22f941e | 610 | @retval EFI_SUCCESS Found the corresponding font glyph for a Unicode \r |
611 | character. \r | |
79964ac8 | 612 | @retval EFI_NOT_FOUND A glyph for a character was not found.\r |
613 | \r | |
614 | **/\r | |
615 | typedef\r | |
616 | EFI_STATUS\r | |
69686d56 | 617 | (EFIAPI *FRAMEWORK_EFI_HII_GET_GLYPH)(\r |
79964ac8 | 618 | IN EFI_HII_PROTOCOL *This,\r |
619 | IN CHAR16 *Source,\r | |
620 | IN OUT UINT16 *Index,\r | |
621 | OUT UINT8 **GlyphBuffer,\r | |
622 | OUT UINT16 *BitWidth,\r | |
623 | IN OUT UINT32 *InternalStatus\r | |
624 | );\r | |
625 | \r | |
626 | /**\r | |
627 | Translates a glyph into the format required for input to the Universal\r | |
628 | Graphics Adapter (UGA) Block Transfer (BLT) routines.\r | |
629 | \r | |
630 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
631 | @param GlyphBuffer A pointer to the buffer that contains glyph data.\r | |
632 | @param Foreground The foreground setting requested to be used for the\r | |
633 | generated BltBuffer data.\r | |
634 | @param Background The background setting requested to be used for the\r | |
635 | generated BltBuffer data.\r | |
636 | @param Count The entry in the BltBuffer upon which to act.\r | |
637 | @param Width The width in bits of the glyph being converted.\r | |
638 | @param Height The height in bits of the glyph being converted\r | |
639 | @param BltBuffer A pointer to the buffer that contains the data that is\r | |
640 | ready to be used by the UGA BLT routines.\r | |
641 | \r | |
f22f941e | 642 | @retval EFI_SUCCESS Successfully translated a glyph into the required \r |
643 | format for input to UGA BLT routines.\r | |
79964ac8 | 644 | @retval EFI_NOT_FOUND A glyph for a character was not found.\r |
77a72512 | 645 | @note Inconsistent with specification here:\r |
f22f941e | 646 | In Framework Spec, HII specification 0.92. The type of 3rd, 4th and 8th parameter is EFI_UGA_PIXEL.\r |
647 | Here the definition uses the EFI_GRAPHICS_OUTPUT_BLT_PIXEL, which is defined in UEFI 2.1 specification.\r | |
79964ac8 | 648 | **/\r |
649 | typedef\r | |
650 | EFI_STATUS\r | |
06a098c4 | 651 | (EFIAPI *EFI_HII_GLYPH_TO_BLT)(\r |
79964ac8 | 652 | IN EFI_HII_PROTOCOL *This,\r |
653 | IN UINT8 *GlyphBuffer,\r | |
654 | IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL Foreground,\r | |
655 | IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL Background,\r | |
656 | IN UINTN Count,\r | |
657 | IN UINTN Width,\r | |
658 | IN UINTN Height,\r | |
659 | IN OUT EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer\r | |
660 | );\r | |
661 | \r | |
662 | /**\r | |
663 | Allows a new string to be added to an already existing string package.\r | |
664 | \r | |
f22f941e | 665 | Note that this function prototype name is different from that in the Framework HII 0.92 specification\r |
666 | to avoid name confict with EFI_HII_NEW_STRING defined in the UEFI 2.1d specification.\r | |
06a098c4 | 667 | \r |
79964ac8 | 668 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r |
f22f941e | 669 | @param Pointer to a NULL-terminated string containing a single \r |
670 | ISO 639-2 language identifier, indicating the language \r | |
671 | in which the string is translated. \r | |
672 | @param Handle The handle of the language pack to which the string \r | |
673 | is to be added.\r | |
674 | @param Reference The identifier of the string to be added. If the \r | |
675 | reference value is zero, then the string will be \r | |
676 | assigned a new identifier on that handle for\r | |
677 | the language specified. Otherwise, the string will \r | |
678 | be updated with the NewString Value.\r | |
79964ac8 | 679 | @param NewString The string to be added.\r |
680 | \r | |
681 | @retval EFI_SUCCESS The string was effectively registered.\r | |
682 | @retval EFI_INVALID_PARAMETER The Handle was unknown.\r | |
683 | \r | |
684 | **/\r | |
685 | typedef\r | |
686 | EFI_STATUS\r | |
69686d56 | 687 | (EFIAPI *FRAMEWORK_EFI_HII_NEW_STRING)(\r |
06a098c4 | 688 | IN EFI_HII_PROTOCOL *This,\r |
689 | IN CHAR16 *Language,\r | |
690 | IN FRAMEWORK_EFI_HII_HANDLE Handle,\r | |
691 | IN OUT STRING_REF *Reference,\r | |
692 | IN CHAR16 *NewString\r | |
79964ac8 | 693 | );\r |
694 | \r | |
695 | /**\r | |
696 | Allows a program to determine the primary languages that are supported\r | |
697 | on a given handle.\r | |
698 | \r | |
699 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
700 | @param Handle The handle on which the strings reside.\r | |
701 | @param LanguageString A string allocated by GetPrimaryLanguages() that\r | |
f22f941e | 702 | contains a list of all primary languages registered \r |
703 | on the handle.\r | |
79964ac8 | 704 | \r |
705 | @retval EFI_SUCCESS LanguageString was correctly returned.\r | |
706 | @retval EFI_INVALID_PARAMETER The Handle was unknown.\r | |
707 | \r | |
708 | **/\r | |
709 | typedef\r | |
710 | EFI_STATUS\r | |
06a098c4 | 711 | (EFIAPI *EFI_HII_GET_PRI_LANGUAGES)(\r |
712 | IN EFI_HII_PROTOCOL *This,\r | |
713 | IN FRAMEWORK_EFI_HII_HANDLE Handle,\r | |
714 | OUT EFI_STRING *LanguageString\r | |
79964ac8 | 715 | );\r |
716 | \r | |
717 | /**\r | |
718 | Allows a program to determine which secondary languages are supported\r | |
719 | on a given handle for a given primary language.\r | |
720 | \r | |
721 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
722 | @param Handle The handle on which the strings reside.\r | |
f22f941e | 723 | @param PrimaryLanguage Pointer to a NULL-terminated string containing a \r |
724 | single ISO 639-2 language identifier, indicating \r | |
725 | the primary language.\r | |
79964ac8 | 726 | @param LanguageString A string allocated by GetSecondaryLanguages()\r |
f22f941e | 727 | containing a list of all secondary languages \r |
728 | registered on the handle.\r | |
79964ac8 | 729 | \r |
730 | @retval EFI_SUCCESS LanguageString was correctly returned.\r | |
731 | @retval EFI_INVALID_PARAMETER The Handle was unknown.\r | |
732 | \r | |
733 | **/\r | |
734 | typedef\r | |
735 | EFI_STATUS\r | |
06a098c4 | 736 | (EFIAPI *EFI_HII_GET_SEC_LANGUAGES)(\r |
737 | IN EFI_HII_PROTOCOL *This,\r | |
738 | IN FRAMEWORK_EFI_HII_HANDLE Handle,\r | |
739 | IN CHAR16 *PrimaryLanguage,\r | |
740 | OUT EFI_STRING *LanguageString\r | |
79964ac8 | 741 | );\r |
742 | \r | |
743 | /**\r | |
744 | Extracts a string from a package already registered with the EFI HII database.\r | |
745 | \r | |
f22f941e | 746 | Note that this function prototype name is different from that in the Framework HII 0.92 specification\r |
747 | to avoid name confict with EFI_HII_GET_STRING defined in the UEFI 2.1d specification.\r | |
06a098c4 | 748 | \r |
79964ac8 | 749 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r |
750 | @param Handle The handle on which the string resides.\r | |
751 | @param Token The string token assigned to the string.\r | |
f22f941e | 752 | @param Raw If TRUE, the string is returned unedited in the \r |
753 | internal storage format. If false, the string \r | |
754 | returned is edited by replacing <cr> with <space> \r | |
755 | and by removing special characters such as the\r | |
756 | <wide> prefix.\r | |
79964ac8 | 757 | @param LanguageString Pointer to a NULL-terminated string containing a\r |
f22f941e | 758 | single ISO 639-2 language identifier, indicating \r |
759 | the language to print. If the LanguageString is \r | |
760 | empty (starts with a NULL), the default system\r | |
79964ac8 | 761 | language will be used to determine the language.\r |
762 | @param BufferLength Length of the StringBuffer.\r | |
763 | @param StringBuffer The buffer designed to receive the characters in the string.\r | |
764 | \r | |
765 | @retval EFI_SUCCESS StringBuffer is filled with a NULL-terminated string.\r | |
766 | @retval EFI_INVALID_PARAMETER The handle or string token is unknown.\r | |
767 | @retval EFI_BUFFER_TOO_SMALL The buffer provided was not large enough to\r | |
768 | allow the entire string to be stored.\r | |
769 | \r | |
770 | **/\r | |
771 | typedef\r | |
772 | EFI_STATUS\r | |
69686d56 | 773 | (EFIAPI *FRAMEWORK_EFI_HII_GET_STRING)(\r |
06a098c4 | 774 | IN EFI_HII_PROTOCOL *This,\r |
775 | IN FRAMEWORK_EFI_HII_HANDLE Handle,\r | |
776 | IN STRING_REF Token,\r | |
777 | IN BOOLEAN Raw,\r | |
778 | IN CHAR16 *LanguageString,\r | |
779 | IN OUT UINTN *BufferLength,\r | |
780 | OUT EFI_STRING StringBuffer\r | |
79964ac8 | 781 | );\r |
782 | \r | |
783 | /**\r | |
784 | Allows a program to extract a part of a string of not more than a given width.\r | |
785 | \r | |
786 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
787 | @param Handle The handle on which the string resides.\r | |
788 | @param Token The string token assigned to the string.\r | |
f22f941e | 789 | @param Index On input, the offset into the string where the \r |
790 | line is to start. On output, the index is updated \r | |
791 | to point beyond the last character returned in \r | |
792 | the call.\r | |
79964ac8 | 793 | @param LineWidth The maximum width of the line in units of narrow glyphs.\r |
f22f941e | 794 | @param LanguageString The pointer to a NULL-terminated string containing a\r |
795 | single ISO 639-2 language identifier, indicating \r | |
796 | the language to print.\r | |
797 | @param BufferLength The pointer to the length of the StringBuffer.\r | |
798 | @param StringBuffer The buffer designed to receive the characters in \r | |
799 | the string.\r | |
800 | \r | |
801 | @retval EFI_SUCCESS StringBuffer filled with characters that will fit \r | |
802 | on the line.\r | |
79964ac8 | 803 | @retval EFI_NOT_FOUND The font glyph for at least one of the characters in\r |
804 | the string is not in the font database.\r | |
805 | @retval EFI_BUFFER_TOO_SMALL The buffer provided was not large enough\r | |
806 | to allow the entire string to be stored.\r | |
807 | \r | |
808 | **/\r | |
809 | typedef\r | |
810 | EFI_STATUS\r | |
06a098c4 | 811 | (EFIAPI *EFI_HII_GET_LINE)(\r |
812 | IN EFI_HII_PROTOCOL *This,\r | |
813 | IN FRAMEWORK_EFI_HII_HANDLE Handle,\r | |
814 | IN STRING_REF Token,\r | |
815 | IN OUT UINT16 *Index,\r | |
816 | IN UINT16 LineWidth,\r | |
817 | IN CHAR16 *LanguageString,\r | |
818 | IN OUT UINT16 *BufferLength,\r | |
819 | OUT EFI_STRING StringBuffer\r | |
79964ac8 | 820 | );\r |
821 | \r | |
822 | /**\r | |
823 | Allows a program to extract a form or form package that has previously\r | |
824 | been registered with the HII database.\r | |
825 | \r | |
826 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
827 | @param Handle Handle on which the form resides.\r | |
828 | @param FormId The ID of the form to return. If the ID is zero,\r | |
829 | the entire form package is returned.\r | |
830 | @param BufferLength On input, the length of the Buffer. On output,\r | |
831 | the length of the returned buffer,\r | |
832 | @param Buffer The buffer designed to receive the form(s).\r | |
833 | \r | |
834 | @retval EFI_SUCCESS Buffer filled with the requested forms. BufferLength\r | |
835 | was updated.\r | |
836 | @retval EFI_INVALID_PARAMETER The handle is unknown.\r | |
837 | @retval EFI_NOT_FOUND A form on the requested handle cannot be found with\r | |
838 | the requested FormId.\r | |
839 | @retval EFI_BUFFER_TOO_SMALL The buffer provided was not large enough\r | |
840 | to allow the form to be stored.\r | |
841 | \r | |
842 | **/\r | |
843 | typedef\r | |
844 | EFI_STATUS\r | |
06a098c4 | 845 | (EFIAPI *EFI_HII_GET_FORMS)(\r |
846 | IN EFI_HII_PROTOCOL *This,\r | |
847 | IN FRAMEWORK_EFI_HII_HANDLE Handle,\r | |
848 | IN EFI_FORM_ID FormId,\r | |
849 | IN OUT UINTN *BufferLength,\r | |
850 | OUT UINT8 *Buffer\r | |
79964ac8 | 851 | );\r |
852 | \r | |
853 | /**\r | |
854 | Extracts the defaults that are associated with a given handle in the HII database.\r | |
855 | \r | |
856 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
857 | @param Handle The HII handle from which will have default data retrieved.\r | |
f22f941e | 858 | @param DefaultMask The mask used to specify some type of default \r |
859 | override when extracting the default image data.\r | |
860 | @param VariablePackList An indirect pointer to the first entry of a link \r | |
861 | list with type EFI_HII_VARIABLE_PACK_LIST.\r | |
79964ac8 | 862 | \r |
863 | @retval EFI_SUCCESS The VariablePackList was populated with the appropriate\r | |
864 | default setting data.\r | |
865 | @retval EFI_NOT_FOUND The IFR does not have any explicit or default map(s).\r | |
866 | @retval EFI_INVALID_PARAMETER The HII database entry associated with Handle\r | |
f22f941e | 867 | contains invalid data.\r |
79964ac8 | 868 | \r |
869 | **/\r | |
870 | typedef\r | |
871 | EFI_STATUS\r | |
06a098c4 | 872 | (EFIAPI *EFI_HII_GET_DEFAULT_IMAGE)(\r |
79964ac8 | 873 | IN EFI_HII_PROTOCOL *This,\r |
dc7b4a5c | 874 | IN FRAMEWORK_EFI_HII_HANDLE Handle,\r |
79964ac8 | 875 | IN UINTN DefaultMask,\r |
876 | OUT EFI_HII_VARIABLE_PACK_LIST **VariablePackList\r | |
877 | );\r | |
878 | \r | |
879 | /**\r | |
880 | Allows the caller to update a form or form package that has previously been\r | |
881 | registered with the EFI HII database.\r | |
882 | \r | |
883 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r | |
884 | @param Handle Handle of the package where the form to be updated resides.\r | |
885 | @param Label The label inside the form package where the update is to take place.\r | |
886 | @param AddData If TRUE, adding data at a given Label; otherwise,\r | |
887 | if FALSE, removing data at a given Label.\r | |
888 | @param Data The buffer containing the new tags to insert after the Label\r | |
889 | \r | |
890 | @retval EFI_SUCCESS The form was updated with the new tags.\r | |
891 | @retval EFI_INVALID_PARAMETER The buffer for the buffer length does not\r | |
892 | contain an integral number of tags.\r | |
893 | @retval EFI_NOT_FOUND The Handle, Label, or FormId was not found.\r | |
894 | \r | |
895 | **/\r | |
896 | typedef\r | |
897 | EFI_STATUS\r | |
06a098c4 | 898 | (EFIAPI *EFI_HII_UPDATE_FORM)(\r |
899 | IN EFI_HII_PROTOCOL *This,\r | |
900 | IN FRAMEWORK_EFI_HII_HANDLE Handle,\r | |
901 | IN EFI_FORM_LABEL Label,\r | |
902 | IN BOOLEAN AddData,\r | |
903 | IN EFI_HII_UPDATE_DATA *Data\r | |
79964ac8 | 904 | );\r |
905 | \r | |
906 | /**\r | |
907 | Retrieves the current keyboard layout.\r | |
908 | \r | |
f22f941e | 909 | Note that this function prototype name is different from that in the Framework HII 0.92 specification\r |
910 | to avoid name confict with EFI_HII_GET_KEYBOARD_LAYOUT defined in the UEFI 2.1d specification.\r | |
06a098c4 | 911 | \r |
79964ac8 | 912 | @param This A pointer to the EFI_HII_PROTOCOL instance.\r |
913 | @param DescriptorCount A pointer to the number of Descriptor entries being\r | |
914 | described in the keyboard layout being retrieved.\r | |
f22f941e | 915 | @param Descriptor A pointer to a buffer containing an array of \r |
916 | FRAMEWORK_EFI_KEY_DESCRIPTOR entries. Each entry \r | |
917 | will reflect the definition of a specific physical key.\r | |
79964ac8 | 918 | \r |
919 | @retval EFI_SUCCESS The keyboard layout was retrieved successfully.\r | |
920 | \r | |
921 | **/\r | |
922 | typedef\r | |
923 | EFI_STATUS\r | |
69686d56 | 924 | (EFIAPI *FRAMEWORK_EFI_HII_GET_KEYBOARD_LAYOUT)(\r |
06a098c4 | 925 | IN EFI_HII_PROTOCOL *This,\r |
926 | OUT UINT16 *DescriptorCount,\r | |
dc7b4a5c | 927 | OUT FRAMEWORK_EFI_KEY_DESCRIPTOR *Descriptor\r |
79964ac8 | 928 | );\r |
929 | \r | |
06a098c4 | 930 | ///\r |
931 | /// The HII Protocol manages the HII database, which is a repository for data\r | |
932 | /// having to do with fonts, strings, forms, keyboards, and other future human\r | |
933 | /// interface items.\r | |
934 | ///\r | |
79964ac8 | 935 | struct _EFI_HII_PROTOCOL {\r |
2bbaeb0d | 936 | ///\r |
937 | /// Extracts the various packs from a package list.\r | |
938 | ///\r | |
06a098c4 | 939 | EFI_HII_NEW_PACK NewPack;\r |
d9fdf2ca | 940 | \r |
2bbaeb0d | 941 | ///\r |
942 | /// Removes a package from the HII database.\r | |
943 | ///\r | |
06a098c4 | 944 | EFI_HII_REMOVE_PACK RemovePack;\r |
d9fdf2ca | 945 | \r |
2bbaeb0d | 946 | ///\r |
947 | /// Determines the handles that are currently active in the database.\r | |
d9fdf2ca | 948 | ///\r |
06a098c4 | 949 | EFI_HII_FIND_HANDLES FindHandles;\r |
d9fdf2ca | 950 | \r |
2bbaeb0d | 951 | ///\r |
f22f941e | 952 | /// Exports the entire contents of the database to a buffer.\r |
2bbaeb0d | 953 | ///\r |
06a098c4 | 954 | EFI_HII_EXPORT ExportDatabase;\r |
c1adc63d | 955 | \r |
2bbaeb0d | 956 | ///\r |
957 | /// Tests if all of the characters in a string have corresponding font characters.\r | |
958 | ///\r | |
06a098c4 | 959 | EFI_HII_TEST_STRING TestString;\r |
d9fdf2ca | 960 | \r |
2bbaeb0d | 961 | ///\r |
962 | /// Translates a Unicode character into the corresponding font glyph.\r | |
963 | ///\r | |
c1adc63d | 964 | FRAMEWORK_EFI_HII_GET_GLYPH GetGlyph;\r |
d9fdf2ca | 965 | \r |
2bbaeb0d | 966 | ///\r |
967 | /// Converts a glyph value into a format that is ready for a UGA BLT command.\r | |
968 | ///\r | |
06a098c4 | 969 | EFI_HII_GLYPH_TO_BLT GlyphToBlt;\r |
c1adc63d | 970 | \r |
2bbaeb0d | 971 | ///\r |
972 | /// Allows a new string to be added to an already existing string package.\r | |
973 | ///\r | |
c1adc63d | 974 | FRAMEWORK_EFI_HII_NEW_STRING NewString;\r |
d9fdf2ca | 975 | \r |
2bbaeb0d | 976 | ///\r |
977 | /// Allows a program to determine the primary languages that are supported\r | |
d9fdf2ca | 978 | /// on a given handle.\r |
2bbaeb0d | 979 | ///\r |
06a098c4 | 980 | EFI_HII_GET_PRI_LANGUAGES GetPrimaryLanguages;\r |
d9fdf2ca | 981 | \r |
2bbaeb0d | 982 | ///\r |
983 | /// Allows a program to determine which secondary languages are supported\r | |
d9fdf2ca | 984 | /// on a given handle for a given primary language.\r |
2bbaeb0d | 985 | ///\r |
06a098c4 | 986 | EFI_HII_GET_SEC_LANGUAGES GetSecondaryLanguages;\r |
d9fdf2ca | 987 | \r |
2bbaeb0d | 988 | ///\r |
989 | /// Extracts a string from a package that is already registered with the\r | |
d9fdf2ca | 990 | /// EFI HII database.\r |
2bbaeb0d | 991 | ///\r |
c1adc63d | 992 | FRAMEWORK_EFI_HII_GET_STRING GetString;\r |
d9fdf2ca | 993 | \r |
2bbaeb0d | 994 | ///\r |
f22f941e | 995 | /// Removes any new strings that were added after the initial string export\r |
d9fdf2ca | 996 | /// for this handle.\r |
997 | ///\r | |
f22f941e | 998 | /// Note this function is not defined in the Framework HII 0.92 specification.\r |
2bbaeb0d | 999 | ///\r |
06a098c4 | 1000 | EFI_HII_RESET_STRINGS ResetStrings;\r |
d9fdf2ca | 1001 | \r |
2bbaeb0d | 1002 | ///\r |
1003 | /// Allows a program to extract a part of a string of not more than a given width.\r | |
1004 | ///\r | |
06a098c4 | 1005 | EFI_HII_GET_LINE GetLine;\r |
d9fdf2ca | 1006 | \r |
2bbaeb0d | 1007 | ///\r |
1008 | /// Allows a program to extract a form or form package that has been previously registered.\r | |
1009 | ///\r | |
06a098c4 | 1010 | EFI_HII_GET_FORMS GetForms;\r |
d9fdf2ca | 1011 | \r |
2bbaeb0d | 1012 | ///\r |
1013 | /// Allows a program to extract the nonvolatile image that represents the default storage image.\r | |
1014 | ///\r | |
06a098c4 | 1015 | EFI_HII_GET_DEFAULT_IMAGE GetDefaultImage;\r |
d9fdf2ca | 1016 | \r |
2bbaeb0d | 1017 | ///\r |
1018 | /// Allows a program to update a previously registered form.\r | |
1019 | ///\r | |
06a098c4 | 1020 | EFI_HII_UPDATE_FORM UpdateForm;\r |
c1adc63d | 1021 | \r |
2bbaeb0d | 1022 | ///\r |
1023 | /// Allows a program to extract the current keyboard layout.\r | |
1024 | ///\r | |
c1adc63d | 1025 | FRAMEWORK_EFI_HII_GET_KEYBOARD_LAYOUT GetKeyboardLayout;\r |
79964ac8 | 1026 | };\r |
1027 | \r | |
1028 | extern EFI_GUID gEfiHiiProtocolGuid;\r | |
c39940b5 | 1029 | extern EFI_GUID gEfiHiiCompatibilityProtocolGuid;\r |
1030 | \r | |
79964ac8 | 1031 | #endif\r |
06a098c4 | 1032 | \r |