diff options
author | Dandan Bi <dandan.bi@intel.com> | 2015-06-09 05:09:50 +0000 |
---|---|---|
committer | dandanbi <dandanbi@Edk2> | 2015-06-09 05:09:50 +0000 |
commit | 5e30b69eb4027f4fc6c8ef78d1961e7c78d80683 (patch) | |
tree | 6f3e23c7cd2433b7a4d89c323ba7df04d26cab3e /MdeModulePkg/Universal/SetupBrowserDxe | |
parent | 9d58ab0923a2fbd856cbe2ac5fadf3ce57ebc953 (diff) | |
download | edk2-platforms-5e30b69eb4027f4fc6c8ef78d1961e7c78d80683.tar.xz |
EDKII:Display engine should not depend on the framework code
Display engine base on class opcode to detect whether in
front page.Now remove class/subclass and use FormsetGuid
or ClassGuid to judge whether in front page
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Dandan Bi <dandan.bi@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17590 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg/Universal/SetupBrowserDxe')
-rw-r--r-- | MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c | 1 | ||||
-rw-r--r-- | MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c | 15 | ||||
-rw-r--r-- | MdeModulePkg/Universal/SetupBrowserDxe/Setup.h | 1 |
3 files changed, 17 insertions, 0 deletions
diff --git a/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c b/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c index 3785c32f3c..45405609c1 100644 --- a/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c +++ b/MdeModulePkg/Universal/SetupBrowserDxe/IfrParse.c @@ -1709,6 +1709,7 @@ ParseOpCodes ( CopyMem (&FormSet->FormSetTitle, &((EFI_IFR_FORM_SET *) OpCodeData)->FormSetTitle, sizeof (EFI_STRING_ID));
CopyMem (&FormSet->Help, &((EFI_IFR_FORM_SET *) OpCodeData)->Help, sizeof (EFI_STRING_ID));
+ FormSet->OpCode = (EFI_IFR_OP_HEADER *) OpCodeData;//save the opcode address of formset
if (OpCodeLength > OFFSET_OF (EFI_IFR_FORM_SET, Flags)) {
//
diff --git a/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c b/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c index 002a86a9b5..356cd9cd9a 100644 --- a/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c +++ b/MdeModulePkg/Universal/SetupBrowserDxe/Presentation.c @@ -546,6 +546,21 @@ AddStatementToDisplayForm ( }
//
+ // treat formset as statement outside the form,get its opcode.
+ //
+ DisplayStatement = AllocateZeroPool (sizeof (FORM_DISPLAY_ENGINE_STATEMENT));
+ ASSERT (DisplayStatement != NULL);
+
+ DisplayStatement->Signature = FORM_DISPLAY_ENGINE_STATEMENT_SIGNATURE;
+ DisplayStatement->Version = FORM_DISPLAY_ENGINE_STATEMENT_VERSION_1;
+ DisplayStatement->OpCode = gCurrentSelection->FormSet->OpCode;
+
+ InitializeListHead (&DisplayStatement->NestStatementList);
+ InitializeListHead (&DisplayStatement->OptionListHead);
+
+ InsertTailList(&gDisplayFormData.StatementListOSF, &DisplayStatement->DisplayLink);
+
+ //
// Process the statement in this form.
//
Link = GetFirstNode (&gCurrentSelection->Form->StatementListHead);
diff --git a/MdeModulePkg/Universal/SetupBrowserDxe/Setup.h b/MdeModulePkg/Universal/SetupBrowserDxe/Setup.h index c8aa9dde44..82bc23bbf1 100644 --- a/MdeModulePkg/Universal/SetupBrowserDxe/Setup.h +++ b/MdeModulePkg/Universal/SetupBrowserDxe/Setup.h @@ -454,6 +454,7 @@ typedef struct { UINT16 Class; // Tiano extended Class code
UINT16 SubClass; // Tiano extended Subclass code
EFI_IMAGE_ID ImageId;
+ EFI_IFR_OP_HEADER *OpCode; //mainly for formset op to get ClassGuid
FORM_BROWSER_STATEMENT *StatementBuffer; // Buffer for all Statements and Questions
EXPRESSION_OPCODE *ExpressionBuffer; // Buffer for all Expression OpCode
|