Changeset 625 in xtideuniversalbios for trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages
- Timestamp:
- Feb 19, 2023, 9:26:52 PM (21 months ago)
- Location:
- trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/BootMenuSettingsMenu.asm
r621 r625 4 4 ; 5 5 ; XTIDE Universal BIOS and Associated Tools 6 ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-20 13 by XTIDE Universal BIOS Team.6 ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-2023 by XTIDE Universal BIOS Team. 7 7 ; 8 8 ; This program is free software; you can redistribute it and/or modify … … 185 185 186 186 ColorThemeTable: 187 ; Note! If there's ever a need to remove a theme or change a theme or reorder the themes then the ROMVARS version must be incremented. 188 ; This is for backwards compatibility. Adding new themes (at the bottom) however should work with no change to the ROMVARS version. 187 ; Note! If there's ever a need to add, remove or change a theme or reorder the themes then the ROMVARS version must be incremented. 189 188 ; Classic (default) 190 189 db COLOR_ATTRIBUTE(COLOR_YELLOW, COLOR_BLUE) ; .cBordersAndBackground … … 396 395 loopne .NextTheme 397 396 cld 398 mov ax, cx 397 mov ax, cx ; Return the color theme index in AX; zero (default theme) if a theme was not found 399 398 jne SHORT .SkipCopy 400 399 -
trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/ConfigurationMenu.asm
r592 r625 4 4 ; 5 5 ; XTIDE Universal BIOS and Associated Tools 6 ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-20 13 by XTIDE Universal BIOS Team.6 ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-2023 by XTIDE Universal BIOS Team. 7 7 ; 8 8 ; This program is free software; you can redistribute it and/or modify … … 26 26 at MENUPAGE.fnEnter, dw ConfigurationMenu_EnterMenuOrModifyItemVisibility 27 27 at MENUPAGE.fnBack, dw MainMenu_EnterMenuOrModifyItemVisibility 28 at MENUPAGE.wMenuitems, dw 1 128 at MENUPAGE.wMenuitems, dw 12 29 29 iend 30 30 … … 113 113 at MENUITEM.itemValue + ITEM_VALUE.rgszValueToStringLookup, dw g_rgszValueToStringLookupForFlagBooleans 114 114 at MENUITEM.itemValue + ITEM_VALUE.wValueBitmask, dw FLG_ROMVARS_FULLMODE 115 at MENUITEM.itemValue + ITEM_VALUE.fnValueWriter, dw WriteFullOperatingMode 116 iend 117 118 g_MenuitemConfigurationRamVars: 119 istruc MENUITEM 120 at MENUITEM.fnActivate, dw Menuitem_ActivateHexInputForMenuitemInDSSI 121 at MENUITEM.fnFormatValue, dw MenuitemPrint_WriteHexValueStringToBufferInESDIfromItemInDSSI 122 at MENUITEM.szName, dw g_szItemCfgRamVars 123 at MENUITEM.szQuickInfo, dw g_szNfoCfgRamVars 124 at MENUITEM.szHelp, dw g_szHelpCfgRamVars 125 at MENUITEM.bFlags, db FLG_MENUITEM_MODIFY_MENU 126 at MENUITEM.bType, db TYPE_MENUITEM_HEX 127 at MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset, dw ROMVARS.wRamVars 128 at MENUITEM.itemValue + ITEM_VALUE.szDialogTitle, dw g_szDlgCfgRamVars 129 at MENUITEM.itemValue + ITEM_VALUE.wMinValue, dw 0A000h 130 at MENUITEM.itemValue + ITEM_VALUE.wMaxValue, dw 0FFFFh ; Disables use of UMB 131 at MENUITEM.itemValue + ITEM_VALUE.fnValueReader, dw ReadRamVars 132 at MENUITEM.itemValue + ITEM_VALUE.fnValueWriter, dw WriteRamVars 115 133 iend 116 134 … … 122 140 at MENUITEM.szQuickInfo, dw g_szNfoCfgStealSize 123 141 at MENUITEM.szHelp, dw g_szHelpCfgStealSize 124 at MENUITEM.bFlags, db FLG_MENUITEM_ VISIBLE | FLG_MENUITEM_BYTEVALUE142 at MENUITEM.bFlags, db FLG_MENUITEM_BYTEVALUE 125 143 at MENUITEM.bType, db TYPE_MENUITEM_UNSIGNED 126 144 at MENUITEM.itemValue + ITEM_VALUE.wRomvarsValueOffset, dw ROMVARS.bStealSize … … 199 217 call .EnableIdeControllerMenuitemsBasedOnConfiguration 200 218 call .EnableOrDisableOperatingModeSelection 219 call Buffers_GetRomvarsFlagsToAX 220 call .EnableOrDisableRamVarsSegmentSelection 201 221 call .EnableOrDisableKiBtoStealFromRAM 202 222 call .EnableOrDisableIdleTimeout … … 251 271 mov bx, g_MenuitemConfigurationFullOperatingMode 252 272 call Buffers_IsXTbuildLoaded 253 j eSHORT .EnableMenuitemFromCSBX273 jz SHORT .EnableMenuitemFromCSBX 254 274 jmp SHORT .DisableMenuitemFromCSBX 255 275 256 276 257 277 ;-------------------------------------------------------------------- 258 ; .EnableOrDisable KiBtoStealFromRAM259 ; Parameters: 260 ; SS:BP: Menu handle261 ; Returns:262 ; Nothing263 ; Corrupts registers:264 ; AX, BX265 ; --------------------------------------------------------------------266 ALIGN JUMP_ALIGN 267 .EnableOrDisableKiBtoStealFromRAM: 268 call Buffers_GetRomvarsFlagsToAX 269 mov bx, g_MenuitemConfiguration KiBtoStealFromRAM278 ; .EnableOrDisableRamVarsSegmentSelection 279 ; Parameters: 280 ; AX: ROMVARS.wFlags 281 ; SS:BP: Menu handle 282 ; Returns: 283 ; Nothing 284 ; Corrupts registers: 285 ; BX 286 ;-------------------------------------------------------------------- 287 ALIGN JUMP_ALIGN 288 .EnableOrDisableRamVarsSegmentSelection: 289 mov bx, g_MenuitemConfigurationRamVars 270 290 test al, FLG_ROMVARS_FULLMODE 271 291 jz SHORT .DisableMenuitemFromCSBX … … 274 294 275 295 ;-------------------------------------------------------------------- 296 ; .EnableOrDisableKiBtoStealFromRAM 297 ; Parameters: 298 ; SS:BP: Menu handle 299 ; Returns: 300 ; Nothing 301 ; Corrupts registers: 302 ; BX 303 ;-------------------------------------------------------------------- 304 ALIGN JUMP_ALIGN 305 .EnableOrDisableKiBtoStealFromRAM: 306 mov bx, g_MenuitemConfigurationKiBtoStealFromRAM 307 cmp WORD [es:ROMVARS.wRamVars], 0 308 jne SHORT .DisableMenuitemFromCSBX 309 jmp SHORT .EnableMenuitemFromCSBX 310 311 312 ;-------------------------------------------------------------------- 276 313 ; .EnableOrDisableIdleTimeout 277 314 ; Parameters: 278 ; SS:BP: Menu handle 279 ; Returns: 280 ; Nothing 281 ; Corrupts registers: 282 ; AX, BX 315 ; AX: ROMVARS.wFlags 316 ; SS:BP: Menu handle 317 ; Returns: 318 ; Nothing 319 ; Corrupts registers: 320 ; BX 283 321 ;-------------------------------------------------------------------- 284 322 ALIGN JUMP_ALIGN 285 323 .EnableOrDisableIdleTimeout: 286 call Buffers_GetRomvarsFlagsToAX287 324 mov bx, g_MenuitemConfigurationIdleTimeout 288 325 test al, FLG_ROMVARS_MODULE_POWER_MANAGEMENT … … 308 345 .DisableMenuitemFromCSBX: 309 346 jmp DisableMenuitemFromCSBX 347 348 349 ;-------------------------------------------------------------------- 350 ; WriteFullOperatingMode 351 ; Parameters: 352 ; AX: Value that the MENUITEM system was interacting with 353 ; ES:DI: ROMVARS location where the value is to be stored 354 ; DS:SI: MENUITEM pointer 355 ; Returns: 356 ; AX: Value to actually write to ROMVARS 357 ; Corrupts registers: 358 ; BX 359 ;-------------------------------------------------------------------- 360 ALIGN JUMP_ALIGN 361 WriteFullOperatingMode: 362 test ax, ax ; FOM disabled? 363 mov bx, LITE_MODE_RAMVARS_SEGMENT 364 jz SHORT .WriteDefaultValueToRamVars ; Yes, Lite mode it is 365 xor bx, bx ; No, use Conventional memory 366 .WriteDefaultValueToRamVars: 367 mov [es:ROMVARS.wRamVars], bx 368 ret 369 370 371 ;-------------------------------------------------------------------- 372 ; ReadRamVars 373 ; Parameters: 374 ; AX: Value read from the ROMVARS location 375 ; ES:DI: ROMVARS location where the value was just read from 376 ; DS:SI: MENUITEM pointer 377 ; Returns: 378 ; AX: Value that the MENUITEM system will interact with and display 379 ; Corrupts registers: 380 ; Nothing 381 ;-------------------------------------------------------------------- 382 ALIGN JUMP_ALIGN 383 ReadRamVars: 384 test ax, ax 385 jz SHORT .PrintNoInsteadOfValue 386 cmp ax, LITE_MODE_RAMVARS_SEGMENT 387 jne SHORT WriteRamVars.Return 388 389 .PrintNoInsteadOfValue: 390 push si 391 mov si, g_szNo 392 CALL_DISPLAY_LIBRARY PrintNullTerminatedStringFromCSSI 393 pop si 394 ; This is a humongous hack. The menu system should not be (ab)used like this. 395 pop ax ; Return from ReadRamVars to Menuitem_GetValueToAXfromMenuitemInDSSI 396 pop bx ; Restore registers 397 pop di 398 pop es 399 pop ax ; Return from Menuitem_GetValueToAXfromMenuitemInDSSI to MenuitemPrint_WriteHexValueStringToBufferInESDIfromItemInDSSI 400 jmp MenuitemPrint_FinishPrintingUnsignedOrHexValue 401 402 403 ;-------------------------------------------------------------------- 404 ; WriteRamVars 405 ; Parameters: 406 ; AX: Value that the MENUITEM system was interacting with 407 ; ES:DI: ROMVARS location where the value is to be stored 408 ; DS:SI: MENUITEM pointer 409 ; Returns: 410 ; AX: Value to actually write to ROMVARS 411 ; Corrupts registers: 412 ; Nothing 413 ;-------------------------------------------------------------------- 414 ALIGN JUMP_ALIGN 415 WriteRamVars: 416 inc ax ; FFFF -> 0000 = Disable UMB usage 417 jz SHORT .Return 418 dec ax 419 .Return: 420 ret 310 421 311 422 -
trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/IdeControllerMenu.asm
r621 r625 4 4 ; 5 5 ; XTIDE Universal BIOS and Associated Tools 6 ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-20 13 by XTIDE Universal BIOS Team.6 ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-2023 by XTIDE Universal BIOS Team. 7 7 ; 8 8 ; This program is free software; you can redistribute it and/or modify … … 229 229 dw 'B' 230 230 dw 'C' 231 dw 'x' ; must be last entry (see reader/write routines)231 dw 'x' ; must be last entry (see reader/writer routines) 232 232 g_rgszChoiceToStringLookupForCOM: 233 233 dw g_szValueCfgCOM1 -
trunk/XTIDE_Universal_BIOS_Configurator_v2/Src/Menupages/MainMenu.asm
r621 r625 4 4 ; 5 5 ; XTIDE Universal BIOS and Associated Tools 6 ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-20 13 by XTIDE Universal BIOS Team.6 ; Copyright (C) 2009-2010 by Tomi Tilli, 2011-2023 by XTIDE Universal BIOS Team. 7 7 ; 8 8 ; This program is free software; you can redistribute it and/or modify … … 292 292 add di, ROMVARS.pColorTheme 293 293 call WriteColorTheme 294 ; We did not copy over wFlags but we did copy over wRamVars so we 295 ; must ensure that the Full Operating Mode setting matches wRamVars. 296 cmp WORD [es:ROMVARS.wRamVars], LITE_MODE_RAMVARS_SEGMENT 297 jne SHORT .SetFullOperatingMode ; All builds supports FOM 298 call Buffers_IsXTbuildLoaded 299 jz SHORT .ClearFullOperatingMode 300 ; The loaded file is an AT build and we just copied the settings from 301 ; an XT build in ROM configured for Lite mode. Resolve the conflict 302 ; by clearing wRamVars thereby setting it to the default for FOM. 303 mov WORD [es:ROMVARS.wRamVars], 0 304 ; Tell the user there was a change in the configuration 305 mov dx, g_szDlgFomEnabled 306 call Dialogs_DisplayNotificationFromCSDX 307 ; We don't need to set the FOM flag but fall through anyway 308 .SetFullOperatingMode: 309 or BYTE [es:ROMVARS.wFlags], FLG_ROMVARS_FULLMODE 310 jmp SHORT .Done 311 312 .ClearFullOperatingMode: 313 and BYTE [es:ROMVARS.wFlags], ~FLG_ROMVARS_FULLMODE 314 315 .Done: 294 316 .FileNotLoaded: 295 317 jmp MainMenu_EnterMenuOrModifyItemVisibility
Note:
See TracChangeset
for help on using the changeset viewer.