Subversion Repositories Kolibri OS

Rev

Rev 3853 | Rev 4336 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
3853 GerdtR 1
proc MovingWnd
2
local MySlot:DWORD
3
        mcall	40,0	;SetMaskMessage 000b
4
 
5
        mcall	12,1	;RedrawWinBeg
6
 
7
        mcall   14
8
        xor     ebx,ebx
9
        xor     ecx,ecx
10
        mov     cx,ax
11
        shr     eax,16
12
        mov     cx,ax
13
        dec     ebx
14
        dec     ecx
15
        mcall   0,,,01000000h
16
        ;mcall   0,IMG_SIZE,IMG_SIZE,01000000h
17
        mcall	12,2	;RedrawWinEnd
18
 
19
 
20
        mov     eax,[SelIcon]
21
        call    DrawIconToArea
22
 
23
        mcall   37,4,IconArea,10100002h
24
        push    eax
25
        test    eax,eax
26
        jz      @f
27
        mov     ecx,eax
28
        mcall   37,5
29
 
30
     @@:
31
        mcall   9,RBProcInfo,-1    ;+30
32
        mcall   18,21,dword[RBProcInfo+30]
33
        mov     [MySlot],eax
34
 
35
  .messages:
36
        cmp     [MovingActiv],1
37
        jne     .close
38
        mcall   18,7
39
        cmp     eax,[MySlot]
40
        je      @f
41
        mcall   18,3,[MySlot]
42
     @@:
43
 
44
        mcall	5,1	;Yield
45
        jmp     .messages
46
 
47
.close:
48
        pop     ecx
49
        test    ecx,ecx
50
        jz      @f
51
        mcall   37,6
52
     @@:
53
 
54
 
55
        mcall   -1
56
 
57
endp
58
 
59
 
60
 
61
;eax = NumIcon
62
proc DrawIconToArea  ;предназначен для иконок размером = 32x32
63
        push    edi esi
64
 
65
        ;mov     eax,[NumIcon]
66
        mov     edi,[IconsOffs+eax*4]
67
        xor     al,al
68
        or      ecx,-1
69
        repne   scasb
70
        repne   scasb
71
        repne   scasb
72
        mov     al,[edi]
73
        cmp     al,'9'
74
        ja      .PathToIcon
75
        cmp     al,'/'
76
        jne     .GetIconInd
77
   .PathToIcon:
78
        mov     al,30h           ;заглушка!!!!!!!!!!!!!
79
        mov     byte[edi+1],0
80
   .GetIconInd:
81
;int3
82
        sub     al,30h
83
        cmp     byte[edi+1],0
84
        je      @f
85
        shl     eax,1
86
        lea     eax,[eax*4+eax]
87
        xor     edx,edx
88
        mov     dl,[edi+1]
89
        sub     dl,30h
90
        add     eax,edx
91
     @@:             ;eax=num icon
92
        cmp     eax,[icon_count]
93
        jb      @f
94
        xor     eax,eax
95
     @@:
96
        test    eax,eax
97
        je      .DIA
98
        mov     ecx,eax
99
        xor     eax,eax
100
      @@:
101
        add     eax,32*32*4;IMG_SIZE*IMG_SIZE*4
102
        loop    @b
103
     .DIA:
104
        mov     esi,eax
105
        add     esi,[raw_pointer]
106
        add     esi,44
107
 
108
        mov     edi,IconArea;+((IMAGE_TOP_Y*ICON_SIZE)+((ICON_SIZE-IMG_SIZE)/2))*4
109
;int3
110
        mov     eax,32;IMG_SIZE
111
        mov     edx,eax
112
      @@:
113
        mov     ecx,eax
114
        rep     movsd
115
     ;   add     edi,32*4
116
        dec     edx
117
        jnz     @b
118
 
119
        pop     esi edi
120
        ret
121
endp