# HG changeset patch # User boisy # Date 1140218947 0 # Node ID 45459aaf5d7d035072eabd06f753d4dcd5bd3777 # Parent d5e3d4f5c45aa354cb66231c43dcf6ee5a68dfe4 Minor code optimizations diff -r d5e3d4f5c45a -r 45459aaf5d7d level2/modules/vtio.asm --- a/level2/modules/vtio.asm Mon Feb 13 12:31:42 2006 +0000 +++ b/level2/modules/vtio.asm Fri Feb 17 23:29:07 2006 +0000 @@ -136,7 +136,7 @@ ldd CC3Irq,pcr set up AltIRQ vector in DP +* leax >ISR,pcr set up AltIRQ vector in DP * stx SHFTCLR,pcr point to SHIFT-CLEAR subroutine pshs x save it on stack @@ -199,7 +199,7 @@ ldx WGlobal+G.OrgAlt save in window globals for later - leax >CC3Irq,pcr set up AltIRQ vector in DP + leax >ISR,pcr set up AltIRQ vector in DP stx (WGlobal+G.Mouse+Pt.CBSA) if paused, check mouse button 1 +Read tst V.PAUS,u device paused? + bpl read1 no, do normal read +* Here, device is paused; check for mouse button down +* If it is down, we simply return without error. + tst >(WGlobal+G.Mouse+Pt.CBSA) test current button state A beq read1 button isn't pressed, do normal read clra clear carry (no error) rts return +* Check to see if there is a signal-on-data-ready set for this path. +* If so, we return a Not Ready error. read1 lda ReadBuf,u point to keyboard buffer ldb G.KeyMem,u and ptr to its statics jsr K$FnKey,x call into it ldu WGlobal+G.JoyEnt get ptr to joydrv leau >G.JoyMem,u and ptr to its statics jsr J$MsBtn,x get mouse button info +* Here, B now holds the value from the MsBtn routine in JoyDrv. ldu CC3Irq,pcr get CC3Irq vector + leax >ISR,pcr get IRQ vector stx