Subversion Repositories Kolibri OS

Rev

Rev 205 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 205 Rev 485
Line 43... Line 43...
43
  dd	 RAM_END      ; stack
43
  dd	 RAM_END      ; stack
44
  dd	 param_area ,0x0   ; param,icon
44
  dd	 param_area ,0x0   ; param,icon
45
;  dd 0,0
45
;  dd 0,0
Line 46... Line 46...
46
 
46
 
47
;******************************************************************************
47
;******************************************************************************
48
include 'macros.inc'
48
include '..\..\..\macros.inc'
49
include 'ascl.inc'
49
include 'ascl.inc'
Line 50... Line 50...
50
include 'ascgl.inc'
50
include 'ascgl.inc'
Line 51... Line 51...
51
 
51
 
52
    gif_hash_offset = gif_hash
52
    gif_hash_offset = gif_hash
53
 
53
 
54
START:		    ; start of execution
54
START:		    ; start of execution
55
; //// Willow
55
; //// Willow
56
;    mov eax,58
56
;    mov eax,58
57
;    mov ebx,MRUfile
57
;    mov ebx,MRUfile
58
;    int 0x40
58
;    mcall
59
; //// Willow
59
; //// Willow
60
    mcall 18,11,1,table_area
60
    mcall 18,11,1,table_area
Line 99... Line 99...
99
        mov     [hdimg4+8], 'OM  '
99
        mov     [hdimg4+8], 'OM  '
100
@@:
100
@@:
Line 101... Line 101...
101
 
101
 
102
    mov eax,40
102
    mov eax,40
103
    mov ebx,0100111b
103
    mov ebx,0100111b
Line 104... Line 104...
104
    int 0x40
104
    mcall
105
 
105
 
106
    cmp byte [param_area],0 ;test parameters line
106
    cmp byte [param_area],0 ;test parameters line
107
    jne no_brow     ;it's dialog
107
    jne no_brow     ;it's dialog
Line 113... Line 113...
113
    mov [dlg_type],al
113
    mov [dlg_type],al
Line 114... Line 114...
114
 
114
 
115
    mov eax,9
115
    mov eax,9
116
    mov ebx,procinfo
116
    mov ebx,procinfo
117
    mov ecx,-1
117
    mov ecx,-1
Line 118... Line 118...
118
    int 0x40
118
    mcall
119
 
119
 
120
    mov eax,dword [procinfo+30]
120
    mov eax,dword [procinfo+30]
121
    mov edi,MYPID+4-1
121
    mov edi,MYPID+4-1
Line 149... Line 149...
149
    mov ecx,eax ;pid to ecx
149
    mov ecx,eax ;pid to ecx
150
    mov eax,60
150
    mov eax,60
151
    mov ebx,2
151
    mov ebx,2
152
    mov edx,MYPID
152
    mov edx,MYPID
153
    mov esi,4
153
    mov esi,4
154
    int 0x40
154
    mcall
155
no_dlg:
155
no_dlg:
Line 156... Line 156...
156
 
156
 
Line 157... Line 157...
157
    giftoimg but_file,tempimg
157
    giftoimg but_file,tempimg
Line 208... Line 208...
208
 
208
 
209
still:
209
still:
210
    mov eax,9
210
    mov eax,9
211
    mov ebx,procinfo
211
    mov ebx,procinfo
212
    mov ecx,-1
212
    mov ecx,-1
Line 213... Line 213...
213
    int 0x40
213
    mcall
Line 214... Line 214...
214
 
214
 
215
    wtevent red,key,button
215
    wtevent red,key,button
216
 
216
 
217
scrolltest:
217
scrolltest:
218
    mov eax,37
218
    mov eax,37
219
    mov ebx,2
219
    mov ebx,2
Line 220... Line 220...
220
    int 0x40
220
    mcall
221
    dec eax
221
    dec eax
222
    jne still
222
    jne still
223
 
223
 
224
scrl:
224
scrl:
225
    mov eax,37
225
    mov eax,37
226
    mov ebx,1
226
    mov ebx,1
227
    int 0x40
227
    mcall
228
        movzx   ebx, ax         ; y
228
        movzx   ebx, ax         ; y
229
        shr     eax, 16         ; x
229
        shr     eax, 16         ; x
230
    mov ebp,eax
230
    mov ebp,eax
231
    sub ebp,[listx] ;[procinfo.x_size]
231
    sub ebp,[listx] ;[procinfo.box.left]
Line 289... Line 289...
289
;===================
289
;===================
290
; Test keyboard
290
; Test keyboard
291
;===================
291
;===================
292
key:		  ; key
292
key:		  ; key
293
    mov  eax,2
293
    mov  eax,2
294
    int  0x40
294
    mcall
295
    cmp dword [focus],0
295
    cmp dword [focus],0
296
    jne con_edit
296
    jne con_edit
297
    cmp  ah,key_Up
297
    cmp  ah,key_Up
298
    jne  no_upk
298
    jne  no_upk
299
    mov  ebx,1
299
    mov  ebx,1
Line 398... Line 398...
398
;Test on mouse button
398
;Test on mouse button
399
;-----------------------------
399
;-----------------------------
Line 400... Line 400...
400
 
400
 
401
  button:	  ; button
401
  button:	  ; button
402
    mov eax,17
402
    mov eax,17
Line 403... Line 403...
403
    int 0x40
403
    mcall
404
 
404
 
Line 405... Line 405...
405
    cmp ah,2	       ;Edit prompt line?
405
    cmp ah,2	       ;Edit prompt line?
406
    je	    edit_prompt
406
    je	    edit_prompt
Line 407... Line 407...
407
 
407
 
408
    cmp ah,4
408
    cmp ah,4
409
    jne no_filelist
409
    jne no_filelist
410
 
410
 
411
mousetest:
411
mousetest:
412
    mov eax,37
412
    mov eax,37
413
    mov ebx,1
413
    mov ebx,1
Line 414... Line 414...
414
    int 0x40
414
    mcall
Line 563... Line 563...
563
    mov ecx,eax ;pid to ecx
563
    mov ecx,eax ;pid to ecx
564
    mov eax,60
564
    mov eax,60
565
    mov ebx,2
565
    mov ebx,2
566
    mov edx,paramtest
566
    mov edx,paramtest
567
    mov esi,1024
567
    mov esi,1024
568
    int 0x40
568
    mcall
Line 569... Line 569...
569
 
569
 
Line 570... Line 570...
570
    jmp exit
570
    jmp exit
Line 645... Line 645...
645
        mov     ebx, fileinfo_start
645
        mov     ebx, fileinfo_start
646
        and     dword [ebx+8], 0                ; no parameters
646
        and     dword [ebx+8], 0                ; no parameters
647
        mov     dword [ebx+21], paramtest       ; program name
647
        mov     dword [ebx+21], paramtest       ; program name
648
.do:
648
.do:
649
        mov     eax, 70
649
        mov     eax, 70
650
        int     0x40
650
        mcall
651
        jmp     still
651
        jmp     still
Line 652... Line 652...
652
 
652
 
653
run:
653
run:
654
        mov     [fileinfo_name], ebx            ; program name
654
        mov     [fileinfo_name], ebx            ; program name
Line 816... Line 816...
816
        sub     edi, paramtest+1
816
        sub     edi, paramtest+1
817
        mov     ebx, clipfile_info
817
        mov     ebx, clipfile_info
818
        mov     byte [ebx], 2
818
        mov     byte [ebx], 2
819
        mov     [ebx+12], edi
819
        mov     [ebx+12], edi
820
        mov     eax, 70
820
        mov     eax, 70
821
        int     0x40
821
        mcall
822
        jmp     still
822
        jmp     still
823
no_copyclip:
823
no_copyclip:
Line 824... Line 824...
824
 
824
 
825
    cmp ah,16
825
    cmp ah,16
826
    jne no_clippaste
826
    jne no_clippaste
827
paste_from_clip:
827
paste_from_clip:
828
        mov     ebx, clipfile_info
828
        mov     ebx, clipfile_info
829
        mov     byte [ebx], 0
829
        mov     byte [ebx], 0
830
        mov     dword [ebx+12], 1023
830
        mov     dword [ebx+12], 1023
831
        mov     eax, 70
831
        mov     eax, 70
832
        int     0x40
832
        mcall
833
        cmp     ebx, 0
833
        cmp     ebx, 0
834
        jle     still
834
        jle     still
835
        mov     byte [paramtest+ebx], 0
835
        mov     byte [paramtest+ebx], 0
836
; OS allows only 256 symbols in command line
836
; OS allows only 256 symbols in command line
Line 882... Line 882...
882
    mov  eax,4		   ; function 4 : write text to window
882
    mov  eax,4		   ; function 4 : write text to window
883
    mov  ebx,10*65536+67     ; [x start] *65536 + [y start]
883
    mov  ebx,10*65536+67     ; [x start] *65536 + [y start]
884
    mov  ecx,0x00000000 ;[sc.grab_text] ; color of text RRGGBB
884
    mov  ecx,0x00000000 ;[sc.grab_text] ; color of text RRGGBB
885
        mov     edx, copyr_param+1
885
        mov     edx, copyr_param+1
886
        movzx   esi, byte [edx-1]
886
        movzx   esi, byte [edx-1]
887
    int  0x40
887
    mcall
888
    mov  ebx,250*65536+67	; [x start] *65536 + [y start]
888
    mov  ebx,250*65536+67	; [x start] *65536 + [y start]
889
    mov  ecx,0x00000000 ;[sc.grab_text] ; color of text RRGGBB
889
    mov  ecx,0x00000000 ;[sc.grab_text] ; color of text RRGGBB
890
        mov     edx, ebp
890
        mov     edx, ebp
891
        mov     esi, edi
891
        mov     esi, edi
892
    int  0x40
892
    mcall
893
no_outpath:
893
no_outpath:
Line 894... Line 894...
894
 
894
 
895
; run COPYR
895
; run COPYR
896
        mov     eax, 70
896
        mov     eax, 70
897
        mov     ebx, copyr_run
897
        mov     ebx, copyr_run
898
        int     0x40
898
        mcall
899
    delay 50   ;wait recoed file
899
    delay 50   ;wait recoed file
900
    jmp update ;still
900
    jmp update ;still
Line 901... Line 901...
901
no_clippaste:
901
no_clippaste:
Line 997... Line 997...
997
; //// Willow
997
; //// Willow
998
;    mov eax,58
998
;    mov eax,58
999
;    mov ebx,MRUfile
999
;    mov ebx,MRUfile
1000
;    mov dword[ebx+8],255
1000
;    mov dword[ebx+8],255
1001
;    inc dword[ebx]
1001
;    inc dword[ebx]
1002
;    int 0x40
1002
;    mcall
1003
; //// Willow
1003
; //// Willow
1004
    mov eax,-1
1004
    mov eax,-1
1005
    int 0x40
1005
    mcall
Line 1006... Line 1006...
1006
 
1006
 
1007
draw_wd:
1007
draw_wd:
1008
;    call draw_window
1008
;    call draw_window
1009
;    jmp still
1009
;    jmp still
Line 1026... Line 1026...
1026
 
1026
 
1027
screen:
1027
screen:
1028
    cmp [browser], 1 ;it's browser?
1028
    cmp [browser], 1 ;it's browser?
Line 1029... Line 1029...
1029
    jne dialogscr
1029
    jne dialogscr
1030
 
1030
 
1031
    mov eax,[procinfo.y_size]
1031
    mov eax,[procinfo.box.top]
1032
    sub eax,90
1032
    sub eax,90
1033
    drawfbox 40,76,300,eax,0x00000000
1033
    drawfbox 40,76,300,eax,0x00000000
1034
    mov eax,[procinfo.y_size]
1034
    mov eax,[procinfo.box.top]
1035
    sub eax,92
1035
    sub eax,92
1036
    drawfbox 41,77,298,eax,0x00ffffff
1036
    drawfbox 41,77,298,eax,0x00ffffff
1037
    mov edi,esi ;14
1037
    mov edi,esi ;14
1038
    mov ebx,(41+26)*65536+(77+20)
1038
    mov ebx,(41+26)*65536+(77+20)
1039
    mov ecx,cl_Black
1039
    mov ecx,cl_Black
Line 1040... Line 1040...
1040
    mov edx,ebp ;help_text
1040
    mov edx,ebp ;help_text
1041
    jmp outlab
1041
    jmp outlab
1042
 
1042
 
1043
dialogscr:
1043
dialogscr:
1044
    mov eax,[procinfo.y_size]
1044
    mov eax,[procinfo.box.top]
1045
    sub eax,84
1045
    sub eax,84
1046
    drawfbox 16,54,270,eax,0x00000000
1046
    drawfbox 16,54,270,eax,0x00000000
1047
    mov eax,[procinfo.y_size]
1047
    mov eax,[procinfo.box.top]
1048
    sub eax,86
1048
    sub eax,86
1049
    drawfbox 17,55,268,eax,0x00ffffff
1049
    drawfbox 17,55,268,eax,0x00ffffff
Line 1054... Line 1054...
1054
 
1054
 
1055
outlab:     ;out labels
1055
outlab:     ;out labels
1056
    mov eax,4
1056
    mov eax,4
1057
    mov esi,40
1057
    mov esi,40
1058
helploo:
1058
helploo:
1059
    int 0x40
1059
    mcall
1060
    add ebx,11
1060
    add ebx,11
1061
    add edx,40
1061
    add edx,40
1062
    dec edi
1062
    dec edi
Line 1142... Line 1142...
1142
draw_window:
1142
draw_window:
Line 1143... Line 1143...
1143
 
1143
 
1144
;    mov eax,9
1144
;    mov eax,9
1145
;    mov ebx,procinfo
1145
;    mov ebx,procinfo
1146
;    mov ecx,-1
1146
;    mov ecx,-1
1147
;    int 0x40
1147
;    mcall
1148
;    mov  eax,[procinfo.x_size]
1148
;    mov  eax,[procinfo.box.left]
1149
;    cmp  eax,66
1149
;    cmp  eax,66
1150
;    jg  temp12345
1150
;    jg  temp12345
1151
;    ret
1151
;    ret
1152
; temp12345:
1152
; temp12345:
1153
    mov  eax,48
1153
    mov  eax,48
1154
    mov  ebx,3
1154
    mov  ebx,3
1155
    mov  ecx,sc
1155
    mov  ecx,sc
1156
    mov  edx,sizeof.system_colors
1156
    mov  edx,sizeof.system_colors
Line 1157... Line 1157...
1157
    int  0x40
1157
    mcall
1158
 
1158
 
Line 1159... Line 1159...
1159
    mov  eax,[sc.work_button]
1159
    mov  eax,[sc.work_button]
1160
    mov  [b_color],eax
1160
    mov  [b_color],eax
1161
 
1161
 
Line 1162... Line 1162...
1162
    mov  eax,12        ; function 12:tell os about windowdraw
1162
    mov  eax,12        ; function 12:tell os about windowdraw
Line 1163... Line 1163...
1163
    mov  ebx,1		   ; 1, start of draw
1163
    mov  ebx,1		   ; 1, start of draw
Line 1176... Line 1176...
1176
    mov  ebx,140*65536+320     ; [x start] *65536 + [x size]
1176
    mov  ebx,140*65536+320     ; [x start] *65536 + [x size]
1177
    mov  ecx,260*65536+240     ; [y start] *65536 + [y size]
1177
    mov  ecx,260*65536+240     ; [y start] *65536 + [y size]
1178
isb1:
1178
isb1:
1179
;    mov  edx,[sc.work]             ; color of work area RRGGBB
1179
;    mov  edx,[sc.work]             ; color of work area RRGGBB
1180
    or	     edx,0x03ffffff;000000
1180
    or	     edx,0x03ffffff;000000
1181
    int  0x40
1181
    mcall
Line 1182... Line 1182...
1182
 
1182
 
1183
;Get proc info
1183
;Get proc info
1184
    mov eax,9
1184
    mov eax,9
1185
    mov ebx,procinfo
1185
    mov ebx,procinfo
1186
    mov ecx,-1
1186
    mov ecx,-1
Line 1187... Line 1187...
1187
    int 0x40
1187
    mcall
1188
 
1188
 
1189
    mov  eax,[procinfo.x_size]
1189
    mov  eax,[procinfo.box.left]
1190
    cmp  eax,66
1190
    cmp  eax,66
1191
    jg	 @f
1191
    jg	 @f
1192
.ret:
1192
.ret:
1193
    ret
1193
    ret
1194
 @@:
1194
 @@:
Line 1195... Line 1195...
1195
    cmp  [procinfo.y_size], 0x70
1195
    cmp  [procinfo.box.top], 0x70
1196
    jl  .ret
1196
    jl  .ret
1197
 
1197
 
1198
    cmp  [browser], 1 ;it's browser
1198
    cmp  [browser], 1 ;it's browser
1199
    jne  nob9
1199
    jne  nob9
1200
    mov  [listx],120
1200
    mov  [listx],120
1201
;    mov  eax,[procinfo.x_size]
1201
;    mov  eax,[procinfo.box.left]
1202
    sub  eax,127;[listx]+7
1202
    sub  eax,127;[listx]+7
1203
    cmp  eax,10
1203
    cmp  eax,10
1204
    jl   .ret
1204
    jl   .ret
1205
    mov  [listxsize],eax
1205
    mov  [listxsize],eax
1206
    mov  [listy],73
1206
    mov  [listy],73
1207
    mov  eax,[procinfo.y_size]
1207
    mov  eax,[procinfo.box.top]
1208
    sub  eax,73+7;[listy]+7
1208
    sub  eax,73+7;[listy]+7
1209
    mov  [listysize],eax
1209
    mov  [listysize],eax
1210
    jmp isb9
1210
    jmp isb9
1211
nob9:
1211
nob9:
1212
    mov  [listx],10
1212
    mov  [listx],10
1213
;    mov  eax,[procinfo.x_size]
1213
;    mov  eax,[procinfo.box.left]
1214
    sub  eax,17 ;[listx]+7
1214
    sub  eax,17 ;[listx]+7
1215
    mov  [listxsize],eax
1215
    mov  [listxsize],eax
1216
    mov  [listy],54
1216
    mov  [listy],54
1217
    mov  eax,[procinfo.y_size]
1217
    mov  eax,[procinfo.box.top]
Line 1233... Line 1233...
1233
    mov  ebx,8*65536+(6*8-1) ;start pos x
1233
    mov  ebx,8*65536+(6*8-1) ;start pos x
1234
    mov  ecx,23*65536+10      ;start pos y
1234
    mov  ecx,23*65536+10      ;start pos y
1235
    mov  edx,22;+1000000000000000000000000000000b  ;spoke butt
1235
    mov  edx,22;+1000000000000000000000000000000b  ;spoke butt
1236
    mov  edi,3		  ;draw 13 button's
1236
    mov  edi,3		  ;draw 13 button's
1237
    mov  esi,0x00339933
1237
    mov  esi,0x00339933
1238
    int  0x40
1238
    mcall
1239
    dec edi
1239
    dec edi
1240
nexthbut:
1240
nexthbut:
1241
    add  ebx,(6*8)*65536
1241
    add  ebx,(6*8)*65536
1242
    inc  edx
1242
    inc  edx
1243
    int  0x40
1243
    mcall
1244
    dec  edi
1244
    dec  edi
1245
    jnz  nexthbut
1245
    jnz  nexthbut
Line 1246... Line 1246...
1246
 
1246
 
1247
;File STRING
1247
;File STRING
Line 1248... Line 1248...
1248
    glabel 8,25,'  FILE    VIEW    INFO  ',  cl_White ;Black
1248
    glabel 8,25,'  FILE    VIEW    INFO  ',  cl_White ;Black
1249
 
1249
 
1250
;BlackLine
1250
;BlackLine
1251
    mov eax,[procinfo.x_size]
1251
    mov eax,[procinfo.box.left]
Line 1252... Line 1252...
1252
    sub eax,10
1252
    sub eax,10
1253
    drawfbox 5,35, eax, 1, cl_Black
1253
    drawfbox 5,35, eax, 1, cl_Black
1254
 
1254
 
1255
;BlackLine2
1255
;BlackLine2
Line 1256... Line 1256...
1256
    mov eax,[procinfo.x_size]
1256
    mov eax,[procinfo.box.left]
1257
    sub eax,10
1257
    sub eax,10
1258
    drawfbox 5,68, eax, 1, cl_Black
1258
    drawfbox 5,68, eax, 1, cl_Black
1259
 
1259
 
Line 1260... Line 1260...
1260
;BlackLine2 vertical
1260
;BlackLine2 vertical
1261
;    mov eax,[procinfo.y_size]
1261
;    mov eax,[procinfo.box.top]
Line 1327... Line 1327...
1327
    mov  ecx,29*65536+15      ;start pos y
1327
    mov  ecx,29*65536+15      ;start pos y
1328
isb3:
1328
isb3:
1329
    mov  edx,8;+1000000000000000000000000000000b  ;spoke butt
1329
    mov  edx,8;+1000000000000000000000000000000b  ;spoke butt
1330
    mov  edi,13        ;draw 13 button's
1330
    mov  edi,13        ;draw 13 button's
1331
    mov  esi,cl_Grey
1331
    mov  esi,cl_Grey
1332
    int  0x40
1332
    mcall
1333
    dec edi
1333
    dec edi
1334
nextbut:
1334
nextbut:
1335
    add  ebx,(16+6)*65536
1335
    add  ebx,(16+6)*65536
1336
    inc  edx
1336
    inc  edx
1337
    int  0x40
1337
    mcall
1338
    dec  edi
1338
    dec  edi
1339
    jnz  nextbut
1339
    jnz  nextbut
Line 1340... Line 1340...
1340
 
1340
 
1341
 
1341
 
1342
    cmp  [browser], 1 ;it's browser
1342
    cmp  [browser], 1 ;it's browser
1343
    jne  nob4
1343
    jne  nob4
1344
;But img browser
1344
;But img browser
1345
    setimg 10,37,butimg
1345
    setimg 10,37,butimg
1346
;left logo
1346
;left logo
1347
    add eax,[procinfo.x_size]
1347
    add eax,[procinfo.box.left]
1348
    sub eax,80
1348
    sub eax,80
1349
    mov [temp],eax
1349
    mov [temp],eax
1350
    setimg [temp],37,logoimg
1350
    setimg [temp],37,logoimg
Line 1357... Line 1357...
1357
    cmp  [browser], 1 ;it's browser
1357
    cmp  [browser], 1 ;it's browser
1358
    jne  nob5
1358
    jne  nob5
Line 1359... Line 1359...
1359
 
1359
 
1360
    mov [urlx],48
1360
    mov [urlx],48
1361
    mov [urly],55
1361
    mov [urly],55
1362
    mov eax,[procinfo.x_size]
1362
    mov eax,[procinfo.box.left]
1363
    sub eax,48+10
1363
    sub eax,48+10
1364
    mov [urlxsize],eax
1364
    mov [urlxsize],eax
Line 1365... Line 1365...
1365
    mov [urlysize],12
1365
    mov [urlysize],12
Line 1372... Line 1372...
1372
    mov eax,4
1372
    mov eax,4
1373
    mov ebx,180*65536+25
1373
    mov ebx,180*65536+25
1374
    mov ecx,cl_Black
1374
    mov ecx,cl_Black
1375
    add edx,modetext
1375
    add edx,modetext
1376
    mov esi,16
1376
    mov esi,16
1377
    int 0x40
1377
    mcall
Line 1378... Line 1378...
1378
 
1378
 
1379
;List size
1379
;List size
1380
    outcount [listsize],294,25,cl_Black,4*65536
1380
    outcount [listsize],294,25,cl_Black,4*65536
Line 1386... Line 1386...
1386
      db 'SAVE'
1386
      db 'SAVE'
Line 1387... Line 1387...
1387
 
1387
 
Line 1388... Line 1388...
1388
nob5:
1388
nob5:
1389
 
1389
 
1390
    mov [urlx],10
1390
    mov [urlx],10
1391
    mov eax,[procinfo.y_size]
1391
    mov eax,[procinfo.box.top]
1392
    sub eax,24
1392
    sub eax,24
1393
    mov [urly],eax
1393
    mov [urly],eax
1394
    mov eax,[procinfo.x_size]
1394
    mov eax,[procinfo.box.left]
1395
    sub eax,80
1395
    sub eax,80
Line 1396... Line 1396...
1396
    mov [urlxsize],eax
1396
    mov [urlxsize],eax
Line 1408... Line 1408...
1408
    mov ebx,8*65536+8
1408
    mov ebx,8*65536+8
1409
    mov ecx,[sc.grab_text]    ; color of text RRGGBB
1409
    mov ecx,[sc.grab_text]    ; color of text RRGGBB
1410
    or	    ecx,0x10000000
1410
    or	    ecx,0x10000000
1411
    mov esi,9
1411
    mov esi,9
1412
    mov eax,4
1412
    mov eax,4
1413
    int 0x40
1413
    mcall
1414
no_saveh:
1414
no_saveh:
Line 1415... Line 1415...
1415
 
1415
 
1416
 
1416
 
1417
;Draw OPEN\SAVE button
1417
;Draw OPEN\SAVE button
1418
    mov ebx,0*65536+50
1418
    mov ebx,0*65536+50
1419
    mov ecx,0*65536+12
1419
    mov ecx,0*65536+12
1420
    mov eax,[procinfo.x_size]
1420
    mov eax,[procinfo.box.left]
1421
    sub eax,63
1421
    sub eax,63
1422
    shl eax,16
1422
    shl eax,16
1423
    add ebx,eax
1423
    add ebx,eax
1424
    mov eax,[procinfo.y_size]
1424
    mov eax,[procinfo.box.top]
1425
    sub eax,25
1425
    sub eax,25
1426
    shl eax,16
1426
    shl eax,16
1427
    add ecx,eax
1427
    add ecx,eax
1428
    mov  eax,8
1428
    mov  eax,8
1429
    mov  edx,5 ;button ID
1429
    mov  edx,5 ;button ID
Line 1430... Line 1430...
1430
    mov  esi,0x006699aa  ;gradient!!!
1430
    mov  esi,0x006699aa  ;gradient!!!
1431
    int  0x40
1431
    mcall
1432
 
1432
 
1433
; label OPEN or SAVE
1433
; label OPEN or SAVE
1434
    mov ebx,[procinfo.x_size]
1434
    mov ebx,[procinfo.box.left]
1435
    sub ebx,48
1435
    sub ebx,48
1436
    mov eax,[procinfo.y_size]
1436
    mov eax,[procinfo.box.top]
Line 1437... Line 1437...
1437
    sub eax,22
1437
    sub eax,22
Line 1448... Line 1448...
1448
    mov edx,but_dlg+4	       ;draw in head SAVE FILE
1448
    mov edx,but_dlg+4	       ;draw in head SAVE FILE
1449
out_labx:
1449
out_labx:
1450
    mov ecx,cl_White
1450
    mov ecx,cl_White
1451
    mov esi,4
1451
    mov esi,4
1452
    mov eax,4
1452
    mov eax,4
1453
    int 0x40
1453
    mcall
1454
no_saveb:
1454
no_saveb:
Line 1455... Line 1455...
1455
 
1455
 
Line 1456... Line 1456...
1456
isb5:
1456
isb5:
Line 1477... Line 1477...
1477
    dec ebx
1477
    dec ebx
1478
    dec ecx
1478
    dec ecx
1479
    mov  eax,8
1479
    mov  eax,8
1480
    mov  edx,2 ;button ID
1480
    mov  edx,2 ;button ID
1481
    mov  esi,0x00aaaaaa  ;gradient!!!
1481
    mov  esi,0x00aaaaaa  ;gradient!!!
1482
    int  0x40
1482
    mcall
Line 1483... Line 1483...
1483
 
1483
 
1484
;Draw URL String
1484
;Draw URL String
1485
    mov eax,13
1485
    mov eax,13
1486
    mov edx,cl_Black
1486
    mov edx,cl_Black
1487
    int 0x40
1487
    mcall
1488
    add ebx,1*65536-2+1
1488
    add ebx,1*65536-2+1
1489
    add ecx,1*65536-2+1
1489
    add ecx,1*65536-2+1
1490
    mov edx,cl_White
1490
    mov edx,cl_White
Line 1491... Line 1491...
1491
    int 0x40
1491
    mcall
1492
 
1492
 
1493
;Draw URL Cursor
1493
;Draw URL Cursor
1494
    mov eax,6
1494
    mov eax,6
Line 1501... Line 1501...
1501
    shl ecx,16
1501
    shl ecx,16
1502
    add ecx,[urlysize]
1502
    add ecx,[urlysize]
1503
    add ecx,2*65536-4
1503
    add ecx,2*65536-4
1504
    mov eax,13
1504
    mov eax,13
1505
    mov edx,cl_Black
1505
    mov edx,cl_Black
1506
    int 0x40
1506
    mcall
Line 1507... Line 1507...
1507
 
1507
 
1508
; OUT TEXT
1508
; OUT TEXT
1509
    mov eax,[urlxsize]	    ;calculating text leight
1509
    mov eax,[urlxsize]	    ;calculating text leight
1510
    sub eax,8
1510
    sub eax,8
Line 1517... Line 1517...
1517
    add  ebx,[urly]
1517
    add  ebx,[urly]
1518
    add  ebx,3*65536+2
1518
    add  ebx,3*65536+2
1519
    mov  eax,4		   ; function 4 : write text to window
1519
    mov  eax,4		   ; function 4 : write text to window
1520
    mov  ecx,0x00000000 ;[sc.grab_text] ; color of text RRGGBB
1520
    mov  ecx,0x00000000 ;[sc.grab_text] ; color of text RRGGBB
1521
    mov  edx,path	 ; pointer to text beginning
1521
    mov  edx,path	 ; pointer to text beginning
1522
    int  0x40
1522
    mcall
Line 1523... Line 1523...
1523
 
1523
 
1524
    cmp  [flick],2
1524
    cmp  [flick],2
1525
    jne  no_flick_url
1525
    jne  no_flick_url
1526
    mov  [flick],0
1526
    mov  [flick],0
Line 1544... Line 1544...
1544
    add ecx,scrollbutsize
1544
    add ecx,scrollbutsize
1545
    shl ecx,16
1545
    shl ecx,16
1546
    add ecx,[listysize]
1546
    add ecx,[listysize]
1547
    sub ecx,scrollbutsize*2
1547
    sub ecx,scrollbutsize*2
1548
    mov edx,[scrollcolor] ;0x00006600
1548
    mov edx,[scrollcolor] ;0x00006600
1549
    int 0x40
1549
    mcall
Line 1550... Line 1550...
1550
 
1550
 
1551
;Draw Scroll Box
1551
;Draw Scroll Box
1552
    mov  edx,0
1552
    mov  edx,0
1553
    mov  eax,[listysize]
1553
    mov  eax,[listysize]
Line 1593... Line 1593...
1593
        add     ebx, [listxsize]
1593
        add     ebx, [listxsize]
1594
        sub     ebx, [scrollsize]
1594
        sub     ebx, [scrollsize]
1595
        shl     ebx, 16
1595
        shl     ebx, 16
1596
        mov     bx, word [scrollsize]
1596
        mov     bx, word [scrollsize]
1597
        mov     edx, [scrollboxcol]
1597
        mov     edx, [scrollboxcol]
1598
        int     0x40
1598
        mcall
1599
notusescroll:
1599
notusescroll:
Line 1600... Line 1600...
1600
 
1600
 
1601
 
1601
 
Line 1609... Line 1609...
1609
    shl  ecx,16
1609
    shl  ecx,16
1610
    add  ecx,[listysize]
1610
    add  ecx,[listysize]
Line 1611... Line 1611...
1611
 
1611
 
1612
    mov  eax,8
1612
    mov  eax,8
1613
    mov  edx,4+1000000000000000000000000000000b  ;spoke butt
1613
    mov  edx,4+1000000000000000000000000000000b  ;spoke butt
Line 1614... Line 1614...
1614
    int  0x40
1614
    mcall
1615
 
1615
 
1616
    add  ebx,15
1616
    add  ebx,15
1617
    mov  eax,13
1617
    mov  eax,13
Line 1618... Line 1618...
1618
    mov  edx,[listcolor] ;ffffff
1618
    mov  edx,[listcolor] ;ffffff
1619
    int  0x40
1619
    mcall
1620
 
1620
 
1621
;Draw up/down buttons
1621
;Draw up/down buttons
Line 1627... Line 1627...
1627
    mov  ecx,[listy]
1627
    mov  ecx,[listy]
1628
    shl  ecx,16
1628
    shl  ecx,16
1629
    add  ecx,scrollbutsize-1
1629
    add  ecx,scrollbutsize-1
1630
    mov  eax,8
1630
    mov  eax,8
1631
    mov  edx,6+1000000000000000000000000000000b  ;spoke butt
1631
    mov  edx,6+1000000000000000000000000000000b  ;spoke butt
1632
    int  0x40
1632
    mcall
Line 1633... Line 1633...
1633
 
1633
 
1634
    inc  ecx
1634
    inc  ecx
1635
    mov  eax,13
1635
    mov  eax,13
1636
    mov  edx,[scrollbutcol] ;ffffff
1636
    mov  edx,[scrollbutcol] ;ffffff
Line 1637... Line 1637...
1637
    int  0x40
1637
    mcall
1638
 
1638
 
1639
; Draw image on up button
1639
; Draw image on up button
1640
    pushad
1640
    pushad
Line 1644... Line 1644...
1644
    shr  ecx,16
1644
    shr  ecx,16
1645
    add  edx,ecx
1645
    add  edx,ecx
1646
    mov  ecx,8*65536+9
1646
    mov  ecx,8*65536+9
1647
    mov  ebx,upsb+8
1647
    mov  ebx,upsb+8
1648
    mov  eax,7
1648
    mov  eax,7
1649
    int  0x40
1649
    mcall
1650
    popad
1650
    popad
Line 1651... Line 1651...
1651
 
1651
 
1652
 
1652
 
Line 1656... Line 1656...
1656
    sub  eax,scrollbutsize
1656
    sub  eax,scrollbutsize
1657
    shl  eax,16
1657
    shl  eax,16
1658
    add  ecx,eax
1658
    add  ecx,eax
Line 1659... Line 1659...
1659
 
1659
 
1660
    mov  eax,8
1660
    mov  eax,8
Line 1661... Line 1661...
1661
    int  0x40
1661
    mcall
1662
 
1662
 
1663
    inc  ecx
1663
    inc  ecx
1664
    mov  eax,13
1664
    mov  eax,13
Line 1665... Line 1665...
1665
    mov  edx,[scrollbutcol] ;ffffff
1665
    mov  edx,[scrollbutcol] ;ffffff
1666
    int  0x40
1666
    mcall
1667
 
1667
 
1668
; Draw image on down button
1668
; Draw image on down button
Line 1673... Line 1673...
1673
    shr  ecx,16
1673
    shr  ecx,16
1674
    add  edx,ecx
1674
    add  edx,ecx
1675
    mov  ecx,8*65536+9
1675
    mov  ecx,8*65536+9
1676
    mov  ebx,dnsb+8
1676
    mov  ebx,dnsb+8
1677
    mov  eax,7
1677
    mov  eax,7
1678
    int  0x40
1678
    mcall
1679
    popad
1679
    popad
Line 1680... Line 1680...
1680
 
1680
 
Line 1793... Line 1793...
1793
        jbe     @b
1793
        jbe     @b
1794
        dec     esi
1794
        dec     esi
1795
@@:
1795
@@:
1796
        push    eax
1796
        push    eax
1797
    mov  eax,4
1797
    mov  eax,4
1798
    int  0x40
1798
    mcall
1799
        cmp     byte [edx+esi], 0
1799
        cmp     byte [edx+esi], 0
1800
        jz      @f
1800
        jz      @f
1801
        pushad
1801
        pushad
1802
        mov     edx, more_char
1802
        mov     edx, more_char
1803
        mov     eax, esi
1803
        mov     eax, esi
1804
        imul    eax, 6*65536
1804
        imul    eax, 6*65536
1805
        add     ebx, eax
1805
        add     ebx, eax
1806
        mov     esi, 1
1806
        mov     esi, 1
1807
        mov     eax, 4
1807
        mov     eax, 4
1808
        int     0x40
1808
        mcall
1809
        popad
1809
        popad
1810
@@:
1810
@@:
1811
        pop     eax
1811
        pop     eax
1812
    pop  edx
1812
    pop  edx
1813
    push ebx edx
1813
    push ebx edx
Line 1815... Line 1815...
1815
        imul    eax, 6*65536
1815
        imul    eax, 6*65536
1816
        add     ebx, eax
1816
        add     ebx, eax
1817
    add  edx,4
1817
    add  edx,4
1818
    mov  esi,23
1818
    mov  esi,23
1819
    mov  eax,4
1819
    mov  eax,4
1820
    int  0x40
1820
    mcall
1821
    pop  edx ebx
1821
    pop  edx ebx
Line 1822... Line 1822...
1822
 
1822
 
1823
    pushad
1823
    pushad
1824
    cmp  [edx+15],dword 'Fvol' ;volume label
1824
    cmp  [edx+15],dword 'Fvol' ;volume label
Line 1909... Line 1909...
1909
    sub  edx,14*65536+1
1909
    sub  edx,14*65536+1
1910
    mov  ecx,12*65536+9
1910
    mov  ecx,12*65536+9
1911
;    mov  ebx,upsb+8
1911
;    mov  ebx,upsb+8
1912
    pop  ebx
1912
    pop  ebx
1913
    mov  eax,7
1913
    mov  eax,7
1914
    int  0x40
1914
    mcall
1915
no_out_ico:
1915
no_out_ico:
1916
    popad
1916
    popad
Line 1917... Line 1917...
1917
 
1917
 
Line 2006... Line 2006...
2006
    jmp  still
2006
    jmp  still
2007
no_flick:
2007
no_flick:
Line 2008... Line 2008...
2008
 
2008
 
2009
    mov  eax,12        ; function 12:tell os about windowdraw
2009
    mov  eax,12        ; function 12:tell os about windowdraw
2010
    mov  ebx,2		   ; 2, end of draw
2010
    mov  ebx,2		   ; 2, end of draw
Line 2011... Line 2011...
2011
    int  0x40
2011
    mcall
Line 2012... Line 2012...
2012
 
2012
 
Line 2038... Line 2038...
2038
 
2038
 
2039
drawmenu:
2039
drawmenu:
2040
    mov eax,4
2040
    mov eax,4
2041
    mov esi,12
2041
    mov esi,12
2042
menuloo:
2042
menuloo:
2043
    int 0x40
2043
    mcall
2044
    add ebx,11
2044
    add ebx,11
2045
    add edx,12
2045
    add edx,12
2046
    dec edi
2046
    dec edi
2047
    jnz menuloo
2047
    jnz menuloo
Line 2048... Line 2048...
2048
    ret
2048
    ret
2049
 
2049
 
2050
menubutton:
2050
menubutton:
2051
    mov  eax,8
2051
    mov  eax,8
2052
nextmenubut:
2052
nextmenubut:
2053
    int  0x40
2053
    mcall
2054
    add  ecx,11*65536
2054
    add  ecx,11*65536
2055
    inc  edx
2055
    inc  edx
2056
    dec  edi
2056
    dec  edi
Line 2154... Line 2154...
2154
;STEP 4 READ DATA FROM HD
2154
;STEP 4 READ DATA FROM HD
Line 2155... Line 2155...
2155
 
2155
 
2156
loorhd:
2156
loorhd:
2157
    mov  eax,70
2157
    mov  eax,70
2158
    mov  ebx,fileinfoblock
2158
    mov  ebx,fileinfoblock
Line 2159... Line 2159...
2159
    int  0x40
2159
    mcall
2160
 
2160
 
Line 2161... Line 2161...
2161
    cmp eax,6
2161
    cmp eax,6