diff options
author | ydong10 <ydong10@6f19259b-4bc3-4df7-8a09-765794883524> | 2011-02-22 08:05:56 +0000 |
---|---|---|
committer | ydong10 <ydong10@6f19259b-4bc3-4df7-8a09-765794883524> | 2011-02-22 08:05:56 +0000 |
commit | 1fcd34f8755c523ec687681c3c6d15ef4c86ccaa (patch) | |
tree | 67e3f5c1627cf1e1aeb2baa42683cf7836d05663 /MdeModulePkg/Universal | |
parent | d66e9f0d04e6b1216a942e918db474b7e5705bed (diff) | |
download | edk2-platforms-1fcd34f8755c523ec687681c3c6d15ef4c86ccaa.tar.xz |
fix refresh menu save attribute error. not consider the grayout attribute.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11329 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg/Universal')
-rw-r--r-- | MdeModulePkg/Universal/SetupBrowserDxe/Ui.c | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/MdeModulePkg/Universal/SetupBrowserDxe/Ui.c b/MdeModulePkg/Universal/SetupBrowserDxe/Ui.c index 54f9db0978..3dea095f5f 100644 --- a/MdeModulePkg/Universal/SetupBrowserDxe/Ui.c +++ b/MdeModulePkg/Universal/SetupBrowserDxe/Ui.c @@ -1876,7 +1876,11 @@ UiDisplayMenu ( MenuRefreshEntry->Selection = Selection;
MenuRefreshEntry->CurrentColumn = MenuOption->OptCol;
MenuRefreshEntry->CurrentRow = MenuOption->Row;
- MenuRefreshEntry->CurrentAttribute = PcdGet8 (PcdBrowserFieldTextColor) | FIELD_BACKGROUND;
+ if (MenuOption->GrayOut) {
+ MenuRefreshEntry->CurrentAttribute = FIELD_TEXT_GRAYED | FIELD_BACKGROUND;
+ } else {
+ MenuRefreshEntry->CurrentAttribute = PcdGet8 (PcdBrowserFieldTextColor) | FIELD_BACKGROUND;
+ }
gMenuRefreshHead = MenuRefreshEntry;
} else {
//
@@ -1894,7 +1898,11 @@ UiDisplayMenu ( MenuRefreshEntry->Selection = Selection;
MenuRefreshEntry->CurrentColumn = MenuOption->OptCol;
MenuRefreshEntry->CurrentRow = MenuOption->Row;
- MenuRefreshEntry->CurrentAttribute = PcdGet8 (PcdBrowserFieldTextColor) | FIELD_BACKGROUND;
+ if (MenuOption->GrayOut) {
+ MenuRefreshEntry->CurrentAttribute = FIELD_TEXT_GRAYED | FIELD_BACKGROUND;
+ } else {
+ MenuRefreshEntry->CurrentAttribute = PcdGet8 (PcdBrowserFieldTextColor) | FIELD_BACKGROUND;
+ }
}
}
@@ -2202,7 +2210,11 @@ UiDisplayMenu ( //
if (gMenuRefreshHead != NULL) {
for (MenuRefreshEntry = gMenuRefreshHead; MenuRefreshEntry != NULL; MenuRefreshEntry = MenuRefreshEntry->Next) {
- MenuRefreshEntry->CurrentAttribute = PcdGet8 (PcdBrowserFieldTextColor) | FIELD_BACKGROUND;
+ if (MenuOption->GrayOut) {
+ MenuRefreshEntry->CurrentAttribute = FIELD_TEXT_GRAYED | FIELD_BACKGROUND;
+ } else {
+ MenuRefreshEntry->CurrentAttribute = PcdGet8 (PcdBrowserFieldTextColor) | FIELD_BACKGROUND;
+ }
if (MenuRefreshEntry->MenuOption == MenuOption) {
MenuRefreshEntry->CurrentAttribute = PcdGet8 (PcdBrowserFieldTextHighlightColor) | PcdGet8 (PcdBrowserFieldBackgroundHighlightColor);
}
|