Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Eric Dong <eric.dong@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15914
6f19259b-4bc3-4df7-8a09-
765794883524
TypeValue,\r
&ActionRequest\r
);\r
TypeValue,\r
&ActionRequest\r
);\r
- //\r
- // IFR is updated, force to reparse the IFR binary\r
- //\r
- if (mHiiPackageListUpdated) {\r
- if (BackUpBuffer != NULL) {\r
- FreePool (BackUpBuffer);\r
- }\r
-\r
- return EFI_SUCCESS;\r
- }\r
-\r
if (!EFI_ERROR (Status)) {\r
//\r
// Need to sync the value between Statement->HiiValue->Value and Statement->BufferValue\r
if (!EFI_ERROR (Status)) {\r
//\r
// Need to sync the value between Statement->HiiValue->Value and Statement->BufferValue\r
((Statement->QuestionFlags & EFI_IFR_FLAG_CALLBACK) == EFI_IFR_FLAG_CALLBACK) && \r
(Statement->Operand != EFI_IFR_PASSWORD_OP)) {\r
Status = ProcessCallBackFunction(Selection, Selection->FormSet, Selection->Form, Statement, EFI_BROWSER_ACTION_CHANGING, FALSE);\r
((Statement->QuestionFlags & EFI_IFR_FLAG_CALLBACK) == EFI_IFR_FLAG_CALLBACK) && \r
(Statement->Operand != EFI_IFR_PASSWORD_OP)) {\r
Status = ProcessCallBackFunction(Selection, Selection->FormSet, Selection->Form, Statement, EFI_BROWSER_ACTION_CHANGING, FALSE);\r
- //\r
- // IFR is updated during callback of EFI_BROWSER_ACTION_CHANGING, force to reparse the IFR binary\r
- //\r
- if (mHiiPackageListUpdated) {\r
- Selection->Action = UI_ACTION_REFRESH_FORMSET;\r
- mHiiPackageListUpdated = FALSE;\r
- break;\r
- }\r
-\r
if (Statement->Operand == EFI_IFR_REF_OP) {\r
//\r
// Process dynamic update ref opcode.\r
if (Statement->Operand == EFI_IFR_REF_OP) {\r
//\r
// Process dynamic update ref opcode.\r
\r
if (!EFI_ERROR (Status) && Statement->Operand != EFI_IFR_REF_OP) {\r
ProcessCallBackFunction(Selection, Selection->FormSet, Selection->Form, Statement, EFI_BROWSER_ACTION_CHANGED, FALSE);\r
\r
if (!EFI_ERROR (Status) && Statement->Operand != EFI_IFR_REF_OP) {\r
ProcessCallBackFunction(Selection, Selection->FormSet, Selection->Form, Statement, EFI_BROWSER_ACTION_CHANGED, FALSE);\r
- //\r
- // IFR is updated during callback of EFI_BROWSER_ACTION_CHANGED, force to reparse the IFR binary\r
- //\r
- if (mHiiPackageListUpdated) {\r
- Selection->Action = UI_ACTION_REFRESH_FORMSET;\r
- mHiiPackageListUpdated = FALSE;\r
- break;\r
- }\r
ASSERT (FormSet != NULL);\r
\r
Find = ValidateHiiHandle(FormSet->HiiHandle);\r
ASSERT (FormSet != NULL);\r
\r
Find = ValidateHiiHandle(FormSet->HiiHandle);\r
+ //\r
+ // Should not remove the formset which is being used.\r
+ //\r
+ if (!Find && (FormSet != gCurrentSelection->FormSet)) {\r
CleanBrowserStorage(FormSet);\r
RemoveEntryList (&FormSet->Link);\r
DestroyFormSet (FormSet);\r
CleanBrowserStorage(FormSet);\r
RemoveEntryList (&FormSet->Link);\r
DestroyFormSet (FormSet);\r