Subversion Repositories Kolibri OS

Rev

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

Rev 7134 Rev 7649
Line 24... Line 24...
24
; +00048300:00004000 - memory for OS (read/write buffer)
24
; +00048300:00004000 - memory for OS (read/write buffer)
25
; +0004C300:FFFB3CFF - dinamically allocated for copy, view, edit etc.
25
; +0004C300:FFFB3CFF - dinamically allocated for copy, view, edit etc.
26
;
26
;
27
 
27
 
Line 28... Line -...
28
include 'lang.inc'
-
 
29
include 'macros.inc'
28
include 'macros.inc'
30
include 'menuet.inc'
29
include 'menuet.inc'
31
include 'mfar.inc'
30
include 'mfar.inc'
Line 32... Line 31...
32
 
31
 
Line 288... Line 287...
288
;------------------------------------------------------------------------------
287
;------------------------------------------------------------------------------
289
;///// DRAW WINDOW ////////////////////////////////////////////////////////////
288
;///// DRAW WINDOW ////////////////////////////////////////////////////////////
290
;------------------------------------------------------------------------------
289
;------------------------------------------------------------------------------
Line 291... Line 290...
291
 
290
 
292
__func draw_window
291
func draw_window
Line 293... Line 292...
293
        mcall   MF_WINPROPS,WP_GETSYSCLRS,sc,sizeof.system_colors
292
        mcall   MF_WINPROPS,WP_GETSYSCLRS,sc,sizeof.system_colors
294
 
293
 
295
        mcall   MF_WNDDRAW,WD_BEGINDRAW
294
        mcall   MF_WNDDRAW,WD_BEGINDRAW
-
 
295
        mov     edx,[fc.background]
296
        mov     edx,[fc.background]
296
        or      edx,$14000000
297
        or      edx,WS_SKINNED
-
 
Line 298... Line 297...
298
        mcall2  MF_DEFWINDOW,90,oX+tW*80+4,45,oY+tH*25+4
297
		mov     edi,caption
299
        mcall1  MF_DRAWTEXT,8,8,[sc.grab_text],caption,caption.size
298
        mcall2  MF_DEFWINDOW,90,oX+tW*80+4,45,oY+tH*25+4
300
 
299
 
301
        mmov    esi,oX+2,oX+tW*39+2
300
        mmov    esi,oX+2,oX+tW*39+2
Line 338... Line 337...
338
;------------------------------------------------------------------------------
337
;------------------------------------------------------------------------------
339
;//////////////////////////////////////////////////////////////////////////////
338
;//////////////////////////////////////////////////////////////////////////////
340
;------------------------------------------------------------------------------
339
;------------------------------------------------------------------------------
Line 341... Line 340...
341
 
340
 
342
__func draw_window_full
341
func draw_window_full
343
        call    draw_window
342
        call    draw_window
344
        mov     edx,1
343
        mov     edx,1
345
        call    get_files_data
344
        call    get_files_data
346
        mov     al,1
345
        mov     al,1
Line 358... Line 357...
358
 
357
 
Line 359... Line 358...
359
align 4
358
align 4
360
len dd ?
359
len dd ?
Line 361... Line 360...
361
 
360
 
362
__func get_normal_path
361
func get_normal_path
363
        pusha
362
        pusha
364
        mov     ecx,5
363
        mov     ecx,5
365
        rep     movsb
364
        rep     movsb
366
        dec     esi
365
        dec     esi
Line 392... Line 391...
392
 
391
 
Line 393... Line 392...
393
; EAX = length needed
392
; EAX = length needed
394
; ECX = current length
393
; ECX = current length
395
; EDI = path string
394
; EDI = path string
396
__func get_path_ellipses
395
func get_path_ellipses
397
        cmp     ecx,eax
396
        cmp     ecx,eax
398
        jbe     @f
397
        jbe     @f
399
        pushad
398
        pushad
400
        lea     esi,[edi+ecx+3+6]       ; ... + /??/?/
399
        lea     esi,[edi+ecx+3+6]       ; ... + /??/?/
401
        sub     esi,eax
400
        sub     esi,eax
Line 414... Line 413...
414
;------------------------------------------------------------------------------
413
;------------------------------------------------------------------------------
415
;//////////////////////////////////////////////////////////////////////////////
414
;//////////////////////////////////////////////////////////////////////////////
416
;------------------------------------------------------------------------------
415
;------------------------------------------------------------------------------
Line 417... Line 416...
417
 
416
 
418
__func draw_path
417
func draw_path
419
        pushad
418
        pushad
420
        cmp     [active_panel],0
419
        cmp     [active_panel],0
421
        jne    ._00
420
        jne    ._00
422
        mov     esi,f_path0
421
        mov     esi,f_path0
Line 442... Line 441...
442
;//////////////////////////////////////////////////////////////////////////////
441
;//////////////////////////////////////////////////////////////////////////////
443
;------------------------------------------------------------------------------
442
;------------------------------------------------------------------------------
444
 
443
 
Line 445... Line 444...
445
; AL = panel
444
; AL = panel
446
__func draw_files
445
func draw_files
447
        push    eax
446
        push    eax
448
        mmov    ecx,oY+tH*2-1,tH*FPC
447
        mmov    ecx,oY+tH*2-1,tH*FPC
449
        mov     edx,[fc.background]
448
        mov     edx,[fc.background]
450
        cmp     al,0
449
        cmp     al,0
451
        mov     eax,MF_FILLRECT
450
        mov     eax,MF_FILLRECT
Line 517... Line 516...
517
;------------------------------------------------------------------------------
516
;------------------------------------------------------------------------------
518
;//////////////////////////////////////////////////////////////////////////////
517
;//////////////////////////////////////////////////////////////////////////////
519
;------------------------------------------------------------------------------
518
;------------------------------------------------------------------------------
Line 520... Line 519...
520
 
519
 
521
__func draw_bottom_keys
520
func draw_bottom_keys
522
        pushad
521
        pushad
523
        mcall2  MF_FILLRECT,oX-1,tW*80+1,oY+tH*24-1,tH+1,[fc.pathbg]
522
        mcall2  MF_FILLRECT,oX-1,tW*80+1,oY+tH*24-1,tH+1,[fc.pathbg]
524
        dec     ecx
523
        dec     ecx
525
        mcall1  ,oX+tW-1,tW*6+1,,[fc.keysbg]
524
        mcall1  ,oX+tW-1,tW*6+1,,[fc.keysbg]
Line 549... Line 548...
549
 
548
 
Line 550... Line 549...
550
; ESI = X1*65536+X2
549
; ESI = X1*65536+X2
551
; EDI = Y1*65536+Y2
550
; EDI = Y1*65536+Y2
552
; EDX = color
551
; EDX = color
553
__func draw_frame
552
func draw_frame
554
        mov     ecx,edi
553
        mov     ecx,edi
555
        mov     ebx,edi
554
        mov     ebx,edi
556
        shr     ebx,16
555
        shr     ebx,16
557
        mov     cx,bx
556
        mov     cx,bx
558
        mcall   MF_DRAWLINE,esi
557
        mcall   MF_DRAWLINE,esi
Line 576... Line 575...
576
;//////////////////////////////////////////////////////////////////////////////
575
;//////////////////////////////////////////////////////////////////////////////
577
;------------------------------------------------------------------------------
576
;------------------------------------------------------------------------------
578
 
577
 
Line 579... Line 578...
579
; EDX = pointer to file data
578
; EDX = pointer to file data
580
__func get_file_color
579
func get_file_color
581
        push    esi
580
        push    esi
582
        mov     cl,[edx+11]
581
        mov     cl,[edx+11]
583
        test    cl,(FA_HIDDEN or FA_SYSTEM)
582
        test    cl,(FA_HIDDEN or FA_SYSTEM)
584
        jz      @f
583
        jz      @f
585
        mov     ecx,[fc.system]
584
        mov     ecx,[fc.system]
Line 630... Line 629...
630
;//////////////////////////////////////////////////////////////////////////////
629
;//////////////////////////////////////////////////////////////////////////////
631
;------------------------------------------------------------------------------
630
;------------------------------------------------------------------------------
632
 
631
 
Line 633... Line 632...
633
; EDI = color
632
; EDI = color
634
__func draw_sel
633
func draw_sel
635
        pushad
634
        pushad
636
        cmp     [active_panel],0
635
        cmp     [active_panel],0
637
        jne    ._00
636
        jne    ._00
638
        mov     eax,[d_lpos]
637
        mov     eax,[d_lpos]
639
        sub     eax,[d_ltop]
638
        sub     eax,[d_ltop]
Line 713... Line 712...
713
;//////////////////////////////////////////////////////////////////////////////
712
;//////////////////////////////////////////////////////////////////////////////
714
;------------------------------------------------------------------------------
713
;------------------------------------------------------------------------------
715
 
714
 
Line 716... Line 715...
716
; AL = panel
715
; AL = panel
717
__func draw_file_info
716
func draw_file_info
718
        push    eax
717
        push    eax
719
        mmov    ecx,oY+tH*21,tH
718
        mmov    ecx,oY+tH*21,tH
720
        mov     edx,[fc.background]
719
        mov     edx,[fc.background]
721
        cmp     al,0
720
        cmp     al,0
722
        mov     eax,MF_FILLRECT
721
        mov     eax,MF_FILLRECT
Line 788... Line 787...
788
;------------------------------------------------------------------------------
787
;------------------------------------------------------------------------------
789
;//////////////////////////////////////////////////////////////////////////////
788
;//////////////////////////////////////////////////////////////////////////////
790
;------------------------------------------------------------------------------
789
;------------------------------------------------------------------------------
Line 791... Line 790...
791
 
790
 
792
__func get_file_name
791
func get_file_name
793
        pushad
792
        pushad
794
        mov     eax,[esi+0]
793
        mov     eax,[esi+0]
795
        mov     [f_name+0],eax
794
        mov     [f_name+0],eax
796
        mov     eax,[esi+4]
795
        mov     eax,[esi+4]
Line 808... Line 807...
808
;//////////////////////////////////////////////////////////////////////////////
807
;//////////////////////////////////////////////////////////////////////////////
809
;------------------------------------------------------------------------------
808
;------------------------------------------------------------------------------
810
 
809
 
Line 811... Line 810...
811
; ESI = pointer to file data
810
; ESI = pointer to file data
812
__func get_file_info
811
func get_file_info
813
        pushad
812
        pushad
814
        mov     eax,[esi+12]
813
        mov     eax,[esi+12]
815
        mov     dword[f_info],FS_READ
814
        mov     dword[f_info],FS_READ
816
        mov     [f_info+4],eax
815
        mov     [f_info+4],eax
817
        mov     dword[f_info+12],read_area
816
        mov     dword[f_info+12],read_area
Line 886... Line 885...
886
;//////////////////////////////////////////////////////////////////////////////
885
;//////////////////////////////////////////////////////////////////////////////
887
;------------------------------------------------------------------------------
886
;------------------------------------------------------------------------------
888
 
887
 
Line 889... Line 888...
889
; DL = panel
888
; DL = panel
890
__func get_files_data
889
func get_files_data
891
        pushad
890
        pushad
892
        mov     [d_tcnt],0
891
        mov     [d_tcnt],0
893
        mov     [d_ttsz],0
892
        mov     [d_ttsz],0
894
        cmp     dl,0
893
        cmp     dl,0
895
        jne    ._00
894
        jne    ._00
Line 983... Line 982...
983
;------------------------------------------------------------------------------
982
;------------------------------------------------------------------------------
984
;//////////////////////////////////////////////////////////////////////////////
983
;//////////////////////////////////////////////////////////////////////////////
985
;------------------------------------------------------------------------------
984
;------------------------------------------------------------------------------
Line 986... Line 985...
986
 
985
 
987
__func execute_current_file
986
func execute_current_file
988
        pushad
987
        pushad
989
        cmp     [active_panel],0
988
        cmp     [active_panel],0
990
        jne    ._00
989
        jne    ._00
991
        mov     esi,[d_lpos]
990
        mov     esi,[d_lpos]
Line 1078... Line 1077...
1078
;------------------------------------------------------------------------------
1077
;------------------------------------------------------------------------------
1079
;//////////////////////////////////////////////////////////////////////////////
1078
;//////////////////////////////////////////////////////////////////////////////
1080
;------------------------------------------------------------------------------
1079
;------------------------------------------------------------------------------
Line 1081... Line 1080...
1081
 
1080
 
1082
__func delete_current_file
1081
func delete_current_file
1083
        pushad
1082
        pushad
1084
        popad
1083
        popad
1085
        ret
1084
        ret
Line 1122... Line 1121...
1122
 dd ?
1121
 dd ?
1123
 dd read_area
1122
 dd read_area
1124
 dd MEM_FOR_OS
1123
 dd MEM_FOR_OS
1125
.path:
1124
.path:
1126
 rb 200
1125
 rb 255
1127
 
1126
 
Line 1128... Line 1127...
1128
f_plen0 dd 5
1127
f_plen0 dd 5
1129
f_plen1 dd 5
1128
f_plen1 dd 5
Line 1130... Line 1129...
1130
 
1129
 
1131
sz caption,'MFAR : PRE-ALPHA-8.1'
1130
sz caption,'MFAR : PRE-ALPHA-8.1',0
1132
sz fcfile,'MFAR    DAT'
1131
sz fcfile,'MFAR    DAT'
1133
sz p_hd,'/HD/1',0
1132
sz p_hd,'/HD/1',0
1134
sz p_rd,'/RD/1',0
1133
sz p_rd,'/RD/1',0
1135
ext0:
1134
ext0: