(m291) Redesigning scroll
This commit is contained in:
parent
8859196212
commit
f8cf42530f
|
@ -116,11 +116,10 @@
|
||||||
POP2 BRK
|
POP2 BRK
|
||||||
|
|
||||||
&scroll ( distance -> )
|
&scroll ( distance -> )
|
||||||
.selection/scroll LDZ ADD
|
.selection/scroll LDZ ADD DUP #ff NEQ ?{ POP JMP2r }
|
||||||
( above ) DUP #ff EQU ?{
|
.selection/scroll STZ
|
||||||
( below ) DUP #18 ADD .lines/tracks LDZ GTH ?{ DUP .selection/scroll STZ
|
<redraw-dir>
|
||||||
<redraw-dir> } }
|
BRK
|
||||||
POP BRK
|
|
||||||
|
|
||||||
@on-control ( -> )
|
@on-control ( -> )
|
||||||
( | mod )
|
( | mod )
|
||||||
|
@ -214,7 +213,6 @@
|
||||||
|
|
||||||
@<move> ( mod -- )
|
@<move> ( mod -- )
|
||||||
.selection LDZ ADD
|
.selection LDZ ADD
|
||||||
( top ) DUP .selection/scroll LDZ #ff00 NEQ2 ?{ POP JMP2r }
|
|
||||||
( bottom ) DUP .lines/folders LDZ .lines/tracks LDZ ADD NEQ ?{ POP JMP2r }
|
( bottom ) DUP .lines/folders LDZ .lines/tracks LDZ ADD NEQ ?{ POP JMP2r }
|
||||||
( >> )
|
( >> )
|
||||||
|
|
||||||
|
@ -229,7 +227,7 @@
|
||||||
POP JMP2r
|
POP JMP2r
|
||||||
|
|
||||||
&tracks ( id -- )
|
&tracks ( id -- )
|
||||||
.selection/scroll LDZ ADD DUP .selection/track STZ
|
DUP .selection/track STZ
|
||||||
#00 SWP
|
#00 SWP
|
||||||
( CELLSIZE ) #70 SFT2 ;mem/tracks ADD2 !<send-load>
|
( CELLSIZE ) #70 SFT2 ;mem/tracks ADD2 !<send-load>
|
||||||
|
|
||||||
|
@ -237,12 +235,11 @@
|
||||||
#00 SWP
|
#00 SWP
|
||||||
( CELLSIZE ) #70 SFT2 ;mem/folders ADD2
|
( CELLSIZE ) #70 SFT2 ;mem/folders ADD2
|
||||||
( > ) [ LIT2 00 -selection ] STZ
|
( > ) [ LIT2 00 -selection ] STZ
|
||||||
( > ) [ LIT2 00 -selection/scroll ] STZ
|
|
||||||
path/<push> !<refresh-dir>
|
path/<push> !<refresh-dir>
|
||||||
|
|
||||||
@<escape> ( -- )
|
@<escape> ( -- )
|
||||||
( > ) [ LIT2 00 -selection/scroll ] STZ
|
|
||||||
;path/null LDA ?{ JMP2r }
|
;path/null LDA ?{ JMP2r }
|
||||||
|
[ LIT2 00 -selection/scroll ] STZ
|
||||||
path/pop !<refresh-dir>
|
path/pop !<refresh-dir>
|
||||||
|
|
||||||
@<change-mode> ( -- )
|
@<change-mode> ( -- )
|
||||||
|
@ -359,8 +356,8 @@
|
||||||
@<fit-window> ( -- )
|
@<fit-window> ( -- )
|
||||||
#00
|
#00
|
||||||
( folders ) .lines/folders LDZ
|
( folders ) .lines/folders LDZ
|
||||||
( tracks ) .lines/tracks LDZ
|
( tracks ) .lines/tracks LDZ ADD
|
||||||
( scroll ) #18 LTHk [ JMP SWP ] POP ADD
|
( scroll ) #18 LTHk [ JMP SWP ] POP
|
||||||
( empty ) DUP #00 EQU ADD #40 SFT2
|
( empty ) DUP #00 EQU ADD #40 SFT2
|
||||||
( no-folder spacer ) has-spacer #00 EQU ?{ #0008 ADD2 }
|
( no-folder spacer ) has-spacer #00 EQU ?{ #0008 ADD2 }
|
||||||
( padding ) #0020 ADD2
|
( padding ) #0020 ADD2
|
||||||
|
@ -537,7 +534,7 @@
|
||||||
#0008 .Screen/x DEO2
|
#0008 .Screen/x DEO2
|
||||||
;dict/empty #0f !<draw-uf2> }
|
;dict/empty #0f !<draw-uf2> }
|
||||||
( | folders )
|
( | folders )
|
||||||
;mem/folders .lines/folders LDZ .selection LDZ <draw-folders>
|
.selection LDZ <draw-folders>
|
||||||
has-spacer #00 EQU ?{ ;dash-icn <draw-spacer> }
|
has-spacer #00 EQU ?{ ;dash-icn <draw-spacer> }
|
||||||
;mem/tracks .lines/tracks LDZ .selection LDZ .lines/folders LDZ SUB
|
;mem/tracks .lines/tracks LDZ .selection LDZ .lines/folders LDZ SUB
|
||||||
( >> )
|
( >> )
|
||||||
|
@ -548,20 +545,19 @@
|
||||||
#0008 .Screen/x DEO2
|
#0008 .Screen/x DEO2
|
||||||
#00 SWP2 ,&t STR2
|
#00 SWP2 ,&t STR2
|
||||||
&>l ( -- )
|
&>l ( -- )
|
||||||
( scroll ) DUP #18 LTH ?{ POP2 JMP2r }
|
|
||||||
[ LITr 05 ]
|
[ LITr 05 ]
|
||||||
( | selected )
|
( | selected )
|
||||||
DUP [ LIT &sel $1 ] NEQ ?{
|
DUP [ LIT &sel $1 ] NEQ ?{
|
||||||
POPr [ LITr 06 ] ;fill-icn <draw-background> }
|
POPr [ LITr 06 ] ;fill-icn <draw-background> }
|
||||||
( | marker )
|
( | marker )
|
||||||
DUP .selection/scroll LDZ ADD .selection/track LDZ NEQ ?{
|
DUP .selection/track LDZ NEQ ?{
|
||||||
[ LIT2 15 -Screen/auto ] DEO
|
[ LIT2 15 -Screen/auto ] DEO
|
||||||
#0000 .Screen/x DEO2
|
#0000 .Screen/x DEO2
|
||||||
;poke-icn .Screen/addr DEO2
|
;poke-icn .Screen/addr DEO2
|
||||||
DUPr [ LITr -Screen/sprite ] DEOr }
|
DUPr [ LITr -Screen/sprite ] DEOr }
|
||||||
( | normal )
|
( | normal )
|
||||||
#0008 .Screen/x DEO2
|
#0008 .Screen/x DEO2
|
||||||
#00 OVR .selection/scroll LDZ ADD
|
#00 OVR
|
||||||
( CELLSIZE ) #70 SFT2 [ LIT2 &t $2 ] ADD2 STHr <draw-uf2>
|
( CELLSIZE ) #70 SFT2 [ LIT2 &t $2 ] ADD2 STHr <draw-uf2>
|
||||||
.Screen/y DEI2k #0010 ADD2 ROT DEO2
|
.Screen/y DEI2k #0010 ADD2 ROT DEO2
|
||||||
INC GTHk ?&>l
|
INC GTHk ?&>l
|
||||||
|
@ -781,11 +777,11 @@
|
||||||
.Screen/y DEO2
|
.Screen/y DEO2
|
||||||
JMP2r
|
JMP2r
|
||||||
|
|
||||||
@<draw-folders> ( addr* length selection -- )
|
@<draw-folders> ( selection -- )
|
||||||
,&sel STR
|
,&sel STR
|
||||||
DUP ?{ POP2 POP JMP2r }
|
|
||||||
#0008 .Screen/x DEO2
|
#0008 .Screen/x DEO2
|
||||||
#00 SWP2 ,&t STR2
|
.lines/folders LDZ #00 NEQk ?{ POP JMP2r }
|
||||||
|
.selection/scroll LDZ ADD GTHk ?{ POP2 JMP2r }
|
||||||
&>l ( -- )
|
&>l ( -- )
|
||||||
[ LITr 05 ]
|
[ LITr 05 ]
|
||||||
( | selected )
|
( | selected )
|
||||||
|
@ -800,7 +796,7 @@
|
||||||
( | normal )
|
( | normal )
|
||||||
#0008 .Screen/x DEO2
|
#0008 .Screen/x DEO2
|
||||||
#00 OVR
|
#00 OVR
|
||||||
( CELLSIZE ) #70 SFT2 [ LIT2 &t $2 ] ADD2 STHr <draw-uf2>
|
( CELLSIZE ) #70 SFT2 ;mem/folders ADD2 STHr <draw-uf2>
|
||||||
.Screen/y DEI2k #0010 ADD2 ROT DEO2
|
.Screen/y DEI2k #0010 ADD2 ROT DEO2
|
||||||
INC GTHk ?&>l
|
INC GTHk ?&>l
|
||||||
POP2 JMP2r
|
POP2 JMP2r
|
||||||
|
|
Loading…
Reference in New Issue