2011-06-12 02:16:26 +04:00
|
|
|
;---------------------------------------------------------------------
|
2011-07-07 23:18:51 +04:00
|
|
|
kinfo:
|
|
|
|
test dword [status],2
|
|
|
|
jnz still
|
2011-06-12 02:16:26 +04:00
|
|
|
or dword [status],2
|
|
|
|
|
2011-07-07 23:18:51 +04:00
|
|
|
call get_memory_for_thread_stack
|
2011-06-12 02:16:26 +04:00
|
|
|
mov [thread_stack_2],eax
|
|
|
|
mcall 51,1,thread2 ;, thread_stack_2
|
|
|
|
jmp still
|
|
|
|
;---------------------------------------------------------------------
|
|
|
|
thread2: ; start of info thread
|
2011-07-07 23:18:51 +04:00
|
|
|
mcall 9,procinfo_threads,-1
|
|
|
|
mov eax,[ebx+30]
|
|
|
|
mov [PID2],eax
|
|
|
|
mcall 40,0x7
|
|
|
|
call load_directory.copy_dir_path
|
|
|
|
;---------------------------------------------------------------------
|
2011-06-12 02:16:26 +04:00
|
|
|
.red:
|
2011-07-07 23:18:51 +04:00
|
|
|
call .draw_window
|
|
|
|
;---------------------------------------------------------------------
|
2011-06-12 02:16:26 +04:00
|
|
|
.still:
|
2011-07-07 23:18:51 +04:00
|
|
|
mcall 10 ; wait here for event
|
|
|
|
cmp eax,1 ; redraw request ?
|
2011-06-12 02:16:26 +04:00
|
|
|
je .red
|
2011-07-07 23:18:51 +04:00
|
|
|
|
|
|
|
cmp eax,2 ; key in buffer ?
|
2011-06-12 02:16:26 +04:00
|
|
|
je .close
|
|
|
|
|
2011-07-07 23:18:51 +04:00
|
|
|
cmp eax,3 ; button in buffer ?
|
|
|
|
je .button
|
2011-06-12 02:16:26 +04:00
|
|
|
|
2011-07-07 23:18:51 +04:00
|
|
|
jmp .still
|
|
|
|
;---------------------------------------------------------------------
|
2011-06-12 02:16:26 +04:00
|
|
|
.button: ; button
|
2011-07-07 23:18:51 +04:00
|
|
|
mcall 17 ; get id
|
|
|
|
cmp ah,1 ; button id=1 ?
|
|
|
|
jne .still ;.noclose
|
2011-06-12 02:16:26 +04:00
|
|
|
.close:
|
|
|
|
xor dword [status],2
|
|
|
|
xor eax,eax
|
|
|
|
mov [PID2],eax
|
|
|
|
mcall 68,13,[thread_stack_2]
|
2011-07-07 23:18:51 +04:00
|
|
|
mcall -1 ; close this program
|
|
|
|
;---------------------------------------------------------------------
|
2011-06-12 02:16:26 +04:00
|
|
|
; *********************************************
|
|
|
|
; ******* WINDOW DEFINITIONS AND DRAW ********
|
|
|
|
; *********************************************
|
|
|
|
.draw_window:
|
2011-07-07 23:18:51 +04:00
|
|
|
mcall 12,2
|
|
|
|
xor eax,eax ; function 0 : define and draw window
|
|
|
|
xor esi,esi
|
|
|
|
mcall ,<100,330>,<100,120>,0x13eeeeee,,labelt2
|
|
|
|
mcall 4,<120,30>,0x80000000,file_name
|
|
|
|
mov edx,fitext
|
|
|
|
mov esi,14
|
|
|
|
mov ebx,10*65536+30
|
|
|
|
mov ecx,0x10000000
|
2011-06-12 02:16:26 +04:00
|
|
|
@@:
|
|
|
|
mcall
|
2011-07-07 23:18:51 +04:00
|
|
|
add ebx,10
|
|
|
|
add edx,esi
|
|
|
|
cmp ebx,10*65536+80
|
|
|
|
jbe @r
|
2011-06-12 02:16:26 +04:00
|
|
|
|
2011-07-07 23:18:51 +04:00
|
|
|
mov esi,ecx
|
|
|
|
mcall 47,0x800a0000,[img_size],<120,40>
|
2011-06-12 02:16:26 +04:00
|
|
|
|
2011-07-07 23:18:51 +04:00
|
|
|
add edx,10
|
|
|
|
mcall ,,[img_width_2]
|
2011-06-12 02:16:26 +04:00
|
|
|
|
2011-07-07 23:18:51 +04:00
|
|
|
add edx,10
|
|
|
|
mcall ,,[img_high_2]
|
2011-06-12 02:16:26 +04:00
|
|
|
|
2011-07-07 23:18:51 +04:00
|
|
|
add edx,10
|
|
|
|
mcall ,,[img_resolution_2]
|
2011-06-12 02:16:26 +04:00
|
|
|
|
2011-07-07 23:18:51 +04:00
|
|
|
add edx,10
|
|
|
|
mcall ,,[Total_Repeat_N]
|
2011-09-07 20:34:44 +04:00
|
|
|
|
2011-06-12 02:16:26 +04:00
|
|
|
; mcall 47,0x80000,[PID2],<200, 5>,0xffffff
|
|
|
|
; mcall 47,0x800a0000,[error_locate],<140,5>,0x10ffffff
|
2011-07-07 23:18:51 +04:00
|
|
|
mcall 12,2
|
2011-06-12 02:16:26 +04:00
|
|
|
ret
|
2011-07-07 23:18:51 +04:00
|
|
|
;--------------------------------------------------------------------
|