mirror of
https://github.com/mi57730/a2d.git
synced 2025-02-27 14:29:55 +00:00
disasm: scroll thumbs
This commit is contained in:
parent
c62ff1bf64
commit
8b66a9faa0
@ -3747,7 +3747,7 @@ done_client_click:
|
|||||||
.proc update_scroll_thumb
|
.proc update_scroll_thumb
|
||||||
copy updatethumb_stash, updatethumb_thumbpos
|
copy updatethumb_stash, updatethumb_thumbpos
|
||||||
MGTK_RELAY_CALL MGTK::UpdateThumb, updatethumb_params
|
MGTK_RELAY_CALL MGTK::UpdateThumb, updatethumb_params
|
||||||
jsr L6523
|
jsr apply_active_winfo_to_grafport2
|
||||||
jsr L84D1
|
jsr L84D1
|
||||||
bit active_window_view_by
|
bit active_window_view_by
|
||||||
bmi :+ ; list view, no icons
|
bmi :+ ; list view, no icons
|
||||||
@ -4568,18 +4568,20 @@ L650D: .word 0
|
|||||||
bit active_window_view_by
|
bit active_window_view_by
|
||||||
bmi :+ ; list view, not icons
|
bmi :+ ; list view, not icons
|
||||||
jsr cached_icons_screen_to_window
|
jsr cached_icons_screen_to_window
|
||||||
: jsr L6523
|
: jsr apply_active_winfo_to_grafport2
|
||||||
jsr compute_icons_bbox
|
jsr compute_icons_bbox
|
||||||
lda active_window_id
|
lda active_window_id
|
||||||
jmp compute_window_dimensions
|
jmp compute_window_dimensions
|
||||||
.endproc
|
.endproc
|
||||||
|
|
||||||
.proc L6523
|
.proc apply_active_winfo_to_grafport2
|
||||||
|
ptr := $06
|
||||||
|
|
||||||
lda active_window_id
|
lda active_window_id
|
||||||
jsr window_lookup
|
jsr window_lookup
|
||||||
addax #$14, $06
|
addax #MGTK::Winfo::port, ptr
|
||||||
ldy #$25
|
ldy #.sizeof(MGTK::GrafPort) + 1 ; ???
|
||||||
: lda ($06),y
|
: lda (ptr),y
|
||||||
sta grafport2,y
|
sta grafport2,y
|
||||||
dey
|
dey
|
||||||
bpl :-
|
bpl :-
|
||||||
@ -4614,79 +4616,91 @@ L650D: .word 0
|
|||||||
;;; ============================================================
|
;;; ============================================================
|
||||||
|
|
||||||
.proc update_hthumb
|
.proc update_hthumb
|
||||||
|
winfo_ptr := $06
|
||||||
|
|
||||||
lda active_window_id
|
lda active_window_id
|
||||||
jsr compute_window_dimensions
|
jsr compute_window_dimensions
|
||||||
stax L6600
|
stax win_width
|
||||||
lda active_window_id
|
lda active_window_id
|
||||||
jsr window_lookup
|
jsr window_lookup
|
||||||
stax $06
|
stax winfo_ptr
|
||||||
ldy #$06
|
ldy #MGTK::Winfo::hthumbmax
|
||||||
lda ($06),y
|
lda (winfo_ptr),y
|
||||||
tay
|
tay
|
||||||
sub16 iconbb_rect+MGTK::Rect::x2, iconbb_rect+MGTK::Rect::x1, L6602
|
|
||||||
sub16 L6602, L6600, L6602
|
sub16 iconbb_rect+MGTK::Rect::x2, iconbb_rect+MGTK::Rect::x1, delta
|
||||||
lsr16 L6602
|
sub16 delta, win_width, delta
|
||||||
ldx L6602
|
lsr16 delta ; / 2
|
||||||
sub16 grafport2::cliprect::x1, iconbb_rect+MGTK::Rect::x1, L6602
|
ldx delta
|
||||||
bpl L65D0
|
sub16 grafport2::cliprect::x1, iconbb_rect+MGTK::Rect::x1, delta
|
||||||
lda #$00
|
bpl pos
|
||||||
beq L65EB
|
lda #0
|
||||||
L65D0: cmp16 grafport2::cliprect::x2, iconbb_rect+MGTK::Rect::x2
|
beq neg ; always
|
||||||
|
|
||||||
|
pos: cmp16 grafport2::cliprect::x2, iconbb_rect+MGTK::Rect::x2
|
||||||
bmi L65E2
|
bmi L65E2
|
||||||
tya
|
tya
|
||||||
jmp L65EE
|
jmp L65EE
|
||||||
|
|
||||||
L65E2: lsr16 L6602
|
L65E2: lsr16 delta ; / 2
|
||||||
lda L6602
|
lda delta
|
||||||
L65EB: jsr L62BC
|
neg: jsr L62BC
|
||||||
|
|
||||||
L65EE: sta updatethumb_thumbpos
|
L65EE: sta updatethumb_thumbpos
|
||||||
lda #MGTK::Ctl::horizontal_scroll_bar
|
lda #MGTK::Ctl::horizontal_scroll_bar
|
||||||
sta updatethumb_which_ctl
|
sta updatethumb_which_ctl
|
||||||
MGTK_RELAY_CALL MGTK::UpdateThumb, updatethumb_params
|
MGTK_RELAY_CALL MGTK::UpdateThumb, updatethumb_params
|
||||||
rts
|
rts
|
||||||
|
|
||||||
L6600: .word 0
|
win_width:
|
||||||
L6602: .word 0
|
.word 0
|
||||||
|
delta: .word 0
|
||||||
.endproc
|
.endproc
|
||||||
|
|
||||||
;;; ============================================================
|
;;; ============================================================
|
||||||
|
|
||||||
.proc update_vthumb
|
.proc update_vthumb
|
||||||
|
winfo_ptr := $06
|
||||||
|
|
||||||
lda active_window_id
|
lda active_window_id
|
||||||
jsr compute_window_dimensions
|
jsr compute_window_dimensions
|
||||||
sty L669F
|
sty win_height
|
||||||
lda active_window_id
|
lda active_window_id
|
||||||
jsr window_lookup
|
jsr window_lookup
|
||||||
stax $06
|
stax winfo_ptr
|
||||||
ldy #$08
|
ldy #MGTK::Winfo::vthumbmax
|
||||||
lda ($06),y
|
lda (winfo_ptr),y
|
||||||
tay
|
tay
|
||||||
sub16 iconbb_rect+MGTK::Rect::y2, iconbb_rect+MGTK::Rect::y1, L66A0
|
|
||||||
sub16_8 L66A0, L669F, L66A0
|
sub16 iconbb_rect+MGTK::Rect::y2, iconbb_rect+MGTK::Rect::y1, delta
|
||||||
lsr16 L66A0
|
sub16_8 delta, win_height, delta
|
||||||
lsr16 L66A0
|
lsr16 delta ; / 4
|
||||||
ldx L66A0
|
lsr16 delta
|
||||||
sub16 grafport2::cliprect::y1, iconbb_rect+MGTK::Rect::y1, L66A0
|
ldx delta
|
||||||
bpl L6669
|
sub16 grafport2::cliprect::y1, iconbb_rect+MGTK::Rect::y1, delta
|
||||||
lda #$00
|
bpl pos
|
||||||
beq L668A
|
lda #0
|
||||||
L6669: cmp16 grafport2::cliprect::y2, iconbb_rect+MGTK::Rect::y2
|
beq neg ; always
|
||||||
|
|
||||||
|
pos: cmp16 grafport2::cliprect::y2, iconbb_rect+MGTK::Rect::y2
|
||||||
bmi L667B
|
bmi L667B
|
||||||
tya
|
tya
|
||||||
jmp L668D
|
jmp L668D
|
||||||
|
|
||||||
L667B: lsr16 L66A0
|
L667B: lsr16 delta ; / 4
|
||||||
lsr16 L66A0
|
lsr16 delta
|
||||||
lda L66A0
|
lda delta
|
||||||
L668A: jsr L62BC
|
neg: jsr L62BC
|
||||||
|
|
||||||
L668D: sta updatethumb_thumbpos
|
L668D: sta updatethumb_thumbpos
|
||||||
lda #MGTK::Ctl::vertical_scroll_bar
|
lda #MGTK::Ctl::vertical_scroll_bar
|
||||||
sta updatethumb_which_ctl
|
sta updatethumb_which_ctl
|
||||||
MGTK_RELAY_CALL MGTK::UpdateThumb, updatethumb_params
|
MGTK_RELAY_CALL MGTK::UpdateThumb, updatethumb_params
|
||||||
rts
|
rts
|
||||||
|
|
||||||
L669F: .byte 0
|
win_height:
|
||||||
L66A0: .word 0
|
.byte 0
|
||||||
|
delta: .word 0
|
||||||
.endproc
|
.endproc
|
||||||
|
|
||||||
;;; ============================================================
|
;;; ============================================================
|
||||||
|
Loading…
x
Reference in New Issue
Block a user