控件系统微调,lnk系列函数移出table

This commit is contained in:
MrZ626
2020-11-13 16:29:04 +08:00
parent 0bf8cda441
commit 78fc5bb8e5
34 changed files with 326 additions and 327 deletions

View File

@@ -94,9 +94,9 @@ WIDGET.init("music",{
WIDGET.newText({name="title", x=30, y=30,font=80,align="L"}),
WIDGET.newText({name="arrow", x=270, y=360,font=45,align="L"}),
WIDGET.newText({name="now", x=700, y=500,font=50,align="R",hide=function()return not BGM.nowPlay end}),
WIDGET.newSlider({name="bgm", x=760, y=80,w=400, font=35,disp=WIDGET.lnk.SETval("bgm"),code=function(v)SETTING.bgm=v BGM.freshVolume()end}),
WIDGET.newButton({name="up", x=200, y=250,w=120, font=55,code=WIDGET.lnk.pressKey("up"),hide=function()return sceneTemp==1 end}),
WIDGET.newButton({name="play", x=200, y=390,w=120, font=35,code=WIDGET.lnk.pressKey("space"),hide=function()return SETTING.bgm==0 end}),
WIDGET.newButton({name="down", x=200, y=530,w=120, font=55,code=WIDGET.lnk.pressKey("down"),hide=function()return sceneTemp==BGM.len end}),
WIDGET.newButton({name="back", x=1140, y=640,w=170,h=80, font=40,code=WIDGET.lnk.BACK}),
WIDGET.newSlider({name="bgm", x=760, y=80,w=400, font=35,disp=WIDGET.lnk_SETval("bgm"),code=function(v)SETTING.bgm=v BGM.freshVolume()end}),
WIDGET.newButton({name="up", x=200, y=250,w=120, font=55,code=WIDGET.lnk_pressKey("up"),hide=function()return sceneTemp==1 end}),
WIDGET.newButton({name="play", x=200, y=390,w=120, font=35,code=WIDGET.lnk_pressKey("space"),hide=function()return SETTING.bgm==0 end}),
WIDGET.newButton({name="down", x=200, y=530,w=120, font=55,code=WIDGET.lnk_pressKey("down"),hide=function()return sceneTemp==BGM.len end}),
WIDGET.newButton({name="back", x=1140, y=640,w=170,h=80, font=40,code=WIDGET.lnk_BACK}),
})