Add new call back return value; also add some sample code to use it.

Signed-off-by: ydong10
Reviewed-by: lgao4


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11713 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
ydong10
2011-05-31 00:59:15 +00:00
parent d490265ca6
commit b18e705046
12 changed files with 990 additions and 433 deletions

View File

@@ -637,7 +637,7 @@ EnterCarriageReturn:
//
// NV flag is unnecessary for RTC type of Date/Time
//
UpdateStatusBar (NV_UPDATE_REQUIRED, Question->QuestionFlags, TRUE);
UpdateStatusBar (Selection, NV_UPDATE_REQUIRED, Question->QuestionFlags, TRUE);
}
}
@@ -653,7 +653,7 @@ EnterCarriageReturn:
// Remove a character
//
EditValue = PreviousNumber[Count - 1];
UpdateStatusBar (INPUT_ERROR, Question->QuestionFlags, FALSE);
UpdateStatusBar (Selection, INPUT_ERROR, Question->QuestionFlags, FALSE);
Count--;
Column--;
PrintAt (Column, Row, L" ");
@@ -670,12 +670,12 @@ EnterCarriageReturn:
} else if ((Key.UnicodeChar >= L'a') && (Key.UnicodeChar <= L'f')) {
Digital = (UINT8) (Key.UnicodeChar - L'a' + 0x0A);
} else {
UpdateStatusBar (INPUT_ERROR, Question->QuestionFlags, TRUE);
UpdateStatusBar (Selection, INPUT_ERROR, Question->QuestionFlags, TRUE);
break;
}
} else {
if (Key.UnicodeChar > L'9' || Key.UnicodeChar < L'0') {
UpdateStatusBar (INPUT_ERROR, Question->QuestionFlags, TRUE);
UpdateStatusBar (Selection, INPUT_ERROR, Question->QuestionFlags, TRUE);
break;
}
}
@@ -704,12 +704,12 @@ EnterCarriageReturn:
}
if (EditValue > Maximum) {
UpdateStatusBar (INPUT_ERROR, Question->QuestionFlags, TRUE);
UpdateStatusBar (Selection, INPUT_ERROR, Question->QuestionFlags, TRUE);
ASSERT (Count < sizeof (PreviousNumber) / sizeof (PreviousNumber[0]));
EditValue = PreviousNumber[Count];
break;
} else {
UpdateStatusBar (INPUT_ERROR, Question->QuestionFlags, FALSE);
UpdateStatusBar (Selection, INPUT_ERROR, Question->QuestionFlags, FALSE);
}
Count++;
@@ -1183,7 +1183,7 @@ TheKey:
GetQuestionValue (Selection->FormSet, Selection->Form, Question, TRUE);
} else {
SetQuestionValue (Selection->FormSet, Selection->Form, Question, TRUE);
UpdateStatusBar (NV_UPDATE_REQUIRED, Question->QuestionFlags, TRUE);
UpdateStatusBar (Selection, NV_UPDATE_REQUIRED, Question->QuestionFlags, TRUE);
}
return Status;