回复 10楼 江静月
require "import"
import "android.widget.*"
import "com.androlua.*"
function 支付宝扫一扫()
service.click({
{">支付宝$300","扫一扫>20",},
})
end
function 支付宝付钱()
service.click({
{">支付宝$300","付钱>20",},
})
end
function 微信扫一扫()
service.click({
{">微信$300","更多功能*>20$300","扫一扫>10",},
})
end
function 网易云签到()
service.click({
{">网易云音乐$3000","抽屉菜单>20$300","签到|赚云贝>10","<连续签到*>10",},
})
end
sj={
"微信扫一扫",
"支付宝扫一扫",
"支付宝付款码",
"网易云音乐签到",
} dj={
{{"%微信扫一扫",}},
{{"%支付宝扫一扫",}},
{{"%支付宝付钱",}},
{{"%网易云签到",}},
} layout={GridView,
id="grid",
items=sj,
numColumns=4,}
dlg=LuaDialog(this)
.setView(loadlayout(layout))
.setTitle("选择操作")
.setButton("打开解说",function()
service.execute("程序设置")
end)
.setNegativeButton("关闭",nil)
.show()
grid.onItemClick=function(l,v,p,i)
local s=dj[p+1]
if s then
dlg.dismiss()
service.click(s)
end
end
task(2,function()
end)
return true
来自解说社区客户端 |