Identify REDRAW_ALL entry point

This commit is contained in:
Joshua Bell 2017-09-18 08:10:19 -07:00
parent ce7926b257
commit 4227be7825
10 changed files with 482 additions and 1973 deletions

View File

@ -8,6 +8,10 @@
A2D := $4000
UNKNOWN_CALL := $8E00
;; MLI-style call (call, addr)
;; Bounces to $93BC
;; References jump table at 939E
;; These must be called from main memory (RAMRDON/RAMWRTON)
JUMP_TABLE_03 := $4003 ; ???
@ -16,7 +20,7 @@ JUMP_TABLE_09 := $4009 ; ???
JUMP_TABLE_0C := $400C ; ??? (made "items/in disk/..." redraw oddly)
JUMP_TABLE_0F := $400F ; ???
JUMP_TABLE_12 := $4012 ; ???
JUMP_TABLE_15 := $4015 ; ???
JUMP_TABLE_REDRAW_ALL := $4015 ; Redraw all windows (e.g. after a drag)
JUMP_TABLE_18 := $4018 ; ???
JUMP_TABLE_CLEAR_SEL := $401E ; Clear DeskTop selection
JUMP_TABLE_MLI := $4021 ; ProDOS MLI call (Y=call, X,A=params addr)

View File

@ -79,12 +79,11 @@ call_init:
;; Used after a drag-and-drop is completed;
;; redraws the window.
.proc call_4015_main
.proc redraw_screen_and_window
zp_stash := $20
;; Call jump table entry $4015 in main memory, by
;; copying a trampoline routine to the ZP.
;; Copying trampoline routine to the ZP.
lda LCBANK1
lda LCBANK1
@ -121,7 +120,7 @@ skip: lda #0
.proc routine
sta RAMRDOFF
sta RAMWRTOFF
jsr JUMP_TABLE_15
jsr JUMP_TABLE_REDRAW_ALL
sta RAMRDON
sta RAMWRTON
rts
@ -925,7 +924,7 @@ loop: lda routine,x
lda LCBANK1
A2D_CALL A2D_DRAG_WINDOW, drag_params
lda ROMIN2
jsr call_4015_main ; redraws window
jsr redraw_screen_and_window
rts
;;; ==================================================

View File

@ -78,12 +78,13 @@ stash_stack: .byte 0
window_id = $33
;;; ==================================================
;;; Redraw the screen (all windows) after a drag
.proc call_4015_main
.proc redraw_screen
dest := $20
;; copy following "call 4015" routine to $20 and call it
;; copy following routine to $20 and call it
ldx #sizeof_routine
loop: lda routine,x
sta dest,x
@ -109,7 +110,7 @@ skip: lda #0
.proc routine
sta RAMRDOFF
sta RAMWRTOFF
jsr JUMP_TABLE_15
jsr JUMP_TABLE_REDRAW_ALL
sta RAMRDON
sta RAMWRTON
rts
@ -762,7 +763,7 @@ check_title:
sta drag_window_params::id
A2D_CALL A2D_DRAG_WINDOW, drag_window_params
ldx #$23
jsr call_4015_main
jsr redraw_screen
rts
;; on key press - exit if Escape

View File

@ -476,7 +476,7 @@ end: rts
ldx font_size_count
sta RAMWRTOFF
loop: lda font_width_table - 1,x
sta call_jt15+2,x
sta font_width_backup - 1,x
dex
bne loop
sta RAMWRTON
@ -563,7 +563,7 @@ title: jsr on_title_bar_click
;;; This is dead code (no resize handle!) and may be buggy
.proc on_resize_click
A2D_CALL A2D_DRAG_RESIZE, resize_drag_params
jsr call_jt15 ; call $4015 on main
jsr redraw_screen
jsr calc_window_size
max_width := default_width
@ -1344,10 +1344,10 @@ loop: clc
rts
.endproc
.proc call_jt15
lda #<JUMP_TABLE_15
sta call_main_addr ; self-modified
lda #>JUMP_TABLE_15
.proc redraw_screen
lda #<JUMP_TABLE_REDRAW_ALL
sta call_main_addr
lda #>JUMP_TABLE_REDRAW_ALL
sta call_main_addr+1
jsr call_main_trampoline
rts

View File

@ -245,3 +245,9 @@ RANGE { START $a95d; END $a95d; TYPE ByteTable; };
RANGE { START $a95e; END $a95f; TYPE AddrTable; };
RANGE { START $bff8; END $bff8; TYPE ByteTable; };
RANGE { START $bff9; END $bffa; TYPE AddrTable; };
RANGE { START $403B; END $4041; TYPE Code; };
RANGE { START $407F; END $40E4; TYPE Code; };
RANGE { START $40E5; END $431f; TYPE ByteTable; };
RANGE { START $44A1; END $4DAE; TYPE ByteTable; };

View File

@ -1,6 +1,6 @@
.org $2000
; da65 V2.16 - Git f5e9b401
; Created: 2017-09-17 12:00:53
; Created: 2017-09-17 15:06:29
; Input file: orig/DESKTOP2_s0_loader
; Page: 1

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
.org $D000
; da65 V2.16 - Git f5e9b401
; Created: 2017-09-17 12:00:53
; Created: 2017-09-17 15:06:29
; Input file: orig/DESKTOP2_s2_aux2
; Page: 1

View File

@ -1,6 +1,6 @@
.org $FB00
; da65 V2.16 - Git f5e9b401
; Created: 2017-09-17 12:00:53
; Created: 2017-09-17 15:06:29
; Input file: orig/DESKTOP2_s3_aux3
; Page: 1

View File

@ -1,6 +1,6 @@
.org $4000
; da65 V2.16 - Git f5e9b401
; Created: 2017-09-17 12:00:53
; Created: 2017-09-17 15:06:29
; Input file: orig/DESKTOP2_s4_main1
; Page: 1