Index: /trunk/XTIDE_Universal_BIOS_Configurator_v2/Inc/Variables.inc
===================================================================
--- /trunk/XTIDE_Universal_BIOS_Configurator_v2/Inc/Variables.inc	(revision 289)
+++ /trunk/XTIDE_Universal_BIOS_Configurator_v2/Inc/Variables.inc	(revision 290)
@@ -5,4 +5,5 @@
 
 ; Equates and defines
+BOOT_MENU_DEFAULT_TIMEOUT			EQU	(30 * TICKS_PER_SECOND)
 MAX_ALLOWED_IDE_CONTROLLERS			EQU		4	; Maximum number of IDE controllers
 MAX_LITE_MODE_CONTROLLERS			EQU		2
Index: /trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/BootMenuSettingsMenu.asm
===================================================================
--- /trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/BootMenuSettingsMenu.asm	(revision 289)
+++ /trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/BootMenuSettingsMenu.asm	(revision 290)
@@ -10,5 +10,5 @@
 	at	MENUPAGE.fnEnter,			dw	BootMenuSettingsMenu_EnterMenuOrModifyItemVisibility
 	at	MENUPAGE.fnBack,			dw	ConfigurationMenu_EnterMenuOrModifyItemVisibility
-	at	MENUPAGE.wMenuitems,		dw	7
+	at	MENUPAGE.wMenuitems,		dw	8
 iend
 
@@ -23,4 +23,69 @@
 iend
 
+g_MenuitemBootMnuStngsDisplayMode:
+istruc MENUITEM
+	at	MENUITEM.fnActivate,		dw	Menuitem_ActivateMultichoiceSelectionForMenuitemInDSSI
+	at	MENUITEM.fnFormatValue,		dw	MenuitemPrint_WriteLookupValueStringToBufferInESDIfromUnshiftedItemInDSSI
+	at	MENUITEM.szName,			dw	g_szItemBootDispMode
+	at	MENUITEM.szQuickInfo,		dw	g_szNfoDispMode
+	at	MENUITEM.szHelp,			dw	g_szNfoDispMode
+	at	MENUITEM.bFlags,			db	FLG_MENUITEM_VISIBLE
+	at	MENUITEM.bType,				db	TYPE_MENUITEM_MULTICHOICE
+	at	MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset,		dw	ROMVARS.wDisplayMode
+	at	MENUITEM.itemValue + ITEM_VALUE.szDialogTitle,				dw	g_szDlgBootDispMode
+	at	MENUITEM.itemValue + ITEM_VALUE.szMultichoice,				dw	g_szMultichoiceBootDispMode
+	at	MENUITEM.itemValue + ITEM_VALUE.rgwChoiceToValueLookup,		dw	g_rgwChoiceToValueLookupForDisplayModes
+	at	MENUITEM.itemValue + ITEM_VALUE.rgszValueToStringLookup,	dw	g_rgszValueToStringLookupForDisplayModes
+iend
+
+g_MenuitemBootMnuStngsFloppyDrives:
+istruc MENUITEM
+	at	MENUITEM.fnActivate,		dw	Menuitem_ActivateMultichoiceSelectionForMenuitemInDSSI
+	at	MENUITEM.fnFormatValue,		dw	MenuitemPrint_WriteLookupValueStringToBufferInESDIfromUnshiftedItemInDSSI
+	at	MENUITEM.szName,			dw	g_szItemBootFloppyDrvs
+	at	MENUITEM.szQuickInfo,		dw	g_szNfoBootFloppyDrvs
+	at	MENUITEM.szHelp,			dw	g_szHelpBootFloppyDrvs
+	at	MENUITEM.bFlags,			db	FLG_MENUITEM_VISIBLE | FLG_MENUITEM_BYTEVALUE
+	at	MENUITEM.bType,				db	TYPE_MENUITEM_MULTICHOICE
+	at	MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset,		dw	ROMVARS.bMinFddCnt
+	at	MENUITEM.itemValue + ITEM_VALUE.szDialogTitle,				dw	g_szDlgBootFloppyDrvs
+	at	MENUITEM.itemValue + ITEM_VALUE.szMultichoice,				dw	g_szMultichoiceBootFloppyDrvs
+	at	MENUITEM.itemValue + ITEM_VALUE.rgwChoiceToValueLookup,		dw	NULL
+	at	MENUITEM.itemValue + ITEM_VALUE.rgszValueToStringLookup,	dw	g_rgszValueToStringLookupForFloppyDrives
+iend
+
+g_MenuitemBootMenuSerialScanDetect:		
+istruc MENUITEM
+	at	MENUITEM.fnActivate,		dw	Menuitem_ActivateMultichoiceSelectionForMenuitemInDSSI
+	at	MENUITEM.fnFormatValue,		dw	MenuitemPrint_WriteLookupValueStringToBufferInESDIfromShiftedItemInDSSI
+	at	MENUITEM.szName,			dw	g_szItemSerialDetect
+	at	MENUITEM.szQuickInfo,		dw	g_szNfoSerialDetect
+	at	MENUITEM.szHelp,			dw	g_szHelpSerialDetect
+	at	MENUITEM.bFlags,			db	FLG_MENUITEM_VISIBLE | FLG_MENUITEM_FLAGVALUE
+	at	MENUITEM.bType,				db	TYPE_MENUITEM_MULTICHOICE
+	at	MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset,		dw	ROMVARS.wFlags
+	at	MENUITEM.itemValue + ITEM_VALUE.szDialogTitle,				dw	g_szDlgSerialDetect
+	at	MENUITEM.itemValue + ITEM_VALUE.szMultichoice,				dw	g_szMultichoiceBooleanFlag
+	at	MENUITEM.itemValue + ITEM_VALUE.rgszValueToStringLookup,	dw	g_rgszValueToStringLookupForFlagBooleans
+	at	MENUITEM.itemValue + ITEM_VALUE.wValueBitmask,				dw	FLG_ROMVARS_SERIAL_SCANDETECT
+iend
+
+g_MenuitemBootMnuStngsEnableBootMenu:
+istruc MENUITEM
+	at	MENUITEM.fnActivate,		dw	Menuitem_ActivateMultichoiceSelectionForMenuitemInDSSI
+	at	MENUITEM.fnFormatValue,		dw	MenuitemPrint_WriteLookupValueStringToBufferInESDIfromShiftedItemInDSSI
+	at	MENUITEM.szName,			dw	g_szItemBootEnableMenu
+	at	MENUITEM.szQuickInfo,		dw	g_szNfoBootEnableMenu
+	at	MENUITEM.szHelp,			dw	g_szNfoBootEnableMenu
+	at	MENUITEM.bFlags,			db	FLG_MENUITEM_VISIBLE | FLG_MENUITEM_MODIFY_MENU
+	at	MENUITEM.bType,				db	TYPE_MENUITEM_MULTICHOICE
+	at	MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset,		dw	ROMVARS.wfDisplayBootMenu
+	at	MENUITEM.itemValue + ITEM_VALUE.szDialogTitle,				dw	g_szDlgBootEnableMenu
+	at	MENUITEM.itemValue + ITEM_VALUE.szMultichoice,				dw	g_szMultichoiceBooleanFlag
+	at	MENUITEM.itemValue + ITEM_VALUE.rgwChoiceToValueLookup,		dw	g_rgwChoiceToValueLookupForEnableBootMenu
+	at	MENUITEM.itemValue + ITEM_VALUE.rgszValueToStringLookup,	dw	g_rgszValueToStringLookupForFlagBooleans
+	at	MENUITEM.itemValue + ITEM_VALUE.fnValueReader,				dw	ValueReaderForEnableBootMenu
+iend
+
 g_MenuitemBootMnuStngsDefaultBootDrive:
 istruc MENUITEM
@@ -30,5 +95,5 @@
 	at	MENUITEM.szQuickInfo,		dw	g_szNfoBootDrive
 	at	MENUITEM.szHelp,			dw	g_szHelpBootDrive
-	at	MENUITEM.bFlags,			db	FLG_MENUITEM_VISIBLE | FLG_MENUITEM_BYTEVALUE
+	at	MENUITEM.bFlags,			db	FLG_MENUITEM_BYTEVALUE
 	at	MENUITEM.bType,				db	TYPE_MENUITEM_HEX
 	at	MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset,		dw	ROMVARS.bBootDrv
@@ -38,36 +103,4 @@
 iend
 
-g_MenuitemBootMnuStngsDisplayMode:
-istruc MENUITEM
-	at	MENUITEM.fnActivate,		dw	Menuitem_ActivateMultichoiceSelectionForMenuitemInDSSI
-	at	MENUITEM.fnFormatValue,		dw	MenuitemPrint_WriteLookupValueStringToBufferInESDIfromUnshiftedItemInDSSI
-	at	MENUITEM.szName,			dw	g_szItemBootDispMode
-	at	MENUITEM.szQuickInfo,		dw	g_szNfoDispMode
-	at	MENUITEM.szHelp,			dw	g_szNfoDispMode
-	at	MENUITEM.bFlags,			db	FLG_MENUITEM_VISIBLE
-	at	MENUITEM.bType,				db	TYPE_MENUITEM_MULTICHOICE
-	at	MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset,		dw	ROMVARS.wDisplayMode
-	at	MENUITEM.itemValue + ITEM_VALUE.szDialogTitle,				dw	g_szDlgBootDispMode
-	at	MENUITEM.itemValue + ITEM_VALUE.szMultichoice,				dw	g_szMultichoiceBootDispMode
-	at	MENUITEM.itemValue + ITEM_VALUE.rgwChoiceToValueLookup,		dw	g_rgwChoiceToValueLookupForDisplayModes
-	at	MENUITEM.itemValue + ITEM_VALUE.rgszValueToStringLookup,	dw	g_rgszValueToStringLookupForDisplayModes
-iend
-
-g_MenuitemBootMnuStngsFloppyDrives:
-istruc MENUITEM
-	at	MENUITEM.fnActivate,		dw	Menuitem_ActivateMultichoiceSelectionForMenuitemInDSSI
-	at	MENUITEM.fnFormatValue,		dw	MenuitemPrint_WriteLookupValueStringToBufferInESDIfromUnshiftedItemInDSSI
-	at	MENUITEM.szName,			dw	g_szItemBootFloppyDrvs
-	at	MENUITEM.szQuickInfo,		dw	g_szNfoBootFloppyDrvs
-	at	MENUITEM.szHelp,			dw	g_szHelpBootFloppyDrvs
-	at	MENUITEM.bFlags,			db	FLG_MENUITEM_VISIBLE | FLG_MENUITEM_BYTEVALUE
-	at	MENUITEM.bType,				db	TYPE_MENUITEM_MULTICHOICE
-	at	MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset,		dw	ROMVARS.bMinFddCnt
-	at	MENUITEM.itemValue + ITEM_VALUE.szDialogTitle,				dw	g_szDlgBootFloppyDrvs
-	at	MENUITEM.itemValue + ITEM_VALUE.szMultichoice,				dw	g_szMultichoiceBootFloppyDrvs
-	at	MENUITEM.itemValue + ITEM_VALUE.rgwChoiceToValueLookup,		dw	NULL
-	at	MENUITEM.itemValue + ITEM_VALUE.rgszValueToStringLookup,	dw	g_rgszValueToStringLookupForFloppyDrives
-iend
-
 g_MenuitemBootMnuStngsSelectionTimeout:
 istruc MENUITEM
@@ -77,9 +110,9 @@
 	at	MENUITEM.szQuickInfo,		dw	g_szNfoBootTimeout
 	at	MENUITEM.szHelp,			dw	g_szHelpBootTimeout
-	at	MENUITEM.bFlags,			db	FLG_MENUITEM_VISIBLE
+	at	MENUITEM.bFlags,			db	NULL
 	at	MENUITEM.bType,				db	TYPE_MENUITEM_UNSIGNED
 	at	MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset,		dw	ROMVARS.wBootTimeout
 	at	MENUITEM.itemValue + ITEM_VALUE.szDialogTitle,				dw	g_szDlgBootTimeout
-	at	MENUITEM.itemValue + ITEM_VALUE.wMinValue,					dw	0
+	at	MENUITEM.itemValue + ITEM_VALUE.wMinValue,					dw	2
 	at	MENUITEM.itemValue + ITEM_VALUE.wMaxValue,					dw	1092
 iend
@@ -92,5 +125,5 @@
 	at	MENUITEM.szQuickInfo,		dw	g_szNfoBootSwap
 	at	MENUITEM.szHelp,			dw	g_szHelpBootSwap
-	at	MENUITEM.bFlags,			db	FLG_MENUITEM_VISIBLE | FLG_MENUITEM_FLAGVALUE
+	at	MENUITEM.bFlags,			db	FLG_MENUITEM_FLAGVALUE
 	at	MENUITEM.bType,				db	TYPE_MENUITEM_MULTICHOICE
 	at	MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset,		dw	ROMVARS.wFlags
@@ -101,19 +134,8 @@
 iend
 
-g_MenuitemBootMenuSerialScanDetect:		
-istruc MENUITEM
-	at	MENUITEM.fnActivate,		dw	Menuitem_ActivateMultichoiceSelectionForMenuitemInDSSI
-	at	MENUITEM.fnFormatValue,		dw	MenuitemPrint_WriteLookupValueStringToBufferInESDIfromShiftedItemInDSSI
-	at	MENUITEM.szName,			dw	g_szItemSerialDetect
-	at	MENUITEM.szQuickInfo,		dw	g_szNfoSerialDetect
-	at	MENUITEM.szHelp,			dw	g_szHelpSerialDetect
-	at	MENUITEM.bFlags,			db	FLG_MENUITEM_VISIBLE | FLG_MENUITEM_FLAGVALUE
-	at	MENUITEM.bType,				db	TYPE_MENUITEM_MULTICHOICE
-	at	MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset,		dw	ROMVARS.wFlags
-	at	MENUITEM.itemValue + ITEM_VALUE.szDialogTitle,				dw	g_szDlgSerialDetect
-	at	MENUITEM.itemValue + ITEM_VALUE.szMultichoice,				dw	g_szMultichoiceBooleanFlag
-	at	MENUITEM.itemValue + ITEM_VALUE.rgszValueToStringLookup,	dw	g_rgszValueToStringLookupForFlagBooleans
-	at	MENUITEM.itemValue + ITEM_VALUE.wValueBitmask,				dw	FLG_ROMVARS_SERIAL_SCANDETECT
-iend		
+
+g_rgwChoiceToValueLookupForEnableBootMenu:
+	dw	FALSE
+	dw	BOOT_MENU_DEFAULT_TIMEOUT
 
 g_rgwChoiceToValueLookupForDisplayModes:
@@ -158,4 +180,56 @@
 	push	cs
 	pop		ds
+	call	EnableOrDisableBootMenuSettings
 	mov		si, g_MenupageForBootMenuSettingsMenu
 	jmp		Menupage_ChangeToNewMenupageInDSSI
+
+
+;--------------------------------------------------------------------
+; EnableOrDisableBootMenuSettings
+;	Parameters:
+;		SS:BP:	Menu handle
+;	Returns:
+;		Nothing
+;	Corrupts registers:
+;		AX, BX
+;--------------------------------------------------------------------
+ALIGN JUMP_ALIGN
+EnableOrDisableBootMenuSettings:
+	mov		bx, [cs:g_MenuitemBootMnuStngsEnableBootMenu+MENUITEM.itemValue+ITEM_VALUE.wRomvarsValueOffset]
+	call	Buffers_GetRomvarsValueToAXfromOffsetInBX
+	test	ax, ax
+	mov		al, FLG_MENUITEM_VISIBLE
+	jz		SHORT .DisableBootMenuSettings
+
+	; Enable boot menu related
+	or		[g_MenuitemBootMnuStngsDefaultBootDrive+MENUITEM.bFlags], al
+	or		[g_MenuitemBootMnuStngsSelectionTimeout+MENUITEM.bFlags], al
+	or		[g_MenuitemBootMnuStngsSwapBootDriveNumbers+MENUITEM.bFlags], al
+	ret
+
+.DisableBootMenuSettings:
+	not		ax
+	and		[g_MenuitemBootMnuStngsDefaultBootDrive+MENUITEM.bFlags], al
+	and		[g_MenuitemBootMnuStngsSelectionTimeout+MENUITEM.bFlags], al
+	and		[g_MenuitemBootMnuStngsSwapBootDriveNumbers+MENUITEM.bFlags], al
+	ret	
+
+
+;--------------------------------------------------------------------
+; MENUITEM value reader functions
+;	Parameters:
+;		AX:		Value from MENUITEM.itemValue+ITEM_VALUE.wRomvarsValueOffset
+;		DS:SI:	Ptr to MENUITEM
+;		ES:DI:	Ptr to value variable
+;	Returns:
+;		AX:		Value with possible modifications
+;	Corrupts registers:
+;		Nothing
+;--------------------------------------------------------------------
+ALIGN JUMP_ALIGN
+ValueReaderForEnableBootMenu:
+	test	ax, ax
+	jz		SHORT .NoNeedToModify
+	mov		ax, TRUE<<1
+.NoNeedToModify:
+	ret
Index: /trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Strings.asm
===================================================================
--- /trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Strings.asm	(revision 289)
+++ /trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Strings.asm	(revision 290)
@@ -82,5 +82,5 @@
 g_szItemCfgIde3:		db	"Tertiary IDE Controller",NULL
 g_szItemCfgIde4:		db	"Quaternary IDE Controller",NULL
-g_szItemCfgBootMenu:	db	"Boot menu settings",NULL
+g_szItemCfgBootMenu:	db	"Boot settings",NULL
 g_szItemCfgFullMode:	db	"Full operating mode",NULL
 g_szItemCfgStealSize:	db	"kiB to steal from RAM",NULL
@@ -92,5 +92,5 @@
 
 g_szNfoCfgIde:			db	"IDE controller and drive configuration.",NULL
-g_szNfoCfgBootMenu:		db	"Boot menu configuration.",NULL
+g_szNfoCfgBootMenu:		db	"Boot configuration.",NULL
 g_szNfoCfgFullMode:		db	"Full mode supports multiple controllers and has more features.",NULL
 g_szNfoCfgStealSize:	db	"How many kiB's to steal from Conventional memory for XTIDE Universal BIOS variables.",NULL
@@ -266,5 +266,6 @@
 
 
-; Strings for boot menu settings menu
+; Strings for boot settings menu
+g_szItemBootEnableMenu:	db	"Boot Menu",NULL
 g_szItemBootTimeout:	db	"Selection timeout",NULL
 g_szItemBootDrive:		db	"Default boot drive",NULL
@@ -274,5 +275,6 @@
 g_szItemSerialDetect:	db	"Scan for Serial Drives",NULL
 
-g_szDlgBootTimeout:		db	"Enter Boot Menu selection timeout in BIOS timer ticks (1...1092, 0 disables timeout).",NULL
+g_szDlgBootEnableMenu:	db	"Enable Boot Menu?",NULL
+g_szDlgBootTimeout:		db	"Enter Boot Menu selection timeout in BIOS timer ticks (2...1092).",NULL
 g_szDlgBootDrive:		db	"Enter default drive number (0xh for Floppy Drives, 8xh for Hard Disks, FFh for ROM boot).",NULL
 g_szDlgBootDispMode:	db	"Select display mode for Boot Menu.",NULL
@@ -281,5 +283,6 @@
 g_szDlgSerialDetect:	db	"Scan for serial drives?",NULL
 
-g_szNfoBootTimeout:		db	"Menu item selection timeout in BIOS timer ticks.",NULL
+g_szNfoBootEnableMenu:	db	"Enable to display boot drive selection menu.",NULL
+g_szNfoBootTimeout:		db	"Menu item selection timeout in BIOS timer ticks. 1 tick = 54.9 ms.",NULL
 g_szNfoBootDrive:		db	"Default drive on boot menu.",NULL
 g_szNfoDispMode:		db	"Display Mode for Boot Menu.",NULL
