From 1b43162d70e8b09297b9cbba2fa7d041e3bc7113 Mon Sep 17 00:00:00 2001
From: Dandan Bi <dandan.bi@intel.com>
Date: Tue, 22 Dec 2015 09:37:33 +0000
Subject: [PATCH] MdeModulePkg:Clear the screen before booting the boot option

When do UiApp remodeling task,miss clearing the screen before booting
the selected boot option,so cause some behaviors change.Now add the code
to fix this issue.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Dandan Bi <dandan.bi@intel.com>
Reviewed-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@19441 6f19259b-4bc3-4df7-8a09-765794883524
---
 MdeModulePkg/Library/BootManagerLib/BootManager.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/MdeModulePkg/Library/BootManagerLib/BootManager.c b/MdeModulePkg/Library/BootManagerLib/BootManager.c
index 7a8ccfe152..d2494d8a37 100644
--- a/MdeModulePkg/Library/BootManagerLib/BootManager.c
+++ b/MdeModulePkg/Library/BootManagerLib/BootManager.c
@@ -705,6 +705,13 @@ BootManagerCallback (
   }
 
   BootOption = EfiBootManagerGetLoadOptions (&BootOptionCount, LoadOptionTypeBoot);
+
+  //
+  // Clear  the  screen  before.
+  //
+  gST->ConOut->SetAttribute (gST->ConOut, EFI_TEXT_ATTR (EFI_LIGHTGRAY, EFI_BLACK));
+  gST->ConOut->ClearScreen (gST->ConOut);
+
   //
   // parse the selected option
   //