mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-31 01:24:12 +02:00
Update the logic to force user to reset when change configuration which need to reset.
Signed-off-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com> git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@13507 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
e768377c22
commit
63588e6106
@ -1124,25 +1124,20 @@ SetupResetReminder (
|
|||||||
ASSERT (StringBuffer1 != NULL);
|
ASSERT (StringBuffer1 != NULL);
|
||||||
StringBuffer2 = AllocateZeroPool (MAX_STRING_LEN * sizeof (CHAR16));
|
StringBuffer2 = AllocateZeroPool (MAX_STRING_LEN * sizeof (CHAR16));
|
||||||
ASSERT (StringBuffer2 != NULL);
|
ASSERT (StringBuffer2 != NULL);
|
||||||
StrCpy (StringBuffer1, L"Configuration changed. Reset to apply it Now ? ");
|
StrCpy (StringBuffer1, L"Configuration changed. Reset to apply it Now");
|
||||||
StrCpy (StringBuffer2, L"Enter (YES) / Esc (NO)");
|
StrCpy (StringBuffer2, L"Press ENTER to reset");
|
||||||
//
|
//
|
||||||
// Popup a menu to notice user
|
// Popup a menu to notice user
|
||||||
//
|
//
|
||||||
do {
|
do {
|
||||||
CreatePopUp (EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE, &Key, StringBuffer1, StringBuffer2, NULL);
|
CreatePopUp (EFI_LIGHTGRAY | EFI_BACKGROUND_BLUE, &Key, StringBuffer1, StringBuffer2, NULL);
|
||||||
} while ((Key.ScanCode != SCAN_ESC) && (Key.UnicodeChar != CHAR_CARRIAGE_RETURN));
|
} while (Key.UnicodeChar != CHAR_CARRIAGE_RETURN);
|
||||||
|
|
||||||
FreePool (StringBuffer1);
|
FreePool (StringBuffer1);
|
||||||
FreePool (StringBuffer2);
|
FreePool (StringBuffer2);
|
||||||
//
|
|
||||||
// If the user hits the YES Response key, reset
|
|
||||||
//
|
|
||||||
if (Key.UnicodeChar == CHAR_CARRIAGE_RETURN) {
|
|
||||||
gRT->ResetSystem (EfiResetCold, EFI_SUCCESS, 0, NULL);
|
gRT->ResetSystem (EfiResetCold, EFI_SUCCESS, 0, NULL);
|
||||||
}
|
}
|
||||||
gST->ConOut->ClearScreen (gST->ConOut);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user