//\r
GetTextColors (This, &Foreground, &Background);\r
\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
\r
Warning = FALSE;\r
\r
This->Mode->CursorRow--;\r
This->Mode->CursorColumn = (INT32) (MaxColumn - 1);\r
This->OutputString (This, SpaceStr);\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
This->Mode->CursorRow--;\r
This->Mode->CursorColumn = (INT32) (MaxColumn - 1);\r
} else if (This->Mode->CursorColumn > 0) {\r
//\r
This->Mode->CursorColumn--;\r
This->OutputString (This, SpaceStr);\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
This->Mode->CursorColumn--;\r
}\r
\r
}\r
\r
if (This->Mode->CursorColumn >= (INT32) MaxColumn) {\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
This->OutputString (This, mCrLfString);\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
}\r
}\r
}\r
\r
This->Mode->Attribute = OriginAttribute;\r
\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
\r
if (Warning) {\r
Status = EFI_WARN_UNKNOWN_GLYPH;\r
// Otherwise, the size of the text console and/or the GOP/UGA mode will be changed,\r
// so erase the cursor, and free the LineBuffer for the current mode\r
//\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
\r
FreePool (Private->LineBuffer);\r
}\r
This->Mode->Mode = (INT32) ModeNumber;\r
\r
//\r
- // Move the text cursor to the upper left hand corner of the display and enable it\r
+ // Move the text cursor to the upper left hand corner of the display and flush it\r
//\r
- This->SetCursorPosition (This, 0, 0);\r
+ This->Mode->CursorColumn = 0;\r
+ This->Mode->CursorRow = 0;\r
+\r
+ FlushCursor (This); \r
\r
Status = EFI_SUCCESS;\r
\r
\r
OldTpl = gBS->RaiseTPL (TPL_NOTIFY);\r
\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
\r
This->Mode->Attribute = (INT32) Attribute;\r
\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
\r
gBS->RestoreTPL (OldTpl);\r
\r
This->Mode->CursorColumn = 0;\r
This->Mode->CursorRow = 0;\r
\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
\r
gBS->RestoreTPL (OldTpl);\r
\r
goto Done;\r
}\r
\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
\r
This->Mode->CursorColumn = (INT32) Column;\r
This->Mode->CursorRow = (INT32) Row;\r
\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
\r
Done:\r
gBS->RestoreTPL (OldTpl);\r
\r
OldTpl = gBS->RaiseTPL (TPL_NOTIFY);\r
\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
\r
This->Mode->CursorVisible = Visible;\r
\r
- EraseCursor (This);\r
+ FlushCursor (This);\r
\r
gBS->RestoreTPL (OldTpl);\r
return EFI_SUCCESS;\r
}\r
\r
/**\r
- Erase the cursor on the screen.\r
+ Flush the cursor on the screen.\r
+ \r
+ If CursorVisible is FALSE, nothing to do and return directly.\r
+ If CursorVisible is TRUE, \r
+ i) If the cursor shows on screen, it will be erased.\r
+ ii) If the cursor does not show on screen, it will be shown. \r
\r
@param This Protocol instance pointer.\r
\r
\r
**/\r
EFI_STATUS\r
-EraseCursor (\r
+FlushCursor (\r
IN EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL *This\r
)\r
{\r