mirror of
https://github.com/reactos/reactos.git
synced 2025-07-24 15:13:36 +00:00
[FREELDR] Remove ShowBootOptions from Menu code
This removes a dependency of UI code to boot options code by getting rid of a call to DisplayBootTimeOptions() from within the menu code. Instead this is now handled by MainBootMenuKeyPressFilter.
This commit is contained in:
parent
9daef292e9
commit
ebcf3f23aa
12 changed files with 4 additions and 28 deletions
|
@ -340,6 +340,7 @@ MainBootMenuKeyPressFilter(
|
|||
{
|
||||
case KEY_F8:
|
||||
DoOptionsMenu(&((OperatingSystemItem*)Context)[SelectedMenuItem]);
|
||||
DisplayBootTimeOptions();
|
||||
return TRUE;
|
||||
|
||||
#ifdef HAS_OPTION_MENU_EDIT_CMDLINE
|
||||
|
@ -433,7 +434,6 @@ VOID RunLoader(VOID)
|
|||
if (!UiDisplayMenu("Please select the operating system to start:",
|
||||
"For troubleshooting and advanced startup options for "
|
||||
"ReactOS, press F8.",
|
||||
TRUE,
|
||||
OperatingSystemDisplayNames,
|
||||
OperatingSystemCount,
|
||||
DefaultOperatingSystem,
|
||||
|
|
|
@ -126,7 +126,6 @@ VOID OptionMenuCustomBoot(VOID)
|
|||
OperatingSystemItem OperatingSystem;
|
||||
|
||||
if (!UiDisplayMenu("Please choose a boot method:", NULL,
|
||||
FALSE,
|
||||
CustomBootMenuList,
|
||||
RTL_NUMBER_OF(CustomBootMenuList),
|
||||
0, -1,
|
||||
|
|
|
@ -211,7 +211,6 @@ typedef struct tagUI_MENU_INFO
|
|||
{
|
||||
PCSTR MenuHeader;
|
||||
PCSTR MenuFooter;
|
||||
BOOLEAN ShowBootOptions;
|
||||
|
||||
PCSTR* MenuItemList;
|
||||
ULONG MenuItemCount;
|
||||
|
@ -236,7 +235,6 @@ BOOLEAN
|
|||
UiDisplayMenu(
|
||||
IN PCSTR MenuHeader,
|
||||
IN PCSTR MenuFooter OPTIONAL,
|
||||
IN BOOLEAN ShowBootOptions,
|
||||
IN PCSTR MenuItemList[],
|
||||
IN ULONG MenuItemCount,
|
||||
IN ULONG DefaultMenuItem,
|
||||
|
@ -293,7 +291,6 @@ typedef struct tagUIVTBL
|
|||
BOOLEAN (*DisplayMenu)(
|
||||
IN PCSTR MenuHeader,
|
||||
IN PCSTR MenuFooter OPTIONAL,
|
||||
IN BOOLEAN ShowBootOptions,
|
||||
IN PCSTR MenuItemList[],
|
||||
IN ULONG MenuItemCount,
|
||||
IN ULONG DefaultMenuItem,
|
||||
|
|
|
@ -93,7 +93,6 @@ BOOLEAN
|
|||
NoUiDisplayMenu(
|
||||
IN PCSTR MenuHeader,
|
||||
IN PCSTR MenuFooter OPTIONAL,
|
||||
IN BOOLEAN ShowBootOptions,
|
||||
IN PCSTR MenuItemList[],
|
||||
IN ULONG MenuItemCount,
|
||||
IN ULONG DefaultMenuItem,
|
||||
|
|
|
@ -149,7 +149,6 @@ BOOLEAN
|
|||
TuiDisplayMenu(
|
||||
IN PCSTR MenuHeader,
|
||||
IN PCSTR MenuFooter OPTIONAL,
|
||||
IN BOOLEAN ShowBootOptions,
|
||||
IN PCSTR MenuItemList[],
|
||||
IN ULONG MenuItemCount,
|
||||
IN ULONG DefaultMenuItem,
|
||||
|
|
|
@ -95,7 +95,6 @@ VOID DoOptionsMenu(IN OperatingSystemItem* OperatingSystem)
|
|||
CHAR DebugChannelString[100];
|
||||
|
||||
if (!UiDisplayMenu("Select an option:", NULL,
|
||||
TRUE,
|
||||
OptionsMenuList,
|
||||
sizeof(OptionsMenuList) / sizeof(OptionsMenuList[0]),
|
||||
11, // Use "Start ReactOS normally" as default; see the switch below.
|
||||
|
|
|
@ -139,7 +139,6 @@ BOOLEAN
|
|||
UiDisplayMenu(
|
||||
IN PCSTR MenuHeader,
|
||||
IN PCSTR MenuFooter OPTIONAL,
|
||||
IN BOOLEAN ShowBootOptions,
|
||||
IN PCSTR MenuItemList[],
|
||||
IN ULONG MenuItemCount,
|
||||
IN ULONG DefaultMenuItem,
|
||||
|
|
|
@ -56,7 +56,7 @@ BOOLEAN MiniTuiInitialize(VOID)
|
|||
VOID MiniTuiDrawBackdrop(VOID)
|
||||
{
|
||||
/* Fill in a black background */
|
||||
TuiFillArea(0, 0, UiScreenWidth - 1, UiScreenHeight - 1,
|
||||
TuiFillArea(0, 0, UiScreenWidth - 1, UiScreenHeight - 3,
|
||||
UiBackdropFillStyle,
|
||||
ATTR(UiBackdropFgColor, UiBackdropBgColor));
|
||||
|
||||
|
@ -225,12 +225,6 @@ MiniTuiDrawMenu(
|
|||
ATTR(UiMenuFgColor, UiMenuBgColor));
|
||||
}
|
||||
|
||||
/* Display the boot options if needed */
|
||||
if (MenuInfo->ShowBootOptions)
|
||||
{
|
||||
DisplayBootTimeOptions();
|
||||
}
|
||||
|
||||
VideoCopyOffScreenBufferToVRAM();
|
||||
}
|
||||
|
||||
|
|
|
@ -163,7 +163,6 @@ BOOLEAN
|
|||
NoUiDisplayMenu(
|
||||
IN PCSTR MenuHeader,
|
||||
IN PCSTR MenuFooter OPTIONAL,
|
||||
IN BOOLEAN ShowBootOptions,
|
||||
IN PCSTR MenuItemList[],
|
||||
IN ULONG MenuItemCount,
|
||||
IN ULONG DefaultMenuItem,
|
||||
|
|
|
@ -275,7 +275,7 @@ VOID TuiDrawBackdrop(VOID)
|
|||
TuiFillArea(0,
|
||||
TUI_TITLE_BOX_CHAR_HEIGHT,
|
||||
UiScreenWidth - 1,
|
||||
UiScreenHeight - 2,
|
||||
UiScreenHeight - 3,
|
||||
UiBackdropFillStyle,
|
||||
ATTR(UiBackdropFgColor, UiBackdropBgColor));
|
||||
|
||||
|
|
|
@ -30,7 +30,6 @@ BOOLEAN
|
|||
TuiDisplayMenu(
|
||||
IN PCSTR MenuHeader,
|
||||
IN PCSTR MenuFooter OPTIONAL,
|
||||
IN BOOLEAN ShowBootOptions,
|
||||
IN PCSTR MenuItemList[],
|
||||
IN ULONG MenuItemCount,
|
||||
IN ULONG DefaultMenuItem,
|
||||
|
@ -80,7 +79,6 @@ TuiDisplayMenu(
|
|||
/* Setup the MENU_INFO structure */
|
||||
MenuInformation.MenuHeader = MenuHeader;
|
||||
MenuInformation.MenuFooter = MenuFooter;
|
||||
MenuInformation.ShowBootOptions = ShowBootOptions;
|
||||
MenuInformation.MenuItemList = MenuItemList;
|
||||
MenuInformation.MenuItemCount = MenuItemCount;
|
||||
MenuInformation.MenuTimeRemaining = MenuTimeOut;
|
||||
|
@ -219,12 +217,6 @@ TuiDrawMenu(
|
|||
/* Update the status bar */
|
||||
UiVtbl.DrawStatusText("Use \x18 and \x19 to select, then press ENTER.");
|
||||
|
||||
/* Display the boot options if needed */
|
||||
if (MenuInfo->ShowBootOptions)
|
||||
{
|
||||
DisplayBootTimeOptions();
|
||||
}
|
||||
|
||||
VideoCopyOffScreenBufferToVRAM();
|
||||
}
|
||||
|
||||
|
|
|
@ -605,7 +605,6 @@ BOOLEAN
|
|||
UiDisplayMenu(
|
||||
IN PCSTR MenuHeader,
|
||||
IN PCSTR MenuFooter OPTIONAL,
|
||||
IN BOOLEAN ShowBootOptions,
|
||||
IN PCSTR MenuItemList[],
|
||||
IN ULONG MenuItemCount,
|
||||
IN ULONG DefaultMenuItem,
|
||||
|
@ -615,7 +614,7 @@ UiDisplayMenu(
|
|||
IN UiMenuKeyPressFilterCallback KeyPressFilter OPTIONAL,
|
||||
IN PVOID Context OPTIONAL)
|
||||
{
|
||||
return UiVtbl.DisplayMenu(MenuHeader, MenuFooter, ShowBootOptions,
|
||||
return UiVtbl.DisplayMenu(MenuHeader, MenuFooter,
|
||||
MenuItemList, MenuItemCount, DefaultMenuItem,
|
||||
MenuTimeOut, SelectedMenuItem, CanEscape,
|
||||
KeyPressFilter, Context);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue