forked from KolibriOS/kolibrios
RDsave:
1) select path with OpenDialog 2) keys 1,2,3,4 for select options git-svn-id: svn://kolibrios.org@1606 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
abc581c09f
commit
bd8bfe3265
13
programs/system/rdsave/trunk/build.sh
Executable file
13
programs/system/rdsave/trunk/build.sh
Executable file
@ -0,0 +1,13 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# This script does for linux the same as build.bat for DOS,
|
||||||
|
# it compiles the KoOS kernel, hopefully ;-)
|
||||||
|
|
||||||
|
echo "lang fix en"
|
||||||
|
echo "lang fix en" > lang.inc
|
||||||
|
fasm -m 16384 rdsave.asm rdsave
|
||||||
|
rm -f lang.inc
|
||||||
|
exit 0
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
|||||||
@erase lang.inc
|
@erase lang.inc
|
||||||
@echo lang fix en >lang.inc
|
@echo lang fix en >lang.inc
|
||||||
@fasm rdsave.asm rdsave
|
@fasm rdsave.asm rdsave
|
||||||
|
@kpack rdsave
|
||||||
@erase lang.inc
|
@erase lang.inc
|
||||||
@pause
|
@pause
|
@ -1,5 +1,6 @@
|
|||||||
@erase lang.inc
|
@erase lang.inc
|
||||||
@echo lang fix et >lang.inc
|
@echo lang fix et >lang.inc
|
||||||
@fasm rdsave.asm rdsave
|
@fasm rdsave.asm rdsave
|
||||||
|
@kpack rdsave
|
||||||
@erase lang.inc
|
@erase lang.inc
|
||||||
@pause
|
@pause
|
@ -1,5 +1,6 @@
|
|||||||
@erase lang.inc
|
@erase lang.inc
|
||||||
@echo lang fix ru >lang.inc
|
@echo lang fix ru >lang.inc
|
||||||
@fasm rdsave.asm rdsave
|
@fasm rdsave.asm rdsave
|
||||||
|
@kpack rdsave
|
||||||
@erase lang.inc
|
@erase lang.inc
|
||||||
@pause
|
@pause
|
@ -1,6 +1,12 @@
|
|||||||
;
|
;
|
||||||
; RDsave ¤«ï Kolibri (0.6.5.0 ¨ áâ àè¥)
|
; RDsave ¤«ï Kolibri (0.6.5.0 ¨ áâ àè¥)
|
||||||
;
|
;
|
||||||
|
; version: 1.3
|
||||||
|
; last update: 08/09/2010
|
||||||
|
; written by: Marat Zakiyanov aka Mario79, aka Mario
|
||||||
|
; changes: select path with OpenDialog,
|
||||||
|
; keys 1,2,3,4 for select options
|
||||||
|
;---------------------------------------------------------------------
|
||||||
; Mario79 2005
|
; Mario79 2005
|
||||||
; Heavyiron 12.02.2007
|
; Heavyiron 12.02.2007
|
||||||
; <Lrz> 11.05.2009 - ¤«ï à ¡®âë 㦠á¨á⥬ ï ¡¨¡«¨®â¥ª box_lib.obj
|
; <Lrz> 11.05.2009 - ¤«ï à ¡®âë 㦠á¨á⥬ ï ¡¨¡«¨®â¥ª box_lib.obj
|
||||||
@ -11,17 +17,17 @@ include 'lang.inc'
|
|||||||
include '..\..\..\macros.inc'
|
include '..\..\..\macros.inc'
|
||||||
|
|
||||||
appname equ 'RDsave '
|
appname equ 'RDsave '
|
||||||
version equ '1.2'
|
version equ '1.3'
|
||||||
|
|
||||||
use32 ; ¢ª«îç¨âì 32-¡¨âë© à¥¦¨¬ áᥬ¡«¥à
|
use32 ; ¢ª«îç¨âì 32-¡¨âë© à¥¦¨¬ áᥬ¡«¥à
|
||||||
org 0x0 ; ¤à¥á æ¨ï á ã«ï
|
org 0x0 ; ¤à¥á æ¨ï á ã«ï
|
||||||
|
|
||||||
db 'MENUET01' ; 8-¡ ©âë© ¨¤¥â¨ä¨ª â®à MenuetOS
|
db 'MENUET01' ; 8-¡ ©âë© ¨¤¥â¨ä¨ª â®à MenuetOS
|
||||||
dd 0x01 ; ¢¥àá¨ï § £®«®¢ª (¢á¥£¤ 1)
|
dd 0x01 ; ¢¥àá¨ï § £®«®¢ª (¢á¥£¤ 1)
|
||||||
dd START ; ¤à¥á ¯¥à¢®© ª®¬ ¤ë
|
dd START ; ¤à¥á ¯¥à¢®© ª®¬ ¤ë
|
||||||
dd I_END ; à §¬¥à ¯à®£à ¬¬ë
|
dd IM_END ; à §¬¥à ¯à®£à ¬¬ë
|
||||||
dd I_END ; ª®«¨ç¥á⢮ ¯ ¬ïâ¨
|
dd I_END ; ª®«¨ç¥á⢮ ¯ ¬ïâ¨
|
||||||
dd I_END ; ¤à¥á ¢¥àè¨ë áâíª
|
dd stacktop ; ¤à¥á ¢¥àè¨ë áâíª
|
||||||
dd 0x0 ; ¤à¥á ¡ãä¥à ¤«ï ¯ à ¬¥â஢ (¥ ¨á¯®«ì§ã¥âáï)
|
dd 0x0 ; ¤à¥á ¡ãä¥à ¤«ï ¯ à ¬¥â஢ (¥ ¨á¯®«ì§ã¥âáï)
|
||||||
dd cur_dir_path
|
dd cur_dir_path
|
||||||
|
|
||||||
@ -39,28 +45,50 @@ include '../../../develop/libraries/box_lib/trunk/box_lib.mac'
|
|||||||
;---------------------------------------------------------------------
|
;---------------------------------------------------------------------
|
||||||
align 4
|
align 4
|
||||||
START:
|
START:
|
||||||
sys_load_library library_name, cur_dir_path, library_path, system_path, \
|
mcall 68,11
|
||||||
err_message_found_lib, head_f_l, myimport, err_message_import, head_f_i
|
|
||||||
|
load_libraries l_libs_start,end_l_libs
|
||||||
|
|
||||||
cmp eax,-1
|
cmp eax,-1
|
||||||
jz close
|
jz close
|
||||||
|
|
||||||
|
mov edi,filename_area
|
||||||
|
mov esi,start_temp_file_name
|
||||||
|
xor eax,eax
|
||||||
|
cld
|
||||||
|
@@:
|
||||||
|
lodsb
|
||||||
|
stosb
|
||||||
|
test eax,eax
|
||||||
|
jnz @b
|
||||||
|
|
||||||
mov eax, 40
|
|
||||||
mov ebx, 100111b
|
mov edi,fname_buf
|
||||||
mcall
|
mov esi,path4
|
||||||
|
xor eax,eax
|
||||||
|
cld
|
||||||
|
@@:
|
||||||
|
lodsb
|
||||||
|
stosb
|
||||||
|
test eax,eax
|
||||||
|
jnz @b
|
||||||
|
|
||||||
|
;OpenDialog initialisation
|
||||||
|
push dword OpenDialog_data
|
||||||
|
call [OpenDialog_Init]
|
||||||
|
|
||||||
|
; prepare for PathShow
|
||||||
|
push dword PathShow_data_1
|
||||||
|
call [PathShow_prepare]
|
||||||
|
|
||||||
|
mcall 40,100111b
|
||||||
red: ; ¯¥à¥à¨á®¢ âì ®ª®
|
red: ; ¯¥à¥à¨á®¢ âì ®ª®
|
||||||
mov eax,48
|
mcall 48,3,sc,sizeof.system_colors
|
||||||
mov ebx,3
|
|
||||||
mov ecx,sc
|
|
||||||
mov edx,sizeof.system_colors
|
|
||||||
mcall
|
|
||||||
edit_boxes_set_sys_color editbox,editbox_end,sc
|
|
||||||
call draw_window ; ¢ë§ë¢ ¥¬ ¯à®æ¥¤ãàã ®âà¨á®¢ª¨ ®ª
|
|
||||||
|
|
||||||
|
call draw_window ; ¢ë§ë¢ ¥¬ ¯à®æ¥¤ãàã ®âà¨á®¢ª¨ ®ª
|
||||||
;---------------------------------------------------------------------
|
;---------------------------------------------------------------------
|
||||||
;--- –ˆŠ‹ Ž<><C5BD>€<EFBFBD>Ž’Šˆ ‘Ž<E28098>›’ˆ‰ ----------------------------------------
|
;--- –ˆŠ‹ Ž<><C5BD>€<EFBFBD>Ž’Šˆ ‘Ž<E28098>›’ˆ‰ ----------------------------------------
|
||||||
;---------------------------------------------------------------------
|
;---------------------------------------------------------------------
|
||||||
|
|
||||||
still:
|
still:
|
||||||
mcall 10
|
mcall 10
|
||||||
|
|
||||||
@ -71,17 +99,10 @@ still:
|
|||||||
dec eax
|
dec eax
|
||||||
jz button
|
jz button
|
||||||
|
|
||||||
mouse:
|
|
||||||
; mouse_edit_box editbox
|
|
||||||
push dword editbox
|
|
||||||
call [edit_box_mouse]
|
|
||||||
|
|
||||||
jmp still
|
jmp still
|
||||||
|
;---------------------------------------------------------------------
|
||||||
button:
|
button:
|
||||||
mov al,17 ; ¯®«ãç¨âì ¨¤¥â¨ä¨ª â®à ¦ ⮩ ª®¯ª¨
|
mcall 17 ; ¯®«ãç¨âì ¨¤¥â¨ä¨ª â®à ¦ ⮩ ª®¯ª¨
|
||||||
mcall
|
|
||||||
|
|
||||||
cmp ah,1 ; ª®¯ª á id=1("§ ªàëâì")?
|
cmp ah,1 ; ª®¯ª á id=1("§ ªàëâì")?
|
||||||
jne noclose
|
jne noclose
|
||||||
close:
|
close:
|
||||||
@ -93,73 +114,85 @@ noclose:
|
|||||||
call clear_err
|
call clear_err
|
||||||
pop eax
|
pop eax
|
||||||
push 16
|
push 16
|
||||||
xor ebx, ebx
|
xor ebx,ebx
|
||||||
inc ebx ; 16.1 = save to /FD/1
|
inc ebx ; 16.1 = save to /FD/1
|
||||||
cmp ah, 2
|
cmp ah,2
|
||||||
je doit
|
je doit
|
||||||
inc ebx ; 16.2 = save to /FD/2
|
inc ebx ; 16.2 = save to /FD/2
|
||||||
cmp ah, 3
|
cmp ah,3
|
||||||
je doit
|
je doit
|
||||||
pop ebx
|
pop ebx
|
||||||
push 18
|
push 18
|
||||||
mov bl, 6 ; 18.6 = save to specified folder
|
mov bl,6 ; 18.6 = save to specified folder
|
||||||
mov ecx, path3
|
mov ecx, path3
|
||||||
cmp ah, 4
|
cmp ah,4
|
||||||
je doit
|
je doit
|
||||||
mov ecx, path4
|
|
||||||
|
; invoke OpenDialog
|
||||||
|
push dword OpenDialog_data
|
||||||
|
call [OpenDialog_Start]
|
||||||
|
cmp [OpenDialog_data.status],1
|
||||||
|
jne still
|
||||||
|
|
||||||
|
; prepare for PathShow
|
||||||
|
push dword PathShow_data_1
|
||||||
|
call [PathShow_prepare]
|
||||||
|
|
||||||
|
call draw_PathShow
|
||||||
|
|
||||||
|
mov ecx,fname_buf ;path4
|
||||||
doit:
|
doit:
|
||||||
pop eax
|
pop eax
|
||||||
mcall
|
mcall
|
||||||
call check_for_error
|
call check_for_error
|
||||||
jmp still
|
jmp still
|
||||||
|
;---------------------------------------------------------------------
|
||||||
key:
|
key:
|
||||||
mov al,2
|
mcall 2
|
||||||
mcall
|
cmp ah,0x31
|
||||||
; key_edit_box editbox
|
jb still
|
||||||
push dword editbox
|
cmp ah,0x34
|
||||||
call [edit_box_key]
|
ja still
|
||||||
|
sub ah,0x30
|
||||||
jmp still
|
inc ah
|
||||||
|
jmp noclose
|
||||||
|
;---------------------------------------------------------------------
|
||||||
check_for_error: ;Ž¡à ¡®â稪 ®è¨¡®ª
|
check_for_error: ;Ž¡à ¡®â稪 ®è¨¡®ª
|
||||||
mov ecx, [sc.work_text]
|
mov ecx,[sc.work_text]
|
||||||
mov edx, ok
|
mov edx,ok
|
||||||
test eax, eax
|
test eax,eax
|
||||||
jz print
|
jz print
|
||||||
mov ecx, 0xdd2222
|
mov ecx,0xdd2222
|
||||||
add edx, error3 - ok
|
add edx,error3 - ok
|
||||||
dec eax
|
dec eax
|
||||||
dec eax
|
dec eax
|
||||||
jz print
|
jz print
|
||||||
add edx, error5 - error3
|
add edx,error5 - error3
|
||||||
dec eax
|
dec eax
|
||||||
dec eax
|
dec eax
|
||||||
jz print
|
jz print
|
||||||
add edx, error8 - error5
|
add edx,error8 - error5
|
||||||
dec eax
|
dec eax
|
||||||
dec eax
|
dec eax
|
||||||
dec eax
|
dec eax
|
||||||
jz print
|
jz print
|
||||||
add edx, error9 - error8
|
add edx,error9 - error8
|
||||||
dec eax
|
dec eax
|
||||||
jz print
|
jz print
|
||||||
add edx, error10 - error9
|
add edx,error10 - error9
|
||||||
dec eax
|
dec eax
|
||||||
jz print
|
jz print
|
||||||
add edx, error11 - error10
|
add edx,error11 - error10
|
||||||
dec eax
|
dec eax
|
||||||
jz print
|
jz print
|
||||||
add edx, aUnknownError - error11
|
add edx,aUnknownError - error11
|
||||||
|
print:
|
||||||
print:
|
|
||||||
mov eax,4 ; ¤¯¨á¨
|
mov eax,4 ; ¤¯¨á¨
|
||||||
mov ebx,20 shl 16 + 148
|
mov ebx,20 shl 16 + 148
|
||||||
or ecx,0x80000000
|
or ecx,0x80000000
|
||||||
mcall
|
mcall
|
||||||
ret
|
ret
|
||||||
|
;---------------------------------------------------------------------
|
||||||
clear_err:
|
clear_err:
|
||||||
mov eax,13
|
mov eax,13
|
||||||
mov ebx,15 shl 16 + 240
|
mov ebx,15 shl 16 + 240
|
||||||
@ -167,36 +200,34 @@ clear_err:
|
|||||||
mov edx,[sc.work]
|
mov edx,[sc.work]
|
||||||
mcall
|
mcall
|
||||||
ret
|
ret
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
draw_PathShow:
|
||||||
|
pusha
|
||||||
|
mcall 13,<8,172>,<110,15>,0xffffff
|
||||||
|
; draw for PathShow
|
||||||
|
push dword PathShow_data_1
|
||||||
|
call [PathShow_draw]
|
||||||
|
popa
|
||||||
|
ret
|
||||||
;---------------------------------------------------------------------
|
;---------------------------------------------------------------------
|
||||||
;--- Ž<><C5BD>…„…‹…<E280B9>ˆ… ˆ Ž’<C5BD>ˆ‘Ž‚Š€ ŽŠ<C5BD>€ ----------------------------------
|
;--- Ž<><C5BD>…„…‹…<E280B9>ˆ… ˆ Ž’<C5BD>ˆ‘Ž‚Š€ ŽŠ<C5BD>€ ----------------------------------
|
||||||
;---------------------------------------------------------------------
|
;---------------------------------------------------------------------
|
||||||
|
|
||||||
draw_window:
|
draw_window:
|
||||||
|
mcall 12,1 ; äãªæ¨ï 12: á®®¡é¨âì Ž‘ ®¡ ®âà¨á®¢ª¥ ®ª
|
||||||
mov eax,12 ; äãªæ¨ï 12: á®®¡é¨âì Ž‘ ®¡ ®âà¨á®¢ª¥ ®ª
|
; 1 - ç¨ ¥¬ à¨á®¢ âì
|
||||||
mov bl,1 ; 1 - ç¨ ¥¬ à¨á®¢ âì
|
|
||||||
mcall
|
|
||||||
|
|
||||||
; ‘Ž‡„€ðŒ ŽŠ<C5BD>Ž
|
; ‘Ž‡„€ðŒ ŽŠ<C5BD>Ž
|
||||||
xor eax,eax ; äãªæ¨ï 0 : ®¯à¥¤¥«¨âì ¨ ®âà¨á®¢ âì ®ª®
|
xor eax,eax ; äãªæ¨ï 0 : ®¯à¥¤¥«¨âì ¨ ®âà¨á®¢ âì ®ª®
|
||||||
mov ebx,200 shl 16 + 270 ; [x áâ àâ] *65536 + [x à §¬¥à]
|
mov ebx,200 shl 16 + 300 ; [x áâ àâ] *65536 + [x à §¬¥à]
|
||||||
mov ecx,200 shl 16 + 190 ; [y áâ àâ] *65536 + [y à §¬¥à]
|
mov ecx,200 shl 16 + 190 ; [y áâ àâ] *65536 + [y à §¬¥à]
|
||||||
mov edx,[sc.work] ; 梥â à ¡®ç¥© ®¡« á⨠RRGGBB,8->color gl
|
mov edx,[sc.work] ; 梥â à ¡®ç¥© ®¡« á⨠RRGGBB,8->color gl
|
||||||
or edx,0x34000000
|
or edx,0x34000000
|
||||||
mov edi,title ; ‡€ƒŽ‹Ž‚ŽŠ ŽŠ<C5BD>€
|
mov edi,title ; ‡€ƒŽ‹Ž‚ŽŠ ŽŠ<C5BD>€
|
||||||
mcall
|
mcall
|
||||||
|
|
||||||
push dword editbox
|
call draw_PathShow
|
||||||
call [edit_box_draw]
|
|
||||||
|
|
||||||
;draw_edit_box editbox ;à¨á®¢ ¨¥ edit box
|
;®âà¨á®¢ª ⥥© ª®¯®ª
|
||||||
|
mcall 13,<194,60>,<34,15>,0x444444
|
||||||
mov al,13 ;®âà¨á®¢ª ⥥© ª®¯®ª
|
|
||||||
mov ebx,194 shl 16 + 60
|
|
||||||
mov ecx,34 shl 16 +15
|
|
||||||
mov edx,0x444444
|
|
||||||
mcall
|
|
||||||
|
|
||||||
add ecx,20 shl 16
|
add ecx,20 shl 16
|
||||||
mcall
|
mcall
|
||||||
@ -206,13 +237,10 @@ draw_window:
|
|||||||
|
|
||||||
add ecx,40 shl 16
|
add ecx,40 shl 16
|
||||||
mcall
|
mcall
|
||||||
|
;®âà¨á®¢ª ª®¯®ª
|
||||||
mov eax,8 ;®âà¨á®¢ª ª®¯®ª
|
|
||||||
sub ebx,4 shl 16
|
sub ebx,4 shl 16
|
||||||
sub ecx,4 shl 16
|
sub ecx,4 shl 16
|
||||||
mov edx,5
|
mcall 8,,,5,[sc.work_button]
|
||||||
mov esi,[sc.work_button]
|
|
||||||
mcall
|
|
||||||
|
|
||||||
sub ecx,40 shl 16
|
sub ecx,40 shl 16
|
||||||
dec edx
|
dec edx
|
||||||
@ -225,13 +253,10 @@ draw_window:
|
|||||||
sub ecx,20 shl 16
|
sub ecx,20 shl 16
|
||||||
dec edx
|
dec edx
|
||||||
mcall
|
mcall
|
||||||
|
; ¤¯¨á¨
|
||||||
mov al,4 ; ¤¯¨á¨
|
|
||||||
mov ebx,45 shl 16 + 12
|
|
||||||
mov ecx,[sc.work_text]
|
mov ecx,[sc.work_text]
|
||||||
or ecx,0x80000000
|
or ecx,0x80000000
|
||||||
mov edx,label1
|
mcall 4,<45,12>,,label1
|
||||||
mcall
|
|
||||||
|
|
||||||
mov ebx,150 shl 16 + 35
|
mov ebx,150 shl 16 + 35
|
||||||
mov edx,path1
|
mov edx,path1
|
||||||
@ -259,36 +284,81 @@ draw_window:
|
|||||||
mov edx,save
|
mov edx,save
|
||||||
mcall
|
mcall
|
||||||
|
|
||||||
add ebx,20
|
push edx
|
||||||
mcall
|
mov edx,key_help
|
||||||
|
call key_help_correct
|
||||||
|
pop edx
|
||||||
|
|
||||||
add ebx,20
|
add ebx,20
|
||||||
mcall
|
mcall
|
||||||
|
|
||||||
|
push edx
|
||||||
|
mov edx,key_help+2
|
||||||
|
call key_help_correct
|
||||||
|
pop edx
|
||||||
|
|
||||||
|
add ebx,20
|
||||||
|
mcall
|
||||||
|
|
||||||
|
push edx
|
||||||
|
mov edx,key_help+4
|
||||||
|
call key_help_correct
|
||||||
|
pop edx
|
||||||
|
|
||||||
|
mov edx,select
|
||||||
add ebx,40
|
add ebx,40
|
||||||
mcall
|
mcall
|
||||||
|
|
||||||
mov al,12 ; äãªæ¨ï 12: á®®¡é¨âì Ž‘ ®¡ ®âà¨á®¢ª¥ ®ª
|
mov edx,key_help+6
|
||||||
mov ebx,2 ; 2, § ª®ç¨«¨ à¨á®¢ âì
|
call key_help_correct
|
||||||
mcall
|
|
||||||
|
|
||||||
|
mcall 12,2 ; äãªæ¨ï 12: á®®¡é¨âì Ž‘ ®¡ ®âà¨á®¢ª¥ ®ª
|
||||||
|
; 2, § ª®ç¨«¨ à¨á®¢ âì
|
||||||
ret ; ¢ë室¨¬ ¨§ ¯à®æ¥¤ãàë
|
ret ; ¢ë室¨¬ ¨§ ¯à®æ¥¤ãàë
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
key_help_correct:
|
||||||
|
push ebx
|
||||||
|
ror ebx,16
|
||||||
|
mov bx,270
|
||||||
|
rol ebx,16
|
||||||
|
pusha
|
||||||
|
mov ecx,ebx
|
||||||
|
sub ebx,3 shl 16
|
||||||
|
mov bx,13
|
||||||
|
sub cx,3
|
||||||
|
shl ecx,16
|
||||||
|
mov cx,13
|
||||||
|
mcall 13,,,0xffffff
|
||||||
|
popa
|
||||||
|
mcall
|
||||||
|
pop ebx
|
||||||
|
ret
|
||||||
;---------------------------------------------------------------------
|
;---------------------------------------------------------------------
|
||||||
;--- „€<E2809E><E282AC>›… <20><>Žƒ<C5BD>€ŒŒ› ----------------------------------------------
|
;--- „€<E2809E><E282AC>›… <20><>Žƒ<C5BD>€ŒŒ› ----------------------------------------------
|
||||||
;---------------------------------------------------------------------
|
;---------------------------------------------------------------------
|
||||||
|
|
||||||
title db appname,version,0
|
title db appname,version,0
|
||||||
|
|
||||||
editbox:
|
;---------------------------------------------------------------------
|
||||||
edit1 edit_box 170,10,113,0xffffff,0xaabbcc,0,0,0,512,path4,mouse_dd,ed_focus,26,26
|
PathShow_data_1:
|
||||||
editbox_end:
|
.type dd 0 ;+0
|
||||||
|
.start_y dw 113 ;+4
|
||||||
|
.start_x dw 10 ;+6
|
||||||
|
.font_size_x dw 6 ;+8 ; 6 - for font 0, 8 - for font 1
|
||||||
|
.area_size_x dw 170 ;+10
|
||||||
|
.font_number dd 0 ;+12 ; 0 - monospace, 1 - variable
|
||||||
|
.background_flag dd 0 ;+16
|
||||||
|
.font_color dd 0x0 ;+20
|
||||||
|
.background_color dd 0x0 ;+24
|
||||||
|
.text_pointer dd fname_buf ;+28
|
||||||
|
.work_area_pointer dd text_work_area ;+32
|
||||||
|
.temp_text_length dd 0 ;+36
|
||||||
|
;---------------------------------------------------------------------
|
||||||
if lang eq ru
|
if lang eq ru
|
||||||
save db '‘®åà ¨âì',0
|
save db '‘®åà ¨âì',0
|
||||||
|
select db ' ‚ë¡à âì',0
|
||||||
label1 db '‚ë¡¥à¨â¥ ®¤¨ ¨§ ¢ ਠ⮢:',0
|
label1 db '‚ë¡¥à¨â¥ ®¤¨ ¨§ ¢ ਠ⮢:',0
|
||||||
label2 db 'ˆ«¨ ¢¢¥¤¨â¥ ¯®«ë© ¯ãâì ª ä ©«ã:',0
|
label2 db 'ˆ«¨ ¢ë¡¥à¨â¥ ¯®«ë© ¯ãâì ª ä ©«ã:',0
|
||||||
label3 db '‚ᥠ¯ ¯ª¨ ¤®«¦ë áãé¥á⢮¢ âì',0
|
label3 db '‚ᥠ¯ ¯ª¨ ¤®«¦ë áãé¥á⢮¢ âì',0
|
||||||
ok db 'RAM-¤¨áª á®åà ¥ ãᯥè®',0
|
ok db 'RAM-¤¨áª á®åà ¥ ãᯥè®',0
|
||||||
error3 db '<27>¥¨§¢¥áâ ï ä ©«®¢ ï á¨á⥬ ',0
|
error3 db '<27>¥¨§¢¥áâ ï ä ©«®¢ ï á¨á⥬ ',0
|
||||||
@ -298,10 +368,12 @@ error9 db '
|
|||||||
error10 db '„®áâ㯠§ ¯à¥é¥',0
|
error10 db '„®áâ㯠§ ¯à¥é¥',0
|
||||||
error11 db 'Žè¨¡ª ãáâனá⢠',0
|
error11 db 'Žè¨¡ª ãáâனá⢠',0
|
||||||
aUnknownError db '<27>¥¨§¢¥áâ ï ®è¨¡ª ',0
|
aUnknownError db '<27>¥¨§¢¥áâ ï ®è¨¡ª ',0
|
||||||
|
;---------------------------------------------------------------------
|
||||||
else if lang eq et
|
else if lang eq et
|
||||||
save db 'Salvesta',0
|
save db 'Salvesta',0
|
||||||
|
select db ' Valige',0
|
||||||
label1 db 'Vali üks variantidest:',0
|
label1 db 'Vali üks variantidest:',0
|
||||||
label2 db 'Või sisesta teekond failinimeni:',0
|
label2 db 'Või valige teekond failinimeni:',0
|
||||||
label3 db 'Kõik kataloogid peavad eksisteerima',0
|
label3 db 'Kõik kataloogid peavad eksisteerima',0
|
||||||
ok db 'RAM-ketas salvestatud edukalt',0
|
ok db 'RAM-ketas salvestatud edukalt',0
|
||||||
error3 db 'Tundmatu failisüsteem',0
|
error3 db 'Tundmatu failisüsteem',0
|
||||||
@ -311,11 +383,12 @@ error9 db 'FAT tabel vigane',0
|
|||||||
error10 db 'Juurdepääs keelatud',0
|
error10 db 'Juurdepääs keelatud',0
|
||||||
error11 db 'Seadme viga',0
|
error11 db 'Seadme viga',0
|
||||||
aUnknownError db 'Tundmatu viga',0
|
aUnknownError db 'Tundmatu viga',0
|
||||||
|
;---------------------------------------------------------------------
|
||||||
else
|
else
|
||||||
save db ' Save',0
|
save db ' Save',0
|
||||||
|
select db ' Select',0
|
||||||
label1 db 'Select one of the variants:',0
|
label1 db 'Select one of the variants:',0
|
||||||
label2 db ' Or enter full path to file:',0
|
label2 db ' Or select full path to file:',0
|
||||||
label3 db ' All folders must exist',0
|
label3 db ' All folders must exist',0
|
||||||
ok db 'RAM-drive was saved successfully',0
|
ok db 'RAM-drive was saved successfully',0
|
||||||
error3 db 'Unknown file system',0
|
error3 db 'Unknown file system',0
|
||||||
@ -330,46 +403,203 @@ end if
|
|||||||
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
|
;>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
|
||||||
;DATA ¤ ë¥
|
;DATA ¤ ë¥
|
||||||
;‚ᥣ¤ ᮡ«î¤ âì ¯®á«¥¤®¢ ⥫ì®áâì ¢ ¨¬¥¨.
|
;‚ᥣ¤ ᮡ«î¤ âì ¯®á«¥¤®¢ ⥫ì®áâì ¢ ¨¬¥¨.
|
||||||
system_path db '/sys/lib/'
|
system_dir_Boxlib db '/sys/lib/box_lib.obj',0
|
||||||
library_name db 'box_lib.obj',0
|
system_dir_ProcLib db '/sys/lib/proc_lib.obj',0
|
||||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
|
||||||
err_message_found_lib db 'Sorry I cannot load library box_lib.obj',0
|
|
||||||
head_f_i:
|
head_f_i:
|
||||||
head_f_l db 'System error',0
|
head_f_l db 'System error',0
|
||||||
err_message_import db 'Error on load import library box_lib.obj',0
|
|
||||||
align 4
|
|
||||||
myimport:
|
|
||||||
|
|
||||||
edit_box_draw dd aEdit_box_draw
|
err_message_found_lib1 db 'box_lib.obj - Not found!',0
|
||||||
edit_box_key dd aEdit_box_key
|
err_message_found_lib2 db 'proc_lib.obj - Not found!',0
|
||||||
edit_box_mouse dd aEdit_box_mouse
|
|
||||||
|
err_message_import1 db 'box_lib.obj - Wrong import!',0
|
||||||
|
err_message_import2 db 'proc_lib.obj - Wrong import!',0
|
||||||
|
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
l_libs_start:
|
||||||
|
|
||||||
|
library01 l_libs system_dir_Boxlib+9, cur_dir_path, library_path, system_dir_Boxlib, \
|
||||||
|
err_message_found_lib1, head_f_l, Box_lib_import, err_message_import1, head_f_i
|
||||||
|
|
||||||
|
library02 l_libs system_dir_ProcLib+9, cur_dir_path, library_path, system_dir_ProcLib, \
|
||||||
|
err_message_found_lib2, head_f_l, ProcLib_import, err_message_import2, head_f_i
|
||||||
|
|
||||||
|
end_l_libs:
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
OpenDialog_data:
|
||||||
|
.type dd 1 ; Save
|
||||||
|
.procinfo dd procinfo ;+4
|
||||||
|
.com_area_name dd communication_area_name ;+8
|
||||||
|
.com_area dd 0 ;+12
|
||||||
|
.opendir_pach dd temp_dir_pach ;+16
|
||||||
|
.dir_default_pach dd communication_area_default_pach ;+20
|
||||||
|
.start_path dd open_dialog_path ;+24
|
||||||
|
.draw_window dd draw_window ;+28
|
||||||
|
.status dd 0 ;+32
|
||||||
|
.openfile_pach dd fname_buf ;+36
|
||||||
|
.filename_area dd filename_area ;+40
|
||||||
|
.filter_area dd Filter
|
||||||
|
.x:
|
||||||
|
.x_size dw 420 ;+48 ; Window X size
|
||||||
|
.x_start dw 10 ;+50 ; Window X position
|
||||||
|
.y:
|
||||||
|
.y_size dw 320 ;+52 ; Window y size
|
||||||
|
.y_start dw 10 ;+54 ; Window Y position
|
||||||
|
|
||||||
|
communication_area_name:
|
||||||
|
db 'FFFFFFFF_open_dialog',0
|
||||||
|
open_dialog_path:
|
||||||
|
db '/sys/File Managers/opendial',0
|
||||||
|
communication_area_default_pach:
|
||||||
|
db '/hd0/1/kolibri',0
|
||||||
|
|
||||||
|
Filter:
|
||||||
|
dd Filter.end - Filter.1
|
||||||
|
.1:
|
||||||
|
db 'IMG',0
|
||||||
|
db 'IMA',0
|
||||||
|
.end:
|
||||||
|
db 0
|
||||||
|
|
||||||
|
start_temp_file_name: db 'kolibri.img',0
|
||||||
|
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
align 4
|
||||||
|
ProcLib_import:
|
||||||
|
OpenDialog_Init dd aOpenDialog_Init
|
||||||
|
OpenDialog_Start dd aOpenDialog_Start
|
||||||
|
;OpenDialog__Version dd aOpenDialog_Version
|
||||||
|
dd 0
|
||||||
|
dd 0
|
||||||
|
aOpenDialog_Init db 'OpenDialog_init',0
|
||||||
|
aOpenDialog_Start db 'OpenDialog_start',0
|
||||||
|
;aOpenDialog_Version db 'Version_OpenDialog',0
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
align 4
|
||||||
|
Box_lib_import:
|
||||||
|
;init_lib dd a_init
|
||||||
|
;version_lib dd a_version
|
||||||
|
|
||||||
|
|
||||||
|
;edit_box_draw dd aEdit_box_draw
|
||||||
|
;edit_box_key dd aEdit_box_key
|
||||||
|
;edit_box_mouse dd aEdit_box_mouse
|
||||||
;version_ed dd aVersion_ed
|
;version_ed dd aVersion_ed
|
||||||
|
|
||||||
|
;check_box_draw dd aCheck_box_draw
|
||||||
|
;check_box_mouse dd aCheck_box_mouse
|
||||||
|
;version_ch dd aVersion_ch
|
||||||
|
|
||||||
|
;option_box_draw dd aOption_box_draw
|
||||||
|
;option_box_mouse dd aOption_box_mouse
|
||||||
|
;version_op dd aVersion_op
|
||||||
|
|
||||||
|
;scrollbar_ver_draw dd aScrollbar_ver_draw
|
||||||
|
;scrollbar_ver_mouse dd aScrollbar_ver_mouse
|
||||||
|
;scrollbar_hor_draw dd aScrollbar_hor_draw
|
||||||
|
;scrollbar_hor_mouse dd aScrollbar_hor_mouse
|
||||||
|
;version_scrollbar dd aVersion_scrollbar
|
||||||
|
|
||||||
|
;dinamic_button_draw dd aDbutton_draw
|
||||||
|
;dinamic_button_mouse dd aDbutton_mouse
|
||||||
|
;version_dbutton dd aVersion_dbutton
|
||||||
|
|
||||||
|
;menu_bar_draw dd aMenu_bar_draw
|
||||||
|
;menu_bar_mouse dd aMenu_bar_mouse
|
||||||
|
;menu_bar_activate dd aMenu_bar_activate
|
||||||
|
;version_menu_bar dd aVersion_menu_bar
|
||||||
|
|
||||||
|
;FileBrowser_draw dd aFileBrowser_draw
|
||||||
|
;FileBrowser_mouse dd aFileBrowser_mouse
|
||||||
|
;FileBrowser_key dd aFileBrowser_key
|
||||||
|
;Version_FileBrowser dd aVersion_FileBrowser
|
||||||
|
|
||||||
|
PathShow_prepare dd sz_PathShow_prepare
|
||||||
|
PathShow_draw dd sz_PathShow_draw
|
||||||
|
;Version_path_show dd szVersion_path_show
|
||||||
dd 0
|
dd 0
|
||||||
dd 0
|
dd 0
|
||||||
|
|
||||||
aEdit_box_draw db 'edit_box',0
|
;a_init db 'lib_init',0
|
||||||
aEdit_box_key db 'edit_box_key',0
|
;a_version db 'version',0
|
||||||
aEdit_box_mouse db 'edit_box_mouse',0
|
|
||||||
|
;aEdit_box_draw db 'edit_box',0
|
||||||
|
;aEdit_box_key db 'edit_box_key',0
|
||||||
|
;aEdit_box_mouse db 'edit_box_mouse',0
|
||||||
;aVersion_ed db 'version_ed',0
|
;aVersion_ed db 'version_ed',0
|
||||||
|
|
||||||
|
;aCheck_box_draw db 'check_box_draw',0
|
||||||
|
;aCheck_box_mouse db 'check_box_mouse',0
|
||||||
|
;aVersion_ch db 'version_ch',0
|
||||||
|
|
||||||
;mouse_flag: dd 0x0
|
;aOption_box_draw db 'option_box_draw',0
|
||||||
|
;aOption_box_mouse db 'option_box_mouse',0
|
||||||
|
;aVersion_op db 'version_op',0
|
||||||
|
|
||||||
|
;aScrollbar_ver_draw db 'scrollbar_v_draw',0
|
||||||
|
;aScrollbar_ver_mouse db 'scrollbar_v_mouse',0
|
||||||
|
;aScrollbar_hor_draw db 'scrollbar_h_draw',0
|
||||||
|
;aScrollbar_hor_mouse db 'scrollbar_h_mouse',0
|
||||||
|
;aVersion_scrollbar db 'version_scrollbar',0
|
||||||
|
|
||||||
|
;aDbutton_draw db 'dbutton_draw',0
|
||||||
|
;aDbutton_mouse db 'dbutton_mouse',0
|
||||||
|
;aVersion_dbutton db 'version_dbutton',0
|
||||||
|
|
||||||
|
;aMenu_bar_draw db 'menu_bar_draw',0
|
||||||
|
;aMenu_bar_mouse db 'menu_bar_mouse',0
|
||||||
|
;aMenu_bar_activate db 'menu_bar_activate',0
|
||||||
|
;aVersion_menu_bar db 'version_menu_bar',0
|
||||||
|
|
||||||
|
;aFileBrowser_draw db 'FileBrowser_draw',0
|
||||||
|
;aFileBrowser_mouse db 'FileBrowser_mouse',0
|
||||||
|
;aFileBrowser_key db 'FileBrowser_key',0
|
||||||
|
;aVersion_FileBrowser db 'version_FileBrowser',0
|
||||||
|
|
||||||
|
sz_PathShow_prepare db 'PathShow_prepare',0
|
||||||
|
sz_PathShow_draw db 'PathShow_draw',0
|
||||||
|
;szVersion_path_show db 'version_PathShow',0
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
|
||||||
path1 db '/fd/1/',0
|
path1 db '/fd/1/',0
|
||||||
path2 db '/fd/2/',0
|
path2 db '/fd/2/',0
|
||||||
path3 db '/hd0/1/kolibri.img',0
|
path3 db '/hd0/1/kolibri.img',0
|
||||||
path4 db '/hd0/1/kolibri/kolibri.img',0 ;¤«ï १¥à¢®£® á®åà ¥¨ï
|
path4 db '/hd0/1/kolibri/kolibri.img',0 ;¤«ï १¥à¢®£® á®åà ¥¨ï
|
||||||
|
|
||||||
;---------------------------------------------------------------------
|
;---------------------------------------------------------------------
|
||||||
|
key_help:
|
||||||
rb 514
|
db '1',0
|
||||||
|
db '2',0
|
||||||
|
db '3',0
|
||||||
|
db '4',0
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
IM_END:
|
||||||
|
;---------------------------------------------------------------------
|
||||||
sc system_colors
|
sc system_colors
|
||||||
mouse_dd rd 1
|
mouse_dd rd 1
|
||||||
cur_dir_path rb 1096
|
;---------------------------------------------------------------------
|
||||||
library_path rb 1096
|
cur_dir_path:
|
||||||
|
rb 4096
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
library_path:
|
||||||
|
rb 4096
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
temp_dir_pach:
|
||||||
|
rb 4096
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
fname_buf:
|
||||||
|
rb 4096
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
procinfo:
|
||||||
|
rb 1024
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
filename_area:
|
||||||
|
rb 256
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
text_work_area:
|
||||||
|
rb 1024
|
||||||
|
;---------------------------------------------------------------------
|
||||||
align 4
|
align 4
|
||||||
rb 0x100 ; for stack
|
rb 4096
|
||||||
|
stacktop:
|
||||||
I_END: ; ¬¥âª ª®æ ¯à®£à ¬¬ë
|
I_END: ; ¬¥âª ª®æ ¯à®£à ¬¬ë
|
||||||
|
Loading…
Reference in New Issue
Block a user