From 54dc123015b877945eb94d5d0b7a82e3abb03fb2 Mon Sep 17 00:00:00 2001 From: "Evgeny Grechnikov (Diamond)" Date: Thu, 29 Mar 2007 10:24:08 +0000 Subject: [PATCH] * bootcode: revision string is now calculated at compile-time * taskman.inc: do not add '@' to thread names * @panel: do not draw undefined (zero-sized) windows * rd.inc: corrected folder creation git-svn-id: svn://kolibrios.org@437 a494cfbc-eb01-0410-851d-a64ba20cac60 --- kernel/trunk/blkdev/rd.inc | 3 ++ kernel/trunk/boot/bootcode.inc | 35 +---------------- kernel/trunk/boot/booteng.inc | 40 -------------------- kernel/trunk/boot/bootet.inc | 40 -------------------- kernel/trunk/boot/bootge.inc | 40 -------------------- kernel/trunk/boot/bootru.inc | 41 +------------------- kernel/trunk/boot/bootstr.inc | 52 ++++++++++++++++++++++++++ kernel/trunk/core/taskman.inc | 2 - kernel/trunk/kernel16.inc | 5 +-- programs/system/panel/trunk/@PANEL.ASM | 12 +++++- 10 files changed, 68 insertions(+), 202 deletions(-) create mode 100644 kernel/trunk/boot/bootstr.inc diff --git a/kernel/trunk/blkdev/rd.inc b/kernel/trunk/blkdev/rd.inc index 0b2433eec9..b45b770eac 100644 --- a/kernel/trunk/blkdev/rd.inc +++ b/kernel/trunk/blkdev/rd.inc @@ -1872,6 +1872,9 @@ fs_RamdiskRewrite: mov byte [edi-32+11], 10h mov eax, [esp+16+8] mov word [edi-32+26], ax + xor eax, eax + mov ecx, (512-32*2)/4 + rep stosd pop edi edi ecx edx add esp, 20 popad diff --git a/kernel/trunk/boot/bootcode.inc b/kernel/trunk/boot/bootcode.inc index 41720951ae..5143914fcf 100644 --- a/kernel/trunk/boot/bootcode.inc +++ b/kernel/trunk/boot/bootcode.inc @@ -160,20 +160,6 @@ printplain: popa ret -uint2str_16: - cmp ax,cx - jb @f - xor dx,dx - div cx - push dx - call uint2str_16 - pop ax - @@: cmp al,10 - sbb al,$69 - das - stosb - ret - ; Now int 16 is used for keyboard support. ; This is shorter, simpler and more reliable. if 0 @@ -576,26 +562,7 @@ wait_loop: ; variant 2 mov [apm_data_16 - 0x10000 + 4], dl mov [es : 0x9040], ebx ; offset of APM entry point apm_end: -; ----------------------------------------- - -; --------------- REVISION ---------------- - push ds - pop es - mov di,svn_num_buf - 0x10000 - mov ax,__REV__ - mov cx,10 - call uint2str_16 - mov ax,' ' - stosw - sub di,svn_num_buf - 0x10000 - mov dx,80 - 1 - msg_svn.len - sub dx,di - call setcursor - mov si,msg_svn - 0x10000 - call printplain - mov si,svn_num_buf - 0x10000 - call printplain - _setcursor d80x25_top_num,0 + _setcursor d80x25_top_num, 0 ; ----------------------------------------- ; DISPLAY VESA INFORMATION diff --git a/kernel/trunk/boot/booteng.inc b/kernel/trunk/boot/booteng.inc index f12a36eed7..5a93fa9157 100644 --- a/kernel/trunk/boot/booteng.inc +++ b/kernel/trunk/boot/booteng.inc @@ -5,46 +5,6 @@ $Revision$ ; ;====================================================================== -macro line_full_top { - db 201 - times 78 db 205 - db 187 -} -macro line_full_bottom { - db 200 - times 78 db 205 - db 188 -} -macro line_half { - db 186,' ' - times 76 db 0xc4 - db ' ',186 -} -macro line_space { - db 186 - times 78 db 32 - db 186 -} -d80x25_top: - line_full_top -space_msg: line_space -verstr: -; line_space -; version string - db 186,32 - repeat 78 - load a byte from version+%-1 - if a = 13 - break - end if - db a - end repeat - repeat 78 - ($-verstr) - db ' ' - end repeat - db 32,186 - line_half -d80x25_top_num = 4 d80x25_bottom: db 186,' KolibriOS based on MenuetOS and comes with ABSOLUTELY ' db 'NO WARRANTY ',186 diff --git a/kernel/trunk/boot/bootet.inc b/kernel/trunk/boot/bootet.inc index 52e69768a3..28a147ed36 100644 --- a/kernel/trunk/boot/bootet.inc +++ b/kernel/trunk/boot/bootet.inc @@ -5,46 +5,6 @@ $Revision$ ; ;====================================================================== -macro line_full_top { - db 201 - times 78 db 205 - db 187 -} -macro line_full_bottom { - db 200 - times 78 db 205 - db 188 -} -macro line_half { - db 186,' ' - times 76 db 0xc4 - db ' ',186 -} -macro line_space { - db 186 - times 78 db 32 - db 186 -} -d80x25_top: - line_full_top -space_msg: line_space -verstr: -; line_space -; version string - db 186,32 - repeat 78 - load a byte from version+%-1 - if a = 13 - break - end if - db a - end repeat - repeat 78 - ($-verstr) - db ' ' - end repeat - db 32,186 - line_half -d80x25_top_num = 4 d80x25_bottom: db 186,' KolibriOS based on MenuetOS and comes with ABSOLUTELY ' db 'NO WARRANTY ',186 diff --git a/kernel/trunk/boot/bootge.inc b/kernel/trunk/boot/bootge.inc index 454c448248..90aa9aead6 100644 --- a/kernel/trunk/boot/bootge.inc +++ b/kernel/trunk/boot/bootge.inc @@ -5,46 +5,6 @@ $Revision$ ; ;====================================================================== -macro line_full_top { - db 201 - times 78 db 205 - db 187 -} -macro line_full_bottom { - db 200 - times 78 db 205 - db 188 -} -macro line_half { - db 186,' ' - times 76 db 0xc4 - db ' ',186 -} -macro line_space { - db 186 - times 78 db 32 - db 186 -} -d80x25_top: - line_full_top -space_msg: line_space -verstr: -; line_space -; version string - db 186,32 - repeat 78 - load a byte from version+%-1 - if a = 13 - break - end if - db a - end repeat - repeat 78 - ($-verstr) - db ' ' - end repeat - db 32,186 - line_half -d80x25_top_num = 4 d80x25_bottom: ; db 186,' KolibriOS based on MenuetOS and comes with ABSOLUTELY ' ; db 'NO WARRANTY ',186 diff --git a/kernel/trunk/boot/bootru.inc b/kernel/trunk/boot/bootru.inc index 82d9ca001b..abf162cae3 100644 --- a/kernel/trunk/boot/bootru.inc +++ b/kernel/trunk/boot/bootru.inc @@ -5,46 +5,6 @@ $Revision$ ; ;====================================================================== -macro line_full_top { - db 201 - times 78 db 205 - db 187 -} -macro line_full_bottom { - db 200 - times 78 db 205 - db 188 -} -macro line_half { - db 186,' ' - times 76 db 0xc4 - db ' ',186 -} -macro line_space { - db 186 - times 78 db 32 - db 186 -} -d80x25_top: - line_full_top -space_msg: line_space -verstr: -; line_space -; version string - db 186,32 - repeat 78 - load a byte from version+%-1 - if a = 13 - break - end if - db a - end repeat - repeat 78 - ($-verstr) - db ' ' - end repeat - db 32,186 - line_half -d80x25_top_num = 4 d80x25_bottom: db 186,' Kolibri OS основана на Menuet OS и не предоставляет ' db 'никаких гарaнтий. ',186 @@ -57,6 +17,7 @@ novesa db " vervesa db "Версия VESA: Vesa x.x",13,10,0 vervesa_off=19 msg_apm db " APM x.x ", 0 + gr_mode db 186," Vesa 2.0+ 16 M LFB: [1] 640x480, [2] 800x600, " db "[3] 1024x768, [4] 1280x1024",13,10 db 186," Vesa 1.2 16 M Bnk: [5] 640x480, [6] 800x600, " diff --git a/kernel/trunk/boot/bootstr.inc b/kernel/trunk/boot/bootstr.inc new file mode 100644 index 0000000000..e82fb85f0e --- /dev/null +++ b/kernel/trunk/boot/bootstr.inc @@ -0,0 +1,52 @@ +; boot data: common strings (for all languages) +macro line_full_top { + db 201 + times 78 db 205 + db 187 +} +macro line_full_bottom { + db 200 + times 78 db 205 + db 188 +} +macro line_half { + db 186,' ' + times 76 db 0xc4 + db ' ',186 +} +macro line_space { + db 186 + times 78 db 32 + db 186 +} +d80x25_top: + line_full_top +cur_line_pos = 75 + store byte ' ' at d80x25_top+cur_line_pos+1 +rev_var = __REV__ +while rev_var > 0 + store byte rev_var mod 10 + '0' at d80x25_top+cur_line_pos + cur_line_pos = cur_line_pos - 1 + rev_var = rev_var / 10 +end while + store byte ' ' at d80x25_top+cur_line_pos + store dword ' SVN' at d80x25_top+cur_line_pos-4 + +space_msg: line_space +verstr: +; line_space +; version string + db 186,32 + repeat 78 + load a byte from version+%-1 + if a = 13 + break + end if + db a + end repeat + repeat 78 - ($-verstr) + db ' ' + end repeat + db 32,186 + line_half +d80x25_top_num = 4 diff --git a/kernel/trunk/core/taskman.inc b/kernel/trunk/core/taskman.inc index 0b6ad5353e..ecf221610e 100644 --- a/kernel/trunk/core/taskman.inc +++ b/kernel/trunk/core/taskman.inc @@ -890,8 +890,6 @@ proc new_sys_threads rep stosd ;clean extended information about new thread mov esi,ebx mov edi,edx - mov byte [edi], '@' - inc edi mov ecx,11 rep movsb ;copy process name diff --git a/kernel/trunk/kernel16.inc b/kernel/trunk/kernel16.inc index 68bd732198..9959d919c1 100644 --- a/kernel/trunk/kernel16.inc +++ b/kernel/trunk/kernel16.inc @@ -19,11 +19,8 @@ $Revision$ ;% +include -msg_svn db " SVN ",0 -msg_svn.len = $ - msg_svn -svn_num_buf rb 12 - ;!!! +include "boot/bootstr.inc" ; language-independent boot messages if lang eq en include "boot/booteng.inc" ; english system boot messages else if lang eq ru diff --git a/programs/system/panel/trunk/@PANEL.ASM b/programs/system/panel/trunk/@PANEL.ASM index 7111c247a2..5aa50c4074 100644 --- a/programs/system/panel/trunk/@PANEL.ASM +++ b/programs/system/panel/trunk/@PANEL.ASM @@ -558,6 +558,14 @@ calculate_applications: cmp byte [0x8000+10], '@' je cnorpl +; \begin{diamond}[29.03.2007] +; do not draw undefined (zero-sized) windows + cmp dword [0x8000+42], 0 + jnz @f + cmp dword [0x8000+46], 0 + jz cnorpl +@@: +; \end{diamond}[29.03.2007] cmp [0x8000+10],dword 'ICON' jne .noicon cmp dword[0x8000+42],51 @@ -567,8 +575,8 @@ calculate_applications: .noicon: cmp [0x8000+11],dword 'CON ' je cnorpl - cmp [0x8000+11],dword 'ENU ' - je cnorpl +; cmp [0x8000+11],dword 'ENU ' +; je cnorpl ; cmp [0x8000+12],dword 'NEL ' ; je cnorpl cmp [0x8000+10],dword ' '