]> git.proxmox.com Git - mirror_edk2.git/blob - MdeModulePkg/Universal/SetupBrowserDxe/Setup.h
UEFI HII: Merge UEFI HII support changes from branch.
[mirror_edk2.git] / MdeModulePkg / Universal / SetupBrowserDxe / Setup.h
1 /** @file
2
3 Copyright (c) 2007, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
8
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
11
12 Module Name:
13
14 Setup.h
15
16 Abstract:
17
18
19 Revision History
20
21
22 **/
23
24 #ifndef _SETUP_H
25 #define _SETUP_H
26
27
28 #include <PiDxe.h>
29
30 #include <Protocol/Print.h>
31 #include <Protocol/SimpleTextOut.h>
32 #include <Protocol/SimpleTextIn.h>
33 #include <Protocol/FormBrowser2.h>
34 #include <Protocol/DevicePath.h>
35 #include <Protocol/UnicodeCollation.h>
36 #include <Protocol/HiiConfigAccess.h>
37 #include <Protocol/HiiConfigRouting.h>
38 #include <Protocol/HiiDatabase.h>
39 #include <Protocol/HiiString.h>
40
41 #include <MdeModuleHii.h>
42
43 #include <Library/GraphicsLib.h>
44 #include <Library/PrintLib.h>
45 #include <Library/DebugLib.h>
46 #include <Library/BaseMemoryLib.h>
47 #include <Library/UefiRuntimeServicesTableLib.h>
48 #include <Library/UefiDriverEntryPoint.h>
49 #include <Library/UefiBootServicesTableLib.h>
50 #include <Library/BaseLib.h>
51 #include <Library/MemoryAllocationLib.h>
52 #include <Library/IfrSupportLib.h>
53 #include <Library/HiiLib.h>
54
55 #include "R8Lib.h"
56
57 #include "Colors.h"
58
59 //@MT:#include EFI_PROTOCOL_DEFINITION (HiiDatabase)
60 //@MT:#include EFI_PROTOCOL_DEFINITION (HiiString)
61 //@MT:#include EFI_PROTOCOL_DEFINITION (HiiConfigRouting)
62 //@MT:#include EFI_PROTOCOL_DEFINITION (HiiConfigAccess)
63 //@MT:#include EFI_PROTOCOL_DEFINITION (FormBrowser2)
64
65 //@MT:#include EFI_GUID_DEFINITION (GlobalVariable)
66 //@MT:#include EFI_PROTOCOL_DEFINITION (DevicePath)
67 //@MT:#include EFI_PROTOCOL_DEFINITION (SimpleTextOut)
68 //@MT:#include EFI_PROTOCOL_DEFINITION (SimpleTextIn)
69 //@MT:#include EFI_PROTOCOL_DEFINITION (Print)
70 //@MT:#include EFI_PROTOCOL_DEFINITION (UnicodeCollation)
71
72 //
73 // This is the generated header file which includes whatever needs to be exported (strings + IFR)
74 //
75
76 extern UINT8 SetupBrowserStrings[];
77
78 //
79 // Screen definitions
80 //
81 #define BANNER_HEIGHT 6
82 #define BANNER_COLUMNS 3
83
84 #define FRONT_PAGE_HEADER_HEIGHT 6
85 #define NONE_FRONT_PAGE_HEADER_HEIGHT 3
86 #define LEFT_SKIPPED_COLUMNS 4
87 #define FOOTER_HEIGHT 4
88 #define STATUS_BAR_HEIGHT 1
89 #define SCROLL_ARROW_HEIGHT 1
90 #define POPUP_PAD_SPACE_COUNT 5
91 #define POPUP_FRAME_WIDTH 2
92
93 //
94 // Definition for function key setting
95 //
96 #define NONE_FUNCTION_KEY_SETTING 0
97 #define DEFAULT_FUNCTION_KEY_SETTING (FUNCTION_ONE | FUNCTION_TWO | FUNCTION_NINE | FUNCTION_TEN)
98
99 #define FUNCTION_ONE (1 << 0)
100 #define FUNCTION_TWO (1 << 1)
101 #define FUNCTION_NINE (1 << 2)
102 #define FUNCTION_TEN (1 << 3)
103
104 typedef struct {
105 EFI_GUID FormSetGuid;
106 UINTN KeySetting;
107 } FUNCTIION_KEY_SETTING;
108
109 //
110 // Character definitions
111 //
112 #define CHAR_SPACE 0x0020
113 #define UPPER_LOWER_CASE_OFFSET 0x20
114
115 //
116 // Time definitions
117 //
118 #define ONE_SECOND 10000000
119
120 //
121 // Display definitions
122 //
123 #define LEFT_HYPER_DELIMITER L'<'
124 #define RIGHT_HYPER_DELIMITER L'>'
125
126 #define LEFT_ONEOF_DELIMITER L'<'
127 #define RIGHT_ONEOF_DELIMITER L'>'
128
129 #define LEFT_NUMERIC_DELIMITER L'['
130 #define RIGHT_NUMERIC_DELIMITER L']'
131
132 #define LEFT_CHECKBOX_DELIMITER L'['
133 #define RIGHT_CHECKBOX_DELIMITER L']'
134
135 #define CHECK_ON L'X'
136 #define CHECK_OFF L' '
137
138 #define TIME_SEPARATOR L':'
139 #define DATE_SEPARATOR L'/'
140
141 #define YES_ANSWER L'Y'
142 #define NO_ANSWER L'N'
143
144 //
145 // This is the Input Error Message
146 //
147 #define INPUT_ERROR 1
148
149 //
150 // This is the NV RAM update required Message
151 //
152 #define NV_UPDATE_REQUIRED 2
153
154 //
155 // Refresh the Status Bar with flags
156 //
157 #define REFRESH_STATUS_BAR 0xff
158
159 //
160 // Incremental string lenght of ConfigRequest
161 //
162 #define CONFIG_REQUEST_STRING_INCREMENTAL 1024
163
164 //
165 // HII value compare result
166 //
167 #define HII_VALUE_UNDEFINED 0
168 #define HII_VALUE_EQUAL 1
169 #define HII_VALUE_LESS_THAN 2
170 #define HII_VALUE_GREATER_THAN 3
171
172 //
173 // Incremental size of stack for expression
174 //
175 #define EXPRESSION_STACK_SIZE_INCREMENT 0x100
176
177
178 #define EFI_SPECIFICATION_ERRATA_VERSION 0
179
180 #define EFI_IFR_SPECIFICATION_VERSION \
181 ((((EFI_SPECIFICATION_VERSION) >> 8) & 0xff00) | \
182 (((EFI_SPECIFICATION_VERSION) & 0xf) << 4) | \
183 ((EFI_SPECIFICATION_ERRATA_VERSION) & 0xf))
184
185 #define SETUP_DRIVER_SIGNATURE EFI_SIGNATURE_32 ('F', 'B', 'D', 'V')
186 typedef struct {
187 UINT32 Signature;
188
189 EFI_HANDLE Handle;
190
191 //
192 // Produced protocol
193 //
194 EFI_FORM_BROWSER2_PROTOCOL FormBrowser2;
195 EFI_PRINT_PROTOCOL Print;
196
197 } SETUP_DRIVER_PRIVATE_DATA;
198
199 typedef struct {
200 EFI_STRING_ID Banner[BANNER_HEIGHT][BANNER_COLUMNS];
201 } BANNER_DATA;
202
203 //
204 // IFR relative definition
205 //
206 #define EFI_HII_EXPRESSION_INCONSISTENT_IF 0
207 #define EFI_HII_EXPRESSION_NO_SUBMIT_IF 1
208 #define EFI_HII_EXPRESSION_GRAY_OUT_IF 2
209 #define EFI_HII_EXPRESSION_SUPPRESS_IF 3
210 #define EFI_HII_EXPRESSION_DISABLE_IF 4
211 #define EFI_HII_EXPRESSION_VALUE 5
212 #define EFI_HII_EXPRESSION_RULE 6
213
214 #define EFI_HII_VARSTORE_BUFFER 0
215 #define EFI_HII_VARSTORE_NAME_VALUE 1
216 #define EFI_HII_VARSTORE_EFI_VARIABLE 2
217
218 #define FORM_INCONSISTENT_VALIDATION 0
219 #define FORM_NO_SUBMIT_VALIDATION 1
220
221 typedef struct {
222 UINT8 Type;
223 EFI_IFR_TYPE_VALUE Value;
224 } EFI_HII_VALUE;
225
226 #define NAME_VALUE_NODE_SIGNATURE EFI_SIGNATURE_32 ('N', 'V', 'S', 'T')
227
228 typedef struct {
229 UINTN Signature;
230 LIST_ENTRY Link;
231 CHAR16 *Name;
232 CHAR16 *Value;
233 CHAR16 *EditValue;
234 } NAME_VALUE_NODE;
235
236 #define NAME_VALUE_NODE_FROM_LINK(a) CR (a, NAME_VALUE_NODE, Link, NAME_VALUE_NODE_SIGNATURE)
237
238 #define FORMSET_STORAGE_SIGNATURE EFI_SIGNATURE_32 ('F', 'S', 'T', 'G')
239
240 typedef struct {
241 UINTN Signature;
242 LIST_ENTRY Link;
243
244 UINT8 Type; // Storage type
245
246 UINT16 VarStoreId;
247 EFI_GUID Guid;
248
249 CHAR16 *Name; // For EFI_IFR_VARSTORE
250 UINT16 Size;
251 UINT8 *Buffer;
252 UINT8 *EditBuffer; // Edit copy for Buffer Storage
253
254 LIST_ENTRY NameValueListHead; // List of NAME_VALUE_NODE
255
256 UINT32 Attributes; // For EFI_IFR_VARSTORE_EFI: EFI Variable attribute
257
258 CHAR16 *ConfigHdr; // <ConfigHdr>
259 CHAR16 *ConfigRequest; // <ConfigRequest> = <ConfigHdr> + <RequestElement>
260 UINTN ElementCount; // Number of <RequestElement> in the <ConfigRequest>
261 UINTN SpareStrLen; // Spare length of ConfigRequest string buffer
262 } FORMSET_STORAGE;
263
264 #define FORMSET_STORAGE_FROM_LINK(a) CR (a, FORMSET_STORAGE, Link, FORMSET_STORAGE_SIGNATURE)
265
266 #define EXPRESSION_OPCODE_SIGNATURE EFI_SIGNATURE_32 ('E', 'X', 'O', 'P')
267
268 typedef struct {
269 UINTN Signature;
270 LIST_ENTRY Link;
271
272 UINT8 Operand;
273
274 UINT8 Format; // For EFI_IFR_TO_STRING, EFI_IFR_FIND
275 UINT8 Flags; // For EFI_IFR_SPAN
276 UINT8 RuleId; // For EFI_IFR_RULE_REF
277
278 EFI_HII_VALUE Value; // For EFI_IFR_EQ_ID_VAL, EFI_IFR_UINT64, EFI_IFR_UINT32, EFI_IFR_UINT16, EFI_IFR_UINT8, EFI_IFR_STRING_REF1
279
280 EFI_QUESTION_ID QuestionId; // For EFI_IFR_EQ_ID_ID, EFI_IFR_EQ_ID_LIST, EFI_IFR_QUESTION_REF1
281 EFI_QUESTION_ID QuestionId2;
282
283 UINT16 ListLength; // For EFI_IFR_EQ_ID_LIST
284 UINT16 *ValueList;
285
286 EFI_STRING_ID DevicePath; // For EFI_IFR_QUESTION_REF3_2, EFI_IFR_QUESTION_REF3_3
287 EFI_GUID Guid;
288 } EXPRESSION_OPCODE;
289
290 #define EXPRESSION_OPCODE_FROM_LINK(a) CR (a, EXPRESSION_OPCODE, Link, EXPRESSION_OPCODE_SIGNATURE)
291
292 #define FORM_EXPRESSION_SIGNATURE EFI_SIGNATURE_32 ('F', 'E', 'X', 'P')
293
294 typedef struct {
295 UINTN Signature;
296 LIST_ENTRY Link;
297
298 UINT8 Type; // Type for this expression
299
300 UINT8 RuleId; // For EFI_IFR_RULE only
301 EFI_STRING_ID Error; // For EFI_IFR_NO_SUBMIT_IF, EFI_IFR_INCONSISTENT_IF only
302
303 EFI_HII_VALUE Result; // Expression evaluation result
304
305 LIST_ENTRY OpCodeListHead; // OpCodes consist of this expression (EXPRESSION_OPCODE)
306 } FORM_EXPRESSION;
307
308 #define FORM_EXPRESSION_FROM_LINK(a) CR (a, FORM_EXPRESSION, Link, FORM_EXPRESSION_SIGNATURE)
309
310 #define QUESTION_DEFAULT_SIGNATURE EFI_SIGNATURE_32 ('Q', 'D', 'F', 'T')
311
312 typedef struct {
313 UINTN Signature;
314 LIST_ENTRY Link;
315
316 UINT16 DefaultId;
317 EFI_HII_VALUE Value; // Default value
318
319 FORM_EXPRESSION *ValueExpression; // Not-NULL indicates default value is provided by EFI_IFR_VALUE
320 } QUESTION_DEFAULT;
321
322 #define QUESTION_DEFAULT_FROM_LINK(a) CR (a, QUESTION_DEFAULT, Link, QUESTION_DEFAULT_SIGNATURE)
323
324 #define QUESTION_OPTION_SIGNATURE EFI_SIGNATURE_32 ('Q', 'O', 'P', 'T')
325
326 typedef struct {
327 UINTN Signature;
328 LIST_ENTRY Link;
329
330 EFI_STRING_ID Text;
331 UINT8 Flags;
332 EFI_HII_VALUE Value;
333 EFI_IMAGE_ID ImageId;
334
335 FORM_EXPRESSION *SuppressExpression; // Non-NULL indicates nested inside of SuppressIf
336 } QUESTION_OPTION;
337
338 #define QUESTION_OPTION_FROM_LINK(a) CR (a, QUESTION_OPTION, Link, QUESTION_OPTION_SIGNATURE)
339
340 #define FORM_BROWSER_STATEMENT_SIGNATURE EFI_SIGNATURE_32 ('F', 'S', 'T', 'A')
341 typedef struct {
342 UINTN Signature;
343 LIST_ENTRY Link;
344
345 UINT8 Operand; // The operand (first byte) of this Statement or Question
346
347 //
348 // Statement Header
349 //
350 EFI_STRING_ID Prompt;
351 EFI_STRING_ID Help;
352 EFI_STRING_ID TextTwo; // For EFI_IFR_TEXT
353
354 //
355 // Question Header
356 //
357 EFI_QUESTION_ID QuestionId; // The value of zero is reserved
358 EFI_VARSTORE_ID VarStoreId; // A value of zero indicates no variable storage
359 FORMSET_STORAGE *Storage;
360 union {
361 EFI_STRING_ID VarName;
362 UINT16 VarOffset;
363 } VarStoreInfo;
364 UINT16 StorageWidth;
365 UINT8 QuestionFlags;
366 CHAR16 *VariableName; // Name/Value or EFI Variable name
367 CHAR16 *BlockName; // Buffer storage block name: "OFFSET=...WIDTH=..."
368
369 EFI_HII_VALUE HiiValue; // Edit copy for checkbox, numberic, oneof
370 UINT8 *BufferValue; // Edit copy for string, password, orderedlist
371
372 //
373 // OpCode specific members
374 //
375 UINT8 Flags; // for EFI_IFR_CHECKBOX, EFI_IFR_DATE, EFI_IFR_NUMERIC, EFI_IFR_ONE_OF,
376 // EFI_IFR_ORDERED_LIST, EFI_IFR_STRING,EFI_IFR_SUBTITLE,EFI_IFR_TIME, EFI_IFR_BANNER
377 UINT8 MaxContainers; // for EFI_IFR_ORDERED_LIST
378
379 UINT16 BannerLineNumber; // for EFI_IFR_BANNER, 1-based line number
380 EFI_STRING_ID QuestionConfig; // for EFI_IFR_ACTION, if 0 then no configuration string will be processed
381
382 UINT64 Minimum; // for EFI_IFR_ONE_OF/EFI_IFR_NUMERIC, it's Min/Max value
383 UINT64 Maximum; // for EFI_IFR_STRING/EFI_IFR_PASSWORD, it's Min/Max length
384 UINT64 Step;
385
386 EFI_DEFAULT_ID DefaultId; // for EFI_IFR_RESET_BUTTON
387 EFI_FORM_ID RefFormId; // for EFI_IFR_REF
388 EFI_QUESTION_ID RefQuestionId; // for EFI_IFR_REF2
389 EFI_GUID RefFormSetId; // for EFI_IFR_REF3
390 EFI_STRING_ID RefDevicePath; // for EFI_IFR_REF4
391
392 //
393 // Get from IFR parsing
394 //
395 FORM_EXPRESSION *ValueExpression; // nested EFI_IFR_VALUE, provide Question value and indicate Question is ReadOnly
396 LIST_ENTRY DefaultListHead; // nested EFI_IFR_DEFAULT list (QUESTION_DEFAULT), provide default values
397 LIST_ENTRY OptionListHead; // nested EFI_IFR_ONE_OF_OPTION list (QUESTION_OPTION)
398
399 EFI_IMAGE_ID ImageId; // nested EFI_IFR_IMAGE
400 UINT8 RefreshInterval; // nested EFI_IFR_REFRESH, refresh interval(in seconds) for Question value, 0 means no refresh
401 BOOLEAN InSubtitle; // nesting inside of EFI_IFR_SUBTITLE
402
403 LIST_ENTRY InconsistentListHead;// nested inconsistent expression list (FORM_EXPRESSION)
404 LIST_ENTRY NoSubmitListHead; // nested nosubmit expression list (FORM_EXPRESSION)
405 FORM_EXPRESSION *GrayOutExpression; // nesting inside of GrayOutIf
406 FORM_EXPRESSION *SuppressExpression; // nesting inside of SuppressIf
407
408 } FORM_BROWSER_STATEMENT;
409
410 #define FORM_BROWSER_STATEMENT_FROM_LINK(a) CR (a, FORM_BROWSER_STATEMENT, Link, FORM_BROWSER_STATEMENT_SIGNATURE)
411
412 #define FORM_BROWSER_FORM_SIGNATURE EFI_SIGNATURE_32 ('F', 'F', 'R', 'M')
413
414 typedef struct {
415 UINTN Signature;
416 LIST_ENTRY Link;
417
418 UINT16 FormId;
419 EFI_STRING_ID FormTitle;
420
421 EFI_IMAGE_ID ImageId;
422
423 LIST_ENTRY ExpressionListHead; // List of Expressions (FORM_EXPRESSION)
424 LIST_ENTRY StatementListHead; // List of Statements and Questions (FORM_BROWSER_STATEMENT)
425 } FORM_BROWSER_FORM;
426
427 #define FORM_BROWSER_FORM_FROM_LINK(a) CR (a, FORM_BROWSER_FORM, Link, FORM_BROWSER_FORM_SIGNATURE)
428
429 #define FORMSET_DEFAULTSTORE_SIGNATURE EFI_SIGNATURE_32 ('F', 'D', 'F', 'S')
430
431 typedef struct {
432 UINTN Signature;
433 LIST_ENTRY Link;
434
435 UINT16 DefaultId;
436 EFI_STRING_ID DefaultName;
437 } FORMSET_DEFAULTSTORE;
438
439 #define FORMSET_DEFAULTSTORE_FROM_LINK(a) CR (a, FORMSET_DEFAULTSTORE, Link, FORMSET_DEFAULTSTORE_SIGNATURE)
440
441 typedef struct {
442 EFI_HII_HANDLE HiiHandle;
443 EFI_HANDLE DriverHandle;
444 EFI_HII_CONFIG_ACCESS_PROTOCOL *ConfigAccess;
445 EFI_DEVICE_PATH_PROTOCOL *DevicePath;
446
447 UINTN IfrBinaryLength;
448 UINT8 *IfrBinaryData;
449
450 EFI_GUID Guid;
451 EFI_STRING_ID FormSetTitle;
452 EFI_STRING_ID Help;
453 UINT16 Class;
454 UINT16 SubClass;
455 EFI_IMAGE_ID ImageId;
456
457 FORM_BROWSER_STATEMENT *StatementBuffer; // Buffer for all Statements and Questions
458 EXPRESSION_OPCODE *ExpressionBuffer; // Buffer for all Expression OpCode
459
460 LIST_ENTRY StorageListHead; // Storage list (FORMSET_STORAGE)
461 LIST_ENTRY DefaultStoreListHead; // DefaultStore list (FORMSET_DEFAULTSTORE)
462 LIST_ENTRY FormListHead; // Form list (FORM_BROWSER_FORM)
463 } FORM_BROWSER_FORMSET;
464
465
466 extern EFI_HII_DATABASE_PROTOCOL *mHiiDatabase;
467 extern EFI_HII_STRING_PROTOCOL *mHiiString;
468 extern EFI_HII_CONFIG_ROUTING_PROTOCOL *mHiiConfigRouting;
469
470 extern BANNER_DATA *BannerData;
471 extern EFI_HII_HANDLE FrontPageHandle;
472 extern UINTN gClassOfVfr;
473 extern UINTN gFunctionKeySetting;
474 extern BOOLEAN gResetRequired;
475 extern BOOLEAN gNvUpdateRequired;
476 extern EFI_HII_HANDLE gHiiHandle;
477 extern BOOLEAN gFirstIn;
478 extern UINT16 gDirection;
479 extern EFI_SCREEN_DESCRIPTOR gScreenDimensions;
480 extern BOOLEAN gUpArrow;
481 extern BOOLEAN gDownArrow;
482
483 //
484 // Browser Global Strings
485 //
486 extern CHAR16 *gFunctionOneString;
487 extern CHAR16 *gFunctionTwoString;
488 extern CHAR16 *gFunctionNineString;
489 extern CHAR16 *gFunctionTenString;
490 extern CHAR16 *gEnterString;
491 extern CHAR16 *gEnterCommitString;
492 extern CHAR16 *gEscapeString;
493 extern CHAR16 *gSaveFailed;
494 extern CHAR16 *gMoveHighlight;
495 extern CHAR16 *gMakeSelection;
496 extern CHAR16 *gDecNumericInput;
497 extern CHAR16 *gHexNumericInput;
498 extern CHAR16 *gToggleCheckBox;
499 extern CHAR16 *gPromptForData;
500 extern CHAR16 *gPromptForPassword;
501 extern CHAR16 *gPromptForNewPassword;
502 extern CHAR16 *gConfirmPassword;
503 extern CHAR16 *gConfirmError;
504 extern CHAR16 *gPassowordInvalid;
505 extern CHAR16 *gPressEnter;
506 extern CHAR16 *gEmptyString;
507 extern CHAR16 *gAreYouSure;
508 extern CHAR16 *gYesResponse;
509 extern CHAR16 *gNoResponse;
510 extern CHAR16 *gMiniString;
511 extern CHAR16 *gPlusString;
512 extern CHAR16 *gMinusString;
513 extern CHAR16 *gAdjustNumber;
514
515 extern CHAR16 gPromptBlockWidth;
516 extern CHAR16 gOptionBlockWidth;
517 extern CHAR16 gHelpBlockWidth;
518
519 extern EFI_GUID gZeroGuid;
520 extern EFI_GUID gTianoHiiIfrGuid;
521
522 //
523 // Global Procedure Defines
524 //
525 VOID
526 InitializeBrowserStrings (
527 VOID
528 )
529 ;
530
531 UINTN
532 _Print (
533 IN CHAR16 *fmt,
534 ...
535 )
536 ;
537
538 UINTN
539 PrintString (
540 CHAR16 *String
541 )
542 ;
543
544 UINTN
545 PrintChar (
546 CHAR16 Character
547 )
548 ;
549
550 UINTN
551 PrintAt (
552 IN UINTN Column,
553 IN UINTN Row,
554 IN CHAR16 *fmt,
555 ...
556 )
557 ;
558
559 UINTN
560 PrintStringAt (
561 IN UINTN Column,
562 IN UINTN Row,
563 CHAR16 *String
564 )
565 ;
566
567 UINTN
568 PrintCharAt (
569 IN UINTN Column,
570 IN UINTN Row,
571 CHAR16 Character
572 )
573 ;
574
575 EFI_STATUS
576 ParseOpCodes (
577 IN FORM_BROWSER_FORMSET *FormSet
578 )
579 ;
580
581 VOID
582 DestroyFormSet (
583 IN OUT FORM_BROWSER_FORMSET *FormSet
584 )
585 ;
586
587 VOID
588 DisplayPageFrame (
589 VOID
590 )
591 ;
592
593 EFI_STRING_ID
594 NewString (
595 IN CHAR16 *String,
596 IN EFI_HII_HANDLE HiiHandle
597 )
598 ;
599
600 EFI_STATUS
601 DeleteString (
602 IN EFI_STRING_ID StringId,
603 IN EFI_HII_HANDLE HiiHandle
604 )
605 ;
606 CHAR16 *
607 GetToken (
608 IN EFI_STRING_ID Token,
609 IN EFI_HII_HANDLE HiiHandle
610 )
611 ;
612
613 VOID
614 CreateSharedPopUp (
615 IN UINTN RequestedWidth,
616 IN UINTN NumberOfLines,
617 IN CHAR16 **ArrayOfStrings
618 )
619 ;
620
621 EFI_STATUS
622 CreateDialog (
623 IN UINTN NumberOfLines,
624 IN BOOLEAN HotKey,
625 IN UINTN MaximumStringSize,
626 OUT CHAR16 *StringBuffer,
627 OUT EFI_INPUT_KEY *KeyValue,
628 IN CHAR16 *String,
629 ...
630 )
631 ;
632
633 EFI_STATUS
634 GetQuestionValue (
635 IN FORM_BROWSER_FORMSET *FormSet,
636 IN FORM_BROWSER_FORM *Form,
637 IN OUT FORM_BROWSER_STATEMENT *Question,
638 IN BOOLEAN Cached
639 )
640 ;
641
642 EFI_STATUS
643 SetQuestionValue (
644 IN FORM_BROWSER_FORMSET *FormSet,
645 IN FORM_BROWSER_FORM *Form,
646 IN OUT FORM_BROWSER_STATEMENT *Question,
647 IN BOOLEAN Cached
648 )
649 ;
650
651 EFI_STATUS
652 ValidateQuestion (
653 IN FORM_BROWSER_FORMSET *FormSet,
654 IN FORM_BROWSER_FORM *Form,
655 IN FORM_BROWSER_STATEMENT *Question,
656 IN UINTN Type
657 )
658 ;
659
660 EFI_STATUS
661 SubmitForm (
662 IN FORM_BROWSER_FORMSET *FormSet,
663 IN FORM_BROWSER_FORM *Form
664 )
665 ;
666
667 EFI_STATUS
668 GetQuestionDefault (
669 IN FORM_BROWSER_FORMSET *FormSet,
670 IN FORM_BROWSER_FORM *Form,
671 IN FORM_BROWSER_STATEMENT *Question,
672 IN UINT16 DefaultId
673 )
674 ;
675
676 EFI_STATUS
677 InitializeCurrentSetting (
678 IN OUT FORM_BROWSER_FORMSET *FormSet
679 )
680 ;
681
682 EFI_STATUS
683 InitializeFormSet (
684 IN EFI_HII_HANDLE Handle,
685 IN OUT EFI_GUID *FormSetGuid,
686 OUT FORM_BROWSER_FORMSET *FormSet
687 )
688 ;
689
690 EFI_STATUS
691 ExtractFormDefault (
692 IN FORM_BROWSER_FORMSET *FormSet,
693 IN FORM_BROWSER_FORM *Form,
694 IN UINT16 DefaultId
695 )
696 ;
697
698 EFI_STATUS
699 LoadFormConfig (
700 IN FORM_BROWSER_FORMSET *FormSet,
701 IN FORM_BROWSER_FORM *Form
702 )
703 ;
704
705 EFI_STATUS
706 StorageToConfigResp (
707 IN FORMSET_STORAGE *Storage,
708 IN CHAR16 **ConfigResp
709 )
710 ;
711
712 EFI_STATUS
713 ConfigRespToStorage (
714 IN FORMSET_STORAGE *Storage,
715 IN CHAR16 *ConfigResp
716 )
717 ;
718
719 EFI_STATUS
720 LoadStorage (
721 IN FORM_BROWSER_FORMSET *FormSet,
722 IN FORMSET_STORAGE *Storage
723 )
724 ;
725
726 EFI_STATUS
727 GetIfrBinaryData (
728 IN EFI_HII_HANDLE Handle,
729 IN OUT EFI_GUID *FormSetGuid,
730 OUT UINTN *BinaryLength,
731 OUT UINT8 **BinaryData
732 )
733 ;
734
735 EFI_STATUS
736 EFIAPI
737 SendForm (
738 IN CONST EFI_FORM_BROWSER2_PROTOCOL *This,
739 IN EFI_HII_HANDLE *Handles,
740 IN UINTN HandleCount,
741 IN EFI_GUID *FormSetGuid, OPTIONAL
742 IN UINT16 FormId, OPTIONAL
743 IN CONST EFI_SCREEN_DESCRIPTOR *ScreenDimensions, OPTIONAL
744 OUT EFI_BROWSER_ACTION_REQUEST *ActionRequest OPTIONAL
745 )
746 ;
747
748 EFI_STATUS
749 EFIAPI
750 BrowserCallback (
751 IN CONST EFI_FORM_BROWSER2_PROTOCOL *This,
752 IN OUT UINTN *ResultsDataSize,
753 IN OUT EFI_STRING ResultsData,
754 IN BOOLEAN RetrieveData,
755 IN CONST EFI_GUID *VariableGuid, OPTIONAL
756 IN CONST CHAR16 *VariableName OPTIONAL
757 )
758 ;
759
760 #endif