A2osX/LIB/LIBGUI.S.SYSBAR.txt

188 lines
3.1 KiB
Plaintext
Raw Normal View History

2020-10-06 15:23:40 +00:00
NEW
AUTO 3,1
*--------------------------------------
2020-10-23 15:23:19 +00:00
SYSBUT.Enter sec
2020-10-20 06:01:04 +00:00
ror WND.SYSBAR.bSysBut
2020-10-06 15:23:40 +00:00
jsr GetCBBuf
2020-10-23 15:23:19 +00:00
bcs .99
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
jsr SYSBAR.ShowSysBut
2020-10-08 15:33:38 +00:00
>LDYA L.WND.SysBar
2020-10-26 16:32:51 +00:00
jsr DrawCBBufToYA
2020-10-09 15:28:01 +00:00
>PUSHW WND.SysBar+S.OBJ.X1
>PUSHW WND.SysBar+S.OBJ.Y1
2020-10-20 06:01:04 +00:00
>PUSHW L.RECT.SysBut Parent RECT
2020-10-09 15:28:01 +00:00
>PUSHW L.MENU.Sys
jsr MENU.New
2020-10-23 15:23:19 +00:00
.99 bcs .9
2020-10-09 15:28:01 +00:00
2020-10-20 06:01:04 +00:00
sta hSysMenu
>PUSHA hSysMenu
2020-10-23 15:23:19 +00:00
>PUSHBI 4
>PUSHBI S.MITEM.pMENU
>PUSHW L.MENU.Sys.Programs
jsr MENU.SetMItemProp
>PUSHB hSysMenu
2020-10-20 06:01:04 +00:00
>PUSHBI 6
>PUSHBI S.MITEM.pMENU
>PUSHW L.MENU.Sys.Settings
jsr MENU.SetMItemProp
lda hSysMenu
2020-10-09 15:28:01 +00:00
jsr MENU.Show
2020-10-06 15:23:40 +00:00
2020-10-08 15:33:38 +00:00
.8 clc
2020-10-06 15:23:40 +00:00
.9 rts
*--------------------------------------
2020-10-20 06:01:04 +00:00
SYSBUT.Leave bit WND.SYSBAR.bSysBut
2020-10-06 15:23:40 +00:00
bpl .8
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
stz WND.SYSBAR.bSysBut
2020-10-06 15:23:40 +00:00
jsr GetCBBuf
bcs .9
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
jsr SYSBAR.ShowSysBut
2020-10-06 15:23:40 +00:00
>LDYA L.WND.SysBar
2020-10-26 16:32:51 +00:00
jmp DrawCBBufToYA
2020-10-06 15:23:40 +00:00
.8 clc
2020-10-26 16:32:51 +00:00
.9 rts
2020-10-06 15:23:40 +00:00
*--------------------------------------
SYSBAR.Show jsr GetCBBuf
bcs .9
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
jsr SYSBAR.ShowSysBut
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
jsr SYSBAR.ShowSysWNDs
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
jsr SYSBAR.ShowSysClk
2020-10-06 15:23:40 +00:00
>LDYA L.WND.SysBar
2020-10-26 16:32:51 +00:00
jmp DrawCBBufToYA
2020-10-06 15:23:40 +00:00
.9 rts
*--------------------------------------
2020-10-20 06:01:04 +00:00
SYSBAR.ShowSysBut
2020-10-06 15:23:40 +00:00
lda #S.CB.CMD.FILLRECT
2020-10-20 06:01:04 +00:00
jsr CB.InitCacheA
2020-10-26 16:32:51 +00:00
2020-10-06 15:23:40 +00:00
lda #S.CB.OP.SET
2020-10-20 06:01:04 +00:00
sta CB.Cache+S.CB.OP
2020-10-26 16:32:51 +00:00
2020-10-06 15:23:40 +00:00
lda #S.CB.M.MONO
2020-10-20 06:01:04 +00:00
sta CB.Cache+S.CB.M
2020-10-26 16:32:51 +00:00
2020-10-06 15:23:40 +00:00
lda PREFS.SYSBARCOLOR
2020-10-20 06:01:04 +00:00
bit WND.SysBar.bSysBut
2020-10-06 15:23:40 +00:00
bpl .1
eor #$ff
2020-10-20 06:01:04 +00:00
.1 sta CB.Cache+S.CB.COLOR
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
ldx #S.RECT-1
2020-10-26 16:32:51 +00:00
.2 lda RECT.SysBut,x
2020-10-20 06:01:04 +00:00
sta CB.Cache+S.CB.X1,x
dex
bpl .2
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
jsr PutCBCache2CBBuf
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
lda RECT.SysBut+S.RECT.X1
2020-10-08 15:33:38 +00:00
clc
adc #4
sta DX
2020-10-20 06:01:04 +00:00
lda RECT.SysBut+S.RECT.X1+1
2020-10-08 15:33:38 +00:00
adc #0
sta DX+1
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
lda RECT.SysBut+S.RECT.Y1
2020-10-08 15:33:38 +00:00
clc
adc #1
sta DY
2020-10-20 06:01:04 +00:00
lda RECT.SysBut+S.RECT.Y1+1
2020-10-08 15:33:38 +00:00
adc #0
sta DY+1
2020-10-26 06:38:50 +00:00
ldx #BM.ID.APPLE
jsr DRAW.xBMAtDXDY
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
lda RECT.SysBut+S.RECT.X1
2020-10-08 15:33:38 +00:00
clc
adc #21
sta DX
2020-10-20 06:01:04 +00:00
lda RECT.SysBut+S.RECT.X1+1
2020-10-08 15:33:38 +00:00
adc #0
sta DX+1
2020-10-26 16:32:51 +00:00
2020-10-08 15:33:38 +00:00
inc DY
2020-10-20 06:01:04 +00:00
bne .3
2020-10-26 16:32:51 +00:00
2020-10-08 15:33:38 +00:00
inc DY+1
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
.3 lda WND.SysBar.bSysBut
2020-10-08 15:33:38 +00:00
asl
2020-10-26 16:32:51 +00:00
2020-10-08 15:33:38 +00:00
>LDYA L.WND.SysBar.2osX
ldx hSYSFON
2020-10-20 06:01:04 +00:00
jmp DRAW.YATextAtDXDY
2020-10-06 15:23:40 +00:00
*--------------------------------------
2020-10-20 06:01:04 +00:00
SYSBAR.ShowSysWNDs
lda #S.CB.CMD.FILLRECT
jsr CB.InitCacheA
2020-10-26 16:32:51 +00:00
2020-10-06 15:23:40 +00:00
lda #S.CB.OP.SET
2020-10-20 06:01:04 +00:00
sta CB.Cache+S.CB.OP
2020-10-26 16:32:51 +00:00
2020-10-06 15:23:40 +00:00
lda #S.CB.M.MONO
2020-10-20 06:01:04 +00:00
sta CB.Cache+S.CB.M
2020-10-26 16:32:51 +00:00
2020-10-06 15:23:40 +00:00
lda PREFS.SYSBARCOLOR
2020-10-20 06:01:04 +00:00
sta CB.Cache+S.CB.COLOR
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
ldx #S.RECT-1
2020-10-08 15:33:38 +00:00
2020-10-26 16:32:51 +00:00
.1 lda RECT.SysWNDs,x
2020-10-20 06:01:04 +00:00
sta CB.Cache+S.CB.X1,x
2020-10-08 15:33:38 +00:00
dex
2020-10-20 06:01:04 +00:00
bpl .1
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
jmp PutCBCache2CBBuf
2020-10-08 15:33:38 +00:00
*--------------------------------------
2020-10-20 06:01:04 +00:00
SYSBAR.ShowSysClk
lda #S.CB.CMD.FILLRECT
jsr CB.InitCacheA
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
lda #S.CB.OP.SET
sta CB.Cache+S.CB.OP
2020-10-26 16:32:51 +00:00
2020-10-08 15:33:38 +00:00
lda #S.CB.M.MONO
2020-10-20 06:01:04 +00:00
sta CB.Cache+S.CB.M
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
lda PREFS.SYSBARCOLOR
sta CB.Cache+S.CB.COLOR
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
ldx #S.RECT-1
2020-10-26 16:32:51 +00:00
.1 lda RECT.SysClk,x
2020-10-20 06:01:04 +00:00
sta CB.Cache+S.CB.X1,x
dex
bpl .1
2020-10-26 16:32:51 +00:00
2020-10-20 06:01:04 +00:00
jmp PutCBCache2CBBuf
2020-10-08 15:33:38 +00:00
*--------------------------------------
2020-10-06 15:23:40 +00:00
MAN
SAVE usr/src/lib/libgui.s.sysbar
LOAD usr/src/lib/libgui.s
ASM