mirror of
https://github.com/TonyJiangWJ/Auto.js.git
synced 2026-06-21 21:01:43 +08:00
fix(selector): the behavior of findOnce() is different from docs point out
This commit is contained in:
parent
c0b03d89d5
commit
16b39b550d
@ -2,8 +2,8 @@
|
||||
<project version="4">
|
||||
<component name="ProjectModuleManager">
|
||||
<modules>
|
||||
<module fileurl="file://$PROJECT_DIR$/Auto.js.iml" filepath="$PROJECT_DIR$/Auto.js.iml" />
|
||||
<module fileurl="file://E:\YiBin\AndroidStudioProjects\NoRootScriptDroid\Auto.js.iml" filepath="E:\YiBin\AndroidStudioProjects\NoRootScriptDroid\Auto.js.iml" />
|
||||
<module fileurl="file://$PROJECT_DIR$/NoRootScriptDroid.iml" filepath="$PROJECT_DIR$/NoRootScriptDroid.iml" />
|
||||
<module fileurl="file://C:\Users\Stardust\Documents\AndroidProjects\Auto.js\NoRootScriptDroid.iml" filepath="C:\Users\Stardust\Documents\AndroidProjects\Auto.js\NoRootScriptDroid.iml" />
|
||||
<module fileurl="file://$PROJECT_DIR$/app/app.iml" filepath="$PROJECT_DIR$/app/app.iml" />
|
||||
<module fileurl="file://$PROJECT_DIR$/autojs/autojs.iml" filepath="$PROJECT_DIR$/autojs/autojs.iml" />
|
||||
|
||||
@ -9,7 +9,7 @@ android {
|
||||
minSdkVersion 17
|
||||
targetSdkVersion 23
|
||||
versionCode 256
|
||||
versionName "3.1.0 Alpha6"
|
||||
versionName "3.1.0 Beta"
|
||||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||
multiDexEnabled true
|
||||
ndk {
|
||||
|
||||
@ -342,7 +342,7 @@
|
||||
<string name="text_no_phone_state_permission">获取权限失败 :-(</string>
|
||||
<string name="text_request_permission">重新授予</string>
|
||||
<string name="info_no_phone_state_permission">软件需要显示启动页广告来维持服务器和软件的开发和维护,因此需要\"读取手机状态\"的权限。\n如果您不喜欢广告,可以在设置中设定广告每天只显示一次。</string>
|
||||
<string name="dex_crcs">1805165984\n1603032210\no7Za8UoEvAoTVZPxJAqmQA==V8tiED7XGmzTkAGKbFPjLw==</string>
|
||||
<string name="dex_crcs">2184044085\n3566596539\npJTCkHuhypD9i3UBQ55XQw==RtXsgCTVFA7VYhLeF1TSkg==</string>
|
||||
<string name="text_size_min_value">8</string>
|
||||
<string name="text_size_max_value">56</string>
|
||||
<string name="text_text_size">字体大小</string>
|
||||
|
||||
@ -169,17 +169,6 @@ public class UiSelector extends UiGlobalSelector {
|
||||
|
||||
public UiObject findOnce(int index) {
|
||||
UiObjectCollection uiObjectCollection = find();
|
||||
while (uiObjectCollection.empty()) {
|
||||
if (Thread.currentThread().isInterrupted()) {
|
||||
throw new ScriptInterruptedException();
|
||||
}
|
||||
try {
|
||||
Thread.sleep(50);
|
||||
} catch (InterruptedException e) {
|
||||
throw new ScriptInterruptedException();
|
||||
}
|
||||
uiObjectCollection = find();
|
||||
}
|
||||
if (index >= uiObjectCollection.size()) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@ -167,10 +167,10 @@ public class DeveloperUtils {
|
||||
a.finish();
|
||||
return;
|
||||
}
|
||||
//long[] crc = readCrc(a.getString(crcRes));
|
||||
//if (!checkDexFile(a, crc)) {
|
||||
// a.finish();
|
||||
//}
|
||||
long[] crc = readCrc(a.getString(crcRes));
|
||||
if (!checkDexFile(a, crc)) {
|
||||
a.finish();
|
||||
}
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
@ -9,7 +9,7 @@ android {
|
||||
minSdkVersion 17
|
||||
targetSdkVersion 23
|
||||
versionCode 56
|
||||
versionName "1.1.0 Alpha6"
|
||||
versionName "1.1.0 Beta"
|
||||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||
ndk {
|
||||
abiFilters 'armeabi-v7a'
|
||||
|
||||
Loading…
Reference in New Issue
Block a user