Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 6359 → Rev 6360

/programs/media/animage/trunk/animage.asm
32,13 → 32,8
use32
org 0x0
db 'MENUET01'
dd 0x1
dd START
dd IM_END
dd I_END
dd stacktop
dd file_path ;parameters
dd cur_dir_path
dd 1, START, IM_END, I_END
dd stacktop, file_path, cur_dir_path
 
include '../../../config.inc' ;for nightbuild
include '../../../macros.inc'
47,6 → 42,7
include '../../../develop/libraries/box_lib/load_lib.mac'
include '../../../dll.inc'
include '../../../libio.inc'
;include '../../../develop/libraries/libs-dev/libimg/libimg.inc'
 
@use_library_mem mem.Alloc,mem.Free,mem.ReAlloc,dll.Load
 
141,8 → 137,7
call copy_str_1
@@:
;OpenDialog initialisation
push dword OpenDialog_data
call [OpenDialog_Init]
stdcall [OpenDialog_Init], OpenDialog_data
;---------------------------------------------------------------------
red:
call drawwin
208,7 → 203,7
;----------------------------------------------------------
;-------------------ICON"S picture-------------------------
;----------------------------------------------------------
dd 0
align 4
panel_picture:
file 'panel_buttons.png'
.end:
284,12 → 279,7
Icon_Y rd 1
counter rd 1
counter2 rd 1
Icon_text_x rd 1
Icon_text_y rd 1
Panel_flag rb 1
counter_menu rd 1
menu_coordinat_x rd 1
menu_size_x rd 1
menu_counter rd 1
counter_11 rd 1
number_panel rd 1
/programs/media/animage/trunk/design.inc
200,88 → 200,29
call draw_line
ret
;----------------------------------------------------------
rectangle:
no_light_rectangle:
mov [line_x],eax
mov [line_y],ebx
mov [line_size_x],ecx
mov [line_size_y],edx
mov edx,esi
mov ebx,[line_x]
mov ecx,[line_y]
shl ebx,16
shl ecx,16
add ebx,[line_size_x]
add ecx,[line_size_y]
mcall SF_DRAW_RECT
ret
;----------------------------------------------------------
draw_conture:
mov [line_x],eax
mov [line_y],ebx
mov [line_size_x],ecx
mov [line_size_y],edx
mov [color_line1],0xaeabae
;line 1
mov edx,[color_line1]
mov ebx,[line_x]
mov ecx,[line_y]
shl ebx,16
shl ecx,16
add ebx,[line_x]
add ecx,[line_y]
add ebx,[line_size_x]
call draw_line
;line 2
mov edx,[color_line1]
mov ebx,[line_x]
mov ecx,[line_y]
shl ebx,16
shl ecx,16
add ebx,[line_x]
add ecx,[line_y]
add ecx,[line_size_y]
call draw_line
;line 3
mov edx,[color_line1]
mov ebx,[line_x]
mov ecx,[line_y]
add ecx,[line_size_y]
shl ebx,16
shl ecx,16
add ebx,[line_x]
add ecx,[line_y]
add ebx,[line_size_x]
add ecx,[line_size_y]
call draw_line
;line 4
mov edx,[color_line1]
mov ebx,[line_x]
mov ecx,[line_y]
add ebx,[line_size_x]
shl ebx,16
shl ecx,16
add ebx,[line_x]
add ecx,[line_y]
add ebx,[line_size_x]
add ecx,[line_size_y]
call draw_line
ret
;----------------------------------------------------------
;input:
; eax - rectangle X
; ebx - rectangle Y
; ecx - point X
; edx - point Y
; esi - rectangle size X
; edi - rectangle size Y
;output:
; eax - 1 if point in rectangle
columnus:
sub eax,ecx
jns no_columnus
jns @f
neg eax
cmp eax,esi
ja no_columnus
ja @f
sub ebx,edx
jns no_columnus
jns @f
neg ebx
cmp ebx,edi
ja no_columnus
ja @f
mov eax,1
jmp columnus_true
no_columnus:
@@:
xor eax,eax
columnus_true:
ret
/programs/media/animage/trunk/icons.inc
125,7 → 125,7
mov [Icon_X],ci_panel_x_pos+131
 
mov ebx,[Icon_X]
mov ecx,ci_panel_but_y1-1
mov ecx,ci_panel_but_y2-1
dec ebx
dec ecx
shl ebx,16