2015-03-23 08:28:03 +01:00
|
|
|
|
NEW
|
2018-11-17 18:17:13 +01:00
|
|
|
|
PREFIX
|
2017-12-22 22:24:30 +01:00
|
|
|
|
AUTO 4,1
|
2015-03-23 08:28:03 +01:00
|
|
|
|
.LIST OFF
|
|
|
|
|
.OP 65C02
|
|
|
|
|
.OR $2000
|
2018-07-23 17:28:42 +02:00
|
|
|
|
.TF SBIN/GUI/GUI
|
2015-03-23 08:28:03 +01:00
|
|
|
|
*--------------------------------------
|
2018-07-23 17:28:42 +02:00
|
|
|
|
.INB INC/IO.I
|
|
|
|
|
.INB INC/MACROS.I
|
|
|
|
|
.INB INC/A2OSX.I
|
|
|
|
|
.INB INC/LIBGUI.I
|
2015-03-23 08:28:03 +01:00
|
|
|
|
*--------------------------------------
|
2019-01-08 16:29:26 +00:00
|
|
|
|
* Zero Page Segment, up to 32 bytes
|
|
|
|
|
*--------------------------------------
|
|
|
|
|
.DUMMY
|
|
|
|
|
.OR ZPBIN
|
|
|
|
|
ZS.START
|
|
|
|
|
* MyPtr .BS 2
|
|
|
|
|
ZS.END
|
|
|
|
|
.ED
|
2017-06-02 17:14:42 +02:00
|
|
|
|
*--------------------------------------
|
2015-06-03 20:30:57 +02:00
|
|
|
|
* File Header (16 Bytes)
|
2015-03-23 08:28:03 +01:00
|
|
|
|
*--------------------------------------
|
|
|
|
|
CS.START cld
|
|
|
|
|
jmp (.1,x)
|
2015-06-03 20:30:57 +02:00
|
|
|
|
.DA #$61 6502,Level 1 (65c02)
|
|
|
|
|
.DA #1 BIN Layout Version 1
|
2019-01-08 16:29:26 +00:00
|
|
|
|
.DA #S.PS.F.EVENT
|
|
|
|
|
.DA #0
|
|
|
|
|
.DA CS.END-CS.START Code Size (without Constants)
|
|
|
|
|
.DA DS.END-DS.START Data SegmentSize
|
|
|
|
|
.DA #64 Stack Size
|
|
|
|
|
.DA #ZS.END-ZS.START Zero Page Size
|
2015-06-03 20:30:57 +02:00
|
|
|
|
.DA 0
|
|
|
|
|
*--------------------------------------
|
|
|
|
|
* Relocation Table
|
|
|
|
|
*--------------------------------------
|
2015-03-23 08:28:03 +01:00
|
|
|
|
.1 .DA CS.INIT
|
|
|
|
|
.DA CS.RUN
|
|
|
|
|
.DA CS.DOEVENT
|
|
|
|
|
.DA CS.QUIT
|
2017-11-30 17:33:33 +01:00
|
|
|
|
L.LIBGUI .DA LIBGUI
|
2017-06-02 17:14:42 +02:00
|
|
|
|
L.MouseData .DA MouseData
|
2015-03-23 08:28:03 +01:00
|
|
|
|
.DA 0
|
|
|
|
|
*--------------------------------------
|
2018-05-04 16:55:29 +02:00
|
|
|
|
CS.INIT >LDYA L.LIBGUI
|
2018-07-19 17:33:55 +02:00
|
|
|
|
>SYSCALL LoadLib
|
2019-01-09 16:42:20 +00:00
|
|
|
|
bcs .9
|
2017-11-15 17:29:23 +01:00
|
|
|
|
sta hLIBGUI
|
2016-06-15 08:21:42 +02:00
|
|
|
|
|
2019-01-09 16:42:20 +00:00
|
|
|
|
* clc
|
|
|
|
|
.9 rts
|
2015-03-23 08:28:03 +01:00
|
|
|
|
*--------------------------------------
|
2019-01-09 16:42:20 +00:00
|
|
|
|
CS.RUN >PUSHW L.MouseData
|
2017-11-30 17:33:33 +01:00
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.ReadMouse
|
|
|
|
|
bcs .4
|
|
|
|
|
lda MouseData+S.MOUSE.S
|
2017-11-28 17:32:38 +01:00
|
|
|
|
bit #S.MOUSE.S.MOVE
|
2017-06-02 17:14:42 +02:00
|
|
|
|
beq .1
|
2017-12-01 16:53:29 +01:00
|
|
|
|
|
2017-11-30 17:33:33 +01:00
|
|
|
|
>PUSHW L.MouseData
|
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.SetCursorPos
|
|
|
|
|
lda MouseData+S.MOUSE.S
|
2017-12-04 17:42:08 +01:00
|
|
|
|
.1 bit #S.MOUSE.S.CLK
|
2017-06-02 17:14:42 +02:00
|
|
|
|
beq .4
|
2017-12-06 08:28:30 +01:00
|
|
|
|
>LDA.G CUR.T
|
|
|
|
|
inc
|
|
|
|
|
inc
|
|
|
|
|
cmp #CUR.T.WAIT+2
|
|
|
|
|
bne .2
|
2017-12-06 17:26:36 +01:00
|
|
|
|
|
2017-12-06 08:28:30 +01:00
|
|
|
|
lda #CUR.T.ARROW
|
|
|
|
|
.2 >STA.G CUR.T
|
2019-01-08 16:29:26 +00:00
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.SetCursor
|
2017-12-05 08:09:16 +01:00
|
|
|
|
|
2017-06-02 17:14:42 +02:00
|
|
|
|
|
2017-12-04 17:42:08 +01:00
|
|
|
|
jsr Destop.Paint
|
2017-06-02 17:14:42 +02:00
|
|
|
|
.4
|
|
|
|
|
|
|
|
|
|
.8 clc
|
2015-06-03 20:30:57 +02:00
|
|
|
|
rts
|
2015-03-23 08:28:03 +01:00
|
|
|
|
*--------------------------------------
|
2017-12-04 08:18:24 +01:00
|
|
|
|
CS.DOEVENT lda (pEvent)
|
|
|
|
|
bpl .9
|
2017-12-04 17:42:08 +01:00
|
|
|
|
asl
|
|
|
|
|
bpl .9
|
2017-12-04 08:18:24 +01:00
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.UpdateCursor
|
|
|
|
|
.9 sec
|
2017-06-02 17:14:42 +02:00
|
|
|
|
rts
|
|
|
|
|
*--------------------------------------
|
2015-03-23 08:28:03 +01:00
|
|
|
|
CS.QUIT clc
|
|
|
|
|
rts
|
|
|
|
|
*--------------------------------------
|
2017-12-04 17:42:08 +01:00
|
|
|
|
Destop.Paint >LIBCALL hLIBGUI,LIBGUI.HideCursor
|
|
|
|
|
|
2019-01-04 13:17:31 +00:00
|
|
|
|
* >LIBCALL hLIBGUI,LIBGUI.GetScreenGC
|
|
|
|
|
* >PUSHYA
|
|
|
|
|
* >PUSHW L.CB.Paint
|
|
|
|
|
* >LIBCALL hLIBGUI,LIBGUI.Draw
|
2017-11-17 17:16:05 +01:00
|
|
|
|
|
2017-12-05 17:33:06 +01:00
|
|
|
|
* >LIBCALL hLIBGUI,LIBGUI.GetScreenGC
|
|
|
|
|
* >PUSHYA
|
|
|
|
|
|
2019-01-04 13:17:31 +00:00
|
|
|
|
* >PUSHW L.GC.Clip
|
|
|
|
|
* >PUSHW L.CB.Marylin
|
|
|
|
|
* >LIBCALL hLIBGUI,LIBGUI.Draw
|
2017-12-01 16:53:29 +01:00
|
|
|
|
|
2017-12-04 17:42:08 +01:00
|
|
|
|
>LIBCALL hLIBGUI,LIBGUI.ShowCursor
|
2019-10-03 08:25:27 +02:00
|
|
|
|
rts
|
2016-07-22 16:11:13 +02:00
|
|
|
|
*--------------------------------------
|
2015-03-23 08:28:03 +01:00
|
|
|
|
CS.END
|
2019-11-11 15:21:06 +01:00
|
|
|
|
LIBGUI .AZ "LIBGUI"
|
2017-11-15 17:29:23 +01:00
|
|
|
|
hLIBGUI .BS 1
|
2017-12-14 17:25:03 +01:00
|
|
|
|
*--------------------------------------
|
2017-12-04 17:42:08 +01:00
|
|
|
|
MouseData .BS S.MOUSE
|
2017-11-15 17:29:23 +01:00
|
|
|
|
*--------------------------------------
|
|
|
|
|
.DUMMY
|
|
|
|
|
.OR 0
|
|
|
|
|
DS.START
|
2017-12-05 08:09:16 +01:00
|
|
|
|
CUR.T .BS 1
|
2017-11-15 17:29:23 +01:00
|
|
|
|
DS.END
|
|
|
|
|
.ED
|
2015-03-23 08:28:03 +01:00
|
|
|
|
MAN
|
2018-11-17 18:17:13 +01:00
|
|
|
|
SAVE USR/SRC/SBIN/GUI.S
|
2015-03-23 08:28:03 +01:00
|
|
|
|
ASM
|