Boot screen: correct default values; added some remarks

git-svn-id: svn://kolibrios.org@726 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Evgeny Grechnikov (Diamond)
2008-02-10 11:48:23 +00:00
parent ee2c4f4c94
commit 26580c8bd1
5 changed files with 89 additions and 10 deletions

View File

@@ -367,13 +367,29 @@ cfgmanager:
mov [.bSettingsChanged], 0 mov [.bSettingsChanged], 0
;.preboot_gr_end: ;.preboot_gr_end:
mov di, preboot_device
; if image in memory is present and [preboot_device] is uninitialized,
; set it to use this preloaded image
cmp byte [di], 0
jnz .preboot_device_inited
cmp [.loader_block], -1
jz @f
les bx, [.loader_block]
test byte [es:bx+1], 1
jz @f
mov byte [di], 3
jmp .preboot_device_inited
@@:
; otherwise, set [preboot_device] to 1 (default value - boot from floppy)
mov byte [di], 1
.preboot_device_inited:
; following 6 lines set variables to 1 if its current value is 0 ; following 6 lines set variables to 1 if its current value is 0
cmp byte[preboot_dma], 1 cmp byte [di+preboot_dma-preboot_device], 1
adc byte[preboot_dma], 0 adc byte [di+preboot_dma-preboot_device], 0
cmp byte[preboot_vrrm], 1 cmp byte [di+preboot_biosdisk-preboot_device], 1
adc byte[preboot_vrrm], 0 adc byte [di+preboot_biosdisk-preboot_device], 0
cmp byte[preboot_device], 1 cmp byte [di+preboot_vrrm-preboot_device], 1
adc byte[preboot_device], 0 adc byte [di+preboot_vrrm-preboot_device], 0
; notify user ; notify user
_setcursor 5,2 _setcursor 5,2
@@ -409,6 +425,30 @@ cfgmanager:
and eax, 7 and eax, 7
mov si, [preboot_device_msgs+eax*2] mov si, [preboot_device_msgs+eax*2]
call printplain call printplain
.show_remarks:
; show remarks in gray color
mov di, ((21-num_remarks)*80 + 2)*2
push 0xB800
pop es
mov cx, num_remarks
mov si, remarks
.write_remarks:
lodsw
push si
xchg ax, si
mov ah, 1*16+7 ; background: blue (1), foreground: gray (7)
push di
.write_remark:
lodsb
test al, al
jz @f
stosw
jmp .write_remark
@@:
pop di
pop si
add di, 80*2
loop .write_remarks
.wait: .wait:
_setcursor 25,0 ; out of screen _setcursor 25,0 ; out of screen
; set timer interrupt handler ; set timer interrupt handler
@@ -437,6 +477,21 @@ cfgmanager:
_setcursor 7,0 _setcursor 7,0
mov si, space_msg mov si, space_msg
call printplain call printplain
; clear remarks and restore normal attributes
push es
mov di, ((21-num_remarks)*80 + 2)*2
push 0xB800
pop es
mov cx, num_remarks
mov ax, ' ' + (1*16 + 15)*100h
@@:
push cx
mov cx, 76
rep stosw
pop cx
add di, 4*2
loop @b
pop es
pop ax pop ax
; switch on key ; switch on key
cmp al, 13 cmp al, 13
@@ -449,7 +504,7 @@ cfgmanager:
cmp al, 'c' cmp al, 'c'
jz .change_c jz .change_c
cmp al, 'd' cmp al, 'd'
jnz .wait jnz .show_remarks
_setcursor 15,0 _setcursor 15,0
mov si, bdev mov si, bdev
call print call print

View File

@@ -95,3 +95,9 @@ _r1 db 186,'
_r2 db 186,' <20> 640x480 VGA 16 colors <20>۳',13,10,0 _r2 db 186,' <20> 640x480 VGA 16 colors <20>۳',13,10,0
_rs db 186,' <20> ????x????@?? SVGA VESA <20>۳',13,10,0 _rs db 186,' <20> ????x????@?? SVGA VESA <20>۳',13,10,0
_bt db 186,' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',13,10,0 _bt db 186,' <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>',13,10,0
remark1 db "Default values were selected to match most of configurations, but not all.",0
remark2 db "If you have LCD-monitor, disable VRR in the item [c] - you do not need it.",0
remark3 db "If the system does not boot, try to disable the item [b].",0
remarks dw remark1, remark2, remark3
num_remarks = 3

View File

@@ -100,3 +100,9 @@ pdm4 db "loo t
loading_msg db "Laadin KolibriOS...",0 loading_msg db "Laadin KolibriOS...",0
save_quest db "J<EFBFBD>ta meelde praegused seaded? [y/n]: ",0 save_quest db "J<EFBFBD>ta meelde praegused seaded? [y/n]: ",0
loader_block_error db "Alglaaduri andmed vigased, ei saa j<>tkata. Peatatud.",0 loader_block_error db "Alglaaduri andmed vigased, ei saa j<>tkata. Peatatud.",0
remark1 db "Default values were selected to match most of configurations, but not all.",0
remark2 db "If you have LCD-monitor, disable VRR in the item [c] - you do not need it.",0
remark3 db "If the system does not boot, try to disable the item [b].",0
remarks dw remark1, remark2, remark3
num_remarks = 3

View File

@@ -105,3 +105,9 @@ pdm4 db "create blank image",13,10,0
loading_msg db "Lade KolibriOS...",0 loading_msg db "Lade KolibriOS...",0
save_quest db "Aktuelle Einstellungen speichern? [y/n]: ",0 save_quest db "Aktuelle Einstellungen speichern? [y/n]: ",0
loader_block_error db "Bootloader Daten ungueltig, Kann nicht fortfahren. Angehalten.",0 loader_block_error db "Bootloader Daten ungueltig, Kann nicht fortfahren. Angehalten.",0
remark1 db "Default values were selected to match most of configurations, but not all.",0
remark2 db "If you have LCD-monitor, disable VRR in the item [c] - you do not need it.",0
remark3 db "If the system does not boot, try to disable the item [b].",0
remarks dw remark1, remark2, remark3
num_remarks = 3

View File

@@ -111,3 +111,9 @@ _bt db 186,'
;_sel1 db 0x1A,0 ;_sel1 db 0x1A,0
;_sel2 db 0x1B,0 ;_sel2 db 0x1B,0
;_selc db ' ',0 ;_selc db ' ',0
remark1 db "<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><><EFBFBD><E7A0AD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><><E3A4AE><20><><EFBFBD><EFBFBD><EFBFBD>⢠, <20><> <20><> <20><><EFBFBD><EFBFBD>.",0
remark2 db "<EFBFBD><20> <20><><EFBFBD> LCD-<2D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <20><EFBFBD><E2AAAB><EFBFBD><EFBFBD><EFBFBD> VRR <20> <20><EFBFBD><E3ADAA> [c] - <20><> <20><><EFBFBD> <20><> <20><EFBFBD>.",0
remark3 db "<EFBFBD><20> <20><><EFBFBD> <20><> <20><><EFBFBD><E3A7A8><EFBFBD> <20><><EFBFBD><EFBFBD>, <20><><EFBFBD><EFBFBD><E0AEA1><EFBFBD><EFBFBD> <20><EFBFBD><E2AAAB><EFBFBD><EFBFBD><EFBFBD> <20><EFBFBD> [b].",0
remarks dw remark1, remark2, remark3
num_remarks = 3