~rabbits/potato

c5ae29dd61243becde1463b2056b6b800549f9bd — neauoire 4 months ago 1b64cb9
Added badge
2 files changed, 20 insertions(+), 18 deletions(-)

M README.md
M src/potato.tal
M README.md => README.md +2 -0
@@ 13,6 13,8 @@ uxnemu bin/potato.rom

If do not wish to assemble it yourself, you can download [potato.rom](https://rabbits.srht.site/potato/potato.rom).

[![builds.sr.ht status](https://builds.sr.ht/~rabbits/potato.svg)](https://builds.sr.ht/~rabbits/potato?)

## Manual

Since this is designed to be used principally on a handheld devices without a window manager, the controls are aimed at d-pad centric. The pattern here is using the B button to handle all window operations, and leave the A button to the applications. Alternatively, you can open a file with `mouse2`.

M src/potato.tal => src/potato.tal +18 -18
@@ 146,9 146,9 @@ JMP2r

	,validate-dir JSR
	;dir ;scpy JSR2
	#00 ;sel-icon JSR2
	#00 ;sel-icon ( .. )

JMP2r
JMP2

@push-dir ( path* -- )



@@ 156,9 156,9 @@ JMP2r
	DUP2 ;dict/parent-ext ;scmp JSR2 ,pop-dir JCN
	LIT "/ ;dir STH2k ;sput JSR2
	STH2r ;scat JSR2
	#00 ;sel-icon JSR2
	#00 ;sel-icon ( .. )

JMP2r
JMP2

@pop-dir ( path* -- )



@@ 173,9 173,9 @@ JMP2r
	#00 ROT ROT STA
	&skip
	POP2
	#00 ;sel-icon JSR2
	#00 ;sel-icon ( .. )

JMP2r
JMP2

@validate-dir ( -- )



@@ 216,9 216,9 @@ JMP2r

@file-create ( -- )

	;dict/create ;dict/newfile-txt ;&callback ;add-form JSR2
	;dict/create ;dict/newfile-txt ;&callback ;add-form ( .. )

JMP2r
JMP2

&callback ( -- )



@@ 232,9 232,9 @@ JMP2r
@file-rename ( -- )

	;file-validate JSR2 #0005 ADD2 DUP2 ;&src STA2
	;dict/rename SWP2 ;&callback ;add-form JSR2
	;dict/rename SWP2 ;&callback ;add-form ( .. )

JMP2r
JMP2

&callback ( -- )



@@ 249,30 249,30 @@ JMP2r
@file-clone ( -- )

	;file-validate JSR2 #0005 ADD2 DUP2 ;&src STA2
	;dict/clone SWP2 ;&callback ;add-form JSR2
	;dict/clone SWP2 ;&callback ;add-form ( .. )

JMP2r
JMP2

&callback ( -- )

	( a* ) [ LIT2 &src $2 ] ;make-src JSR2
	( b* ) ;buf/form ;make-dst JSR2
		;fcpy JSR2
		;fcpy ( .. )

JMP2r
JMP2

@file-delete ( -- )

	;file-validate JSR2 #0005 ADD2 DUP2 ;&src STA2
	;dict/delete SWP2 ;&callback ;add-option JSR2
	;dict/delete SWP2 ;&callback ;add-option ( .. )

JMP2r
JMP2

&callback ( -- )

	( a* ) [ LIT2 &src $2 ] ;make-src JSR2 ;fdel JSR2
	( a* ) [ LIT2 &src $2 ] ;make-src JSR2 ;fdel ( .. )

JMP2r
JMP2

@file-validate ( -- file* )