Subversion Repositories Kolibri OS

Rev

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

Rev 3182 Rev 6763
Line 14... Line 14...
14
        wait_event .red,.key,.button,.mouse
14
        wait_event .red,.key,.button,.mouse
Line 15... Line 15...
15
 
15
 
16
.key:
16
.key:
Line 17... Line 17...
17
        get_key
17
        get_key
18
 
-
 
19
        push    dword rect_input.left
-
 
20
        call    [edit_box_key]
18
 
21
 
-
 
22
        push    dword rect_input.top
-
 
23
        call    [edit_box_key]
19
        stdcall    [edit_box_key], rect_input.left
24
 
-
 
25
        push    dword rect_input.width
-
 
26
        call    [edit_box_key]
20
        stdcall    [edit_box_key], rect_input.top
27
 
-
 
28
        push    dword rect_input.height
-
 
Line 29... Line 21...
29
        call    [edit_box_key]
21
        stdcall    [edit_box_key], rect_input.width
30
;        key_edit_boxes rect_input,rect_input_end
22
        stdcall    [edit_box_key], rect_input.height
Line 31... Line 23...
31
 
23
 
Line 48... Line 40...
48
.mouse:
40
.mouse:
49
        get_active_window
41
        get_active_window
50
        cmp     eax,[set_rect_window_slot]
42
        cmp     eax,[set_rect_window_slot]
51
        jne     .still
43
        jne     .still
Line 52... Line -...
52
 
-
 
53
        push    dword rect_input.left
44
 
54
        call    [edit_box_mouse]
-
 
55
 
-
 
56
        push    dword rect_input.top
45
        stdcall    [edit_box_mouse], rect_input.left
57
        call    [edit_box_mouse]
-
 
58
 
46
        stdcall    [edit_box_mouse], rect_input.top
59
        push    dword rect_input.width
-
 
60
        call    [edit_box_mouse]
-
 
61
 
47
        stdcall    [edit_box_mouse], rect_input.width
62
        push    dword rect_input.height
-
 
Line 63... Line 48...
63
        call    [edit_box_mouse]
48
        stdcall    [edit_box_mouse], rect_input.height
64
 
49
 
65
;;;;;;;;;;;;;;;;;;;;;;
-
 
66
        push    dword use_rect_active_window
-
 
67
        call    [check_box_mouse]
-
 
68
 
-
 
Line 69... Line 50...
69
;        mouse_edit_boxes rect_input,rect_input_end
50
;;;;;;;;;;;;;;;;;;;;;;
Line 70... Line 51...
70
;        mouse_check_boxes riw_check_boxes,riw_check_boxes_end
51
        stdcall    [check_box_mouse], use_rect_active_window
71
 
52
 
Line 72... Line -...
72
        jmp     .still
-
 
73
 
-
 
74
.draw_window:
-
 
75
        start_draw_window
53
        jmp     .still
76
 
54
 
77
        xor     eax,eax
55
.draw_window:
78
        mov     ebx,100*65536+250
56
        start_draw_window
79
        mov     ecx,100*65536+130
57
 
Line 80... Line 58...
80
        mov     edx,[sc.work]
58
        mov     edx,[sc.work]
Line 81... Line 59...
81
        add     edx,0x33000000
59
        add     edx,0x33000000
82
        mov     edi,riw_grab_text
-
 
83
        xor     esi,esi
-
 
84
        mcall
60
        mov     edi,riw_grab_text
85
 
-
 
86
        draw_labels rect_input_labels,rect_input_labels_end
-
 
87
 
61
        xor     esi,esi
88
        push    dword rect_input.left
-
 
89
        call    [edit_box_draw]
-
 
90
 
62
        mcall   SF_CREATE_WINDOW, 100*65536+250, 100*65536+130
91
        push    dword rect_input.top
-
 
92
        call    [edit_box_draw]
63
 
93
 
64
        draw_labels rect_input_labels,rect_input_labels_end
94
        push    dword rect_input.width
-
 
95
        call    [edit_box_draw]
-
 
96
 
-
 
Line 97... Line 65...
97
        push    dword rect_input.height
65
 
98
        call    [edit_box_draw]
66
        stdcall    [edit_box_draw], rect_input.left
Line 99... Line 67...
99
;;;;;;;;;;;;;;;;;;;;;;
67
        stdcall    [edit_box_draw], rect_input.top
Line 167... Line 135...
167
        mov     [rect.height],ax
135
        mov     [rect.height],ax
168
ret
136
ret
Line 169... Line 137...
169
 
137
 
Line 170... Line -...
170
draw_rect_on_screen:
-
 
171
 
-
 
172
        mov     eax,13
-
 
173
        mov     ebx,150*65536+80
138
draw_rect_on_screen:
174
        mov     ecx,5*65536+60
139
 
Line 175... Line 140...
175
        xor     edx,edx
140
        xor     edx,edx
176
        mcall
141
        mcall   SF_DRAW_RECT, 150*65536+80, 5*65536+60
177
 
142
 
178
        ;movzx   eax,word [rect.left]
143
        ;movzx   eax,word [rect.left]
Line 212... Line 177...
212
        shl     ecx,16
177
        shl     ecx,16
Line 213... Line 178...
213
 
178
 
214
        pop     bx
179
        pop     bx
Line 215... Line 180...
215
        pop     cx
180
        pop     cx
216
 
-
 
217
        mov     edx,0xffffff
-
 
218
        mov     eax,13
181
 
Line 219... Line 182...
219
        mcall
182
        mcall   SF_DRAW_RECT,,,0xffffff
220
ret
183
ret
221
 
184
 
Line 222... Line 185...
222
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
185
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
223
;DATA ¤ ­­ë¥
186
;DATA ¤ ­­ë¥
-
 
187
;‚ᥣ¤  ᮡ«î¤ âì ¯®á«¥¤®¢ â¥«ì­®áâì ¢ ¨¬¥­¨.
-
 
188
 
-
 
189
system_dir_Boxlib	db '/sys/lib/box_lib.obj',0
-
 
190
system_dir_ProcLib	db '/sys/lib/proc_lib.obj',0
-
 
191
system_dir_LibImg   db '/sys/lib/libimg.obj',0
-
 
192
 
-
 
193
if lang eq ru
-
 
194
head_f_i:
-
 
195
head_f_l	db '‘¨á⥬­ ï ®è¨¡ª ',0
-
 
196
 
-
 
197
err_message_found_lib1	db 'box_lib.obj - ­¥ ­ ©¤¥­ !',0
-
 
198
err_message_found_lib2	db 'proc_lib.obj - ­¥ ­ ©¤¥­ !',0
-
 
199
err_message_found_lib3	db 'libimg.obj - ­¥ ­ ©¤¥­ !',0
-
 
200
 
-
 
201
err_message_import1	db 'box_lib.obj - ®è¨¡ª  ¨¬¯®àâ !',0
Line 224... Line 202...
224
;‚ᥣ¤  ᮡ«î¤ âì ¯®á«¥¤®¢ â¥«ì­®áâì ¢ ¨¬¥­¨.
202
err_message_import2	db 'proc_lib.obj - ®è¨¡ª  ¨¬¯®àâ !',0
225
 
203
err_message_import3	db 'libimg.obj - ®è¨¡ª  ¨¬¯®àâ !',0
Line 226... Line 204...
226
system_dir_Boxlib	db '/sys/lib/box_lib.obj',0
204
 
227
system_dir_ProcLib	db '/sys/lib/proc_lib.obj',0
205
else
-
 
206
 
Line 228... Line 207...
228
 
207
head_f_i:
229
head_f_i:
208
head_f_l	db 'System error',0
-
 
209
 
230
head_f_l	db 'System error',0
210
err_message_found_lib1	db 'box_lib.obj - Not found!',0
231
 
211
err_message_found_lib2	db 'proc_lib.obj - Not found!',0
232
err_message_found_lib1	db 'box_lib.obj - Not found!',0
212
err_message_found_lib3	db 'libimg.obj - Not found!',0
233
err_message_found_lib2	db 'proc_lib.obj - Not found!',0
213
 
234
 
214
err_message_import1	db 'box_lib.obj - Wrong import!',0
235
err_message_import1	db 'box_lib.obj - Wrong import!',0
215
err_message_import2	db 'proc_lib.obj - Wrong import!',0
Line 250... Line 230...
250
align 4
230
align 4
251
Box_lib_import:	
231
Box_lib_import:	
252
;init_lib		dd a_init
232
;init_lib		dd a_init
253
;version_lib		dd a_version
233
;version_lib		dd a_version
Line 254... Line -...
254
 
-
 
255
 
234
 
256
edit_box_draw		dd aEdit_box_draw
235
edit_box_draw		dd aEdit_box_draw
257
edit_box_key		dd aEdit_box_key
236
edit_box_key		dd aEdit_box_key
258
edit_box_mouse		dd aEdit_box_mouse
237
edit_box_mouse		dd aEdit_box_mouse
Line 259... Line -...
259
;version_ed		dd aVersion_ed
-
 
260
 
238
;version_ed		dd aVersion_ed
261
 
239
 
262
init_checkbox		dd aInit_checkbox
240
init_checkbox		dd aInit_checkbox
263
check_box_draw		dd aCheck_box_draw
241
check_box_draw		dd aCheck_box_draw
Line 264... Line -...
264
check_box_mouse 	dd aCheck_box_mouse
-
 
265
;version_ch	dd	aVersion_ch
-
 
266
 
-
 
267
;check_box_draw		dd aCheck_box_draw
-
 
268
;check_box_mouse		dd aCheck_box_mouse
242
check_box_mouse 	dd aCheck_box_mouse
269
;version_ch		dd aVersion_ch
243
;version_ch	dd	aVersion_ch
270
 
244
 
Line 271... Line -...
271
option_box_draw	dd aOption_box_draw
-
 
272
option_box_mouse	dd aOption_box_mouse
-
 
273
;version_op		dd aVersion_op
-
 
274
 
-
 
275
;scrollbar_ver_draw	dd aScrollbar_ver_draw
-
 
276
;scrollbar_ver_mouse	dd aScrollbar_ver_mouse
-
 
277
;scrollbar_hor_draw	dd aScrollbar_hor_draw
-
 
278
;scrollbar_hor_mouse	dd aScrollbar_hor_mouse
-
 
279
;version_scrollbar	dd aVersion_scrollbar
-
 
280
 
-
 
281
;dinamic_button_draw	dd aDbutton_draw
-
 
282
;dinamic_button_mouse	dd aDbutton_mouse
-
 
283
;version_dbutton	dd aVersion_dbutton
-
 
284
 
-
 
285
;menu_bar_draw		dd aMenu_bar_draw
-
 
286
;menu_bar_mouse		dd aMenu_bar_mouse
-
 
287
;menu_bar_activate	dd aMenu_bar_activate
-
 
288
;version_menu_bar	dd aVersion_menu_bar
-
 
289
 
-
 
290
;FileBrowser_draw	dd aFileBrowser_draw
-
 
291
;FileBrowser_mouse	dd aFileBrowser_mouse
245
option_box_draw	dd aOption_box_draw
292
;FileBrowser_key	dd aFileBrowser_key
246
option_box_mouse	dd aOption_box_mouse
293
;Version_FileBrowser	dd aVersion_FileBrowser
247
;version_op		dd aVersion_op
294
 
-
 
295
PathShow_prepare	dd sz_PathShow_prepare
248
 
Line 296... Line 249...
296
PathShow_draw		dd sz_PathShow_draw
249
PathShow_prepare	dd sz_PathShow_prepare
297
;Version_path_show	dd szVersion_path_show
250
PathShow_draw		dd sz_PathShow_draw
Line 298... Line 251...
298
			dd 0
251
;Version_path_show	dd szVersion_path_show
Line 310... Line 263...
310
aInit_checkbox	 db 'init_checkbox2',0
263
aInit_checkbox	 db 'init_checkbox2',0
311
aCheck_box_draw  db 'check_box_draw2',0
264
aCheck_box_draw  db 'check_box_draw2',0
312
aCheck_box_mouse db 'check_box_mouse2',0
265
aCheck_box_mouse db 'check_box_mouse2',0
313
;aVersion_ch	 db 'version_ch2',0
266
;aVersion_ch	 db 'version_ch2',0
Line 314... Line -...
314
 
-
 
315
;aCheck_box_draw	db 'check_box_draw',0
-
 
316
;aCheck_box_mouse	db 'check_box_mouse',0
-
 
317
;aVersion_ch		db 'version_ch',0
-
 
318
 
267
 
319
aOption_box_draw	db 'option_box_draw',0
268
aOption_box_draw	db 'option_box_draw',0
320
aOption_box_mouse	db 'option_box_mouse',0
269
aOption_box_mouse	db 'option_box_mouse',0
Line 321... Line -...
321
;aVersion_op		db 'version_op',0
-
 
322
 
-
 
323
;aScrollbar_ver_draw	db 'scrollbar_v_draw',0
-
 
324
;aScrollbar_ver_mouse	db 'scrollbar_v_mouse',0
-
 
325
;aScrollbar_hor_draw	db 'scrollbar_h_draw',0
-
 
326
;aScrollbar_hor_mouse	db 'scrollbar_h_mouse',0
-
 
327
;aVersion_scrollbar	db 'version_scrollbar',0
-
 
328
 
-
 
329
;aDbutton_draw		db 'dbutton_draw',0
-
 
330
;aDbutton_mouse		db 'dbutton_mouse',0
-
 
331
;aVersion_dbutton	db 'version_dbutton',0
-
 
332
 
-
 
333
;aMenu_bar_draw		db 'menu_bar_draw',0
-
 
334
;aMenu_bar_mouse		db 'menu_bar_mouse',0
-
 
335
;aMenu_bar_activate	db 'menu_bar_activate',0
-
 
336
;aVersion_menu_bar	db 'version_menu_bar',0
-
 
337
 
-
 
338
;aFileBrowser_draw	db 'FileBrowser_draw',0
-
 
339
;aFileBrowser_mouse	db 'FileBrowser_mouse',0
-
 
340
;aFileBrowser_key	db 'FileBrowser_key',0
-
 
341
;aVersion_FileBrowser	db 'version_FileBrowser',0
270
;aVersion_op		db 'version_op',0
342
 
271
 
343
sz_PathShow_prepare	db 'PathShow_prepare',0
272
sz_PathShow_prepare	db 'PathShow_prepare',0
344
sz_PathShow_draw	db 'PathShow_draw',0
273
sz_PathShow_draw	db 'PathShow_draw',0
-
 
274
;szVersion_path_show	db 'version_PathShow',0
-
 
275
;---------------------------------------------------------------------
-
 
276
align 4
-
 
277
import_libimg:
-
 
278
	dd alib_init1
-
 
279
	img_is_img  dd aimg_is_img
-
 
280
	img_info    dd aimg_info
-
 
281
	img_from_file dd aimg_from_file
-
 
282
	img_to_file dd aimg_to_file
-
 
283
	img_from_rgb dd aimg_from_rgb
-
 
284
	img_to_rgb  dd aimg_to_rgb
-
 
285
	img_to_rgb2 dd aimg_to_rgb2
-
 
286
	img_decode  dd aimg_decode
-
 
287
	img_encode  dd aimg_encode
-
 
288
	img_create  dd aimg_create
-
 
289
	img_destroy dd aimg_destroy
-
 
290
	img_destroy_layer dd aimg_destroy_layer
-
 
291
	img_count   dd aimg_count
-
 
292
	img_lock_bits dd aimg_lock_bits
-
 
293
	img_unlock_bits dd aimg_unlock_bits
-
 
294
	img_flip    dd aimg_flip
-
 
295
	img_flip_layer dd aimg_flip_layer
-
 
296
	img_rotate  dd aimg_rotate
345
;szVersion_path_show	db 'version_PathShow',0
297
	img_rotate_layer dd aimg_rotate_layer
-
 
298
	img_draw    dd aimg_draw
-
 
299
dd 0,0
-
 
300
	alib_init1   db 'lib_init',0
-
 
301
	aimg_is_img  db 'img_is_img',0
-
 
302
	aimg_info    db 'img_info',0
-
 
303
	aimg_from_file db 'img_from_file',0
-
 
304
	aimg_to_file db 'img_to_file',0
-
 
305
	aimg_from_rgb db 'img_from_rgb',0
-
 
306
	aimg_to_rgb  db 'img_to_rgb',0
-
 
307
	aimg_to_rgb2 db 'img_to_rgb2',0
-
 
308
	aimg_decode  db 'img_decode',0
-
 
309
	aimg_encode  db 'img_encode',0
-
 
310
	aimg_create  db 'img_create',0
-
 
311
	aimg_destroy db 'img_destroy',0
-
 
312
	aimg_destroy_layer db 'img_destroy_layer',0
-
 
313
	aimg_count   db 'img_count',0
-
 
314
	aimg_lock_bits db 'img_lock_bits',0
-
 
315
	aimg_unlock_bits db 'img_unlock_bits',0
-
 
316
	aimg_flip    db 'img_flip',0
-
 
317
	aimg_flip_layer db 'img_flip_layer',0
-
 
318
	aimg_rotate  db 'img_rotate',0
-
 
319
	aimg_rotate_layer db 'img_rotate_layer',0
346
;---------------------------------------------------------------------
320
	aimg_draw    db 'img_draw',0
347
 
321
;---------------------------------------------------------------------
Line 348... Line 322...
348
;width,left,top,color,shift_color,focus_border_color,\
322
;width,left,top,color,shift_color,focus_border_color,\
349
;       blur_border_color,text_color,max,text,mouse_variable,flags,size,pos
323
;       blur_border_color,text_color,max,text,mouse_variable,flags,size,pos
Line 361... Line 335...
361
.width label 10,50,0,rect_input_labels_text.width
335
.width  label 10,50,0,rect_input_labels_text.width
362
.height label 10,70,0,rect_input_labels_text.height
336
.height label 10,70,0,rect_input_labels_text.height
363
rect_input_labels_end:
337
rect_input_labels_end:
Line 364... Line 338...
364
 
338
 
-
 
339
rect_input_labels_text:
365
rect_input_labels_text:
340
if lang eq ru
366
.left db 'Žâáâ㯠᫥¢ :',0
341
.left db 'Žâáâ㯠᫥¢ :',0
367
.top  db 'Žâáâ㯠ᢥàåã:',0
342
.top  db 'Žâáâ㯠ᢥàåã:',0
368
.width  db '˜¨à¨­ :',0
343
.width  db '˜¨à¨­ :',0
-
 
344
.height db '‚ëá®â :',0
-
 
345
else
-
 
346
.left db 'Left:',0
-
 
347
.top  db 'Top:',0
-
 
348
.width  db 'Width:',0
-
 
349
.height db 'Height:',0
Line 369... Line 350...
369
.height db '‚ëá®â :',0
350
end if
370
 
351
 
371
riw_check_boxes:
352
riw_check_boxes:
372
use_rect_active_window check_box2 (10 shl 16)+10,(85 shl 16) +10,5,cl_white,0,0,\
353
use_rect_active_window check_box2 (10 shl 16)+10,(85 shl 16) +10,5,cl_white,0,0,\
Line 373... Line 354...
373
riw_check_boxes_text, ch_flag_bottom
354
riw_check_boxes_text, ch_flag_bottom
374
riw_check_boxes_end:
355
riw_check_boxes_end:
375
 
-
 
376
riw_check_boxes_text:
-
 
377
db 'ˆá¯®«ì§®¢ âì ®¡« áâì  ªâ¨¢­®£® ®ª­ ',0
356
 
378
 
357
if lang eq ru
-
 
358
riw_check_boxes_text db 'ˆá¯®«ì§®¢ âì ®¡« áâì  ªâ¨¢­®£® ®ª­ ',0
-
 
359
riw_grab_text db 'Š®®à¤¨­ âë ¨ à §¬¥àë ®¡« áâ¨:',0
-
 
360
else
-
 
361
riw_check_boxes_text db 'Use area of the active window',0
379
 
362
riw_grab_text db 'Coordinates and size of the field:',0