end: bigger checkbox, no draw overlap

git-svn-id: svn://kolibrios.org@6190 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Kirill Lipatov (Leency) 2016-02-10 23:25:56 +00:00
parent ed44ecca04
commit ef2476cf2f
2 changed files with 24 additions and 8 deletions

View File

@ -90,14 +90,14 @@ aini_get_int db 'ini_get_int',0
aini_set_int db 'ini_set_int',0
;---------------------------------------------------------------------
check1 check_box2 20 shl 16 +8,110 shl 16 +8,6,0xffffff,0,0,label4
check1 check_box2 20 shl 16 +12,108 shl 16 +12,6,0xffffff,0,0,label4,ch_flag_middle
hide db 'h',0
asettings db 'settings',0
aautosave db 'autosave',0
ini_file db '/sys/settings/rdsave.ini',0
color1 dd 0x019098d0
color1 dd 0x6068a0
color2 dd 0xFFFFFF
color3 dd 0xe4dfe1

View File

@ -25,9 +25,24 @@ include '../../../develop/libraries/box_lib/trunk/box_lib.mac'
@use_library
macro DrawBar x, y, width, height, color
{
mcall 13, (x) shl 16 + (width), (y) shl 16 + (height), color
}
macro DrawRectangle x, y, w, h, color
{
DrawBar x,y,w,1,color
DrawBar x,y+h,w,1
DrawBar x,y,1,h
DrawBar x+w,y,1,h+1
}
align 4
START:
load_libraries l_libs_start,end_l_libs
inc eax
test eax,eax
@ -167,8 +182,7 @@ checkbox:
jmp still
draw_window:
mov al,12
mcall ,1
mcall 12,1
mov al,14
mcall ;eax=14 - get screen max x & max y
@ -181,11 +195,13 @@ draw_window:
lea ecx,[ecx-70 shl 16+132]
xor eax,eax
mcall , , ,[color1],0x01000000 ;define and draw window
mov edx, 0x01000000
mcall ;define and draw window
DrawRectangle 0,0,332,132,[color1]
mov al,13
mcall ,<0,333> ,<0,133>
mcall ,<1,331>,<1,131>,[color2]
mcall ,<1,331>,<1,1>,[color2]
mcall ,<1,1>,<1,131>
mcall ,<2,330>,<2,130>, [color3]
mov al,8