diff options
author | qhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-01-16 09:50:29 +0000 |
---|---|---|
committer | qhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524> | 2008-01-16 09:50:29 +0000 |
commit | 66311a7863811a96aa2573852bcb4afe48720330 (patch) | |
tree | 5740eb7be06233d21661a3921fa714f4cbd2d6d4 | |
parent | 4befd6c3e0b0c6c46b49c4e55612bde6040243d0 (diff) | |
download | edk2-66311a7863811a96aa2573852bcb4afe48720330.zip edk2-66311a7863811a96aa2573852bcb4afe48720330.tar.gz edk2-66311a7863811a96aa2573852bcb4afe48720330.tar.bz2 |
1. Remove the hardcode default PlatformLang for English, use PcdUefiVariableDefaultPlatformLang defined in MdePkg instead.
2. Rename NibbleToHexChar to avoid naming collision.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/branches/UefiHiiEnable4354@4560 6f19259b-4bc3-4df7-8a09-765794883524
4 files changed, 10 insertions, 7 deletions
diff --git a/MdeModulePkg/Library/UefiIfrSupportLib/R8Lib.c b/MdeModulePkg/Library/UefiIfrSupportLib/R8Lib.c index 7f459e8..634bdb6 100644 --- a/MdeModulePkg/Library/UefiIfrSupportLib/R8Lib.c +++ b/MdeModulePkg/Library/UefiIfrSupportLib/R8Lib.c @@ -16,7 +16,7 @@ CHAR16 -NibbleToHexChar ( +InternalNibbleToHexChar ( IN UINT8 Nibble ) /*++ @@ -96,8 +96,8 @@ R8_BufToHexString ( for (Idx = 0; Idx < Len; Idx++) { Byte = Buf[Idx]; - Str[StrLen - 1 - Idx * 2] = NibbleToHexChar (Byte); - Str[StrLen - 2 - Idx * 2] = NibbleToHexChar ((UINT8)(Byte >> 4)); + Str[StrLen - 1 - Idx * 2] = InternalNibbleToHexChar (Byte); + Str[StrLen - 2 - Idx * 2] = InternalNibbleToHexChar ((UINT8)(Byte >> 4)); } return EFI_SUCCESS; diff --git a/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrLibraryInternal.h b/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrLibraryInternal.h index 0231d60..1a1f1c0 100644 --- a/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrLibraryInternal.h +++ b/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrLibraryInternal.h @@ -37,6 +37,7 @@ Abstract: #include <Library/DevicePathLib.h> #include <Library/MemoryAllocationLib.h> #include <Library/UefiIfrSupportLib.h> +#include <Library/PcdLib.h> #include <MdeModuleHii.h> diff --git a/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrString.c b/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrString.c index b1b43be..2536940 100644 --- a/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrString.c +++ b/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrString.c @@ -272,7 +272,7 @@ GetCurrentLanguage ( ); if (EFI_ERROR (Status)) { - AsciiStrCpy (Lang, "en-US"); + AsciiStrCpy (Lang, (CHAR8 *) PcdGetPtr (PcdUefiVariableDefaultPlatformLang)); } return Status; diff --git a/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrSupportLib.inf b/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrSupportLib.inf index dd01c67..30040b2 100644 --- a/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrSupportLib.inf +++ b/MdeModulePkg/Library/UefiIfrSupportLib/UefiIfrSupportLib.inf @@ -55,15 +55,17 @@ UefiRuntimeServicesTableLib
BaseMemoryLib
DebugLib
-
+ PcdLib
[Guids]
gEfiGlobalVariableGuid # ALWAYS_CONSUMED
-
[Protocols]
gEfiDevicePathProtocolGuid # PROTOCOL ALWAYS_CONSUMED
gEfiHiiDatabaseProtocolGuid
gEfiHiiStringProtocolGuid
gEfiHiiConfigRoutingProtocolGuid
-
+ gEfiFormBrowser2ProtocolGuid
+
+[Pcd]
+ gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultPlatformLang
\ No newline at end of file |