support more devices for proxy
This commit is contained in:
@@ -671,10 +671,10 @@ class CommandorPage {
|
|||||||
|
|
||||||
async slidingCaptcha(onResult) {
|
async slidingCaptcha(onResult) {
|
||||||
logWithDevice("slidingCaptcha", this.device);
|
logWithDevice("slidingCaptcha", this.device);
|
||||||
if (this.device.model() === "MI 5s" || this.device.model() === "ASUS_X00QD") {
|
if (this.device.model() === "MI 5s" || this.device.model() === "ASUS_X00QD" || this.device.model() === "ASUS_Z012D") {
|
||||||
let cmd = `adb -s ${this.device.serial()} shell input touchscreen swipe 900 495 900 195`
|
let cmd = `adb -s ${this.device.serial()} shell input touchscreen swipe 900 495 900 195`
|
||||||
await exec(cmd);
|
await exec(cmd);
|
||||||
await delay(1000);
|
await delay(5000);
|
||||||
}
|
}
|
||||||
let slidingCaptchaSolver = new SlidingCaptchaSolver(this.device);
|
let slidingCaptchaSolver = new SlidingCaptchaSolver(this.device);
|
||||||
await slidingCaptchaSolver.solve(this.page, async (isSuccessful) => {
|
await slidingCaptchaSolver.solve(this.page, async (isSuccessful) => {
|
||||||
@@ -933,10 +933,10 @@ class CommandorPage {
|
|||||||
await this.checkResultWithOcr();
|
await this.checkResultWithOcr();
|
||||||
break;
|
break;
|
||||||
case OCRResult.BRAVE_PRIVACY:
|
case OCRResult.BRAVE_PRIVACY:
|
||||||
if (this.device.model() === "MI 5s") {
|
if (this.device.model() === "MI 5s" || this.device.model() === "SM-G965U1" || this.device.model() === "ASUS_Z012D") {
|
||||||
await this.tapForDevice(this.device, 530, 970)
|
await this.tapForDevice(this.device, 530, 970)
|
||||||
} else if (this.device.model() === "ONEPLUS A6000") {
|
} else if (this.device.model() === "ONEPLUS A6000") {
|
||||||
await this.device.shell("input tap " + 530 + " " + 1064)
|
await this.tapForDevice(this.device, 530, 1064)
|
||||||
} else if (this.device.model() === "moto g51 5G") {
|
} else if (this.device.model() === "moto g51 5G") {
|
||||||
await this.tapForDevice(this.device, 500, 1080)
|
await this.tapForDevice(this.device, 500, 1080)
|
||||||
} else if (this.device.model() === "M2006C3LG" || this.device.model() === "220233L2G") {
|
} else if (this.device.model() === "M2006C3LG" || this.device.model() === "220233L2G") {
|
||||||
@@ -955,7 +955,7 @@ class CommandorPage {
|
|||||||
await this.checkResultWithOcr();
|
await this.checkResultWithOcr();
|
||||||
break;
|
break;
|
||||||
case OCRResult.BRAVE_PRIVACY_PUB:
|
case OCRResult.BRAVE_PRIVACY_PUB:
|
||||||
if (this.device.model() === "MI 5s") {
|
if (this.device.model() === "MI 5s" || this.device.model() === "ASUS_Z012D") {
|
||||||
await this.tapForDevice(this.device, 60, 1400)
|
await this.tapForDevice(this.device, 60, 1400)
|
||||||
} else
|
} else
|
||||||
await this.tapForDevice(this.device, 455, 1920)
|
await this.tapForDevice(this.device, 455, 1920)
|
||||||
@@ -1070,12 +1070,14 @@ class CommandorPage {
|
|||||||
let model = this.device.model()
|
let model = this.device.model()
|
||||||
if (model === "CPH2219") {
|
if (model === "CPH2219") {
|
||||||
await this.device.shell("input tap " + 558 + " " + 1160)
|
await this.device.shell("input tap " + 558 + " " + 1160)
|
||||||
} else if (model === "MI 5s") {
|
} else if (model === "MI 5s" || model === "ASUS_Z012D") {
|
||||||
|
await this.tapForDevice(this.device, 530, 1000)
|
||||||
|
} else if (model === "SM-G965U1") {
|
||||||
await this.tapForDevice(this.device, 530, 1000)
|
await this.tapForDevice(this.device, 530, 1000)
|
||||||
} else if (model === "M2006C3LG" || model === "220233L2G") {
|
} else if (model === "M2006C3LG" || model === "220233L2G") {
|
||||||
await this.tapForDevice(this.device, 360, 777)
|
await this.tapForDevice(this.device, 360, 777)
|
||||||
} else if (model === "ONEPLUS A6000") {
|
} else if (model === "ONEPLUS A6000") {
|
||||||
await this.device.shell("input tap " + 530 + " " + 1106)
|
await this.tapForDevice(this.device, 530, 1045)
|
||||||
} else {
|
} else {
|
||||||
logWithDevice("handleBraveSkipBtn", this.device)
|
logWithDevice("handleBraveSkipBtn", this.device)
|
||||||
await this.tapForDevice(this.device, 470, 1160)
|
await this.tapForDevice(this.device, 470, 1160)
|
||||||
|
|||||||
Reference in New Issue
Block a user