Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 1587 → Rev 1588

/programs/media/midamp/trunk/event.inc
12,7 → 12,7
; bottom actions
dw kDel,bLsave,bLload,bRemAll,bAdd,bAddDir,bSelZero,bInvSel,bSelAll,bRemCrop
dw bMinimize,bAbout,bResetTrk
 
;------------------------------------------------------------------------
jmps_end:
 
key:
108,7 → 108,7
mov eax,IPC_TRIG
call ipc_send
jmp red
 
;------------------------------------------------------------------------
button:
mov eax,17
mcall
171,9 → 171,11
mov eax,67
mcall
ret
;------------------------------------------------------------------------
bMinimize:
; mcall 18,10
jmp still
;------------------------------------------------------------------------
bList:
mov [popup],-1
mov edx,[listsel]
253,6 → 255,7
cmp al,[list_count]
jae still
jmp play_
;------------------------------------------------------------------------
bBar:
cmp [tick_count],0
jz still
281,8 → 284,9
mov [cur_ptr],esi
drw:
jmp red
 
;------------------------------------------------------------------------
OCT_CH equ 3
;------------------------------------------------------------------------
bOctU:
add [octave],OCT_CH
jmp midi_kill
320,10 → 324,18
and [list_count],0
mov [play_limit],playlist-2
jmp red
;------------------------------------------------------------------------
bAdd:
movzx eax,[list_count]
dpd eax
call fopen
mov [OpenDialog_data.type],0 ; Open
or [flag],FL_LOCK
push dword OpenDialog_data
call [OpenDialog_Start]
and [flag],not FL_LOCK
cmp [OpenDialog_data.status],1
jne still
 
mov edi,filename
cmp byte[edi],0
jz still
331,23 → 343,34
xchg eax,ecx
mov esi,edi
jmp add_song
;------------------------------------------------------------------------
bAddDir:
call fopen
mov edi,filename
cmp byte[edi],0
jz still
call find_slash
lea edx,[edi-filename+fnbuf] ; edx -> '/'
and byte[edi],0
mov [OpenDialog_data.type],2 ; Dir
or [flag],FL_LOCK
push dword OpenDialog_data
call [OpenDialog_Start]
and [flag],not FL_LOCK
cmp [OpenDialog_data.status],1
jne still
 
mov esi,filename
mov edi,fnbuf
mov ecx,1024/4
rep movsd
xor eax,eax
@@:
cld
lodsb
stosb
test eax,eax
jnz @r
mov [edi-1],byte '/'
mov edx,edi
 
and dword [dir_info+4], 0
.nxt2:
mcall 70, dir_info
cmp ebx, 1
jnz red ;still
test eax,eax
jnz red
 
test byte [dir_table+32], 11000b ; exclude directories & vol label
jnz .no
mov edi, dir_table+32+40
370,8 → 393,12
sub ecx, esi
call PL_add
.no:
mov eax,[dir_info+4]
cmp eax,[dir_table+8]
je red
inc dword [dir_info+4]
jmp .nxt2
;------------------------------------------------------------------------
bSelZero:
call PL_clearsel
jmp red
390,7 → 417,7
mov edx,about1
call debug_outstr
jmp still
 
;------------------------------------------------------------------------
get_num: ; out: eax-number entered
or [flag],FL_LOCK
mcall 10
418,7 → 445,7
jne get_num
mcall 17
jmp get_num
 
;------------------------------------------------------------------------
find_slash:
; in: edi-filename, out: edi-slash ptr-1
push eax ecx
432,4 → 459,4
add edi,2
pop ecx eax
ret
 
;------------------------------------------------------------------------
/programs/media/midamp/trunk/midamp.asm
73,7 → 73,7
lang fix en
;purge mov
include 'debug.inc'
include 'dlg.inc'
;include 'dlg.inc'
include 'playlist.inc'
include 'gif_lite.inc'
bottom:
137,22 → 137,24
;---------------------------------------------------------------------
;OpenDialog_start:
; copy_path open_dialog_name,path,library_path,0
mov [OpenDialog_data.type],0 ; Open
or [flag],FL_LOCK
push dword OpenDialog_data
call [OpenDialog_Start]
 
cmp [OpenDialog_data.status],2 ; OpenDialog does not start
je .fopen ; some kind of alternative, instead OpenDialog
and [flag],not FL_LOCK
; cmp [OpenDialog_data.status],2 ; OpenDialog does not start
; je .fopen ; some kind of alternative, instead OpenDialog
cmp [OpenDialog_data.status],1
je open_file
jmp still
; je open_file
; jmp still
jne still
;---------------------------------------------------------------------
 
.fopen:
call fopen
get_path:
cmp byte[filename],0
jz still
;.fopen:
; call fopen
; get_path:
; cmp byte[filename],0
; jz still
open_file:
cmp [param],'W'
je .noplay
323,12 → 325,12
pop edi ecx
ret
 
fopen:
or [flag],FL_LOCK
opendialog draw_window, ret_path, ret_path, filename
ret_path:
and [flag],not FL_LOCK
ret
;fopen:
; or [flag],FL_LOCK
;; opendialog draw_window, ret_path, ret_path, filename
;ret_path:
; and [flag],not FL_LOCK
; ret
 
include 'event.inc'
include "thread.inc"
491,7 → 493,8
rb 4096
stacktop:
;----------------------------------------------------------------
dir_table rb 32+304
dir_table:
rb 32+304
workarea:
rb 120*1024
I_END: