mirror of
https://github.com/mi57730/a2d.git
synced 2024-12-01 20:50:06 +00:00
SIF: Space toggles B&W/Color where available
This commit is contained in:
parent
06c721b418
commit
da8bc28883
@ -240,6 +240,9 @@ nextwinfo: .addr 0
|
|||||||
lda LCBANK1
|
lda LCBANK1
|
||||||
lda LCBANK1
|
lda LCBANK1
|
||||||
|
|
||||||
|
lda #0
|
||||||
|
sta mode
|
||||||
|
|
||||||
;; Get filename by checking DeskTop selected window/icon
|
;; Get filename by checking DeskTop selected window/icon
|
||||||
|
|
||||||
;; Check that an icon is selected
|
;; Check that an icon is selected
|
||||||
@ -366,7 +369,10 @@ on_key:
|
|||||||
lda event_params::key
|
lda event_params::key
|
||||||
cmp #CHAR_ESCAPE
|
cmp #CHAR_ESCAPE
|
||||||
beq exit
|
beq exit
|
||||||
bne input_loop
|
cmp #' '
|
||||||
|
bne :+
|
||||||
|
jsr toggle_mode
|
||||||
|
: jmp input_loop
|
||||||
|
|
||||||
exit:
|
exit:
|
||||||
jsr set_bw_mode
|
jsr set_bw_mode
|
||||||
@ -604,7 +610,20 @@ cloop: lda (src),y
|
|||||||
;;; ============================================================
|
;;; ============================================================
|
||||||
;;; Color/B&W Toggle
|
;;; Color/B&W Toggle
|
||||||
|
|
||||||
|
mode: .byte 0 ; 0 = B&W, $80 = color
|
||||||
|
|
||||||
|
.proc toggle_mode
|
||||||
|
lda mode
|
||||||
|
bne set_bw_mode
|
||||||
|
;; fall through
|
||||||
|
.endproc
|
||||||
|
|
||||||
.proc set_color_mode
|
.proc set_color_mode
|
||||||
|
lda mode
|
||||||
|
bne done
|
||||||
|
lda #$80
|
||||||
|
sta mode
|
||||||
|
|
||||||
;; AppleColor Card - Mode 2 (Color 140x192)
|
;; AppleColor Card - Mode 2 (Color 140x192)
|
||||||
sta SET80VID
|
sta SET80VID
|
||||||
lda AN3_OFF
|
lda AN3_OFF
|
||||||
@ -629,6 +648,11 @@ done: rts
|
|||||||
.endproc
|
.endproc
|
||||||
|
|
||||||
.proc set_bw_mode
|
.proc set_bw_mode
|
||||||
|
lda mode
|
||||||
|
beq done
|
||||||
|
lda #0
|
||||||
|
sta mode
|
||||||
|
|
||||||
;; AppleColor Card - Mode 1 (Monochrome 560x192)
|
;; AppleColor Card - Mode 1 (Monochrome 560x192)
|
||||||
sta CLR80VID
|
sta CLR80VID
|
||||||
lda AN3_OFF
|
lda AN3_OFF
|
||||||
|
Loading…
Reference in New Issue
Block a user