forked from KolibriOS/kolibrios
downloader: bug #22 (bug with address inputbox) fixed
git-svn-id: svn://kolibrios.org@2712 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
9e6f7eb64d
commit
1f38b08f1b
@ -1459,16 +1459,9 @@ end if
|
|||||||
;****************************************************************************
|
;****************************************************************************
|
||||||
print_text:
|
print_text:
|
||||||
; Draw a bar to blank out previous text
|
; Draw a bar to blank out previous text
|
||||||
mov ebx,30*65536+URLMAXLEN*6 ; 50 should really be [len] and 103 [xa]
|
mcall 13, <30,520>, <[ya], 9>,0xFFFFFF
|
||||||
mov ecx,[ya]
|
|
||||||
shl ecx,16
|
|
||||||
mov cx,9
|
|
||||||
mcall 13,,,0xFFFFFF
|
|
||||||
; write text
|
; write text
|
||||||
mov ebx,30*65536
|
mcall 4, <30,[ya]>, 0,[addr],URLMAXLEN
|
||||||
add ebx,[ya]
|
|
||||||
xor ecx,ecx
|
|
||||||
mcall 4,,,[addr],URLMAXLEN
|
|
||||||
ret
|
ret
|
||||||
|
|
||||||
; *********************************************
|
; *********************************************
|
||||||
@ -1476,42 +1469,15 @@ print_text:
|
|||||||
; *********************************************
|
; *********************************************
|
||||||
|
|
||||||
draw_window:
|
draw_window:
|
||||||
; function 12: tell os about windowdraw
|
|
||||||
; 1 start of draw
|
mcall 12,1 ; start window redraw
|
||||||
mcall 12,1
|
|
||||||
|
|
||||||
; cmp [params],byte 0
|
; cmp [params],byte 0
|
||||||
; jz .noret
|
; jz .noret
|
||||||
|
|
||||||
; ýòî íåñêîëüêî çàãàäî÷íî, íî åñëè íå ðèñîâàòü îêîøêî ñîâñåì, ïðîãà íå ïàøåò.
|
|
||||||
; DRAW WINDOW
|
|
||||||
; eax function 0 : define and draw window
|
|
||||||
; xor eax,eax
|
|
||||||
; ebx [x start] *65536 + [x size]
|
|
||||||
; xor ebx,ebx
|
|
||||||
; ecx [y start] *65536 + [y size]
|
|
||||||
; xor ecx,ecx
|
|
||||||
; edx color of work area RRGGBB,8->color gl
|
|
||||||
; esi color of bar and flags
|
|
||||||
; xor esi,esi
|
|
||||||
; mcall ,,,0x14ffffff,,title
|
|
||||||
|
|
||||||
; function 12: tell os about windowdraw
|
|
||||||
; 2, end of draw
|
|
||||||
; mcall 12,2
|
|
||||||
; ret
|
|
||||||
|
|
||||||
;.noret:
|
;.noret:
|
||||||
; DRAW WINDOW
|
; DRAW WINDOW
|
||||||
; eax function 0 : define and draw window
|
mcall 0,<50,570>,<350,200>,0x14ffffff,0,title
|
||||||
xor eax,eax
|
|
||||||
; ebx [x start] *65536 + [x size]
|
|
||||||
; ecx [y start] *65536 + [y size]
|
|
||||||
; edx color of work area RRGGBB,8->color gl
|
|
||||||
; esi color of bar and flags
|
|
||||||
xor esi,esi
|
|
||||||
; edi WINDOW LABEL
|
|
||||||
mcall ,<50,600>,<350,200>,0x14ffffff,,title
|
|
||||||
; eax function 4: write text to window
|
; eax function 4: write text to window
|
||||||
; ebx [x start] *65536 + [y start]
|
; ebx [x start] *65536 + [y start]
|
||||||
; ecx color of text RRGGBB
|
; ecx color of text RRGGBB
|
||||||
@ -1530,30 +1496,18 @@ draw_window:
|
|||||||
; mcall 38,<5,545>
|
; mcall 38,<5,545>
|
||||||
|
|
||||||
; RELOAD
|
; RELOAD
|
||||||
; eax function 8 : define and draw button
|
mcall 8,<388,50>,<54,14>,22,0x5588dd
|
||||||
; ebx [x start] *65536 + [x size]
|
|
||||||
; ecx [y start] *65536 + [y size]
|
|
||||||
; edx button id
|
|
||||||
; esi button color RRGGBB
|
|
||||||
mcall 8,<388,50>,<34,14>,22,0x5588dd
|
|
||||||
; URL
|
; URL
|
||||||
mcall ,<10,12>,<34,12>,10
|
mcall ,<10,12>,<34,12>,10
|
||||||
; STOP
|
; STOP
|
||||||
mcall ,<443,50>,<34,14>,24
|
mcall ,<443,50>,<54,14>,24
|
||||||
; SAVE
|
; SAVE
|
||||||
mcall ,<498,50>,,26
|
mcall ,<498,50>,,26
|
||||||
; BUTTON TEXT
|
; BUTTON TEXT
|
||||||
; eax function 4 : write text to window
|
mcall 4,<390,58>,0xffffff,button_text,30
|
||||||
; ebx [x start] *65536 + [y start]
|
|
||||||
; ecx color of text RRGGBB
|
|
||||||
; edx pointer to text beginning
|
|
||||||
; esi text length
|
|
||||||
mcall 4,<390,38>,0xffffff,button_text,30
|
|
||||||
call display_page
|
call display_page
|
||||||
|
|
||||||
; function 12: tell os about windowdraw
|
mcall 12,2 ; end window redraw
|
||||||
; 2, end of draw
|
|
||||||
mcall 12,2
|
|
||||||
ret
|
ret
|
||||||
;-----------------------------------------------------------------------------
|
;-----------------------------------------------------------------------------
|
||||||
; Data area
|
; Data area
|
||||||
@ -1610,7 +1564,7 @@ addr dd 0x0
|
|||||||
ya dd 0x0
|
ya dd 0x0
|
||||||
len dd 0x00
|
len dd 0x00
|
||||||
|
|
||||||
title db 'Downloader',0
|
title db 'Network Downloader',0
|
||||||
|
|
||||||
server_ip: db 207,44,212,20
|
server_ip: db 207,44,212,20
|
||||||
;dns_ip: db 194,145,128,1
|
;dns_ip: db 194,145,128,1
|
||||||
@ -1619,9 +1573,6 @@ server_ip: db 207,44,212,20
|
|||||||
;times URLMAXLEN db ' '
|
;times URLMAXLEN db ' '
|
||||||
;db 0
|
;db 0
|
||||||
|
|
||||||
;document_user: db 'Click on the button to the left to enter a URL',0
|
|
||||||
;times URLMAXLEN+document_user-$ db 0
|
|
||||||
|
|
||||||
;document: db '/'
|
;document: db '/'
|
||||||
;times URLMAXLEN-1 db ' '
|
;times URLMAXLEN-1 db ' '
|
||||||
;---------------------------------------------------------------------
|
;---------------------------------------------------------------------
|
||||||
|
Loading…
Reference in New Issue
Block a user