Subversion Repositories Kolibri OS

Rev

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

Rev 2439 Rev 2465
Line 1... Line 1...
1
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
1
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2
;;                                                              ;;
2
;;                                                              ;;
3
;; Copyright (C) KolibriOS team 2004-2010. All rights reserved. ;;
3
;; Copyright (C) KolibriOS team 2004-2012. All rights reserved. ;;
4
;; Copyright (C) MenuetOS 2000-2004 Ville Mikael Turjanmaa      ;;
4
;; Copyright (C) MenuetOS 2000-2004 Ville Mikael Turjanmaa      ;;
5
;; Distributed under terms of the GNU General Public License    ;;
5
;; Distributed under terms of the GNU General Public License    ;;
6
;;                                                              ;;
6
;;                                                              ;;
7
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
7
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 8... Line 8...
8
 
8
 
Line 9... Line 9...
9
$Revision: 2439 $
9
$Revision: 2465 $
10
 
10
 
11
;==============================================================================
11
;==============================================================================
Line 58... Line 58...
58
        dec     al
58
        dec     al
59
        jnz     @f
59
        jnz     @f
Line 60... Line 60...
60
 
60
 
61
        ; type II - only reserve area, no draw
61
        ; type II - only reserve area, no draw
62
;        call    sys_window_mouse
62
;        call    sys_window_mouse
-
 
63
;        call    [draw_pointer]
63
        call    [draw_pointer]
64
        call    __sys_draw_pointer
64
        jmp     .exit
65
        jmp     .exit
65
;--------------------------------------
66
;--------------------------------------
66
align 4
67
align 4
67
@@:
68
@@:
Line 679... Line 680...
679
        rol     ebx, 16
680
        rol     ebx, 16
680
        pop     bx
681
        pop     bx
681
        test    ecx, 1 shl 25
682
        test    ecx, 1 shl 25
682
        jnz     @f
683
        jnz     @f
683
        sub     ecx, 1 shl 25
684
        sub     ecx, 1 shl 25
684
        call    [draw_line]
685
;        call    [draw_line]
-
 
686
        call    __sys_draw_line
685
;--------------------------------------
687
;--------------------------------------
686
align 4
688
align 4
687
@@:
689
@@:
688
        ; draw bottom border
690
        ; draw bottom border
689
        mov     ebx, [esp - 2]
691
        mov     ebx, [esp - 2]
690
        pop     bx
692
        pop     bx
691
        call    [draw_line]
693
;        call    [draw_line]
-
 
694
        call    __sys_draw_line
Line 692... Line 695...
692
 
695
 
693
        pop     ebx
696
        pop     ebx
Line 694... Line 697...
694
        add     ebx, 1 * 65536 - 1
697
        add     ebx, 1 * 65536 - 1
695
 
698
 
696
        ; draw left border
699
        ; draw left border
697
        rol     eax, 16
700
        rol     eax, 16
698
        push    eax
701
        push    eax
699
        rol     eax, 16
702
        rol     eax, 16
-
 
703
        pop     ax
Line 700... Line 704...
700
        pop     ax
704
;        call    [draw_line]
701
        call    [draw_line]
705
        call    __sys_draw_line
702
 
706
 
703
        ; draw right border
707
        ; draw right border
-
 
708
        mov     eax, [esp - 2]
Line 704... Line 709...
704
        mov     eax, [esp - 2]
709
        pop     ax
705
        pop     ax
710
;        call    [draw_line]
706
        call    [draw_line]
711
        call    __sys_draw_line
707
 
712
 
Line 758... Line 763...
758
        mov     [esi + WDATA.cl_titlebar], ecx
763
        mov     [esi + WDATA.cl_titlebar], ecx
759
;--------------------------------------
764
;--------------------------------------
760
align 4
765
align 4
761
@@:
766
@@:
762
        and     ecx, 0x00ffffff
767
        and     ecx, 0x00ffffff
763
        call    [draw_line]
768
;        call    [draw_line]
-
 
769
        call    __sys_draw_line
764
        inc     edx
770
        inc     edx
765
        cmp     edx, [esp]
771
        cmp     edx, [esp]
766
        jb      .next_line
772
        jb      .next_line
Line 767... Line 773...
767
 
773
 
Line 811... Line 817...
811
        ; okay, let's draw it
817
        ; okay, let's draw it
812
        mov     eax, 1
818
        mov     eax, 1
813
        mov     ebx, 21
819
        mov     ebx, 21
814
        mov     ecx, [esi + WDATA.box.width]
820
        mov     ecx, [esi + WDATA.box.width]
815
        mov     edx, [esi + WDATA.box.height]
821
        mov     edx, [esi + WDATA.box.height]
816
        call    [drawbar]
822
;        call    [drawbar]
-
 
823
        call    vesa20_drawbar
817
;--------------------------------------
824
;--------------------------------------
818
align 4
825
align 4
819
.exit:
826
.exit:
820
        popad
827
        popad
821
        ret
828
        ret
Line 869... Line 876...
869
;--------------------------------------
876
;--------------------------------------
870
align 4
877
align 4
871
@@:
878
@@:
872
        mov     [esi + WDATA.cl_titlebar], ecx
879
        mov     [esi + WDATA.cl_titlebar], ecx
873
        and     ecx, 0x00ffffff
880
        and     ecx, 0x00ffffff
874
        call    [draw_line]
881
;        call    [draw_line]
-
 
882
        call    __sys_draw_line
875
        inc     edx
883
        inc     edx
876
        cmp     edx, [esp]
884
        cmp     edx, [esp]
877
        jb      .next_line
885
        jb      .next_line
Line 878... Line 886...
878
 
886
 
Line 898... Line 906...
898
        add     bx, word[edx + WDATA.box.height]
906
        add     bx, word[edx + WDATA.box.height]
Line 899... Line 907...
899
 
907
 
900
        mov     esi, [edx + WDATA.cl_frames]
908
        mov     esi, [edx + WDATA.cl_frames]
901
        shr     esi, 1
909
        shr     esi, 1
902
        and     esi, 0x007f7f7f
-
 
903
        or      esi, 1 shl 25; 0x02000000 used for draw_rectangle without top line
-
 
904
        ror     ebx, 16
-
 
905
        add     ebx, [_skinh]
-
 
906
        sub     bx, 1
-
 
907
        rol     ebx, 16
910
        and     esi, 0x007f7f7f
Line 908... Line 911...
908
        call    draw_rectangle
911
        call    draw_rectangle
909
 
912
 
910
        push    esi
913
        push    esi
911
        mov     ecx, 3
-
 
912
        mov     esi, [edx + WDATA.cl_frames]
914
        mov     ecx, 3
913
        or      esi, 1 shl 25; 0x02000000 used for draw_rectangle without top line
915
        mov     esi, [edx + WDATA.cl_frames]
914
;--------------------------------------
916
;--------------------------------------
915
align 4
917
align 4
916
.next_frame:
918
.next_frame:
917
        add     eax, 1 * 65536 - 1
919
        add     eax, 1 * 65536 - 1
918
        add     ebx, 0 * 65536 - 1
920
        add     ebx, 1 * 65536 - 1
919
        call    draw_rectangle
921
        call    draw_rectangle
Line 920... Line 922...
920
        dec     ecx
922
        dec     ecx
921
        jnz     .next_frame
923
        jnz     .next_frame
922
 
924
 
923
        pop     esi
925
        pop     esi
Line 924... Line 926...
924
        add     eax, 1 * 65536 - 1
926
        add     eax, 1 * 65536 - 1
Line 925... Line 927...
925
        add     ebx, 0 * 65536 - 1
927
        add     ebx, 1 * 65536 - 1
Line 949... Line 951...
949
        mov     ebx, 20
951
        mov     ebx, 20
950
        mov     ecx, [esi + WDATA.box.width]
952
        mov     ecx, [esi + WDATA.box.width]
951
        mov     edx, [esi + WDATA.box.height]
953
        mov     edx, [esi + WDATA.box.height]
952
        sub     ecx, 4
954
        sub     ecx, 4
953
        sub     edx, 4
955
        sub     edx, 4
954
        call    [drawbar]
956
;        call    [drawbar]
-
 
957
        call    vesa20_drawbar
955
;--------------------------------------
958
;--------------------------------------
956
align 4
959
align 4
957
.exit:
960
.exit:
958
        popad
961
        popad
959
        ret
962
        ret
Line 1828... Line 1831...
1828
        inc     ecx
1831
        inc     ecx
1829
        inc     edx
1832
        inc     edx
Line 1830... Line 1833...
1830
 
1833
 
1831
        ; get WinMap start
1834
        ; get WinMap start
1832
        push    esi
1835
        push    esi
1833
        mov     edi, [Screen_Max_X]
1836
;        mov     edi, [Screen_Max_X]
1834
        inc     edi
1837
;        inc     edi
-
 
1838
;        mov     esi, edi
-
 
1839
        mov     esi, [Screen_Max_X]
1835
        mov     esi, edi
1840
        inc     esi
-
 
1841
;        imul    edi, ebx
-
 
1842
        mov     edi, [d_width_calc_area + ebx*4]
1836
        imul    edi, ebx
1843
 
1837
        add     edi, eax
1844
        add     edi, eax
1838
        add     edi, [_WinMapAddress]
1845
        add     edi, [_WinMapAddress]
1839
        pop     eax
1846
        pop     eax
1840
        mov     ah, al
1847
        mov     ah, al
Line 1872... Line 1879...
1872
 
1879
 
Line 1873... Line 1880...
1873
        push    [edi + APPDATA.wnd_shape_scale]  ; push scale first -> for loop
1880
        push    [edi + APPDATA.wnd_shape_scale]  ; push scale first -> for loop
1874
 
1881
 
1875
        ; get WinMap start  -> ebp
1882
        ; get WinMap start  -> ebp
1876
        push    eax
1883
        push    eax
1877
        mov     eax, [Screen_Max_X] ; screen_sx
1884
;        mov     eax, [Screen_Max_X] ; screen_sx
-
 
1885
;        inc     eax
-
 
1886
;        imul    eax, ebx
1878
        inc     eax
1887
        mov     eax, [d_width_calc_area + ebx*4]
1879
        imul    eax, ebx
1888
 
1880
        add     eax, [esp]
1889
        add     eax, [esp]
Line 1881... Line 1890...
1881
        add     eax, [_WinMapAddress]
1890
        add     eax, [_WinMapAddress]
Line 2306... Line 2315...
2306
        xor     edi, edi
2315
        xor     edi, edi
2307
        call    dtext_asciiz_esi
2316
        call    dtext_asciiz_esi
2308
;--------------------------------------
2317
;--------------------------------------
2309
align 4
2318
align 4
2310
.exit:
2319
.exit:
2311
        call    [draw_pointer]
2320
;        call    [draw_pointer]
-
 
2321
        call    __sys_draw_pointer
2312
        ret
2322
        ret
2313
;------------------------------------------------------------------------------
2323
;------------------------------------------------------------------------------
2314
align 4
2324
align 4
2315
;------------------------------------------------------------------------------
2325
;------------------------------------------------------------------------------
2316
window._.draw_negative_box: ;//////////////////////////////////////////////////
2326
window._.draw_negative_box: ;//////////////////////////////////////////////////