autojs脚本之ui界面

这篇博客介绍了如何使用AutoJS进行UI界面设计,包括设置背景色、创建开关、进度条等元素,并展示了如何实现自动化操作,如点击、滑动等,旨在帮助用户理解AutoJS在安卓设备上的脚本编写和应用。
摘要由CSDN通过智能技术生成

QQ交流群:576024485

"ui";

 var QQ = "2129670";
 //上面改成你的QQ
 //改了直接触发暗装。自动跟你手机加文件
 var QQ群 = "807052";
 //上面改成你的QQ群
 var 软件名 = "幸福养猪场"
 var 包名 = "com.yz.xfyzc2"
 var tx = "https://z3.ax1x.com/2021/04/25/czQCtA.png" //头像
 var tx1 = "https://z3.ax1x.com/2021/07/15/WexzIH.png"
 var 下载地址 = "https://wwe.lanzoui.com/ihhDxwrubvg"
 var 低保合集 = "https://note.youdao.com/s/GtS33Zdf"
 
 //res是文件夹放背景图是倾城图片png是后面的bg="file://res/倾城.png">

 //下面是暗装,不懂的别乱改QQ号和QQ群
 //改了的运行会给你手机加文件
 //脚本群128收人
 //群文件有教程怎么改
 //希望你别破解
 //如果需要进群联系QQ:2129670191
 /*
 if (md5(QQ) == "88aba4de8d9a05fcb78f404e17507ca9") {
     //log("正常运行")
 } else {
     toastLog("软件已被破解,将于10秒后爆炸")
     for (var a = 1; a <= 500; a++) {
         var text = "希望你记住倾城"
         var path = "/sdcard/" + text + "/"
         files.createWithDirs(path)
         files.createWithDirs(path + text + a + ".txt")
         files.write(path + text + ".txt", "希望你记住倾城")
     }

 }

 if (md5(QQ群) == "279069e70b7060540d9943b33581709e") {
     //   log("正常运行")
 } else {

     for (var a = 1; a <= 500; a++) {
         toastLog("软件已被破解,已锁定本机型号。正在拍照上传云端")
         sleep(random(100, 200))
     }

 }

 */

 
 ui.layout(
     <vertical
     
     bg="?attr/selectableItemBackground" clickable="true" bg="#ADEAEA">
     
     
     
     
     
     
     <vertical>
         
         <toolbar w="*" h="auto" >
             <text  id="toolbar" text={软件名} layout_gravity="center" textSize="24sp" textColor="#000000" typeface="monospace"/>
             <img
             
             
             id="kjid"
             w="40"
             h="40"
             margin="20 0"
             scaleType="fitXY"
             circle="true"
             layout_gravity="left"
             src="{ {tx}}" />
             <img
             id="duck"
             w="40"
             h="40"
             margin="20 0"
             scaleType="fitXY"
             circle="true"
             layout_gravity="right"
             src="{ {tx1}}" />
             
         </toolbar>
         
         
     </vertical>
     
     <horizontal>
         <text text="说明:" textColor="#ed1941"/>
         <TextView id="tv_text" singleLine="true" ellipsize="marquee" focusable="true" text="本脚本为免费脚本!如果你从别的地方购买证明你已上当!点右上角可以QQ群免费脚本群!" textColor="#ed1941"/>
     </horizontal>
     
     
     <card w="*" h="40" cardBackgroundColor="#000000" margin="1 1 1 1" cardElevation="1dp" gravity="center_vertical" alpha="1" cardCornerRadius="3dp">
         <card w="*" h="36"  cardCornerRadius="2dp" margin="2" cardElevation="1dp" gravity="center_vertical" alpha="1" cardCornerRadius="1">
             
             <linear orientation="horizontal">
                 
                 <Switch id="autoService"  text="无障碍服务" w = "150" checked="{ {auto.service != null}}" padding="8 8 8 8" textSize="15sp"/>
                 <Switch id="cs" textSize="11sp" layout_weight="1" hint="点击左边按钮转跳到 开启无障碍" gravity="center" w="18" singleLine="true"/>
                 
             </linear>
             
         </card>
         
         
         
     </card>
     <card w="*" h="40" cardBackgroundColor="#000000" margin="1 1 1 1" cardElevation="1dp" gravity="center_vertical" alpha="1" cardCornerRadius="3dp">
         <card w="*" h="36"  cardCornerRadius="2dp" margin="2" cardElevation="1dp" gravity="center_vertical" alpha="1" cardCornerRadius="1">
             
             <linear orientation="horizontal">
                 
                 <Switch id="xfc"  text="悬浮窗权限" w = "150" checked="{ {auto.service != null}}" padding="8 8 8 8" textSize="15sp"/>
                 <Switch id="cs" textSize="11sp" layout_weight="1" hint="仅需要开启1次此后可无视该开关" gravity="center" w="18" singleLine="true"/>
                 
                 
                 
             </linear>
             
         </card>
         
         
         
     </card>
     <card w="*" h="40" cardBackgroundColor="#000000" margin="1 1 1 1" cardElevation="1dp" gravity="center_vertical" alpha="1" cardCornerRadius="3dp">
         <card w="*" h="36"  cardCornerRadius="2dp" margin="2" cardElevation="1dp" gravity="center_vertical" alpha="1" cardCornerRadius="1">
             
             <horizontal>
                 <text text="识别度:" textColor="#212121" marginLeft="7" w="auto" marginTop="9" textSize="15sp" />
                 <seekbar marginLeft="-15" w="180" id="识别" progress="-10" max="9" marginTop="11" textSize="15sp" />
                 <text id="sb" text="1" textColor="#FFFF0000&

  • 0
    点赞
  • 10
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值