2015-03-23 07:28:03 +00:00
|
|
|
|
NEW
|
2018-11-17 17:17:13 +00:00
|
|
|
|
PREFIX
|
2017-12-22 21:24:30 +00:00
|
|
|
|
AUTO 4,1
|
2015-03-23 07:28:03 +00:00
|
|
|
|
.LIST OFF
|
|
|
|
|
.OP 65C02
|
|
|
|
|
.OR $2000
|
2018-07-23 15:28:42 +00:00
|
|
|
|
.TF SBIN/GUI/GUI
|
2015-03-23 07:28:03 +00:00
|
|
|
|
*--------------------------------------
|
2018-07-23 15:28:42 +00:00
|
|
|
|
.INB INC/IO.I
|
|
|
|
|
.INB INC/MACROS.I
|
|
|
|
|
.INB INC/A2OSX.I
|
|
|
|
|
.INB INC/GUI.I
|
|
|
|
|
.INB INC/LIBGUI.I
|
2015-03-23 07:28:03 +00:00
|
|
|
|
*--------------------------------------
|
2017-06-02 15:14:42 +00:00
|
|
|
|
ZPPtr1 .EQ ZPBIN
|
|
|
|
|
*--------------------------------------
|
2015-06-03 18:30:57 +00:00
|
|
|
|
* File Header (16 Bytes)
|
2015-03-23 07:28:03 +00:00
|
|
|
|
*--------------------------------------
|
|
|
|
|
CS.START cld
|
|
|
|
|
jmp (.1,x)
|
2015-06-03 18:30:57 +00:00
|
|
|
|
.DA #$61 6502,Level 1 (65c02)
|
|
|
|
|
.DA #1 BIN Layout Version 1
|
|
|
|
|
.DA 0
|
2017-11-15 16:29:23 +00:00
|
|
|
|
.DA CS.END-CS.START CS
|
|
|
|
|
.DA DS.END-DS.START DS
|
|
|
|
|
.DA #16 SS
|
|
|
|
|
.DA #2 ZP
|
2015-06-03 18:30:57 +00:00
|
|
|
|
.DA 0
|
|
|
|
|
*--------------------------------------
|
|
|
|
|
* Relocation Table
|
|
|
|
|
*--------------------------------------
|
2015-03-23 07:28:03 +00:00
|
|
|
|
.1 .DA CS.INIT
|
|
|
|
|
.DA CS.RUN
|
|
|
|
|
.DA CS.DOEVENT
|
|
|
|
|
.DA CS.QUIT
|
2017-11-30 16:33:33 +00:00
|
|
|
|
L.LIBGUI .DA LIBGUI
|
2017-06-02 15:14:42 +00:00
|
|
|
|
L.MouseData .DA MouseData
|
2015-03-23 07:28:03 +00:00
|
|
|
|
.DA 0
|
|
|
|
|
*--------------------------------------
|
2018-05-04 14:55:29 +00:00
|
|
|
|
CS.INIT >LDYA L.LIBGUI
|
2018-07-19 15:33:55 +00:00
|
|
|
|
>SYSCALL LoadLib
|
2018-05-04 14:55:29 +00:00
|
|
|
|
bcs .98
|
2017-11-15 16:29:23 +00:00
|
|
|
|
sta hLIBGUI
|
2016-06-15 06:21:42 +00:00
|
|
|
|
|
2017-11-30 16:33:33 +00:00
|
|
|
|
lda (pPs)
|
|
|
|
|
ora #S.PS.F.EVENT Now accept events
|
|
|
|
|
sta (pPs)
|
|
|
|
|
|
2015-03-23 07:28:03 +00:00
|
|
|
|
clc
|
2018-05-09 06:02:05 +00:00
|
|
|
|
CS.INIT.RTS rts
|
2015-03-23 07:28:03 +00:00
|
|
|
|
*--------------------------------------
|
2017-06-09 15:36:05 +00:00
|
|
|
|
CS.RUN lda A2osX.ASCREEN GUI screen active ?
|
2016-07-22 14:11:13 +00:00
|
|
|
|
cmp #3
|
2017-06-02 15:14:42 +00:00
|
|
|
|
bne .8 no, exit....
|
2016-07-22 14:11:13 +00:00
|
|
|
|
|
2017-11-30 16:33:33 +00:00
|
|
|
|
>PUSHW L.MouseData
|
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.ReadMouse
|
|
|
|
|
bcs .4
|
2015-06-03 18:30:57 +00:00
|
|
|
|
|
2017-11-30 16:33:33 +00:00
|
|
|
|
lda MouseData+S.MOUSE.S
|
2017-11-28 16:32:38 +00:00
|
|
|
|
bit #S.MOUSE.S.MOVE
|
2017-06-02 15:14:42 +00:00
|
|
|
|
beq .1
|
2017-12-01 15:53:29 +00:00
|
|
|
|
|
2017-11-30 16:33:33 +00:00
|
|
|
|
>PUSHW L.MouseData
|
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.SetCursorPos
|
2015-06-03 18:30:57 +00:00
|
|
|
|
|
2017-11-30 16:33:33 +00:00
|
|
|
|
lda MouseData+S.MOUSE.S
|
2017-11-28 16:32:38 +00:00
|
|
|
|
|
2017-12-04 16:42:08 +00:00
|
|
|
|
.1 bit #S.MOUSE.S.CLK
|
2017-06-02 15:14:42 +00:00
|
|
|
|
beq .4
|
2016-11-27 21:59:46 +00:00
|
|
|
|
|
2017-12-06 07:28:30 +00:00
|
|
|
|
>LDA.G CUR.T
|
|
|
|
|
inc
|
|
|
|
|
inc
|
|
|
|
|
cmp #CUR.T.WAIT+2
|
|
|
|
|
bne .2
|
2017-12-06 16:26:36 +00:00
|
|
|
|
|
2017-12-06 07:28:30 +00:00
|
|
|
|
lda #CUR.T.ARROW
|
|
|
|
|
|
|
|
|
|
.2 >STA.G CUR.T
|
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.SetCursor.A
|
2017-12-05 07:09:16 +00:00
|
|
|
|
|
2017-06-02 15:14:42 +00:00
|
|
|
|
|
2017-12-04 16:42:08 +00:00
|
|
|
|
jsr Destop.Paint
|
|
|
|
|
|
2017-06-02 15:14:42 +00:00
|
|
|
|
.4
|
|
|
|
|
|
|
|
|
|
.8 clc
|
2015-06-03 18:30:57 +00:00
|
|
|
|
rts
|
2015-03-23 07:28:03 +00:00
|
|
|
|
*--------------------------------------
|
2017-12-04 07:18:24 +00:00
|
|
|
|
CS.DOEVENT lda (pEvent)
|
|
|
|
|
bpl .9
|
2017-12-04 16:42:08 +00:00
|
|
|
|
asl
|
|
|
|
|
bpl .9
|
2017-12-04 07:18:24 +00:00
|
|
|
|
|
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.UpdateCursor
|
|
|
|
|
|
|
|
|
|
.9 sec
|
2017-06-02 15:14:42 +00:00
|
|
|
|
rts
|
|
|
|
|
*--------------------------------------
|
2015-03-23 07:28:03 +00:00
|
|
|
|
CS.QUIT clc
|
|
|
|
|
rts
|
|
|
|
|
*--------------------------------------
|
2017-12-04 16:42:08 +00:00
|
|
|
|
Destop.Paint >LIBCALL hLIBGUI,LIBGUI.HideCursor
|
|
|
|
|
|
2017-12-05 16:33:06 +00:00
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.GetScreenGC
|
|
|
|
|
>PUSHYA
|
2017-12-30 22:14:05 +00:00
|
|
|
|
>PUSHW L.CB.Paint
|
2017-11-15 16:29:23 +00:00
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.Draw
|
2017-11-17 16:16:05 +00:00
|
|
|
|
|
2017-12-05 16:33:06 +00:00
|
|
|
|
* >LIBCALL hLIBGUI,LIBGUI.GetScreenGC
|
|
|
|
|
* >PUSHYA
|
|
|
|
|
|
|
|
|
|
>PUSHW L.GC.Clip
|
|
|
|
|
|
2017-12-22 21:24:30 +00:00
|
|
|
|
>PUSHW L.CB.Marylin
|
2017-11-29 06:59:27 +00:00
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.Draw
|
2017-12-01 15:53:29 +00:00
|
|
|
|
|
2017-12-04 16:42:08 +00:00
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.ShowCursor
|
2017-11-20 06:59:59 +00:00
|
|
|
|
rts
|
2016-07-22 14:11:13 +00:00
|
|
|
|
*--------------------------------------
|
2015-03-23 07:28:03 +00:00
|
|
|
|
CS.END
|
2018-04-11 15:35:51 +00:00
|
|
|
|
LIBGUI .AZ "libgui.o"
|
2017-11-15 16:29:23 +00:00
|
|
|
|
hLIBGUI .BS 1
|
2017-12-14 16:25:03 +00:00
|
|
|
|
*--------------------------------------
|
2017-12-04 16:42:08 +00:00
|
|
|
|
MouseData .BS S.MOUSE
|
2017-11-15 16:29:23 +00:00
|
|
|
|
*--------------------------------------
|
|
|
|
|
.DUMMY
|
|
|
|
|
.OR 0
|
|
|
|
|
DS.START
|
2017-12-05 07:09:16 +00:00
|
|
|
|
CUR.T .BS 1
|
2017-11-15 16:29:23 +00:00
|
|
|
|
DS.END
|
|
|
|
|
.ED
|
2015-03-23 07:28:03 +00:00
|
|
|
|
MAN
|
2018-11-17 17:17:13 +00:00
|
|
|
|
SAVE USR/SRC/SBIN/GUI.S
|
2015-03-23 07:28:03 +00:00
|
|
|
|
ASM
|