A2osX/LIB/LIBGUI.S.WND.txt

88 lines
1.8 KiB
Plaintext
Raw Normal View History

NEW
2019-07-30 08:57:25 +00:00
AUTO 3,1
*--------------------------------------
2019-01-08 16:29:26 +00:00
WND.Init >PUSHBI 0
>LDYA L.DEVNAME.GFX
2019-05-05 17:15:37 +00:00
>SYSCALL2 open
2018-05-16 06:02:57 +00:00
bcs .9
2019-01-10 16:26:58 +00:00
sta SCR+S.SCREEN.hDEV
2019-01-09 16:42:20 +00:00
>LDYA L.DCB.GFX
>STYA IOCTL+S.IOCTL.BUFPTR
lda #S.IOCTL.STATCODE.GETDCB
sta IOCTL+S.IOCTL.STATCODE
>PUSHW L.IOCTL
>PUSHBI IOCTL.STATUS
2019-01-10 16:26:58 +00:00
lda SCR+S.SCREEN.hDEV
2019-05-05 17:15:37 +00:00
>SYSCALL2 IOCTL
2019-10-03 06:25:27 +00:00
.9 rts
2019-01-10 16:26:58 +00:00
*--------------------------------------
WND.Setup >LDYA DCB.GFX+S.DCB.GFX.W
>STYA SCR+S.OBJ.W
>STYA WND.Desktop+S.OBJ.W
>STYA WND.SysBar+S.OBJ.W
2019-01-08 16:29:26 +00:00
lda SYSFON.H
2018-05-16 06:02:57 +00:00
clc
2019-01-14 07:11:50 +00:00
adc #6
2019-01-10 16:26:58 +00:00
sta WND.SysBar+S.OBJ.H
2019-01-09 06:58:19 +00:00
lda DCB.GFX+S.DCB.GFX.H
2019-01-10 16:26:58 +00:00
sta SCR+S.OBJ.H
2018-05-16 06:02:57 +00:00
sec
2019-01-10 16:26:58 +00:00
sbc WND.SysBar+S.OBJ.H
sta WND.Desktop+S.OBJ.H
sta WND.SysBar+S.OBJ.X1
lda DCB.GFX+S.DCB.GFX.H+1
sta WND.SysBar+S.OBJ.H+1
2018-05-16 06:02:57 +00:00
sbc #0
2019-01-10 16:26:58 +00:00
sta WND.Desktop+S.OBJ.H+1
sta WND.SysBar+S.OBJ.X1+1
>LDYA L.SCR
jsr OBJ.SetX2Y2
>LDYA L.WND.Desktop
>STYA SCR.Childs
jsr OBJ.SetX2Y2
>LDYA L.WND.SysBar
jsr OBJ.SetX2Y2
>STYA SCR.Childs+2
>LDYA L.WND.Desktop
2018-05-16 06:02:57 +00:00
lda #CUR.T.ARROW
2019-01-10 16:26:58 +00:00
sta WND.Desktop+S.WND.hCUR
sta WND.SysBar+S.WND.hCUR
rts
2018-05-16 06:02:57 +00:00
*--------------------------------------
2019-01-10 16:26:58 +00:00
WND.Quit lda SCR+S.SCREEN.hDEV
2019-01-08 16:29:26 +00:00
beq .8
pha
>PUSHBI IOCTL.CLOSE
2019-06-07 15:02:51 +00:00
>PUSHWZ
2019-01-08 16:29:26 +00:00
pla
2019-05-05 17:15:37 +00:00
>SYSCALL2 IOCTL
2019-01-08 16:29:26 +00:00
2019-10-03 06:25:27 +00:00
.8 clc
rts
*--------------------------------------
2018-05-16 06:02:57 +00:00
WND.New >STYA ZPPtr1
2019-01-09 06:58:19 +00:00
>LDYAI S.WND
2019-05-05 17:15:37 +00:00
>SYSCALL2 getmem
2018-05-16 06:02:57 +00:00
bcs .9
>STYA ZPWNDPtr
ldy #S.WND-1
.1 lda (ZPPtr1),y
sta (ZPWNDPtr),y
dey
bpl .1
2019-10-03 06:25:27 +00:00
.9 rts
2018-05-16 06:02:57 +00:00
*--------------------------------------
WND.Paint >STYA ZPPtr1
2018-05-16 06:02:57 +00:00
clc
rts
*--------------------------------------
2019-01-10 16:26:58 +00:00
WND.Close clc
rts
*--------------------------------------
MAN
2018-11-17 17:17:13 +00:00
SAVE USR/SRC/LIB/LIBGUI.S.WND
LOAD USR/SRC/LIB/LIBGUI.S
ASM