整理代码

This commit is contained in:
MrZ626
2020-11-23 09:39:19 +08:00
parent 914a962a94
commit 44b151c617
44 changed files with 559 additions and 559 deletions

View File

@@ -124,23 +124,23 @@ function Pnt.calculator()
end
WIDGET.init("calculator",{
WIDGET.newKey({name="_1", x=150,y=300,w=90, font=50,code=WIDGET.lnk_pressKey("1")}),
WIDGET.newKey({name="_2", x=250,y=300,w=90, font=50,code=WIDGET.lnk_pressKey("2")}),
WIDGET.newKey({name="_3", x=350,y=300,w=90, font=50,code=WIDGET.lnk_pressKey("3")}),
WIDGET.newKey({name="_4", x=150,y=400,w=90, font=50,code=WIDGET.lnk_pressKey("4")}),
WIDGET.newKey({name="_5", x=250,y=400,w=90, font=50,code=WIDGET.lnk_pressKey("5")}),
WIDGET.newKey({name="_6", x=350,y=400,w=90, font=50,code=WIDGET.lnk_pressKey("6")}),
WIDGET.newKey({name="_7", x=150,y=500,w=90, font=50,code=WIDGET.lnk_pressKey("7")}),
WIDGET.newKey({name="_8", x=250,y=500,w=90, font=50,code=WIDGET.lnk_pressKey("8")}),
WIDGET.newKey({name="_9", x=350,y=500,w=90, font=50,code=WIDGET.lnk_pressKey("9")}),
WIDGET.newKey({name="_0", x=150,y=600,w=90, font=50,code=WIDGET.lnk_pressKey("0")}),
WIDGET.newKey({name=".", x=250,y=600,w=90, color="lPurple",font=50,code=WIDGET.lnk_pressKey(".")}),
WIDGET.newKey({name="e", x=350,y=600,w=90, color="lPurple",font=50,code=WIDGET.lnk_pressKey("e")}),
WIDGET.newKey({name="+", x=450,y=300,w=90, color="lBlue", font=50,code=WIDGET.lnk_pressKey("+")}),
WIDGET.newKey({name="-", x=450,y=400,w=90, color="lBlue", font=50,code=WIDGET.lnk_pressKey("-")}),
WIDGET.newKey({name="*", x=450,y=500,w=90, color="lBlue", font=50,code=WIDGET.lnk_pressKey("*")}),
WIDGET.newKey({name="/", x=450,y=600,w=90, color="lBlue", font=50,code=WIDGET.lnk_pressKey("/")}),
WIDGET.newKey({name="<", x=550,y=300,w=90, color="lRed", font=50,code=WIDGET.lnk_pressKey("backspace")}),
WIDGET.newKey({name="=", x=550,y=400,w=90, color="lYellow",font=50,code=WIDGET.lnk_pressKey("return")}),
WIDGET.newButton({name="play", x=640,y=600,w=180,h=90, color="lGreen", font=40,code=WIDGET.lnk_pressKey("space"),hide=function()return not sceneTemp.pass end}),
WIDGET.newKey{name="_1",x=150,y=300,w=90, font=50,code=WIDGET.lnk_pressKey("1")},
WIDGET.newKey{name="_2",x=250,y=300,w=90, font=50,code=WIDGET.lnk_pressKey("2")},
WIDGET.newKey{name="_3",x=350,y=300,w=90, font=50,code=WIDGET.lnk_pressKey("3")},
WIDGET.newKey{name="_4",x=150,y=400,w=90, font=50,code=WIDGET.lnk_pressKey("4")},
WIDGET.newKey{name="_5",x=250,y=400,w=90, font=50,code=WIDGET.lnk_pressKey("5")},
WIDGET.newKey{name="_6",x=350,y=400,w=90, font=50,code=WIDGET.lnk_pressKey("6")},
WIDGET.newKey{name="_7",x=150,y=500,w=90, font=50,code=WIDGET.lnk_pressKey("7")},
WIDGET.newKey{name="_8",x=250,y=500,w=90, font=50,code=WIDGET.lnk_pressKey("8")},
WIDGET.newKey{name="_9",x=350,y=500,w=90, font=50,code=WIDGET.lnk_pressKey("9")},
WIDGET.newKey{name="_0",x=150,y=600,w=90, font=50,code=WIDGET.lnk_pressKey("0")},
WIDGET.newKey{name=".", x=250,y=600,w=90,color="lPurple",font=50,code=WIDGET.lnk_pressKey(".")},
WIDGET.newKey{name="e", x=350,y=600,w=90,color="lPurple",font=50,code=WIDGET.lnk_pressKey("e")},
WIDGET.newKey{name="+", x=450,y=300,w=90,color="lBlue", font=50,code=WIDGET.lnk_pressKey("+")},
WIDGET.newKey{name="-", x=450,y=400,w=90,color="lBlue", font=50,code=WIDGET.lnk_pressKey("-")},
WIDGET.newKey{name="*", x=450,y=500,w=90,color="lBlue", font=50,code=WIDGET.lnk_pressKey("*")},
WIDGET.newKey{name="/", x=450,y=600,w=90,color="lBlue", font=50,code=WIDGET.lnk_pressKey("/")},
WIDGET.newKey{name="<", x=550,y=300,w=90,color="lRed", font=50,code=WIDGET.lnk_pressKey("backspace")},
WIDGET.newKey{name="=", x=550,y=400,w=90,color="lYellow",font=50,code=WIDGET.lnk_pressKey("return")},
WIDGET.newButton{name="play",x=640,y=600,w=180,h=90,color="lGreen", font=40,code=WIDGET.lnk_pressKey("space"),hide=function()return not sceneTemp.pass end},
})