Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 6085 → Rev 6086

/programs/other/t_edit/t_button.inc
43,7 → 43,7
call On_NewFile
.ret_f:
mov byte[openfile_path],0
mcall 71,1,hed
mcall SF_SET_CAPTION,1,hed
pop ebx eax
ret
 
142,17 → 142,25
@@:
cmp [OpenDialog_data.status],1
jne .ret_f
stdcall auto_open_syntax,[OpenDialog_data.openfile_path]
stdcall [ted_open_file], tedit0,run_file_70,openfile_path
call ted_messages_after_open_file
.ret_f:
popad
ret
 
proc auto_open_syntax, of_path:dword
pushad
;¨é¥¬ ¥áâì «¨ ä ©« ¯®¤á¢¥âª¨ ¤«ï ®âªà뢠¥¬®£® ⥪á⮢®£® ä ©« 
mov esi,[OpenDialog_data.openfile_path]
mov esi,[of_path]
call strlen
mov edx,openfile_path
mov edx,[of_path]
add edx,eax
.f_beg:
cmp byte[edx],'.'
je .found
dec edx
cmp edx,openfile_path
cmp edx,[of_path]
jg .f_beg
.found:
inc edx ;edx - 㪠§ â¥«ì ­  à áè¨à¥­¨¥ ®âªàë⮣® ä ©« 
169,17 → 177,11
jmp .end_0
.ok: ;®âªàë⨥ ä ©«  ¯®¤á¢¥âª¨ ¢ § ¢¨á¨¬®á⨠®â ­ ©¤¥­­®£® à áè¨à¥­¨ï
sub ebx,32
;mov ecx,ebx
;mcall 71,1
call open_unpac_synt_file
stdcall open_unpac_synt_file,ebx
.end_0:
 
stdcall [ted_open_file], tedit0,run_file_70,openfile_path
call ted_messages_after_open_file
 
.ret_f:
popad
ret
endp
 
;description:
; äã­ªæ¨ï á®åà ­¥­¨ï ä ©«  á ¢ë§®¢®¬ ®ª­  ¤¨ «®£ 
269,8 → 271,7
jne @f
stdcall dword[tl_node_get_data], tree1
mov [fn_col_option],eax
mov ebx,eax
call open_unpac_synt_file
stdcall open_unpac_synt_file,eax
cmp ebx,-1
je @f
 
282,13 → 283,13
 
;®âªàë⨥ ¨ à á¯ ª®¢ª  ä ©«  ¯®¤á¢¥âª¨ ᨭ⠪á¨á 
;input:
; ebx - 㪠§ â¥«ì ­  ¨¬ï ®âªà뢠¥¬®£® ä ©«  ᨭ⠪á¨á  (¡¥§ ¯ã⨠¨ ¯ ¯ª¨ info)
; f_name - 㪠§ â¥«ì ­  ¨¬ï ®âªà뢠¥¬®£® ä ©«  ᨭ⠪á¨á  (¡¥§ ¯ã⨠¨ ¯ ¯ª¨ info)
;output:
; ebx - ç¨á«® ¯à®ç¨â ­­ëå ¡ ©â ¨§ ä ©« 
; ecx - à §àãè ¥âáï
align 4
open_unpac_synt_file:
push eax edi esi
proc open_unpac_synt_file uses eax edi esi, f_name:dword
mov ebx,[f_name]
mov edi,last_open_synt_file
stdcall strcmp,ebx,edi ;áà ¢­¨¢ ¥¬ ¨¬ï ¯®¤ª«î祭­®£® ä ©«  á ¯®¤ª«î祭­ë¬ à ­¥¥ ä ©«®¬
test eax,eax
296,14 → 297,14
 
;ª®¯¨à㥬 ¨¬ï ¯®¤ª«î祭­®£® ä ©«  (¤«ï ¨§¡¥¦ ­¨ï ¯®¢â®à­ëå ¯®¤ª«î祭¨©)
mov esi,ebx
mov ecx,32
mov ecx,32/4
cld
rep movsb
rep movsd
 
copy_path ebx,fn_syntax_dir,syntax_path,0
copy_path syntax_path,sys_path,file_name,0
mov edi, tedit0
mov [run_file_70.Function], 0
mov [run_file_70.Function], SSF_READ_FILE
mov [run_file_70.Position], 0
mov [run_file_70.Flags], 0
mov ecx, ted_syntax_file_size
311,7 → 312,7
m2m dword[run_file_70.Buffer], ted_syntax_file
mov byte[run_file_70+20], 0
mov [run_file_70.FileName], file_name
mcall 70, run_file_70
mcall SF_FILE, run_file_70
cmp ebx,-1
jne .end_0
call ted_on_init_synt_err
337,8 → 338,8
.end_unpack:
stdcall [ted_init_syntax_file], tedit0
@@:
pop esi edi eax
ret
endp
 
;description:
; ¢ë§®¢/áªàë⨥ ¯ ­¥«¨ ¯®¨áª 
403,7 → 404,7
cmp byte[wnd_k_words_run],0
jne @f
pushad
mcall 51,1,prop_start,thread_coords
mcall SF_CREATE_THREAD,1,prop_start,thread_coords
popad
@@:
ret