]>
Commit | Line | Data |
---|---|---|
5c08e117 | 1 | /** @file\r |
2 | String support\r | |
3 | \r | |
fefefa4c | 4 | Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>\r |
180a5a35 | 5 | This program and the accompanying materials\r |
5c08e117 | 6 | are licensed and made available under the terms and conditions of the BSD License\r |
7 | which accompanies this distribution. The full text of the license may be found at\r | |
8 | http://opensource.org/licenses/bsd-license.php\r | |
9 | \r | |
10 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r | |
11 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r | |
12 | \r | |
13 | **/\r | |
14 | \r | |
15 | #include "Bds.h"\r | |
16 | #include "Language.h"\r | |
17 | #include "FrontPage.h"\r | |
18 | \r | |
19 | EFI_HII_HANDLE gStringPackHandle;\r | |
20 | \r | |
21 | EFI_GUID mBdsStringPackGuid = {\r | |
22 | 0x7bac95d3, 0xddf, 0x42f3, {0x9e, 0x24, 0x7c, 0x64, 0x49, 0x40, 0x37, 0x9a}\r | |
23 | };\r | |
24 | \r | |
25 | /**\r | |
13078b3f | 26 | Initialize HII global accessor for string support.\r |
5c08e117 | 27 | \r |
5c08e117 | 28 | **/\r |
cb7d01c0 | 29 | VOID\r |
5c08e117 | 30 | InitializeStringSupport (\r |
31 | VOID\r | |
32 | )\r | |
33 | {\r | |
cb7d01c0 | 34 | gStringPackHandle = HiiAddPackages (\r |
35 | &mBdsStringPackGuid,\r | |
fefefa4c | 36 | gImageHandle,\r |
cb7d01c0 | 37 | BdsDxeStrings,\r |
38 | NULL\r | |
39 | );\r | |
40 | ASSERT (gStringPackHandle != NULL);\r | |
5c08e117 | 41 | }\r |
42 | \r | |
43 | /**\r | |
44 | Get string by string id from HII Interface\r | |
45 | \r | |
46 | \r | |
47 | @param Id String ID.\r | |
48 | \r | |
49 | @retval CHAR16 * String from ID.\r | |
50 | @retval NULL If error occurs.\r | |
51 | \r | |
52 | **/\r | |
53 | CHAR16 *\r | |
54 | GetStringById (\r | |
55 | IN EFI_STRING_ID Id\r | |
56 | )\r | |
57 | {\r | |
cb7d01c0 | 58 | return HiiGetString (gStringPackHandle, Id, NULL);\r |
5c08e117 | 59 | }\r |