/programs/develop/examples/checkbox/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
/programs/develop/examples/checkbox/trunk/check.inc |
---|
48,12 → 48,12 |
shl ecx,16 |
add ecx,ch_size |
mov edx,ch_border_color |
int 0x40 ;à¨á㥬 à ¬ªã |
mcall ;à¨á㥬 à ¬ªã |
mov edx,ch_color |
add ebx,1 shl 16 - 2 |
add ecx,1 shl 16 - 2 |
int 0x40 ;§ ªà 訢 ¥¬ ¢ãâ८á⨠祪¡®ªá |
mcall ;§ ªà 訢 ¥¬ ¢ãâ८á⨠祪¡®ªá |
test word ch_flags,2 ;¤®áâ âì § 票¥ ¡¨â ¨§ ¯¥à¥¬¥®© ¨ ¯®¬¥áâ¨âì ¢ ä« £ CF |
jz @f ;¢ ¥á«¨ CF=1, â® ¢ë¯®«¨¬ á«¥¤ãîéãî ¯à®æ¥¤ãàã ¨ ç¥ ¯¥à¥©â¨ ¨¦îî @@ |
73,7 → 73,7 |
movzx esi,word ch_text_length ; £à㧨¬ ¤«¨ã ¤¯¨á¨ ¢ esi |
;¢¥á¥¬ ¢ eax § 票¥ ¢ë¢®¤ ¤¯¨á¨ ª ¢ã |
mov eax,4 |
int 0x40 ;뢮¤ |
mcall ;뢮¤ |
popa ;¢®ááâ ®¢¨âì § 票ï ॣ¨áâ஢ ¨§ á⥪ |
ret ;¢ë©¤¥¬ ¨§ ¯à®æ¥¤ãàë |
96,13 → 96,13 |
shl ecx,16 ;ᤢ¨¥¬ 16 à §à冷¢ ¢ «¥¢® (㬮¦¨¬ 65536) |
mov cx,bp ;§ £à㧨¬ § 票ï ॣ¨áâà 㪠§ â¥«ï ¡ §ë ¢ cx |
;pop cx |
int 0x40 ;¢ë¢®¤ |
mcall ;¢ë¢®¤ |
ret ;¢ë©â¨ ¨§ ¯à®æ¥¤ãàë |
.mouse: ;®¡à ¡®âª ¬ëè¨ |
pusha |
mov eax,37 ;¡ã¤¥¬ çâ® â® ¤¥« âì ¥á«¨ ã á çâ® - ¨âì ¦ â® |
mov ebx,2 ;¢¥á⨠¢ ॣ¨áâà § 票¥ 2 |
int 0x40 ;¯à®¢¥àª ¥ ¦ « «¨ ¯®«ì§®¢ â¥«ì ª®¯ªã ¬ë誨 |
mcall ;¯à®¢¥àª ¥ ¦ « «¨ ¯®«ì§®¢ â¥«ì ª®¯ªã ¬ë誨 |
test eax,eax ;¯à®¢¥àª ¥á«¨ ã á ¢ eax=0, â® ãáâ ®¢¨¬ ä« £ ¨ ¢ë©¤¥¬ |
jnz @f ;¯¥à¥©â¨ ¨¦îî ¬¥âªã @@ |
btr word ch_flags,2 ;¨§¢«¥ç¥¨¥ § ç¥¨ï § ¤ ®£® ¡¨â ¢ ä« £ cf ¨ ¨§¬¥¥¨¥ ¥£® § 票ï ã«¥¢®¥. |
120,7 → 120,7 |
mov eax,37 ;¯®«ã稬 ª®®à¤¨ âë ¬ë誨 |
mov ebx,1 ;¤®¡ ¢¨âì 1 |
int 0x40 ;¯®«ãç¨âì ª®®à¤¨ âë ªãàá®à ®â®á¨â¥«ì® ®ª |
mcall ;¯®«ãç¨âì ª®®à¤¨ âë ªãàá®à ®â®á¨â¥«ì® ®ª |
movzx ebx,word ch_top ;§ £à㧨âì ¢ bx § 票¥ ª®®à¤¨ âë ã |
cmp ax,bx ;áà ¢¨âì á á ª®®à¤¨ ⮩ ªãàá®à |
/programs/develop/examples/checkbox/trunk/checkbox.asm |
---|
23,7 → 23,7 |
; 㪠§ ⥫ì áâபã, ¢ ª®â®àãî § ¯¨á ¯ãâì, |
; ®âªã¤ § ¯ã饮 ¯à¨«®¦¥¨¥ |
;------------------ |
include 'macros.inc' |
include '..\..\..\..\macros.inc' |
include 'check.inc' ;¢ª«îç¨âì ä ©« check.inc |
; version_ch ;¥®¡å®¤¨¬ë© ¬ ªà®á ¤«ï ¢ª«î票ï "áâ ன" ¢¥àᨨ check_box |
version_ch1 ;¥®¡å®¤¨¬ë© ¬ ªà®á ¤«ï ¢ª«î票ï new ¢¥àᨨ check_box1 |
36,16 → 36,16 |
mov ebx,3 |
mov ecx,sc |
mov edx,sizeof.system_colors |
int 0x40 |
mcall |
mov eax,40 ;ãáâ ®¢¨âì ¬ áªã ¤«ï ®¦¨¤ ¥¬ëå ᮡë⨩ |
mov ebx,0x25 ;á¨á⥬ ¡ã¤¥â ॠ£¨à®¢ âì ⮫쪮 á®®¡é¥¨¥ ® ¯¥à¥à¨á®¢ª¥, ¦ â ª®¯ª , ®¯à¥¤¥«ñ ï à ¥¥, ᮡë⨥ ®â ¬ëè¨ (çâ®-â® á«ã稫®áì - ¦ ⨥ ª®¯ªã ¬ëè¨ ¨«¨ ¯¥à¥¬¥é¥¨¥; á¡à áë¢ ¥âáï ¯à¨ ¯à®ç⥨¨) |
int 0x40 |
mcall |
red_win: |
call draw_window ;¯¥à¢® ç «ì® ¥®¡å®¤¨¬® à¨á®¢ âì ®ª® |
still: ;®á®¢®© ®¡à ¡®â稪 |
mov eax,10 ;¦¨¤ âì ᮡëâ¨ï |
int 0x40 ;®¦¨¤ âì ᮡë⨥ ¢ â¥ç¥¨¥ 2 ¬¨««¨á¥ªã¤ |
mcall ;®¦¨¤ âì ᮡë⨥ ¢ â¥ç¥¨¥ 2 ¬¨««¨á¥ªã¤ |
cmp al,0x1 ;¥á«¨ ¨§¬¥¨«®áì ¯®«®¦¥¨¥ ®ª |
jz red_win |
55,7 → 55,7 |
jmp still ;¥á«¨ ¨ç¥£® ¨§ ¯¥à¥ç¨á«¥®£® ⮠ᮢ ¢ 横« |
button: |
or eax,-1 ;¢ eax,-1 - 5 ,¡ ©â®¢ ã á ¦¥ ⮫쪮 3 ¢ë©â¨ |
int 0x40 ;¤ «¥¥ ¢ë¯®«ï¥âáï ¢ë室 ¨§ ¯à®£à ¬¬ë |
mcall ;¤ «¥¥ ¢ë¯®«ï¥âáï ¢ë室 ¨§ ¯à®£à ¬¬ë |
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>> |
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>> |
62,7 → 62,7 |
draw_window: ;à¨á®¢ ¨¥ ®ª ¯à¨«®¦¥¨ï |
mov eax,12 ;¢ ॣ¨áâà ¢¥á⨠§ 票¥ = 12 |
mov ebx,1 ;¯à¨á¢®¨âì 1 |
int 0x40 |
mcall |
xor eax,eax ;®¡ã«¨âì eax |
mov ebx,50*65536+180 ;[ª®®à¤¨ â ¯® ®á¨ x]*65536 + [à §¬¥à ¯® ®á¨ x] |
70,13 → 70,13 |
mov edx,[sc.work] ; color of work area RRGGBB,8->color gl |
or edx,0xb3000000 |
mov edi,hed |
int 0x40 ; à¨á®¢ âì ®ª® ¯à¨«®¦¥¨ï |
mcall ; à¨á®¢ âì ®ª® ¯à¨«®¦¥¨ï |
draw_check_boxes check_boxes,check_boxes_end ;à¨á®¢ ¨¥ 祪¡®ªá®¢ |
mov eax,12 ;ãªæ¨ï 12 - ç âì/§ ª®ç¨âì ¯¥à¥à¨á®¢ªã ®ª . |
mov ebx,2 ;®¤äãªæ¨ï 2 - § ª®ç¨âì ¯¥à¥à¨á®¢ªã ®ª . |
int 0x40 |
mcall |
ret |
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> |
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> |
/programs/develop/examples/circle/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
Property changes: |
Deleted: svn:eol-style |
-native |
\ No newline at end of property |
/programs/develop/examples/circle/trunk/circle.asm |
---|
16,7 → 16,7 |
dd 0x1000 ; esp |
dd 0x00000000 ; reserved=no extended header |
include 'macros.inc' |
include '..\..\..\..\macros.inc' |
29,7 → 29,7 |
still: |
mov eax,10 ; wait here for event |
int 0x40 |
mcall |
dec eax ; redraw request ? |
jz red |
38,16 → 38,16 |
button: |
mov al,17 ; get id |
int 0x40 |
mcall |
cmp ah,1 ; button id=1 ? |
jne noclose |
or eax,-1 ; close this program |
int 0x40 |
mcall |
key: ; key |
mov al,2 ; just read it and ignore |
int 0x40 |
mcall |
jmp still |
noclose: |
61,12 → 61,12 |
mov eax,50 ; give the shape reference area |
mov ebx,0 |
mov ecx,shape_reference |
int 0x40 |
mcall |
mov eax,50 ; give the shape scale 32 x 32 -> 128 x 128 |
mov ebx,1 ; you dont have to give this, scale is 1:1 by default |
mov ecx,2 |
int 0x40 |
mcall |
popa |
118,7 → 118,7 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,1 ; 1, start of draw |
int 0x40 |
mcall |
; DRAW WINDOW |
xor eax,eax ; function 0 : define and draw window |
129,7 → 129,7 |
mov edx,0x00cccc00 ; color of work area RRGGBB,8->color glide |
mov esi,0x00cccc00 ; color of grab bar RRGGBB,8->color glide |
mov edi,0x00cccc00 ; color of frames RRGGBB |
int 0x40 |
mcall |
; CLOSE BUTTON |
138,12 → 138,12 |
mov ecx,20*65536+12 ; [y start] *65536 + [y size] |
mov edx,1 ; button id |
mov esi,0x5599cc ; button color RRGGBB |
int 0x40 |
mcall |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,2 ; 2, end of draw |
int 0x40 |
mcall |
ret |
/programs/develop/examples/cpuspeed/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
/programs/develop/examples/cpuspeed/trunk/build_en.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix en >lang.inc |
@fasm cpuspeed.asm cpuspeed |
@erase lang.inc |
@pause |
/programs/develop/examples/cpuspeed/trunk/build_ru.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix ru >lang.inc |
@fasm cpuspeed.asm cpuspeed |
@erase lang.inc |
@pause |
/programs/develop/examples/cpuspeed/trunk/cpuspeed.asm |
---|
16,13 → 16,13 |
dd 0x00000000 ; reserved=no extended header |
include 'lang.inc' |
include 'macros.inc' |
include '..\..\..\..\macros.inc' |
START: ; start of execution |
mov eax,18 |
mov ebx,5 |
int 0x40 |
mcall |
xor edx,edx |
mov ebx,1000000 |
38,6 → 38,13 |
mov [edi],dl |
sub edi,1 |
loop newnum |
mov eax,48 |
mov ebx,3 |
mov ecx,sc |
mov edx,sizeof.system_colors |
mcall |
red: |
call draw_window ; at first, draw the window |
44,7 → 51,7 |
still: |
mov eax,10 ; wait here for event |
int 0x40 |
mcall |
cmp eax,1 ; redraw request ? |
jz red |
57,17 → 64,17 |
key: ; key |
mov eax,2 ; just read it and ignore |
int 0x40 |
mcall |
jmp still |
button: ; button |
mov eax,17 ; get id |
int 0x40 |
mcall |
cmp ah,1 ; button id=1 ? |
jnz still |
or eax,-1 ; close this program |
int 0x40 |
mcall |
; ********************************************* |
79,14 → 86,8 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,1 ; 1, start of draw |
int 0x40 |
mcall |
mov eax,48 |
mov ebx,3 |
mov ecx,sc |
mov edx,sizeof.system_colors |
int 0x40 |
; DRAW WINDOW |
mov eax,0 ; function 0 : define and draw window |
mov ebx,100*65536+200 ; [x start] *65536 + [x size] |
93,8 → 94,8 |
mov ecx,100*65536+65 ; [y start] *65536 + [y size] |
mov edx,[sc.work] ; color of work area RRGGBB,8->color glide |
or edx,0x33000000 ; color of grab bar RRGGBB,8->color |
mov edi,header ; WINDOW LABEL |
int 0x40 |
mov edi,title ; WINDOW LABEL |
mcall |
mov ebx,20*65536+14 ; draw info text with function 4 |
102,11 → 103,11 |
mov edx,text |
mov esi,24 |
mov eax,4 |
int 0x40 |
mcall |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,2 ; 2, end of draw |
int 0x40 |
mcall |
ret |
117,7 → 118,7 |
text: |
db 'CPU RUNNING AT MHZ' |
header db 'CPU SPEED',0 |
title db 'CPU SPEED',0 |
I_END: |
/programs/develop/examples/editbox/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
/programs/develop/examples/editbox/trunk/editbox.asm |
---|
13,7 → 13,7 |
dd i_end ; ¡ê¥¬ ¨á¯®«ì§ã¥¬®© ¯ ¬ïâ¨, ¤«ï á⥪ ®â¢¥¤¥¬ 0å100 ¡ ©â ¨ ¢ë஢¨¬ £à¨æã 4 ¡ ©â |
dd i_end ; à ᯮ«®¦¨¬ ¯®§¨æ¨î á⥪ ¢ ®¡« á⨠¯ ¬ïâ¨, áà §ã § ⥫®¬ ¯à®£à ¬¬ë. ¥àè¨ á⥪ ¢ ¤¨ ¯ §®¥ ¯ ¬ïâ¨, 㪠§ ®¬ ¢ëè¥ |
dd 0x0,0x0 ; 㪠§ ⥫ì áâபã á ¯ à ¬¥âà ¬¨. |
include 'macros.inc' |
include '..\..\..\..\macros.inc' |
include 'editbox.inc' |
align 4 |
use_edit_box procinfo,22,5 |
/programs/develop/examples/example/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
Property changes: |
Deleted: svn:eol-style |
-native |
\ No newline at end of property |
/programs/develop/examples/example/trunk/build_en.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix en >lang.inc |
@fasm example.asm example |
@erase lang.inc |
@pause |
/programs/develop/examples/example/trunk/build_ru.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix ru >lang.inc |
@fasm example.asm example |
@erase lang.inc |
@pause |
/programs/develop/examples/example/trunk/example.asm |
---|
24,7 → 24,7 |
dd 0x0 ; § १¥à¢¨à®¢ ® |
include 'lang.inc' |
include 'macros.inc' ; ¬ ªà®áë ®¡«¥£ç îâ ¦¨§ì áᥬ¡«¥à騪®¢! |
include '..\..\..\..\macros.inc' ; ¬ ªà®áë ®¡«¥£ç îâ ¦¨§ì áᥬ¡«¥à騪®¢! |
;--------------------------------------------------------------------- |
;--- ---------------------------------------------- |
108,7 → 108,7 |
; mov edi,header ; |
; int 0x40 |
mcall 0, <200,200>, <200,50>, 0x33AABBCC,,header |
mcall 0, <200,200>, <200,50>, 0x33AABBCC,,title |
148,7 → 148,7 |
en,'Press any key...',\ |
fr,'Pressez une touche...' |
lsz header,\ |
lsz title,\ |
ru,' ',\ |
en,'EXAMPLE APPLICATION',\ |
fr,"L'exemplaire programme" |
/programs/develop/examples/example2/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
Property changes: |
Deleted: svn:eol-style |
-native |
\ No newline at end of property |
/programs/develop/examples/example2/trunk/build_en.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix en >lang.inc |
@fasm example2.asm example2 |
@erase lang.inc |
@pause |
/programs/develop/examples/example2/trunk/build_ru.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix ru >lang.inc |
@fasm example2.asm example2 |
@erase lang.inc |
@pause |
/programs/develop/examples/example2/trunk/dialogs1.inc |
---|
59,7 → 59,7 |
mov eax,37 |
mov ebx,2 |
int 0x40 |
mcall |
cmp [window_on],0 |
jne openw2 |
73,7 → 73,7 |
mov eax,23 |
mov ebx,2 |
int 0x40 |
mcall |
cmp eax,0 |
jne no_open |
80,7 → 80,7 |
mov eax,37 |
mov ebx,2 |
int 0x40 |
mcall |
cmp eax,0 |
jne waitformouse |
88,7 → 88,7 |
mov eax,37 |
mov ebx,1 |
int 0x40 |
mcall |
mov esi,eax |
120,7 → 120,7 |
waitm: |
mov eax,5 |
mov ebx,1 |
int 0x40 |
mcall |
dec ecx |
jz no_open |
cmp [window_on],0 |
150,7 → 150,7 |
mov eax,9 |
mov ebx,table |
mov ecx,-1 |
int 0x40 |
mcall |
mov eax,[table+34] |
mov [mo_x],eax |
161,7 → 161,7 |
mov ebx,1 |
mov ecx,alert_entry |
mov edx,[g_stack] |
int 0x40 |
mcall |
mov [esp+28],dword 0 ; clear button entry |
179,7 → 179,7 |
mov eax,9 |
mov ebx,table |
mov ecx,-1 |
int 0x40 |
mcall |
cmp [table+46],dword 30 |
jb drmr |
193,7 → 193,7 |
shl ecx,16 |
add ecx,[m_ys] |
mov edx,0xf0f8ff |
int 0x40 |
mcall |
mov eax,38 ; egde lines |
mov ebx,[m_x] |
204,7 → 204,7 |
shl ecx,16 |
add ecx,[m_y] |
mov edx,0x000000 |
int 0x40 |
mcall |
mov eax,38 |
mov ecx,[m_y] |
add ecx,[m_ys] |
211,7 → 211,7 |
shl ecx,16 |
add ecx,[m_y] |
add ecx,[m_ys] |
int 0x40 |
mcall |
mov esi,menu-1 |
mov edi,[m_x] |
231,7 → 231,7 |
mov edx,esi |
add edx,3 |
mov esi,12 |
int 0x40 ; draw text |
mcall ; draw text |
pop esi |
add esi,2 |
add edi,50 |
282,7 → 282,7 |
mov ebx,1 |
mov ecx,alert_entry |
mov edx,[g_stack] |
int 0x40 |
mcall |
mov [menu_action],'MA ' |
298,7 → 298,7 |
mov eax,23 ; wait here for event |
mov ebx,1 |
int 0x40 |
mcall |
cmp eax,1 ; redraw request ? |
je alert_red |
313,7 → 313,7 |
mov eax,9 |
mov ebx,table |
mov ecx,-1 |
int 0x40 |
mcall |
cmp ax,[table+4] |
je no_close |
323,7 → 323,7 |
mov [menu_action],'----' |
mov [window_on],0 |
mov eax,-1 |
int 0x40 |
mcall |
no_close: |
jmp alert_still |
334,12 → 334,12 |
alert_key: ; key |
mov eax,2 ; just read it and ignore |
int 0x40 |
mcall |
jmp alert_still |
alert_button: ; button |
mov eax,17 ; get id |
int 0x40 |
mcall |
shr eax,8 |
cmp eax,3 |
364,7 → 364,7 |
mov [g_n],-1 |
mov [window_on],0 |
mov eax,-1 ; close this program |
int 0x40 |
mcall |
rtext db 'NO YES OK ' |
381,7 → 381,7 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,1 ; 1, start of draw |
int 0x40 |
mcall |
cmp [window_on],2 |
jne no_win_type_2 |
418,7 → 418,7 |
mov edx,0x00ffffff ; color of work area RRGGBB,8->color gl |
mov esi,0x00ffffff ; color of grab bar RRGGBB,8->color gl |
mov edi,0x000000cc ; color of frames RRGGBB |
int 0x40 |
mcall |
pop edx |
445,10 → 445,10 |
mov edx,0x40000000 |
add edx,ebp |
mov esi,0 |
int 0x40 |
mcall |
popa |
mov eax,4 ; draw text |
int 0x40 |
mcall |
inc ebp |
add ebx,14 |
jmp no_d_found |
461,7 → 461,7 |
jne no_win_1 |
mov eax,14 ; to middle of screen |
int 0x40 |
mcall |
mov ecx,eax |
and ecx,0xffff |
shr ecx,1 |
480,7 → 480,7 |
mov edx,0x02ffffff ; color of work area RRGGBB,8->color gl |
mov esi,0x80d05050 ; color of grab bar RRGGBB,8->color gl |
mov edi,0x00d05050 ; color of frames RRGGBB |
int 0x40 |
mcall |
mov eax,4 ; label |
488,7 → 488,7 |
mov ecx,0x10ddeeff |
mov edx,alert_labelt1 |
mov esi,alert_label1len-alert_labelt1 |
int 0x40 |
mcall |
mov eax,4 |
mov ebx,10*65536+43 |
495,7 → 495,7 |
mov ecx,0x10000000 |
mov edx,[g_t] |
mov esi,[g_l] |
int 0x40 |
mcall |
cmp [g_1],1 |
jne gadgets_no_1 |
509,7 → 509,7 |
mov ecx,75*65536+16 |
mov edx,3 |
mov esi,0x446688 |
int 0x40 |
mcall |
mov eax,4 |
mov ebx,[g_x] |
520,7 → 520,7 |
mov ecx,0x10ffffff |
mov edx,alert_t2 |
mov esi,alert_t2len-alert_t2 |
int 0x40 |
mcall |
gadgets_no_1: |
536,7 → 536,7 |
mov ecx,75*65536+16 |
mov edx,1 |
mov esi,0x446688 |
int 0x40 |
mcall |
mov eax,8 |
mov ebx,[g_x] |
547,7 → 547,7 |
mov ecx,75*65536+16 |
mov edx,2 |
mov esi,0x446688 |
int 0x40 |
mcall |
mov eax,4 |
mov ebx,[g_x] |
558,7 → 558,7 |
mov ecx,0x10ffffff |
mov edx,alert_t1 |
mov esi,alert_t1len-alert_t1 |
int 0x40 |
mcall |
gadgets_no_2: |
566,7 → 566,7 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,2 ; 2, end of draw |
int 0x40 |
mcall |
ret |
/programs/develop/examples/example2/trunk/example2.asm |
---|
18,7 → 18,7 |
dd 0x0 , 0x0 ; I_Param , I_Icon |
include 'lang.inc' |
include 'macros.inc' |
include '..\..\..\..\macros.inc' |
include 'dialogs1.inc' |
menu_history dd 0x0 |
25,13 → 25,13 |
START: ; start of execution |
red: |
call draw_window_main |
still: ; wait here for event |
mov eax,23 |
mov ebx,2 |
int 0x40 |
mov eax,10 |
mcall |
cmp eax,1 ; process events |
je red |
52,7 → 52,7 |
mov ebx,220*65536+6*4 |
mov ecx,70*65536+8 |
mov edx,0xffffff |
int 0x40 |
mcall |
mov eax,4 ; show menu selections |
mov ebx,220*65536+70 |
59,7 → 59,7 |
mov ecx,0x000000 |
mov edx,menu_action |
mov esi,4 |
int 0x40 |
mcall |
nodisplay: |
66,28 → 66,24 |
cmp word [menu_action],word 'AD' ; user requests close |
jne no_menu_close |
mov eax,-1 |
int 0x40 |
mcall |
no_menu_close: |
jmp still |
red: ; redraw |
call draw_window_main |
jmp still |
key: |
mov eax,2 ; key in buffer |
int 0x40 |
mcall |
jmp still |
button: ; button in buffer |
mov eax,17 |
int 0x40 |
mcall |
cmp ah,1 ; close application |
jne noclose |
mov eax,-1 |
int 0x40 |
or eax,-1 |
mcall |
noclose: |
cmp ah,2 |
122,7 → 118,7 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,1 ; 1, start of draw |
int 0x40 |
mcall |
mov eax,0 ; open window |
mov ebx,100*65536+300 |
130,7 → 126,7 |
mov edx,0x02ffffff |
mov esi,0x805080d0 |
mov edi,0x005080d0 |
int 0x40 |
mcall |
call draw_menu ; DRAW MENU |
139,7 → 135,7 |
mov ecx,0x10ddeeff |
mov edx,labelt |
mov esi,labellen-labelt |
int 0x40 |
mcall |
mov eax,8 ; close button |
mov ebx,(300-17)*65536+10 |
146,7 → 142,7 |
mov ecx,5*65536+10 |
mov edx,1 |
mov esi,0x4466bb |
int 0x40 |
mcall |
mov eax,8 ; button : OPEN ALERT BOX |
mov ebx,25*65536+150 |
153,7 → 149,7 |
mov ecx,61*65536+14 |
mov edx,2 |
mov esi,0x4466aa |
int 0x40 |
mcall |
mov eax,8 ; button : OPEN CHOOSE BOX |
mov ebx,25*65536+150 |
160,7 → 156,7 |
mov ecx,81*65536+14 |
mov edx,3 |
mov esi,0x4466aa |
int 0x40 |
mcall |
mov ebx,20*65536+55 ; draw info text with function 4 |
mov ecx,0xffffff |
168,7 → 164,7 |
mov esi,40 |
newline: |
mov eax,4 |
int 0x40 |
mcall |
add ebx,10 |
add edx,40 |
cmp [edx],byte 'x' |
176,7 → 172,7 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,2 ; 2, end of draw |
int 0x40 |
mcall |
ret |
/programs/develop/examples/example3/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
Property changes: |
Deleted: svn:eol-style |
-native |
\ No newline at end of property |
/programs/develop/examples/example3/trunk/build_en.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix en >lang.inc |
@fasm example3.asm example3 |
@erase lang.inc |
@pause |
/programs/develop/examples/example3/trunk/build_ru.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix ru >lang.inc |
@fasm example3.asm example3 |
@erase lang.inc |
@pause |
/programs/develop/examples/example3/trunk/example3.asm |
---|
16,10 → 16,11 |
dd 0x0 , 0x0 ; I_Param , I_Icon |
include 'lang.inc' |
include 'macros.inc' |
include '..\..\..\..\macros.inc' |
START: ; start of execution |
red: |
call draw_window ; draw window |
call clear_data ; clear status bar |
26,34 → 27,26 |
still: |
mov eax,10 ; wait here for event |
int 0x40 ; do it |
mcall ; do it |
cmp eax,1 ; redraw request ? |
je red ; yes jump to it |
jz red ; yes jump to it |
cmp eax,2 ; key in buffer ? |
je key ; yes jump to it |
cmp eax,3 ; button in buffer ? |
je button ; yes jump to it |
jmp still ; start again |
jnz button |
red: ; redraw |
call draw_window ; redraw window |
call clear_data ; clear status info |
jmp still ; start again |
key: ; key |
mov eax,2 ; just read it and ignore |
int 0x40 ; do it |
mcall ; do it |
jmp still ; start again |
button: ; button |
mov eax,17 ; get id |
int 0x40 ; do it |
mcall ; do it |
cmp ah,1 ; is it the close button |
jne noclose ; no then jump code |
mov eax,-1 ; close this program |
int 0x40 ; do it |
or eax,-1 ; close this program |
mcall ; do it |
noclose: |
cmp ah,100 ; is it main menu |
92,7 → 85,7 |
mov eax,12 ; function 12: tell os about windowdraw |
mov ebx,1 ; 1, start of draw |
int 0x40 ; do it |
mcall ; do it |
mov eax,0 ; function 0: define and draw window |
mov ebx,50*65536 ; [x start] *65536 |
101,7 → 94,7 |
add ecx,[y_size] ; add [y size] |
mov edx,0x80ffffff ; colour of work area RRGGBB |
mov esi,0x806688dd ; grab bar colour. negative glide |
int 0x40 ; do it |
mcall ; do it |
mov eax,4 ; function 4: write text to window |
mov ebx,6*65536+7 ; [x start] *65536 + [y start] |
108,7 → 101,7 |
mov ecx,0x00ffffff ; text colour |
mov edx,window_text ; pointer to text beginning |
mov esi,12 ; text length |
int 0x40 ; do it |
mcall ; do it |
mov eax,8 ; function 8: define and draw button |
mov ebx,(381-18)*65536+13 ; [x start] *65536 + [x size] |
115,7 → 108,7 |
mov ecx,4*65536+13 ; [y start] *65536 + [y size] |
mov edx,1 ; button id |
mov esi,0x6688dd ; button color RRGGBB |
int 0x40 ; do it |
mcall ; do it |
mov eax,13 ; function 13: draw bar |
mov ebx,1*65536 ; [x start] *65536 |
126,7 → 119,7 |
shl ecx,16 ; *65536 |
add ecx,17 ; add height |
mov edx,0x006688dd ; bar colour |
int 0x40 ; do it |
mcall ; do it |
mov eax,4 ; function 4 : write text to window |
mov ebx,5*65536 ; [x start] *65536 |
135,17 → 128,17 |
xor ecx,ecx ; text colour |
mov edx,button_no ; pointer to text beginning |
mov esi,14 ; text length |
int 0x40 ; do it |
mcall ; do it |
add ebx,95*65536 ; move xy position |
mov edx,menu_text ; pointer to text beginning |
int 0x40 ; do it |
mcall ; do it |
call write_main ; draw menu |
mov eax,12 ; function 12: tell os about windowdraw |
mov ebx,2 ; 2, end of draw |
int 0x40 ; do it |
mcall ; do it |
pop eax ; restore register |
ret ; return |
160,7 → 153,7 |
dec ebx ; x size - 1 |
mov ecx,21*65536+17 ; [y start] *65536 +[y size] |
mov edx,[menu_colour] ; menu colour |
int 0x40 ; do it |
mcall ; do it |
mov [main_pos],1 ; start position first button |
xor edi,edi ; data offset = 0 |
184,7 → 177,7 |
xor edx,edx ; clear register |
mov dl,[MENU_DATA+edi+2] ; get byte button id number |
mov esi,[menu_colour] ; button colour |
int 0x40 ; do it |
mcall ; do it |
mov eax,4 ; function 4: write text to window |
add ebx,6*65536-49 ; move xy position |
xor ecx,ecx ; text colour |
191,7 → 184,7 |
mov edx,MENU_DATA+3 ; point at menu text |
add edx,edi ; add our offset |
mov esi,11 ; number of characters |
int 0x40 ; do it |
mcall ; do it |
is_main_bar: |
add [main_pos],76 ; update button position |
217,7 → 210,7 |
add edx,[y_size] ; +[y start] |
sub edx,12 ; move position |
xor esi,esi ; text colour |
int 0x40 ; do it |
mcall ; do it |
pop eax ; restore register |
cmp [button_press],1 ; has a sub button been pressed |
238,7 → 231,7 |
mov esi,1 ; 1 character |
mov eax,4 ; function 4: write text to window |
xor ecx,ecx ; text colour |
int 0x40 ; do it |
mcall ; do it |
pop eax ; restore register |
draw_get_out: |
256,9 → 249,9 |
shl ecx,16 ; *65536 |
add ecx,13 ; [y size] |
mov edx,0x00aaaaaa ; bar colour |
int 0x40 ; do it |
mcall ; do it |
mov ebx,185*65536+11 ; move position |
int 0x40 ; do it again |
mcall ; do it again |
pop eax ; restore register |
ret ; return |
309,7 → 302,7 |
mov ecx,[but_pos] ; [y start] |
shl ecx,16 ; *65536 |
add ecx,17 ; [y size] |
int 0x40 ; do it |
mcall ; do it |
jmp is_sub_bar ; jump button code |
is_sub_button: |
323,7 → 316,7 |
shl ecx,16 ; *65536 |
add ecx,16 ; [y size] |
mov esi,[menu_colour] ; button colour |
int 0x40 ; do it |
mcall ; do it |
mov ebx,[sub_pos] ; [x start] |
shl ebx,16 ; *65536 |
335,7 → 328,7 |
add edx,edi ; add offset |
mov esi,11 ; number of characters |
mov eax,4 ; function 4: write text to window |
int 0x40 ; do it |
mcall ; do it |
is_sub_bar: |
add [but_pos],17 ; move y position |
/programs/develop/examples/hello/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
Property changes: |
Deleted: svn:eol-style |
-native |
\ No newline at end of property |
/programs/develop/examples/hello/trunk/build_en.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix en >lang.inc |
@fasm hello.asm hello |
@erase lang.inc |
@pause |
/programs/develop/examples/hello/trunk/build_ru.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix ru >lang.inc |
@fasm hello.asm hello |
@erase lang.inc |
@pause |
/programs/develop/examples/hello/trunk/cmdipc.inc |
---|
1,10 → 1,10 |
include "macros.inc" |
include "..\..\..\..\macros.inc" |
initipc: |
mov eax,9 |
mov ebx,prc |
mov ecx,-1 |
int 0x40 |
mcall |
mov ecx,eax |
loop1: |
12,7 → 12,7 |
mov eax,9 |
mov ebx,prc |
int 0x40 |
mcall |
cmp word [prc+10],'CM' |
jne no_cmd |
39,7 → 39,7 |
mov ecx,dword [cmdpid] |
mov edx,printf |
mov esi,4 |
int 0x40 |
mcall |
call initcmd |
46,11 → 46,11 |
waitcmdinit: |
mov eax,40 |
mov ebx,01000000b |
int 0x40 |
mcall |
mov eax,23 |
mov ebx,100 |
int 0x40 |
mcall |
cmp eax,7 |
je cmd_ok |
64,7 → 64,7 |
mov eax,18 |
mov ebx,3 |
mov ecx,dword [cmdnumb] |
int 0x40 |
mcall |
ret |
71,12 → 71,12 |
pause1: |
mov eax,5 |
mov ebx,1 |
int 0x40 |
mcall |
ret |
exit: |
mov eax,-1 |
int 0x40 |
mcall |
cls: |
mov eax,60 |
84,7 → 84,7 |
mov ecx,dword [cmdpid] |
mov edx,ipccls |
mov esi,4 |
int 0x40 |
mcall |
call pause1 |
120,7 → 120,7 |
mov ecx,dword [cmdpid] |
mov edx,stripc |
mov esi,84 |
int 0x40 |
mcall |
call pause1 |
132,7 → 132,7 |
mov ecx,dword [cmdpid] |
mov edx,ipceol |
mov esi,4 |
int 0x40 |
mcall |
call pause1 |
144,13 → 144,13 |
mov ecx,dword [cmdpid] |
mov edx,ipckey |
mov esi,4 |
int 0x40 |
mcall |
mov eax,60 |
mov ebx,1 |
mov ecx,ipcb |
mov edx,28 |
int 0x40 |
mcall |
cld |
mov ecx,28 |
166,10 → 166,10 |
waitagain: |
mov eax,40 |
mov ebx,01000000b |
int 0x40 |
mcall |
mov eax,10 |
int 0x40 |
mcall |
cmp eax,7 |
jne waitagain |
186,7 → 186,7 |
mov ecx,dword [cmdpid] |
mov edx,ipcend |
mov esi,4 |
int 0x40 |
mcall |
jmp exit |
/programs/develop/examples/ir/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
/programs/develop/examples/ir/trunk/build_en.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix en >lang.inc |
@fasm ir.asm ir |
@erase lang.inc |
@pause |
/programs/develop/examples/ir/trunk/build_ru.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix ru >lang.inc |
@fasm ir.asm ir |
@erase lang.inc |
@pause |
/programs/develop/examples/ir/trunk/ir.asm |
---|
17,7 → 17,7 |
dd 0, 0 |
include 'macros.inc' |
include '..\..\..\..\macros.inc' |
START: ; start of execution |
27,17 → 27,17 |
mov ebx,0 |
mov ecx,0x3f0 |
mov edx,0x3ff |
int 0x40 |
mcall |
mov eax,45 ; reserve irq 4 |
mov ebx,0 |
mov ecx,4 |
int 0x40 |
mcall |
mov eax,44 ; set read ports for irq 4 |
mov ebx,irqtable |
; mov ecx,4 |
int 0x40 |
mcall |
mov dh, 3 ; all ports have number 3xx hex |
67,7 → 67,7 |
mov eax,5 |
mov ebx,100 |
int 0x40 |
mcall |
mov dl, 0xf8 |
mov al, 'I' |
75,7 → 75,7 |
mov eax,5 |
mov ebx,10 |
int 0x40 |
mcall |
mov al, 'R' |
out dx, al |
82,7 → 82,7 |
mov eax,40 ; get com 1 data with irq 4 |
mov ebx,0000000000010000b shl 16 + 101b |
int 0x40 |
mcall |
red: |
call draw_window |
90,7 → 90,7 |
still: |
mov eax,10 ; wait here for event |
int 0x40 |
mcall |
dec eax |
jz red |
dec eax |
99,7 → 99,7 |
button: ; button |
mov al,17 ; get id |
int 0x40 |
mcall |
; we have only one button, close |
106,16 → 106,16 |
mov eax,45 ; free irq |
mov ebx,1 |
mov ecx,4 |
int 0x40 |
mcall |
mov eax,46 ; free ports 0x3f0-0x3ff |
mov ebx,1 |
mov ecx,0x3f0 |
mov edx,0x3ff |
int 0x40 |
mcall |
or eax,-1 ; close this program |
int 0x40 |
mcall |
pos dd 0x0 |
130,7 → 130,7 |
readir: |
mov eax,42 |
mov ebx,4 |
int 0x40 |
mcall |
cmp ebx,80 |
jne nocd |
137,7 → 137,7 |
mov eax,70 |
mov ebx,cdplayer |
int 0x40 |
mcall |
nocd: |
156,7 → 156,7 |
mov ebx,20*65536+260 |
mov ecx,22*65536+220 |
mov edx,[wcolor] |
int 0x40 |
mcall |
mov eax,10*19+1 |
noeaxz: |
mov [pos],eax |
209,7 → 209,7 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,1 ; 1, start of draw |
int 0x40 |
mcall |
; DRAW WINDOW |
mov eax,0 ; function 0 : define and draw window |
217,7 → 217,7 |
mov ecx,100*65536+250 ; [y start] *65536 + [y size] |
mov edx,[wcolor] ; color of work area RRGGBB,8->color |
mov edi,labelt ; caption string |
int 0x40 |
mcall |
; ; WINDOW LABEL |
; mov eax,4 ; function 4 : write text to window |
225,7 → 225,7 |
; mov ecx,0x00ffffff ; color of text RRGGBB |
; mov edx,labelt ; pointer to text beginning |
; mov esi,labellen-labelt ; text length |
; int 0x40 |
; mcall |
; CLOSE BUTTON |
; mov eax,8 ; function 8 : define and draw button |
233,7 → 233,7 |
; mov ecx,5*65536+12 ; [y start] *65536 + [y size] |
; mov edx,1 ; button id |
; mov esi,0x5599cc ; button color RRGGBB |
; int 0x40 |
; mcall |
draw_text: |
244,7 → 244,7 |
mov edi,20 |
newline: |
mov eax,4 |
int 0x40 |
mcall |
add ebx,10 |
add edx,esi |
dec edi |
252,7 → 252,7 |
mov eax,12 |
mov ebx,2 |
int 0x40 |
mcall |
ret |
/programs/develop/examples/md5/trunk/build_en.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix en >lang.inc |
@fasm md5.asm md5 |
@erase lang.inc |
@pause |
/programs/develop/examples/md5/trunk/build_ru.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix ru >lang.inc |
@fasm md5.asm md5 |
@erase lang.inc |
@pause |
/programs/develop/examples/md5/trunk/md5.asm |
---|
12,20 → 12,7 |
; |
; ®¬¯¨«¨àã¥âìáï Fasm'®¬ ¤«ï ¥ãíâ |
include 'lang.inc' |
macro diff16 title,l2 |
{ |
local s,d,l1 |
s = l2 |
display title,': 0x' |
repeat 8 |
d = 48 + s shr ((8-%) shl 2) and $0F |
if d > 57 |
d = d + 65-57-1 |
end if |
display d |
end repeat |
display 13,10 |
} |
include '..\..\..\..\macros.inc' |
use32 |
35,47 → 22,39 |
dd 0x01 ; ¢¥àá¨ï § £®«®¢ª (¢á¥£¤ 1) |
dd START ; ¤à¥á ¯¥à¢®© ª®¬ ¤ë |
dd I_END ; à §¬¥à ¯à®£à ¬¬ë |
dd 0x100000 ; ª®«¨ç¥á⢮ ¯ ¬ï⨠|
dd 0x100000 ; ¤à¥á ¢¥àè¨ë áâíª |
dd 0x4000 ; ª®«¨ç¥á⢮ ¯ ¬ï⨠|
dd 0x4000 ; ¤à¥á ¢¥àè¨ë áâíª |
dd 0x0 ; ¤à¥á ¡ãä¥à ¤«ï ¯ à ¬¥â஢ (¥ ¨á¯®«ì§ã¥âáï) |
dd 0x0 ; § १¥à¢¨à®¢ ® |
START: ; ç «® ¢ë¯®«¥¨ï ¯à®£à ¬¬ë |
red: |
call draw_window ; ¯¥à¢ ¯¥à¥à¨á㥬 ®ª® |
still: |
mov eax,23 ; ¦¨¤ ¥¬ ᮡë⨩ |
mov ebx,1 |
int 0x40 |
mov eax,10 ; ¦¨¤ ¥¬ ᮡë⨩ |
mcall |
cmp eax,1 ; ¯à®á ¯¥à¥à¨á®¢ªã ? |
jz red |
cmp eax,2 ; ¦ â ª« ¢¨è¨ ? |
jz key |
cmp eax,3 ; ¦ â ª®¯ª ? |
jz button |
jnz button |
jmp still |
red: |
call draw_window |
jmp still |
key: |
mov eax,2 |
int 0x40 |
mcall |
jmp still |
button: |
mov eax,17 |
int 0x40 |
mcall |
cmp ah,1 ; id ª®¯ª¨ = 1 ? |
jnz noclose |
mov eax,-1 |
int 0x40 |
or eax,-1 |
mcall |
noclose: |
356,23 → 335,16 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,1 ; 1, start of draw |
int 0x40 |
mcall |
; DRAW WINDOW |
mov eax,0 ; function 0 : define and draw window |
mov ebx,100*65536+230 ; [x start] *65536 + [x size] |
mov ecx,60*65536+100 ; [y start] *65536 + [y size] |
mov edx,0x03ffffff ; color of work area RRGGBB |
mov esi,0x80aabbcc ; color of grab bar RRGGBB,8->color gl |
mov edi,0x00aabbcc ; color of frames RRGGBB |
int 0x40 |
mov edx,0x13ffffff ; color of work area RRGGBB |
mov edi,title ; WINDOW LABEL |
mcall |
; WINDOW LABEL |
mov eax,4 ; function 4 : write text to window |
mov ebx,8*65536+8 ; [x start] *65536 + [y start] |
mov ecx,0x00ffffff ; color of text RRGGBB |
mov edx,labeltext ; pointer to text beginning |
mov esi,lte-labeltext ; text length |
int 0x40 |
; ¨á㥬 ª®¯ªã ¤«ï £¥¥à 樨 |
mov eax,8 ; function 8 : define and draw button |
mov ebx,20*65536+80 ; [x start] *65536 + [x size] |
379,7 → 351,7 |
mov ecx,34*65536+14 ; [y start] *65536 + [y size] |
mov edx,2 ; button id |
mov esi,0x5588dd ; button color RRGGBB |
int 0x40 |
mcall |
; §¢ ¨¥ ª®¯ªã |
mov eax,4 ; function 4 : write text to window |
387,9 → 359,8 |
mov ecx,0x000000 ; color of text RRGGBB |
mov edx,gen_txt ; pointer to text beginning |
mov esi,gen_len-gen_txt ; text length |
int 0x40 |
mcall |
mov eax,4 ; draw info text with function 4 |
mov ebx,20*65536+70 |
mov ecx,0x000000 |
mov edx,[text] |
397,18 → 368,17 |
mov al, [textlen] |
mov esi,eax |
mov eax,4 |
int 0x40 |
mcall |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,2 ; 2, end of draw |
int 0x40 |
mcall |
ret |
;¡« áâì ¤ ëå |
labeltext: db 'MD5 Generator' |
lte: |
title db 'MD5 Generator',0 |
text: dd 0 |
textlen: dd 0 |
/programs/develop/examples/numcalc/trunk/@numcalc.asm |
---|
1,3 → 1,4 |
include '..\..\..\..\macros.inc' |
use32 |
db 'MENUET01' |
dd 1 |
15,17 → 16,17 |
pop ebx |
mov cl, 45h ; NumLock scancode |
xor edx, edx |
int 40h |
mcall |
mov al, 40 ; ñòàðøèå áèòû óæå îáíóëåíû |
mov bl, 2 ; ñòàðøèå áèòû óæå îáíóëåíû |
int 40h |
mcall |
event: |
push 10 |
pop eax |
int 40h |
mcall |
; ó íàñ ìîæåò áûòü òîëüêî îäíî ñîáûòèå - íàæàòà êëàâèøà |
mov al, 2 |
int 40h |
mcall |
cmp al, 2 |
jnz event |
; ó íàñ åñòü òîëüêî îäíà ãîðÿ÷àÿ êëàâèøà |
32,7 → 33,7 |
push 70 |
pop eax |
mov ebx, fileinfo |
int 40h |
mcall |
jmp event |
fileinfo: |
/programs/develop/examples/radiobutton/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
/programs/develop/examples/radiobutton/trunk/optionbox.asm |
---|
23,7 → 23,7 |
; 㪠§ ⥫ì áâபã, ¢ ª®â®àãî § ¯¨á ¯ãâì, |
; ®âªã¤ § ¯ã饮 ¯à¨«®¦¥¨¥ |
;------------------ |
include 'macros.inc' |
include '..\..\..\..\macros.inc' |
include 'optionbox.inc' ;¢ª«îç¨âì ä ©« opeck.inc |
version_op ;¢ ਠâ, ¯à¨ ª®â®à®¬ ¨á¯®«ì§ãîâáï 梥â , ª®â®àë¥ § ¤ ¥â ¯®«ì§®¢ ⥫ì |
36,16 → 36,16 |
mov ebx,3 |
mov ecx,sc |
mov edx,sizeof.system_colors |
int 0x40 |
mcall |
mov eax,40 ;ãáâ ®¢¨âì ¬ áªã ¤«ï ®¦¨¤ ¥¬ëå ᮡë⨩ |
mov ebx,0x25 ;á¨á⥬ ¡ã¤¥â ॠ£¨à®¢ âì ⮫쪮 á®®¡é¥¨¥ ® ¯¥à¥à¨á®¢ª¥, ¦ â ª®¯ª , ®¯à¥¤¥«ñ ï à ¥¥, ᮡë⨥ ®â ¬ëè¨ (çâ®-â® á«ã稫®áì - ¦ ⨥ ª®¯ªã ¬ëè¨ ¨«¨ ¯¥à¥¬¥é¥¨¥; á¡à áë¢ ¥âáï ¯à¨ ¯à®ç⥨¨) |
int 0x40 |
mcall |
red_win: |
call draw_window ;¯¥à¢® ç «ì® ¥®¡å®¤¨¬® à¨á®¢ âì ®ª® |
still: ;®á®¢®© ®¡à ¡®â稪 |
mov eax,10 ;¦¨¤ âì ᮡëâ¨ï |
int 0x40 ;®¦¨¤ âì ᮡë⨥ ¢ â¥ç¥¨¥ 2 ¬¨««¨á¥ªã¤ |
mcall ;®¦¨¤ âì ᮡë⨥ ¢ â¥ç¥¨¥ 2 ¬¨««¨á¥ªã¤ |
cmp al,0x1 ;¥á«¨ ¨§¬¥¨«®áì ¯®«®¦¥¨¥ ®ª |
jz red_win |
55,17 → 55,17 |
jmp still ;¥á«¨ ¨ç¥£® ¨§ ¯¥à¥ç¨á«¥®£® ⮠ᮢ ¢ 横« |
button: |
; mov eax,17 ;¯®«ãç¨âì ¨¤¥â¨ä¨ª â®à ¦ ⮩ ª« ¢¨è¨ |
; int 0x40 |
; mcall |
; test ah,ah ;¥á«¨ ¢ ah 0, â® ¯¥à¥©â¨ ®¡à ¡®â稪 ᮡë⨩ still |
; jz still |
or eax,-1 ;¢ eax,-1 - 5 ,¡ ©â®¢ ã á ¦¥ ⮫쪮 3 ¢ë©â¨ |
int 0x40 ;¤ «¥¥ ¢ë¯®«ï¥âáï ¢ë室 ¨§ ¯à®£à ¬¬ë |
mcall ;¤ «¥¥ ¢ë¯®«ï¥âáï ¢ë室 ¨§ ¯à®£à ¬¬ë |
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>> |
draw_window: ;à¨á®¢ ¨¥ ®ª ¯à¨«®¦¥¨ï |
mov eax,12 ;¢ ॣ¨áâà ¢¥á⨠§ 票¥ = 12 |
mov ebx,1 ;¯à¨á¢®¨âì 1 |
int 0x40 |
mcall |
xor eax,eax ;®¡ã«¨âì eax |
mov ebx,50*65536+180 ;[ª®®à¤¨ â ¯® ®á¨ x]*65536 + [à §¬¥à ¯® ®á¨ x] |
73,13 → 73,13 |
mov edx,[sc.work] ; color of work area RRGGBB,8->color gl |
or edx,0xb3000000 |
mov edi,hed |
int 0x40 ; à¨á®¢ âì ®ª® ¯à¨«®¦¥¨ï |
mcall ; à¨á®¢ âì ®ª® ¯à¨«®¦¥¨ï |
draw_option_boxes option_boxes,option_boxes_end ;à¨á®¢ ¨¥ 祪¡®ªá®¢ |
mov eax,12 ;ãªæ¨ï 12 - ç âì/§ ª®ç¨âì ¯¥à¥à¨á®¢ªã ®ª . |
mov ebx,2 ;®¤äãªæ¨ï 2 - § ª®ç¨âì ¯¥à¥à¨á®¢ªã ®ª . |
int 0x40 |
mcall |
ret |
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> |
/programs/develop/examples/radiobutton/trunk/optionbox.bat |
---|
1,4 → 1,2 |
@fasm.exe optionbox.asm optionbox |
@kpack.exe optionbox |
REM @klbrinwin.exe optionbox |
@pause |
/programs/develop/examples/radiobutton/trunk/optionbox.inc |
---|
48,12 → 48,12 |
shl ecx,16 |
add ecx,op_size |
mov edx,op_border_color |
int 0x40 ;à¨á㥬 à ¬ªã |
mcall ;à¨á㥬 à ¬ªã |
mov edx,op_color |
add ebx,1 shl 16 - 2 |
add ecx,1 shl 16 - 2 |
int 0x40 ;§ ªà 訢 ¥¬ ¢ãâ८á⨠祪¡®ªá |
mcall ;§ ªà 訢 ¥¬ ¢ãâ८á⨠祪¡®ªá |
mov eax,option_group |
mov dword eax,[eax] |
74,7 → 74,7 |
movzx esi,word op_text_length ; £à㧨¬ ¤«¨ã ¤¯¨á¨ ¢ esi |
;¢¥á¥¬ ¢ eax § 票¥ ¢ë¢®¤ ¤¯¨á¨ ª ¢ã |
mov eax,4 |
int 0x40 ;뢮¤ |
mcall ;뢮¤ |
popa ;¢®ááâ ®¢¨âì § 票ï ॣ¨áâ஢ ¨§ á⥪ |
ret ;¢ë©¤¥¬ ¨§ ¯à®æ¥¤ãàë |
97,7 → 97,7 |
add ecx,(op_size/3) ;¤®¡ ¢¨âì (áâ®à® ¯àאַ㣮«ì¨ª /3) |
shl ecx,16 ;ᤢ¨¥¬ 16 à §à冷¢ ¢ «¥¢® (㬮¦¨¬ 65536) |
mov cx,bp ;§ £à㧨¬ § 票ï ॣ¨áâà 㪠§ â¥«ï ¡ §ë ¢ cx |
int 0x40 ;¢ë¢®¤ |
mcall ;¢ë¢®¤ |
ret ;¢ë©â¨ ¨§ ¯à®æ¥¤ãàë |
.mouse: ;®¡à ¡®âª ¬ëè¨ |
104,7 → 104,7 |
pusha |
mov eax,37 ;¡ã¤¥¬ çâ® â® ¤¥« âì ¥á«¨ ã á çâ® - ¨âì ¦ â® |
mov ebx,2 ;¢¥á⨠¢ ॣ¨áâà § 票¥ 2 |
int 0x40 ;¯à®¢¥àª ¥ ¦ « «¨ ¯®«ì§®¢ â¥«ì ª®¯ªã ¬ë誨 |
mcall ;¯à®¢¥àª ¥ ¦ « «¨ ¯®«ì§®¢ â¥«ì ª®¯ªã ¬ë誨 |
test eax,eax ;¯à®¢¥àª ¥á«¨ ã á ¢ eax=0, â® ãáâ ®¢¨¬ ä« £ ¨ ¢ë©¤¥¬ |
jnz @f ;¯¥à¥©â¨ ¨¦îî ¬¥âªã @@ |
popa ;¥á«¨ ¨ç¥£® ¥ ¯à®¨§®è«®, â® ¢®ááâ ®¢¨¬ § 票ï ॣ¨áâ஢ ¨§ á⥪ |
120,7 → 120,7 |
mov eax,37 ;¯®«ã稬 ª®®à¤¨ âë ¬ë誨 |
inc ebx ;¤®¡ ¢¨âì 1 |
int 0x40 ;¯®«ãç¨âì ª®®à¤¨ âë ªãàá®à ®â®á¨â¥«ì® ®ª |
mcall ;¯®«ãç¨âì ª®®à¤¨ âë ªãàá®à ®â®á¨â¥«ì® ®ª |
movzx ebx,word op_top ;§ £à㧨âì ¢ bx § 票¥ ª®®à¤¨ âë ã |
cmp ax,bx ;áà ¢¨âì á á ª®®à¤¨ ⮩ ªãàá®à |
/programs/develop/examples/rtdata/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
/programs/develop/examples/rtdata/trunk/build_en.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix en >lang.inc |
@fasm rtdata.asm rtdata |
@erase lang.inc |
@pause |
/programs/develop/examples/rtdata/trunk/build_ru.bat |
---|
1,4 → 1,5 |
@erase lang.inc |
@echo lang fix ru >lang.inc |
@fasm rtdata.asm rtdata |
@erase lang.inc |
@pause |
/programs/develop/examples/rtdata/trunk/rtdata.asm |
---|
5,7 → 5,7 |
; |
include "lang.inc" |
include "macros.inc" |
include "..\..\..\..\macros.inc" |
use32 |
org 0x0 |
25,31 → 25,38 |
mov eax,45 ; reserve irq 4 |
mov ebx,0 |
mov ecx,4 |
int 0x40 |
mcall |
mov eax,46 ; reserve ports 0x3f8-0x3ff |
mov ebx,0 |
mov ecx,0x3f8 |
mov edx,0x3ff |
int 0x40 |
mcall |
mov eax,44 ; read these ports at interrupt/irq 4 |
mov ebx,irqtable |
mov ecx,4 |
int 0x40 |
mcall |
mov eax,40 ; enable event for interrupt/irq 4 |
mov ebx,10000b shl 16 + 111b |
int 0x40 |
mcall |
call program_com1 |
mov eax, 48 |
mov ebx, 3 |
mov ecx, sc |
mov edx, sizeof.system_colors |
mcall |
red: |
call draw_window |
still: |
mov eax,10 ; wait here for event |
int 0x40 |
mcall |
cmp eax,1 ; redraw request ? |
je red |
62,13 → 69,9 |
jmp still |
red: ; redraw |
call draw_window |
jmp still |
key: ; key |
mov eax,2 ; just read it and ignore |
int 0x40 |
mcall |
mov al,ah |
mov dx,0x3f8 |
78,7 → 81,7 |
button: ; button |
or eax,-1 ; close this program |
int 0x40 |
mcall |
irq4: |
85,7 → 88,7 |
mov eax,42 |
mov ebx,4 |
int 0x40 |
mcall |
; eax = number of bytes left |
; ecx = 0 success, =1 fail |
141,15 → 144,9 |
draw_window: |
mov eax, 48 |
mov ebx, 3 |
mov ecx, sc |
mov edx, sizeof.system_colors |
int 0x40 |
mov eax, 12 ; function 12:tell os about windowdraw |
mov ebx, 1 ; 1, start of draw |
int 0x40 |
mcall |
; DRAW WINDOW |
mov eax, 0 ; function 0 : define and draw window |
157,7 → 154,7 |
mov ecx, 100*65536+85 ; [y start] *65536 + [y size] |
mov edx, [sc.work] |
or edx, 0x03000000 ; color of work area RRGGBB,8->color gl |
int 0x40 |
mcall |
; WINDOW LABEL |
mov eax, 4 ; function 4 : write text to window |
164,9 → 161,9 |
mov ebx, 8*65536+8 ; [x start] *65536 + [y start] |
mov ecx, [sc.grab_text] |
or ecx, 0x10000000 ; font 1 & color ( 0xF0RRGGBB ) |
mov edx, header ; pointer to text beginning |
mov esi, header.len ; text length |
int 0x40 |
mov edx, title ; pointer to text beginning |
mov esi, title.len ; text length |
mcall |
mov eax, 4 ; draw text |
mov ebx, 20*65536+33 |
176,7 → 173,7 |
mov esi, [edx-4] |
test esi, 0xFF000000 |
jnz .finstr |
int 0x40 |
mcall |
add edx, esi |
add edx, 4 |
add ebx, 10 |
187,7 → 184,7 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,2 ; 2, end of draw |
int 0x40 |
mcall |
ret |
198,7 → 195,7 |
mov ecx, [sc.work_text] |
mov edx, string |
mov esi, 32 |
int 0x40 |
mcall |
ret |
209,16 → 206,16 |
text mstr " .",\ |
" ",\ |
" IRQ4 ." |
header: |
title: |
db ' COM1' |
.len = $ - header |
.len = $ - title |
else |
text mstr "TYPED CHARACTERS ARE SENT TO MODEM.",\ |
"DATA FROM MODEM IS READ BY IRQ4",\ |
"INTERRUPT AND DISPLAYED BELOW." |
header: |
title: |
db 'MODEM AT COM1' |
.len = $ - header |
.len = $ - title |
end if |
pos dd 0x0 |
/programs/develop/examples/template/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
Property changes: |
Deleted: svn:eol-style |
-native |
\ No newline at end of property |
/programs/develop/examples/template/trunk/template.asm |
---|
9,7 → 9,7 |
; <--- include all MeOS stuff ---> |
include "lang.inc" |
include "macros.inc" |
include "..\..\..\..\macros.inc" |
; <--- start of MenuetOS application ---> |
23,7 → 23,7 |
mov ebx,3 |
mov ecx,sc |
mov edx,sizeof.system_colors |
int 0x40 |
mcall |
redraw: ; redraw event handler |
call draw_window ; at first create and draw the window |
30,7 → 30,7 |
wait_event: ; main cycle |
mov eax, 10 |
int 0x40 |
mcall |
dec eax ; if event = 1 |
jz redraw ; jump to redraw handler |
40,17 → 40,17 |
button: ; button event handler |
mov al, 17 ; get button identifier |
int 0x40 |
mcall |
cmp ah, 1 |
jne wait_event ; return if button id != 1 |
or eax, -1 ; exit application |
int 0x40 |
mcall |
key: ; key event handler |
mov al, 2 ; get key code |
int 0x40 |
mcall |
jmp wait_event |
57,7 → 57,7 |
draw_window: |
mov eax, 12 ; start drawing |
mov ebx, 1 |
int 0x40 |
mcall |
xor eax, eax ; create and draw the window |
mov ebx, 100*65536+200 ; (window_cx)*65536+(window_sx) |
64,12 → 64,12 |
mov ecx, 100*65536+100 ; (window_cy)*65536+(window_sy) |
mov edx, [sc.work] ; work area color |
or edx, 0x33000000 ; & window type 3 |
mov edi, header ; window header |
mov edi, title ; window title |
int 0x40 |
mov eax, 12 ; finish drawing |
mov ebx, 2 |
int 0x40 |
mcall |
ret |
77,11 → 77,11 |
DATA |
if lang eq ru |
header db ' ¡«® ¯à®£à ¬¬ë',0 |
title db ' ¡«® ¯à®£à ¬¬ë',0 |
else if lang eq fr |
header db 'La programme poncive',0 |
title db 'La programme poncive',0 |
else |
header db 'Template program',0 |
title db 'Template program',0 |
end if |
; <--- uninitialised data ---> |
/programs/develop/examples/thread/trunk/macros.inc |
---|
File deleted |
\ No newline at end of file |
Property changes: |
Deleted: svn:eol-style |
-native |
\ No newline at end of property |
/programs/develop/examples/thread/trunk/thread.asm |
---|
12,48 → 12,41 |
dd START ; start of code |
dd I_END ; size of image |
dd 0x2000 ; memory for app |
dd 0x1000 ; esp |
dd 0x2000 ; esp |
dd 0x0 , 0x0 ; I_Param , I_Icon |
include 'lang.inc' |
include 'macros.inc' |
include '..\..\..\..\macros.inc' |
START: ; start of execution |
red: ; redraw |
call draw_window ; at first, draw the window |
still: |
mov eax,10 ; wait here for event |
int 0x40 |
mcall |
cmp eax,1 ; redraw request ? |
dec eax ; redraw request ? |
je red |
cmp eax,2 ; key in buffer ? |
je key |
cmp eax,3 ; button in buffer ? |
je button |
dec eax ; key in buffer ? |
jne button |
jmp still |
red: ; redraw |
call draw_window |
jmp still |
key: ; key |
mov eax,2 ; just read it and ignore |
int 0x40 |
mcall |
jmp still |
button: ; button |
mov eax,17 ; get id |
int 0x40 |
mcall |
cmp ah,1 ; button id=1 ? |
jne noclose |
mov eax,-1 ; close this program (thread) |
int 0x40 |
or eax,-1 ; close this program (thread) |
mcall |
noclose: |
cmp ah,2 |
67,7 → 60,7 |
mov ebx,1 |
mov ecx,START |
mov edx,[thread_stack] |
int 0x40 |
mcall |
jmp still |
75,6 → 68,7 |
jmp still |
thread_stack dd 0x1000 |
87,10 → 81,10 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,1 ; 1, start of draw |
int 0x40 |
mcall |
; DRAW WINDOW |
mov eax,0 ; function 0 : define and draw window |
xor eax,eax ; function 0 : define and draw window |
mov ebx,10*65536+290 ; [x start] *65536 + [x size] |
mov ecx,10*65536+130 ; [y start] *65536 + [y size] |
mov esi,[thread_stack] |
99,33 → 93,25 |
shl esi,16 |
add ebx,esi |
add ecx,esi |
mov edx,0x03ffffff ; color of work area RRGGBB,8->color gl |
mov esi,0x808899ff ; color of grab bar RRGGBB,8->color gl |
mov edi,0x008899ff ; color of frames RRGGBB |
int 0x40 |
mov edx,0x33ffffff ; color of work area RRGGBB,8->color gl |
mov edi,title ; WINDOW LABEL |
mcall |
; WINDOW LABEL |
mov eax,4 ; function 4 : write text to window |
mov ebx,8*65536+8 ; [x start] *65536 + [y start] |
mov ecx,0x10ddeeff ; color of text RRGGBB |
mov edx,labelt ; pointer to text beginning |
mov esi,labellen-labelt ; text length |
int 0x40 |
mov eax,8 ; NEW THREAD BUTTON |
mov ebx,25*65536+128 |
mov ecx,88*65536+20 |
mov ebx,20*65536+128 |
mov ecx,63*65536+20 |
mov edx,2 |
mov esi,0x90b0d0 ;0x5577cc |
int 0x40 |
mcall |
mov ebx,25*65536+35 ; draw info text with function 4 |
mov eax,4 |
mov ebx,20*65536+10 ; draw info text with function 4 |
mov ecx,0x224466 |
mov edx,text |
mov esi,40 |
newline: |
mov eax,4 |
int 0x40 |
mcall |
add ebx,10 |
add edx,40 |
cmp [edx],byte 'x' |
134,7 → 120,7 |
mov eax,12 ; function 12:tell os about windowdraw |
mov ebx,2 ; 2, end of draw |
int 0x40 |
mcall |
ret |
143,19 → 129,17 |
if lang eq ru |
text: |
db ' , ' |
db ' . ' |
db ' ' |
db ' . ' |
db ' . ' |
db 'â ¯à®£à ¬¬ ᮧ¤ ¥â ¯®â®ª¨, § ¯ã᪠ï ' |
db '®¤¨ ¨ â®â ¦¥ ª®¤ ¬®£® à §. ¬ 㦮 ' |
db '⮫쪮 ¯®§ ¡®â¨âìáï ®¡ ®â¤¥«ì®¬ áâíª¥ ' |
db '¤«ï ª ¦¤®£® ¯®â®ª . ' |
db ' ¬ïâì ¤«ï ¢á¥å ¯®â®ª®¢ ®¡é ï. ' |
db ' ' |
db ' ' |
db 'x' ; <- END MARKER, DONT DELETE |
labelt: |
db ' 51®© ' |
labellen: |
title db 'ਬ¥à ¨á¯®«ì§®¢ ¨ï ¯®â®ª®¢',0 |
else |
text: |
db 'THIS EXAMPLE CREATES THREADS BY RUNNING ' |
165,11 → 149,9 |
db ' ' |
db ' ' |
db ' CREATE NEW THREAD ' |
db 'x' ; <- END MARKER, DONT DELETE |
labelt: |
db 'THREAD EXAMPLE' |
labellen: |
title db 'THREAD EXAMPLE',0 |
end if |
I_END: |