2018-05-16 06:02:57 +00:00
|
|
|
|
NEW
|
|
|
|
|
PREFIX /A2OSX.BUILD
|
|
|
|
|
AUTO 4,1
|
|
|
|
|
*--------------------------------------
|
|
|
|
|
MOU.Init
|
|
|
|
|
.1 >LDYA L.DEVNAME.MOUSE
|
|
|
|
|
>SYSCALL GetDevByName.YA
|
|
|
|
|
bcc .2
|
|
|
|
|
|
|
|
|
|
inc DEVNAME.MOUSE+3
|
|
|
|
|
lda DEVNAME.MOUSE+3
|
|
|
|
|
cmp #'8'
|
|
|
|
|
bne .1
|
|
|
|
|
|
|
|
|
|
clc
|
|
|
|
|
.9 rts
|
|
|
|
|
|
|
|
|
|
.2 stx hDevMouse
|
|
|
|
|
txa
|
|
|
|
|
>PUSHA
|
|
|
|
|
>PUSHBI DEVMGR.OPEN
|
|
|
|
|
>PUSHWI 0
|
|
|
|
|
>SYSCALL IOCTL
|
|
|
|
|
|
|
|
|
|
lda GC.Screen+S.GC.X2+1
|
|
|
|
|
sta MouseClamp+3
|
|
|
|
|
lsr
|
|
|
|
|
sta CUR.Pos+S.POINT.X+1
|
|
|
|
|
|
|
|
|
|
lda GC.Screen+S.GC.X2
|
|
|
|
|
sta MouseClamp+2
|
|
|
|
|
ror
|
|
|
|
|
sta CUR.Pos+S.POINT.X
|
|
|
|
|
|
|
|
|
|
lda GC.Screen+S.GC.Y2+1
|
|
|
|
|
sta MouseClamp+7
|
|
|
|
|
lsr
|
|
|
|
|
sta CUR.Pos+S.POINT.Y+1
|
|
|
|
|
|
|
|
|
|
lda GC.Screen+S.GC.Y2
|
|
|
|
|
sta MouseClamp+6
|
|
|
|
|
ror
|
|
|
|
|
sta CUR.Pos+S.POINT.Y
|
|
|
|
|
|
|
|
|
|
>PUSHB.G hDevMouse
|
|
|
|
|
>PUSHBI DEVMGR.CONTROL
|
|
|
|
|
>PUSHWI L.MouseClamp
|
|
|
|
|
>SYSCALL IOCTL
|
|
|
|
|
|
|
|
|
|
>LDYA L.CUR.SaveBuf
|
|
|
|
|
>STYA CUR.CB+S.CB.DstPtr
|
|
|
|
|
|
|
|
|
|
lda #CUR.T.ARROW
|
|
|
|
|
jsr SetCursor.A
|
|
|
|
|
bra .8
|
|
|
|
|
|
|
|
|
|
sec
|
|
|
|
|
.9 rts
|
|
|
|
|
*--------------------------------------
|
|
|
|
|
MOU.Quit lda hDevMouse
|
|
|
|
|
beq .8
|
|
|
|
|
|
|
|
|
|
>PUSHA
|
|
|
|
|
>PUSHBI DEVMGR.CLOSE
|
|
|
|
|
>PUSHWI 0
|
|
|
|
|
>SYSCALL IOCTL
|
|
|
|
|
|
|
|
|
|
.8 clc
|
|
|
|
|
rts
|
|
|
|
|
*--------------------------------------
|
|
|
|
|
MOU.Read >STYA ZPPtr1
|
|
|
|
|
|
|
|
|
|
lda hDevMouse
|
|
|
|
|
beq .9
|
|
|
|
|
|
|
|
|
|
>PUSHA
|
|
|
|
|
>PUSHBI DEVMGR.READBLOCK
|
2018-05-22 06:01:05 +00:00
|
|
|
|
>PUSHW ZPPtr1
|
2018-05-16 06:02:57 +00:00
|
|
|
|
>SYSCALL IOCTL
|
|
|
|
|
bcs .9
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
.8 sec
|
|
|
|
|
.9 rts
|
|
|
|
|
*--------------------------------------
|
|
|
|
|
MAN
|
|
|
|
|
SAVE /A2OSX.SRC/LIB/LIBGUI.S.MOU
|
|
|
|
|
LOAD /A2OSX.SRC/LIB/LIBGUI.S
|
|
|
|
|
ASM
|