Subversion Repositories Kolibri OS

Rev

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

Rev 4036 Rev 4082
Line 1... Line -...
1
if lang eq ru
-
 
2
MinRMenuW equ 18*6+10
-
 
3
else
-
 
4
MinRMenuW equ 15*6+10
-
 
5
end if
-
 
Line 6... Line 1...
6
 
1
;idbRRedrawFon equ 100
7
idbRRedrawFon equ 100
2
;idbRAlign    equ 101
8
idbRAlign    equ 101
3
;idbRFixIcons equ 102
9
idbRFixIcons equ 102
4
;idbRAdd      equ 103
10
idbRAdd      equ 103
5
;idbRDel      equ 104
11
idbRDel      equ 104
6
;idbRProp     equ 105
Line 12... Line 7...
12
idbRProp     equ 105
7
 
-
 
8
DELTA_COLOR  equ 70
-
 
9
COLOR_SEL_BUT equ 00F7092Dh
Line 13... Line 10...
13
 
10
MAX_USER_BUTTONS equ 30
14
DELTA_COLOR  equ 70
11
 
-
 
12
;---- thread for rbutton -----------------------------------------------------------------------
-
 
13
RButtonWin:
-
 
14
       if lang eq ru
-
 
15
        mov     [MinRMenuW],18*6+10
-
 
16
       else
-
 
17
        mov     [MinRMenuW],15*6+10
-
 
18
       end if
-
 
19
 
15
 
20
 
16
;---- thread for rbutton -----------------------------------------------------------------------
21
 
Line 17... Line 22...
17
RButtonWin:
22
        mcall   40,100101b      ;SetMaskMessage 100101b
18
        mcall   40,100101b      ;SetMaskMessage 100101b
23
        mcall   48,3,sc,40
Line 55... Line 60...
55
 
60
 
56
 
61
        stdcall GetNumIcon,[MouseX],[MouseY],-1
Line -... Line 62...
-
 
62
        mov     [SelIcon],eax
-
 
63
 
-
 
64
                      ;¢ëáâ ¢«ï¥¬ ¯¥à¢®­ ç «ì­ë¥ §­ ç¥­¨ï
57
        stdcall GetNumIcon,[MouseX],[MouseY],-1
65
        m2m     [RMenuW],[MinRMenuW]
-
 
66
 
-
 
67
        cmp     [SelIcon],-1
58
        mov     [SelIcon],eax
68
        jne     .RBW1
-
 
69
;----------- ¥á«¨ ª«¨ª ­¥ ¯® ¨ª®­ª¥ ------------------------------------------------
59
 
70
        mov     [NumMenuButt],0
60
        mov     [NumUserButt],0
71
 
61
        mov     [RMenuW],0
72
        mcall   70,fiIni
62
        mcall   70,fiIni
73
        mcall   68,12,dword[bufIni+32]  ;¢ë¤¥«ï¥¬ ¯ ¬ïâì ¤«ï ¯®¤¯¨á¥© ¨ ¯ã⥩ § ¯ã᪠
Line -... Line 74...
-
 
74
        mov     [RBMenuCP],eax          ;GetUserBut ¡¥àñâ ®âá ¯¥à¢®­ ç «ì­ë© 㪠§ â¥«ì ­  ¯ ¬ïâì
-
 
75
        stdcall [ini_enum_keys],IconIni,secRButt,GetUserBut
-
 
76
 
-
 
77
        mov     ebx,[NumMenuButt]
-
 
78
        add     [NumMenuButt],4
-
 
79
 
-
 
80
        mov     [RBMenuCP+ebx*8],RMenuRedrawFon
-
 
81
        mov     [RBMenuCP+ebx*8+8],RMenuAlign
-
 
82
        cmp     [bFixIcons],1
-
 
83
        je      @f
-
 
84
        mov     [RBMenuCP+ebx*8+16],RMenuOffMoving
-
 
85
        jmp     .RBW11
-
 
86
    @@:
-
 
87
        mov     [RBMenuCP+ebx*8+16],RMenuOnMoving
-
 
88
    .RBW11:
-
 
89
 
-
 
90
        mov     [RBMenuCP+ebx*8+24],RMenuAdd
-
 
91
 
-
 
92
        mov     [RBMenuCP+ebx*8+4],0
-
 
93
        mov     [RBMenuCP+ebx*8+8+4],0
-
 
94
        mov     [RBMenuCP+ebx*8+16+4],0
-
 
95
        mov     [RBMenuCP+ebx*8+24+4],0
-
 
96
 
-
 
97
 
-
 
98
        jmp     .RBW2
-
 
99
;----------- ¥á«¨ ª«¨ª ¯® ¨ª®­ª¥ ------------------------------------------------
-
 
100
.RBW1:
-
 
101
        xor     ebx,ebx
-
 
102
        mov     [NumMenuButt],5
-
 
103
 
-
 
104
        mov     [RBMenuCP+ebx*8],RMenuRedrawFon
-
 
105
        mov     [RBMenuCP+ebx*8+8],RMenuAlign
-
 
106
        cmp     [bFixIcons],1
-
 
107
        je      @f
-
 
108
        mov     [RBMenuCP+ebx*8+16],RMenuOffMoving
-
 
109
        jmp     .RBW21
-
 
110
    @@:
-
 
111
        mov     [RBMenuCP+ebx*8+16],RMenuOnMoving
-
 
112
    .RBW21:
-
 
113
        mov     [RBMenuCP+ebx*8+24],RMenuDel
-
 
114
        mov     [RBMenuCP+ebx*8+32],RMenuProp
-
 
115
 
-
 
116
        mov     [RBMenuCP+ebx*8+4],0
-
 
117
        mov     [RBMenuCP+ebx*8+8+4],0
-
 
118
        mov     [RBMenuCP+ebx*8+16+4],0
-
 
119
        mov     [RBMenuCP+ebx*8+24+4],0
-
 
120
        mov     [RBMenuCP+ebx*8+32+4],0
-
 
121
 
63
        mcall   68,12,dword[bufIni+32]
122
;-------------------------------------------------------------------------------
64
        mov     [RBUser],eax
123
.RBW2:
65
        stdcall [ini_enum_keys],IconIni,secRButt,GetUserBut
-
 
66
 
124
 
67
        cmp     [SelIcon],-1
125
        cmp     [SelIcon],-1
68
        jne     @f
126
        jne     @f
69
        mov     [RMenuH],16*4
127
        mov     eax,[NumMenuButt]
70
        mov     eax,[NumUserButt]
128
        shl     eax,4
71
        shl     eax,4
129
        mov     [RMenuH],ax
72
        add     [RMenuH],ax
130
        jmp     .rbw1
Line -... Line 131...
-
 
131
      @@:
-
 
132
        mov     [RMenuH],16*5
-
 
133
    .rbw1:
73
        jmp     .rbw1
134
 
74
      @@:
135
        add     [RMenuW],3              ;­  à ¬ªã
75
        mov     [RMenuH],16*5
136
        add     [RMenuH],3              ;­  à ¬ªã
76
    .rbw1:
137
 
77
 
138
RBWRedraw:
-
 
139
        mcall   12,1    ;RedrawWinBeg
78
RBWRedraw:
140
        mov     ebx,[MouseX]
79
        mcall   12,1    ;RedrawWinBeg
141
        shl     ebx,16
80
        mov     ebx,[MouseX]
142
        mov     bx,[RMenuW]
-
 
143
 
81
        shl     ebx,16
144
        mov     ecx,[MouseY]
82
        mov     bx,[RMenuW]
145
        shl     ecx,16
83
        mov     ecx,[MouseY]
146
        mov     cx,[RMenuH]
84
        shl     ecx,16
147
 
Line 92... Line 155...
92
        inc     bx
155
        and     ecx,0FFFFh
93
        and     ecx,0FFFFh
156
        inc     cx
94
        inc     cx
157
        mcall   13,,,[sc.work]
95
        mcall   13,,,[sc.work]
158
 
Line 96... Line 159...
96
 
159
       ;----------- ®¯à¥¤¥«ï¥¬ ¨ à¨á㥬 ª­®¯ª¨
97
        cmp     [SelIcon],-1       ;¥á«¨ ª«¨ª ¯® ¨ª®­ª¥, â® ¯ã­ªâë ¯®«ì§®¢ â¥«ï ­¥ ­ã¦­ë
-
 
98
        jne     .NoDrawUserBut
-
 
99
       ;-----------
160
        mov     ecx,[NumMenuButt]
100
        mov     ecx,[NumUserButt]
161
  .DrawUB:
101
  .DrawUB:
162
        push    ecx
Line 102... Line 163...
102
        push    ecx
163
 
103
 
164
        mov     eax,[NumMenuButt]
104
        mov     eax,[NumUserButt]
165
        sub     eax,ecx
105
        sub     eax,ecx
166
        mov     edx,eax      ;button ID = ®â 0 ¤® NumMenuButt
106
        mov     edx,eax      ;button ID
167
        or      edx,60000000h
107
        or      edx,60000000h
168
        shl     eax,4+16          ;*16*10000h
108
        shl     eax,4+16          ;*16*10000h
169
        mov     ecx,eax
Line 109... Line 170...
109
        mov     ecx,eax
170
        mov     cx,16
110
        mov     cx,16
171
 
111
 
172
        xor     ebx,ebx
112
        xor     ebx,ebx
173
        mov     bx,[RMenuW]
Line 113... Line 174...
113
        mov     bx,[RMenuW]
174
        mov     esi,[sc.work]
114
        mov     esi,[sc.work]
175
        mcall   8                       ;®¯à¥¤¥«¨«¨
115
        mcall   8                       ;®¯à¥¤¥«¨«¨
176
 
116
 
177
        mov     ebx,70000h
Line 117... Line 178...
117
        mov     ebx,50000h
178
        shr     ecx,16
Line 118... Line 179...
118
        shr     ecx,16
179
        mov     bx,cx
119
        mov     bx,cx
180
        add     bx,7
120
        add     bx,5
181
 
121
 
182
        mov     ecx,80000000h
Line 122... Line 183...
122
        mov     ecx,80000000h
183
 
123
 
184
        mov     eax,[NumMenuButt]
-
 
185
        sub     eax,[esp]
Line 124... Line -...
124
        mov     eax,[NumUserButt]
-
 
125
        sub     eax,[esp]
-
 
126
        mov     edx,[RBUser+eax*8]
186
        mov     edx,[RBMenuCP+eax*8]
127
        mcall   4                      ;¯®¤¯¨á «¨
187
        mcall   4                      ;¯®¤¯¨á «¨
128
 
188
 
-
 
189
        pop     ecx
-
 
190
        loop    .DrawUB
Line 129... Line -...
129
        pop     ecx
-
 
130
        loop    .DrawUB
-
 
131
 
-
 
132
       ;-----------
191
  ;---------------
133
.NoDrawUserBut:
-
 
134
                                        ;®¯à¥¤¥«¥­¨¥ ª­®¯®ª ¤«ï ¨ª®­®ª
192
 
135
        xor     ebx,ebx
193
; ®¡à ¬«ïî騩 ¯àאַ㣮«ì­¨ª
136
        mov     bx,[RMenuW]
194
        xor     ebx,ebx            ;¢¥àå
137
 
195
        mov     bx,[RMenuW]
138
        xor     eax,eax
-
 
139
        cmp     [SelIcon],-1
-
 
140
        jne     @f
-
 
141
        mov     eax,[NumUserButt]
-
 
142
     @@:
-
 
143
        shl     eax,4
-
 
144
        mov     cx,ax
-
 
145
        shl     ecx,16
-
 
146
        mov     cx,16
196
        xor     ecx,ecx
Line -... Line 197...
-
 
197
        mcall   38,,,[sc.workL]
-
 
198
 
147
        push    ecx                     ;®âá à¨á®¢ âì ª­®¯ª¨ (¯® ¢ëá®â¥)
199
        mov     bx,[RMenuW]         ;¯à ¢®
148
 
200
        shl     ebx,16
-
 
201
        mov     bx,[RMenuW]
-
 
202
        xor     ecx,ecx
Line 149... Line 203...
149
 
203
        mov     cx,[RMenuH]
150
        mcall   8,,,60000000h or idbRRedrawFon,[sc.work]
204
        mcall
151
        add     ecx,16*10000h
-
 
152
        mcall    ,,,60000000h or idbRAlign
205
 
153
        add     ecx,16*10000h
-
 
154
        mcall    ,,,60000000h or idbRFixIcons
-
 
155
        add     ecx,16*10000h
206
        xor     ebx,ebx                  ;­¨§
Line 156... Line -...
156
 
-
 
157
        cmp     dword[SelIcon],-1
-
 
158
        je      @f
-
 
159
 
-
 
160
        mcall    ,,,60000000h or idbRDel,
-
 
161
        add     ecx,16*10000h
-
 
162
        mcall    ,,,60000000h or idbRProp,
-
 
163
        jmp     .endRM1
-
 
164
      @@:
-
 
Line -... Line 207...
-
 
207
        mov     bx,[RMenuW]
165
        mcall    ,,,60000000h or idbRAdd,
208
        mov     cx,[RMenuH]
166
      .endRM1:
209
        shl     ecx,16
167
 
210
        mov     cx,[RMenuH]
-
 
211
        mcall
168
                                        ;¯®¤¯¨á¨ ª ª­®¯ª ¬
212
 
Line 169... Line 213...
169
        xor     eax,eax
213
        xor     ebx,ebx               ;«¥¢®
170
        cmp     [SelIcon],-1
-
 
171
        jne     @f
214
        xor     ecx,ecx
172
        mov     eax,[NumUserButt]
215
        mov     cx,[RMenuH]
173
      @@:
-
 
174
        shl     eax,4
-
 
175
        mov     ebx,50000h
216
        mcall
176
        mov     bx,ax
-
 
177
 
217
 
178
        add     bx,5
-
 
179
        mcall   4,,80000000h,RMenuRedrawFon
-
 
180
        add     ebx,16
-
 
181
        mcall    ,,,RMenuAlign
-
 
Line 182... Line -...
182
 
-
 
183
        add     ebx,16
-
 
184
        cmp     [bFixIcons],0
-
 
185
        jne     @f
-
 
186
        mov     edx,RMenuOffMoving
-
 
187
        jmp     .RBWR1
-
 
188
     @@:
-
 
189
        mov     edx,RMenuOnMoving
-
 
Line 190... Line 218...
190
     .RBWR1:
218
 
191
        mcall
219
; ᢥâ«ë© «¥¢ë© ¢¥àå­¨© 㣮«
-
 
220
        xor     ebx,ebx
Line 192... Line 221...
192
        add     ebx,16
221
        mov     bx,[RMenuW]
193
 
222
        add     ebx,1*10000h-1
194
        cmp     dword[SelIcon],-1
223
        mov     ecx,00010001h
Line 221... Line 250...
221
        jmp     RBWMessages
250
 
Line 222... Line 251...
222
 
251
RBWButton:
223
RBWButton:
252
        mcall   17              ;GetButtonPressed
224
        mcall   17              ;GetButtonPressed
253
        shr     eax,8
-
 
254
 
-
 
255
        mov     ebx,eax
-
 
256
        mov     eax,[RBMenuCP+ebx*8+4] ;¥á«¨ ᤥáì 0, â® ª«¨ª ¯® áâ ­¤ àâ­®© ª­®¯ª¥(ª®â®à ï ­¥ ¢ ini)
225
        shr     eax,8
257
        test    eax,eax
-
 
258
        jnz     .RBWB
-
 
259
        mov     eax,[RBMenuCP+ebx*8]  ;ᬮâਬ, 㪠§ â¥«ì ­  ª ªãî ­ ¤¯¨áì ¢ ¯®¤¯¨á¨
-
 
260
        cmp     eax,RMenuRedrawFon                  ; ¨ ¯® ­¥© ¢ë¡¨à ¥¬ ¤¥©á⢨¥
226
        cmp     eax,idbRRedrawFon
261
        jz      RBRedrawFon
227
        jz      RBRedrawFon
262
        cmp     eax,RMenuAlign
228
        cmp     eax,idbRAlign
263
        jz      RBAlign
229
        jz      RBAlign
264
        cmp     eax,RMenuOffMoving
-
 
265
        jz      RBFixIcons
-
 
266
        cmp     eax,RMenuOnMoving
230
        cmp     eax,idbRFixIcons
267
        jz      RBFixIcons
231
        jz      RBFixIcons
268
        cmp     eax,RMenuAdd
232
        cmp     eax,idbRAdd
269
        jz      RBAdd
233
        jz      RBAdd
270
        cmp     eax,RMenuDel
234
        cmp     eax,idbRDel
271
        jz      RBDelete
235
        jz      RBDelete
272
        cmp     eax,RMenuProp
236
        cmp     eax,idbRProp
273
        jz      RBPropeties
Line 237... Line 274...
237
        jz      RBPropeties
274
 
238
 
275
        jmp     RBWExit
239
        cmp     eax,[NumUserButt]
-
 
240
        ja      @f
-
 
241
 
276
   .RBWB:
242
        mov     eax,[RBUser+eax*8+4]
277
        mov     dword[fiRunProg+8],0
243
        mov     dword[fiRunProg+8],0
278
        mov     dword[fiRunProg+21],eax
244
        mov     dword[fiRunProg+21],eax
279
        mcall   70,fiRunProg
245
        mcall   70,fiRunProg
280
 
Line 246... Line 281...
246
    @@:
281
        jmp     RBWExit
-
 
282
 
-
 
283
RBWMouse:
-
 
284
        call    MouseInWin
-
 
285
        jnc     .RBWMnoInWin          ;¥á«¨ ¢­¥ ®ª­ , â® ¯à®áâ® ¢®ááâ ­ ¢«¨¢ ¥¬ ¯à¥¤ë¤ãéãî ª­®¯ªã
-
 
286
 
247
        jmp     RBWExit
287
        mcall   37,1          ;¯®«®¦¥­¨¥ ¬ëè¨ ®â­®á¨â¥«ì­® ®ª­ 
-
 
288
        and     eax,0FFF0h      ;­ã¦¥­ ⮫쪮 Y, ¯à¨çñ¬ ®ªà㣫ñ­­ë© ¤® ¢¥àå­¥© â®çª¨ ªà â­®© 16(¢ëá®â  ª­®¯ª¨)
-
 
289
        cmp     [PredItem],eax
-
 
290
        je      .RBWMendLightBut
-
 
291
 
-
 
292
        shr     eax,4              ;¥á«¨ ¬ëèì ­  ­¨¦­¥© à ¬ª¥, â® â ª¦¥ ⮫쪮 ¢®ááâ ­®¢¨âì ¯à¥¤ë¤ãéãî ª­®¯ªã
-
 
293
        cmp     eax,[NumMenuButt]
-
 
294
        jae     .RBWMnoInWin
248
 
295
 
-
 
296
        cmp     [PredItem],-1      ;¢®ááâ ­®¢«¥­¨¥ ¯à¥¤ë¤ã饩 ª­®¯ª¨
249
RBWMouse:
297
        je      @f
250
        cmp     [PredItem],-1
-
 
251
        je      @f
-
 
252
        mov     eax,[PredItem]
-
 
253
        xor     ebx,ebx
-
 
254
        mov     bx,[RMenuW]
-
 
255
        mov     cx,ax
-
 
256
        shl     ecx,16
-
 
257
        mov     cx,ax
-
 
-
 
298
 
258
        mcall   38,,,[sc.work]
299
        stdcall DrawRBLine,[PredItem],0
-
 
300
 
259
        add     ecx,00100010h
301
      @@:
260
        mcall    ,,,[sc.work]
302
 
261
      @@:
303
        call    MouseInWin
262
        call    ClickInWin
304
        jnc     @f
263
        jnc     @f
305
        mcall   37,1          ;¯®«®¦¥­¨¥ ¬ëè¨ ®â­®á¨â¥«ì­® ®ª­ 
264
        mcall   37,1          ;¯®«®¦¥­¨¥ ¬ëè¨ ®â­®á¨â¥«ì­® ®ª­ 
-
 
265
        and     eax,0FFF0h
-
 
266
        mov     [PredItem],eax
-
 
267
        xor     ebx,ebx
-
 
268
        mov     bx,[RMenuW]
-
 
269
        mov     cx,ax
-
 
270
        shl     ecx,16
-
 
271
        mov     cx,ax
306
        and     eax,0FFF0h      ;­ã¦¥­ ⮫쪮 Y, ¯à¨çñ¬ ®ªà㣫ñ­­ë© ¤® ¢¥àå­¥© â®çª¨ ªà â­®© 16(¢ëá®â  ª­®¯ª¨)
-
 
307
        mov     [PredItem],eax
272
        mcall   38,,,[sc.workL]
308
        stdcall DrawRBLine,eax,1
-
 
309
 
-
 
310
      @@:
-
 
311
        jmp     .RBWMendLightBut
-
 
312
 
-
 
313
 
-
 
314
  .RBWMnoInWin:
Line -... Line 315...
-
 
315
        cmp     [PredItem],-1      ;¢®ááâ ­®¢«¥­¨¥ ¯à¥¤ë¤ã饩 ª­®¯ª¨
-
 
316
        je      .RBWMendLightBut
Line -... Line 317...
-
 
317
 
273
        add     ecx,00100010h
318
        stdcall DrawRBLine,[PredItem],0
274
        mcall    ,,,[sc.workH]
319
        mov     [PredItem],-1
275
      @@:
320
 
Line 276... Line 321...
276
 
321
  .RBWMendLightBut:
277
 
322
        mcall   37,2            ;GetMouseKey
Line 278... Line 323...
278
        mcall   37,2            ;GetMouseKey
323
        test    eax,111b
279
        test    eax,111b
324
        jz      RBWMessages
-
 
325
 
-
 
326
        call    MouseInWin
-
 
327
        jc      RBWMessages
280
        jz      RBWMessages
328
 
281
 
329
RBWExit:
Line 282... Line 330...
282
        call    ClickInWin
330
        cmp     [SelIcon],-1
Line 326... Line 374...
326
 
374
        mcall   51,1,DlgAdd,stack_dlg           ;CreateThread DlgAdd,stack_dlg
327
        mcall   51,1,DlgAdd,stack_dlg           ;CreateThread DlgAdd,stack_dlg
375
        jmp     RBWExit
Line 328... Line 376...
328
        jmp     RBWExit
376
 
329
 
-
 
330
RBDelete:
377
RBDelete:
331
 
378
        mov     eax,[SelIcon]
332
        mov     eax,[SelIcon]
379
        mov     eax,[IconsOffs+eax*4]
Line 333... Line 380...
333
        mov     eax,[IconsOffs+eax*4]
380
        stdcall [ini_del_section],IconIni,eax
334
        stdcall [ini_del_section],IconIni,eax
-
 
335
 
-
 
336
        stdcall DelIcon,[SelIcon]
-
 
Line 337... Line 381...
337
    ;    mov     dword[fiStdIco],2
381
 
338
    ;    m2m     dword[fInfo+12],dword[SizeData]
382
        stdcall DelIcon,[SelIcon]
339
    ;    mcall   70,fInfo
383
 
340
 
384
        mov     dword[fiRunProg+8],WarningSave
Line 355... Line 399...
355
 
399
RBWSetActivWin:
356
RBWSetActivWin:
400
        mcall   18,3,[slotDlgAdd]
357
        mcall   18,3,[slotDlgAdd]
401
        jmp     RBWExit
Line -... Line 402...
-
 
402
 
-
 
403
proc DrawRBLine y,active
-
 
404
 
-
 
405
        xor     ebx,ebx
-
 
406
        mov     bx,[RMenuW]
-
 
407
        add     ebx,2*10000h-3
-
 
408
        mov     ecx,[y]
-
 
409
        add     ecx,2
-
 
410
        shl     ecx,16
-
 
411
        mov     cx,16;-1-2
-
 
412
        cmp     [active],1
-
 
413
        jne     @f
-
 
414
        mov     edx,[sc.work_button]
-
 
415
        jmp     .L1
-
 
416
       @@:
-
 
417
        mov     edx,[sc.work]
-
 
418
      .L1:
-
 
419
        mcall   13
-
 
420
 
-
 
421
;----------------------------------------------
-
 
422
        xor     ebx,ebx            ;¢¥àå
-
 
423
        mov     bx,[RMenuW]
-
 
424
        add     ebx,2*10000h-3
-
 
425
        mov     cx,word[y]
-
 
426
        shl     ecx,16
-
 
427
        mov     cx,word[y]
-
 
428
        add     ecx,00020002h
-
 
429
 
-
 
430
        cmp     [active],1
-
 
431
        jne     @f
-
 
432
        mov     edx,[sc.workL]
-
 
433
        jmp     .L3
-
 
434
       @@:
-
 
435
        mov     edx,[sc.work]
-
 
436
      .L3:
-
 
437
 
-
 
438
        mcall   38
-
 
439
 
-
 
440
        mov     ebx,00020002h            ;«¥¢®
-
 
441
        mov     cx,word[y]
-
 
442
        shl     ecx,16
-
 
443
        mov     cx,word[y]
-
 
444
        add     ecx,00020002h+16
-
 
445
 
-
 
446
        cmp     [active],1
-
 
447
        jne     @f
-
 
448
        mov     edx,[sc.workL]
-
 
449
 
-
 
450
       @@:
-
 
451
 
-
 
452
        mcall
-
 
453
 
-
 
454
        xor     ebx,ebx                  ;­¨§
-
 
455
        mov     bx,[RMenuW]
-
 
456
        add     ebx,2*10000h-3
-
 
457
        mov     cx,word[y]
-
 
458
        shl     ecx,16
-
 
459
        mov     cx,word[y]
-
 
460
        add     ecx,16*10000h+16+00020002h
-
 
461
 
-
 
462
        cmp     [active],1
-
 
463
        jne     @f
-
 
464
        mov     edx,[sc.workH]
-
 
465
       @@:
-
 
466
 
-
 
467
        mcall
-
 
468
 
-
 
469
 
-
 
470
        mov     bx,[RMenuW]                 ;¯à ¢®
-
 
471
        shl     ebx,16
-
 
472
        mov     bx,[RMenuW]
-
 
473
        add     ebx,-2*10000h-2
-
 
474
        mov     cx,word[y]
-
 
475
        shl     ecx,16
-
 
476
        mov     cx,word[y]
-
 
477
        add     ecx,00020002h+16
-
 
478
 
-
 
479
        cmp     [active],1
-
 
480
        jne     @f
-
 
481
        mov     edx,[sc.workH]
-
 
482
       @@:
-
 
483
 
-
 
484
        mcall
-
 
485
 
-
 
486
 
-
 
487
 
-
 
488
 
-
 
489
 
-
 
490
        mov     eax,[y]
-
 
491
        shr     eax,4
-
 
492
        mov     edx,[RBMenuCP+eax*8]
-
 
493
 
-
 
494
        xor     ebx,ebx
-
 
495
        mov     ebx,[y]
-
 
496
        add     ebx,7*10000h+7
-
 
497
 
-
 
498
        cmp     [active],1
-
 
499
        jne     @f
-
 
500
        mov     ecx,[sc.work_button_text]
-
 
501
        jmp     .L2
-
 
502
       @@:
-
 
503
        mov     ecx,[sc.work_text]
-
 
504
      .L2:
-
 
505
 
-
 
506
 
-
 
507
 
-
 
508
        or      ecx,80000000h
-
 
509
 
-
 
510
        mcall   4
-
 
511
 
-
 
512
        ret
-
 
513
endp
-
 
514
 
358
        jmp     RBWExit
515
 
359
 
516
proc MouseInWin        ;Carry flag = 1, ¥á«¨ ª«¨ª ¢ ®ª­¥
360
proc ClickInWin        ;Carry flag = 1, ¥á«¨ ª«¨ª ¢ ®ª­¥
517
        mcall   37,0            ;GetMousePos
361
        mcall   37,0            ;GetMousePos
518
        xor     ebx,ebx
362
        xor     ebx,ebx
519
        mov     bx,ax           ;y
Line 517... Line 674...
517
        ret
674
endp
518
endp
675
 
Line 519... Line 676...
519
 
676
;-------------------------------------------------------------------------------
520
;-------------------------------------------------------------------------------
677
proc GetUserBut stdcall,f_name,sec_name,key_name,key_value
521
proc GetUserBut stdcall,f_name,sec_name,key_name,key_value
678
        cmp     [NumMenuButt],MAX_USER_BUTTONS
522
        cmp     [NumUserButt],16
679
        jne     @f
523
        jne     @f
680
        ret
524
        ret
681
     @@:
Line 525... Line 682...
525
     @@:
682
 
Line 536... Line 693...
536
        lea     eax,[eax*2+eax+5*2]
693
        cmp     ax,[RMenuW]
537
        cmp     ax,[RMenuW]
694
        jbe     @f
538
        jbe     @f
695
        mov     [RMenuW],ax
539
        mov     [RMenuW],ax
696
     @@:
540
     @@:
697
 
541
        cmp     [RMenuW],MinRMenuW
-
 
542
        jae     @f
-
 
543
        mov     [RMenuW],MinRMenuW
-
 
544
     @@:
-
 
Line 545... Line 698...
545
 
698
        mov     ebx,[NumMenuButt]
Line 546... Line 699...
546
        mov     ebx,[NumUserButt]
699
 
547
 
700
        mov     esi,[key_name]
548
        mov     esi,[key_name]
701
        mov     edi,[RBMenuCP+ebx*8]
549
        mov     edi,[RBUser+ebx*8]
702
    @@: lodsb
550
    @@: lodsb
703
        stosb
551
        stosb
704
        test    al,al
Line 552... Line -...
552
        test    al,al
-
 
553
        jnz     @b
-
 
Line 554... Line 705...
554
 
705
        jnz     @b
555
;debug_newline
706
 
556
 
707
 
557
 
708
        mov     [RBMenuCP+ebx*8+4],edi
558
        mov     [RBUser+ebx*8+4],edi
709
        mov     esi,[key_value]
559
        mov     esi,[key_value]
710
    @@: lodsb
Line 560... Line 711...
560
    @@: lodsb
711
        stosb
Line 561... Line 712...
561
        stosb
712
        test    al,al
Line 562... Line 713...
562
        test    al,al
713
        jnz     @b
563
        jnz     @b
714
 
564
 
715
        mov     [RBMenuCP+ebx*8+8],edi
565
        mov     [RBUser+ebx*8+8],edi
716