mirror of
https://github.com/blondie7575/WeeGUI.git
synced 2025-02-13 09:30:40 +00:00
Scrolling fixes
- Fixed window titles rendering in wrong coordinate space - Fixed superfluous redrawing caused by scroll arrow clicking
This commit is contained in:
parent
7feec071c1
commit
0c12da7c89
31
views.s
31
views.s
@ -465,10 +465,12 @@ paintWindowTitle_compute:
|
||||
lsr
|
||||
sec
|
||||
sbc SCRATCH1
|
||||
sta WG_LOCALCURSORX ; Position cursor
|
||||
lda #-1
|
||||
sta WG_LOCALCURSORY
|
||||
jsr WGSyncGlobalCursor
|
||||
clc
|
||||
adc WG_VIEWRECORDS+0,y
|
||||
sta WG_CURSORX ; Position cursor
|
||||
lda WG_VIEWRECORDS+1,y
|
||||
dec
|
||||
sta WG_CURSORY
|
||||
|
||||
ldy #0
|
||||
paintWindowTitleLoop:
|
||||
@ -592,6 +594,21 @@ WGViewFocus:
|
||||
rts
|
||||
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
; WGViewFocusQuiet
|
||||
; Shifts focus to the selected view without redrawing anything
|
||||
; Side effects: Changes selected view, repaints some views
|
||||
;
|
||||
WGViewFocusQuiet:
|
||||
pha
|
||||
|
||||
lda WG_ACTIVEVIEW ; Stash current selection
|
||||
sta WG_FOCUSVIEW ; Focus on our current selection
|
||||
|
||||
pla
|
||||
rts
|
||||
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
; WGViewUnfocus
|
||||
; Unfocuses all views
|
||||
@ -878,21 +895,21 @@ WGPendingViewAction_done: ; Located here for branch range
|
||||
WGPendingViewAction_up:
|
||||
lda #1 ; Up arrow
|
||||
jsr WGScrollYBy
|
||||
jsr WGViewFocus
|
||||
jsr WGViewFocusQuiet
|
||||
jsr WGViewFocusAction ; Trigger application to redraw contents
|
||||
bra WGPendingViewAction_done
|
||||
|
||||
WGPendingViewAction_down:
|
||||
lda #-1 ; Down arrow
|
||||
jsr WGScrollYBy
|
||||
jsr WGViewFocus
|
||||
jsr WGViewFocusQuiet
|
||||
jsr WGViewFocusAction ; Trigger application to redraw contents
|
||||
bra WGPendingViewAction_done
|
||||
|
||||
WGPendingViewAction_left:
|
||||
lda #1 ; Left arrow
|
||||
jsr WGScrollXBy
|
||||
jsr WGViewFocus
|
||||
jsr WGViewFocusQuiet
|
||||
jsr WGViewFocusAction ; Trigger application to redraw contents
|
||||
bra WGPendingViewAction_done
|
||||
|
||||
|
BIN
weegui.dsk
BIN
weegui.dsk
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user