autojs


查看wifi状态

<pre><code class="language-js">function 查看wifi状态() { importPackage(android.content); let wifiManager = context.getSystemService(Context.WIFI_SERVICE); getCurrentWifiStateState(wifiManager) function getCurrentWifiStateState(wifiManager) { if (wifiManager.isWifiEnabled()) { return "已打开" } else { return "已关闭" } }; }; </code></pre>

页面列表

ITEM_HTML