导航菜单

页面标题

页面副标题

Tasker v6.5.11 - c6.java 源代码

正在查看: Tasker v6.5.11 应用的 c6.java JAVA 源代码文件

本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。


package net.dinglisch.android.taskerm;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.os.ConditionVariable;
import android.os.Handler;
import android.os.Message;
import android.text.TextUtils;
import android.webkit.JavascriptInterface;
import android.webkit.WebSettings;
import android.webkit.WebView;
import com.joaomgcd.taskerm.structuredoutput.StructureType;
import com.joaomgcd.taskerm.util.App;
import com.joaomgcd.taskerm.util.AppBasic;
import com.joaomgcd.taskerm.util.ExtensionsContextKt;
import com.joaomgcd.taskerservercommon.ConstantsCommonTaskerServer;
import cyanogenmod.app.ProfileManager;
import cyanogenmod.profiles.RingModeSettings;
import java.io.File;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import java.util.Random;
import java.util.Set;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import kotlin.Pair;
import net.dinglisch.android.taskerm.WebChromeClientCommon;
import net.dinglisch.android.taskerm.yd;

public class c6 {
    private static final e[] A;
    private static final e[] A0;
    private static final String[] A1;
    private static final String[] A2;
    private static final e[] A3;
    public static final int ACTION_EDIT_ID = 50000;
    public static final String ALARM_VOL_LABEL = "alarmVol";
    public static final String AUDIO_RECORD_LABEL = "audioRecord";
    private static final String[] B;
    private static final String[] B0;
    private static final e[] B1;
    private static final e[] B2;
    private static final String[] B3;
    public static final String BT_VOICE_VOL_LABEL = "btVoiceVol";
    private static final e[] C;
    private static final e[] C0;
    private static final String[] C1;
    private static final String[] C2;
    private static final e[] C3;
    public static final String CALL_BLOCK_LABEL = "callBlock";
    public static final String CALL_DIVERT_LABEL = "callDivert";
    public static final String CALL_LABEL = "call";
    public static final String CALL_REVERT_LABEL = "callRevert";
    public static final String CALL_VOL_LABEL = "callVol";
    public static final String CAR_MODE_LABEL = "carMode";
    private static final String[] D;
    private static final String[] D0;
    private static final e[] D1;
    private static final e[] D2;
    private static final String[] D3;
    public static final String DECRYPT_DIR_LABEL = "decryptDir";
    public static final String DECRYPT_FILE_LABEL = "decryptFile";
    public static final String DISABLE_LABEL = "disable";
    public static final String DISPLAY_AUTO_BRIGHT_LABEL = "displayAutoBright";
    public static final String DISPLAY_AUTO_ROTATE_LABEL = "displayAutoRotate";
    public static final String DISPLAY_TIMEOUT_LABEL = "displayTimeout";
    public static final String DTMF_VOL_LABEL = "dtmfVol";
    private static final e[] E;
    private static final e[] E0;
    private static final String[] E1;
    private static final String[] E2;
    private static final e[] E3;
    public static final String ELEMENT_BACK_COLOUR_LABEL = "elemBackColour";
    public static final String ELEMENT_BORDER_LABEL = "elemBorder";
    public static final String ELEMENT_POSITION_LABEL = "elemPosition";
    public static final String ELEMENT_TEXT_COLOUR_LABEL = "elemTextColour";
    public static final String ELEMENT_TEXT_LABEL = "elemText";
    public static final String ELEMENT_TEXT_SIZE_LABEL = "elemTextSize";
    public static final String ELEMENT_VISIBILITY_LABEL = "elemVisibility";
    public static final String ENABLE_PROFILE_LABEL = "enableProfile";
    public static final String ENCRYPT_DIR_LABEL = "encryptDir";
    public static final String ENCRYPT_FILE_LABEL = "encryptFile";
    public static final String END_CALL_LABEL = "endCall";
    public static final String EXPORT_FILENAME = "tasker.js";
    public static final String EXTRA_ID = "id";
    private static final String[] F;
    private static final String[] F0;
    private static final e[] F1;
    private static final e[] F2;
    private static final String[] F3;
    private static final e[] G;
    private static final e[] G0;
    private static final String[] G1;
    private static final String[] G2;
    private static final e[] G3;
    public static final e[] GET_LOCATION_AT;
    public static final String GET_LOCATION_LABEL = "getLocation";
    private static final String[] H;
    private static final String[] H0;
    private static final e[] H1;
    private static final e[] H2;
    private static final String[] H3;
    public static final String HAPTICS_LABEL = "haptics";
    private static final e[] I;
    private static final e[] I0;
    private static final String[] I1;
    private static final String[] I2;
    private static final e[] I3;
    private static final String[] J;
    private static final String[] J0;
    private static final e[] J1;
    private static final e[] J2;
    private static final String[] J3;
    private static final e[] K;
    private static final e[] K0;
    private static final String[] K1;
    private static final String[] K2;
    private static final e[] K3;
    private static final String[] L;
    private static final String[] L0;
    private static final e[] L1;
    private static final e[] L2;
    private static final String[] L3;
    public static final String LOCK_LABEL = "lock";
    private static final e[] M;
    private static final e[] M0;
    private static final String[] M1;
    private static final String[] M2;
    private static final e[] M3;
    public static final String MEDIA_CONTROL_LABEL = "mediaControl";
    public static final String MEDIA_VOL_LABEL = "mediaVol";
    public static final String MIC_MUTE_LABEL = "micMute";
    public static final String MOBILE_DATA_LABEL = "mobileData";
    public static final String MUSIC_BACK_LABEL = "musicBack";
    public static final String MUSIC_PLAY_LABEL = "musicPlay";
    public static final String MUSIC_SKIP_LABEL = "musicSkip";
    public static final String MUSIC_STOP_LABEL = "musicStop";
    private static final String[] N;
    private static final String[] N0;
    private static final e[] N1;
    private static final e[] N2;
    private static final String[] N3;
    public static final String NIGHT_MODE_LABEL = "nightMode";
    public static final String NOTIFICATION_VOL_LABEL = "notificationVol";
    private static final e[] O;
    private static final e[] O0;
    private static final String[] O1;
    private static final String[] O2;
    private static final e[] O3;
    private static final String[] P;
    private static final String[] P0;
    private static final e[] P1;
    private static final e[] P2;
    private static final String[] P3;
    public static final e[] PARSE_FORMAT_DATETIME_AT;
    public static final String PARSE_FORMAT_DATETIME_LABEL = "parseFormatDateTime";
    public static final e[] PERFORM_TASK_AT;
    public static final String PERFORM_TASK_LABEL = "performTask";
    public static final String POPUP_LABEL = "popup";
    public static final String PROFILE_ACTIVE_LABEL = "profileActive";
    public static final String PULSE_LABEL = "pulse";
    private static final e[] Q;
    private static final e[] Q0;
    private static final String[] Q1;
    private static final String[] Q2;
    private static final e[] Q3;
    private static final String[] R;
    private static final String[] R0;
    private static final e[] R1;
    private static final e[] R2;
    private static final String[] R3;
    public static final String RINGER_VOL_LABEL = "ringerVol";
    private static final e[] S;
    private static final e[] S0;
    private static final String[] S1;
    private static final String[] S2;
    private static final e[][] S3;
    public static final String SAVE_IMAGE_LABEL = "saveImage";
    public static final String SAY_LABEL = "say";
    public static final int SCENE_JSI_ID_START = 100000;
    public static final String SEND_INTENT_LABEL = "sendIntent";
    public static final String SEND_SMS_LABEL = "sendSMS";
    public static final String SETTINGS_LABEL = "settings";
    public static final String SET_AIRPLANE_MODE_LABEL = "setAirplaneMode";
    public static final String SET_AIRPLANE_RADIOS_LABEL = "setAirplaneRadios";
    public static final String SET_ALARM_LABEL = "setAlarm";
    public static final String SET_AUTO_SYNC_LABEL = "setAutoSync";
    public static final String SET_BT_ID_LABEL = "setBTID";
    public static final String SET_BT_LABEL = "setBT";
    public static final String SET_CLIP_LABEL = "setClip";
    public static final String SET_WALLPAPER_LABEL = "setWallpaper";
    public static final String SET_WIFI_LABEL = "setWifi";
    public static final e[] SHOW_SCENE_AT;
    public static final String SHOW_SCENE_LABEL = "showScene";
    public static final String SILENT_MODE_LABEL = "silentMode";
    public static final String SL4A_LABEL = "sl4a";
    public static final String SOUND_EFFECTS_LABEL = "soundEffects";
    public static final String SPEAKERPHONE_LABEL = "speakerphone";
    public static final String STATUS_BAR_LABEL = "statusBar";
    public static final String STAY_ON_LABEL = "stayOn";
    public static final String STOP_LOCATION_LABEL = "stopLocation";
    public static final String SYSTEM_LOCK_LABEL = "systemLock";
    public static final String SYSTEM_VOL_LABEL = "systemVol";
    private static final String[] T;
    private static final String[] T0;
    private static final e[] T1;
    private static final e[] T2;
    private static final String[][] T3;
    public static final String TAKE_CALL_LABEL = "takeCall";
    public static final String TAKE_PHOTO_LABEL = "takePhoto";
    public static final String TASKER_OBJECT_NAME = "tk";
    public static final int TASK_JSI_ID_START = 0;
    public static final String TASK_NAME_PREFIX = "JSI:";
    public static final String TASK_RUNNING_LABEL = "taskRunning";
    private static final e[] U;
    private static final e[] U0;
    private static final String[] U1;
    private static final String[] U2;
    private static Pattern U3 = null;
    public static final String UNZIP_LABEL = "unzip";
    public static final String USB_TETHER_LABEL = "usbTether";
    private static final String[] V;
    private static final String[] V0;
    private static final e[] V1;
    private static final e[] V2;
    private static String[] V3 = null;
    public static final int VERSION = 1;
    public static final String VIBRATE_LABEL = "vibrate";
    public static final String VIBRATE_PATTERN_LABEL = "vibratePattern";
    private static final e[] W;
    private static final e[] W0;
    private static final String[] W1;
    private static final String[] W2;
    private static Pattern W3 = null;
    public static final int WHAT_ERROR = 2;
    public static final int WHAT_EXIT = 1;
    public static final int WHAT_FIRST = 0;
    public static final int WHAT_LAST = 4;
    public static final int WHAT_START = 0;
    public static final int WHAT_TIMEOUT = 3;
    public static final int WHAT_WARNING = 4;
    public static final String WIFI_TETHER_LABEL = "wifiTether";
    public static final String WRITE_FILE_LABEL = "writeFile";
    private static final String[] X;
    private static final String[] X0;
    private static final e[] X1;
    private static final e[] X2;
    private static final e[] Y;
    private static final e[] Y0;
    private static final String[] Y1;
    private static final String[] Y2;
    private static final String[] Z;
    private static final String[] Z0;
    private static final e[] Z1;
    private static final e[] Z2;
    public static final String ZIP_LABEL = "zip";
    private static final e[] a0;
    private static final e[] a1;
    private static final String[] a2;
    private static final String[] a3;
    private static final String[] b0;
    private static final String[] b1;
    private static final e[] b2;
    private static final e[] b3;
    private static final e[] c0;
    private static final e[] c1;
    private static final String[] c2;
    private static final String[] c3;
    private static final String[] d0;
    private static final String[] d1;
    private static final e[] d2;
    private static final String[] d3;
    private static final e[] e0;
    private static final e[] e1;
    private static final String[] e2;
    private static final e[] e3;
    private static final String[] f0;
    private static final String[] f1;
    private static final e[] f2;
    private static final String[] f3;
    private static final e[] g0;
    private static final e[] g1;
    private static final String[] g2;
    private static final e[] g3;
    private static final String[] h0;
    private static final String[] h1;
    private static final e[] h2;
    private static final String[] h3;
    private static final e[] i0;
    private static final String[] i1;
    private static final String[] i2;
    private static final e[] i3;
    private static final String[] j0;
    private static final e[] j1;
    private static final e[] j2;
    private static final String[] j3;
    private static final e[] k0;
    private static final String[] k1;
    private static final String[] k2;
    private static final e[] k3;
    private static final String[] l0;
    private static final e[] l1;
    private static final e[] l2;
    private static final String[] l3;
    private static final e[] m0;
    private static final String[] m1;
    private static final String[] m2;
    private static final e[] m3;
    private static final String[] n0;
    private static final e[] n1;
    private static final e[] n2;
    private static final String[] n3;
    private static final e[] o0;
    private static final String[] o1;
    private static final String[] o2;
    private static final e[] o3;
    private static final String[] p0;
    private static final String[] p1;
    private static final e[] p2;
    private static final String[] p3;
    private static final e[] q0;
    private static final String[] q1;
    private static final String[] q2;
    private static final e[] q3;
    private static final String[] r;
    private static final String[] r0;
    private static final e[] r1;
    private static final e[] r2;
    private static final String[] r3;
    private static final String[] s;
    private static final e[] s0;
    private static final String[] s1;
    private static final String[] s2;
    private static final e[] s3;
    private static final String[] t;
    private static final String[] t0;
    private static final e[] t1;
    private static final e[] t2;
    private static final String[] t3;
    private static final e[] u;
    private static final e[] u0;
    private static final String[] u1;
    private static final String[] u2;
    private static final e[] u3;
    private static final String[] v;
    private static final String[] v0;
    private static final e[] v1;
    private static final e[] v2;
    private static final String[] v3;
    private static final e[] w;
    private static final e[] w0;
    private static final String[] w1;
    private static final String[] w2;
    private static final e[] w3;
    private static final String[] x;
    private static final String[] x0;
    private static final e[] x1;
    private static final e[] x2;
    private static final String[] x3;
    private static final e[] y;
    private static final e[] y0;
    private static final String[] y1;
    private static final String[] y2;
    private static final e[] y3;
    private static final String[] z;
    private static final String[] z0;
    private static final e[] z1;
    private static final e[] z2;
    private static final String[] z3;
    private String b;
    private com.joaomgcd.taskerm.util.c<Pair<String, String>> c;
    private com.joaomgcd.taskerm.util.c<Bundle> d;
    private Context e;
    private Handler f;
    private WebView g;
    private Bundle h;
    private WebChromeClientCommon i;
    private int m;
    private int n;
    private String o;
    private volatile f p;
    private volatile String q;
    private final ConditionVariable a = new ConditionVariable();
    private boolean j = false;
    private boolean k = false;
    private Object l = new Object();

    class a extends Handler {
        final Handler a;
        final int b;

        a(Handler handler, int i) {
            this.a = handler;
            this.b = i;
        }

        @Override
        public void handleMessage(Message message) {
            if (message.what != 1) {
                return;
            }
            Bundle data = message.getData();
            WebChromeClientCommon.a valueOf = WebChromeClientCommon.a.valueOf(data.getString("r"));
            r7.f("JSI", "console: " + valueOf.toString() + ": " + data.getInt("l") + ": " + data.getString("m"));
            int i = d.a[valueOf.ordinal()];
            if (i == 1) {
                Message obtainMessage = this.a.obtainMessage();
                obtainMessage.what = 2;
                obtainMessage.setData(data);
                data.putInt(c6.EXTRA_ID, this.b);
                this.a.sendMessage(obtainMessage);
                return;
            }
            if (i != 2) {
                return;
            }
            Message obtainMessage2 = this.a.obtainMessage();
            obtainMessage2.what = 4;
            obtainMessage2.setData(data);
            data.putInt(c6.EXTRA_ID, this.b);
            this.a.sendMessage(obtainMessage2);
        }
    }

    class b extends BroadcastReceiver {
        final String a;

        b(String str) {
            this.a = str;
        }

        @Override
        public void onReceive(Context context, Intent intent) {
            com.joaomgcd.taskerm.util.f1.e(intent);
            if (intent.getData().getSchemeSpecificPart().equals(this.a)) {
                boolean booleanExtra = intent.getBooleanExtra("success", false);
                byte[] byteArrayExtra = intent.getByteArrayExtra("output");
                r7.f(c6.this.b, "JSI" + c6.this.m + ": onReceive: result: " + booleanExtra);
                if (booleanExtra) {
                    c6.this.p = f.Success;
                    if (byteArrayExtra != null) {
                        c6.this.q = jr.b(byteArrayExtra);
                    }
                } else {
                    c6.this.p = f.Failure;
                }
                if (c6.this.e != null) {
                    dq.K3(c6.this.j(), this);
                }
                if (c6.this.a != null) {
                    c6.this.a.open();
                }
            }
        }
    }

    class c implements Runnable {
        c() {
        }

        @Override
        public void run() {
            c6.this._stop();
        }
    }

    static class d {
        static final int[] a;

        static {
            int[] iArr = new int[WebChromeClientCommon.a.values().length];
            a = iArr;
            try {
                iArr[WebChromeClientCommon.a.ERROR.ordinal()] = 1;
            } catch (NoSuchFieldError unused) {
            }
            try {
                a[WebChromeClientCommon.a.WARNING.ordinal()] = 2;
            } catch (NoSuchFieldError unused2) {
            }
        }
    }

    enum e {
        None,
        String,
        Int,
        Bool,
        StringArray
    }

    private enum f {
        Waiting,
        Failure,
        Success
    }

    static {
        e eVar = e.Bool;
        e eVar2 = e.String;
        e eVar3 = e.Int;
        e[] eVarArr = {eVar, eVar2, eVar, eVar3};
        GET_LOCATION_AT = eVarArr;
        e[] eVarArr2 = {eVar, eVar2, eVar3, eVar2, eVar2, eVar2, eVar, eVar, eVar2, eVar};
        PERFORM_TASK_AT = eVarArr2;
        e[] eVarArr3 = {eVar2, eVar3, eVar2, eVar2, eVar2, eVar2, eVar2, eVar};
        PARSE_FORMAT_DATETIME_AT = eVarArr3;
        e[] eVarArr4 = {eVar, eVar2, eVar2, eVar3, eVar3, eVar, eVar};
        SHOW_SCENE_AT = eVarArr4;
        r = new String[]{"Chrome Frame", "Dojo", "Ext Core", "jQuery", "jQuery UI", "Moo Tools", "Prototype", "script.aculo.us", "SWFObject", "WebFont Loader"};
        s = new String[]{"https://ajax.googleapis.com/ajax/libs/chrome-frame/1.0.2/CFInstall.min.js", "https://ajax.googleapis.com/ajax/libs/dojo/1.7.2/dojo/dojo.js", "https://ajax.googleapis.com/ajax/libs/ext-core/3.1.0/ext-core.js", "https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js", "https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.18/jquery-ui.min.js", "https://ajax.googleapis.com/ajax/libs/mootools/1.4.5/mootools-yui-compressed.js", "https://ajax.googleapis.com/ajax/libs/prototype/1.7.0.0/prototype.js", "https://ajax.googleapis.com/ajax/libs/scriptaculous/1.9.0/scriptaculous.js", "https://ajax.googleapis.com/ajax/libs/swfobject/2.2/swfobject.js", "https://ajax.googleapis.com/ajax/libs/webfont/1.0.28/webfont.js"};
        String[] strArr = {"ok", "vol", "disp", "snd"};
        t = strArr;
        e[] eVarArr5 = {eVar, eVar3, eVar, eVar};
        u = eVarArr5;
        String[] strArr2 = {"ok", "text", "title", "button1", "button2", "button3", "timeout", "useHTML"};
        v = strArr2;
        e[] eVarArr6 = {eVar, eVar2, eVar2, eVar2, eVar2, eVar2, eVar3, eVar};
        w = eVarArr6;
        String[] strArr3 = {"ok", "path", "source", "codec", "format"};
        x = strArr3;
        e[] eVarArr7 = {eVar, eVar2, eVar2, eVar2, eVar2};
        y = eVarArr7;
        String[] strArr4 = {"ok"};
        z = strArr4;
        e[] eVarArr8 = {eVar};
        A = eVarArr8;
        String[] strArr5 = {"ok", "URL"};
        B = strArr5;
        e[] eVarArr9 = {eVar, eVar2};
        C = eVarArr9;
        String[] strArr6 = {"ok", ProfileManager.EXTRA_PROFILE_NAME};
        D = strArr6;
        e[] eVarArr10 = {eVar, eVar2};
        E = eVarArr10;
        String[] strArr7 = {"ok", "num", "auto"};
        F = strArr7;
        e[] eVarArr11 = {eVar, eVar2, eVar};
        G = eVarArr11;
        String[] strArr8 = {"ok", "nummatch", "info"};
        H = strArr8;
        e[] eVarArr12 = {eVar, eVar2, eVar};
        I = eVarArr12;
        String[] strArr9 = {"ok", "frommatch", "to", "info"};
        J = strArr9;
        e[] eVarArr13 = {eVar, eVar2, eVar2, eVar};
        K = eVarArr13;
        String[] strArr10 = {"ok", "numMatch"};
        L = strArr10;
        e[] eVarArr14 = {eVar, eVar2};
        M = eVarArr14;
        String[] strArr11 = {"ok", "on"};
        N = strArr11;
        e[] eVarArr15 = {eVar, eVar};
        O = eVarArr15;
        String[] strArr12 = {"ok", "key"};
        P = strArr12;
        e[] eVarArr16 = {eVar, eVar2};
        Q = eVarArr16;
        String[] strArr13 = {"newval", "val", "mode"};
        R = strArr13;
        e[] eVarArr17 = {eVar2, eVar2, eVar2};
        S = eVarArr17;
        String[] strArr14 = {"ok", "to", "subj", "msg"};
        T = strArr14;
        e[] eVarArr18 = {eVar, eVar2, eVar2, eVar2};
        U = eVarArr18;
        String[] strArr15 = {"ok", "to", "subj", "msg", "attach"};
        V = strArr15;
        e[] eVarArr19 = {eVar, eVar2, eVar2, eVar2, eVar2};
        W = eVarArr19;
        String[] strArr16 = {"ok", "to", "msg"};
        X = strArr16;
        e[] eVarArr20 = {eVar, eVar2, eVar2};
        Y = eVarArr20;
        String[] strArr17 = {"ok", "path", "all", "root"};
        Z = strArr17;
        e[] eVarArr21 = {eVar, eVar2, eVar, eVar};
        a0 = eVarArr21;
        String[] strArr18 = {"http_data", "method", "url", "headers", "queryParameters", "body", "fileToSend", "fileOutput", "timeout", "trustAnyCertificate", "autoRedirect", "useCookies", "structureOutput"};
        b0 = strArr18;
        e[] eVarArr22 = {eVar2, eVar2, eVar2, eVar2, eVar2, eVar2, eVar2, eVar2, eVar3, eVar, eVar, eVar, eVar};
        c0 = eVarArr22;
        String[] strArr19 = {"ok", "command"};
        d0 = strArr19;
        e[] eVarArr23 = {eVar, eVar2};
        e0 = eVarArr23;
        String[] strArr20 = {"ok", ProfileManager.EXTRA_PROFILE_NAME};
        f0 = strArr20;
        e[] eVarArr24 = {eVar, eVar2};
        g0 = eVarArr24;
        String[] strArr21 = {"ok", "lft", "rgt", "top", "bot"};
        h0 = strArr21;
        e[] eVarArr25 = {eVar, eVar3, eVar3, eVar3, eVar3};
        i0 = eVarArr25;
        String[] strArr22 = {"ok", "path", "key", "removekey"};
        j0 = strArr22;
        e[] eVarArr26 = {eVar, eVar2, eVar2, eVar};
        k0 = eVarArr26;
        String[] strArr23 = {"ok", "path", "key", "removekey"};
        l0 = strArr23;
        e[] eVarArr27 = {eVar, eVar2, eVar2, eVar};
        m0 = eVarArr27;
        String[] strArr24 = {"ok", "path", "rec", "root"};
        n0 = strArr24;
        e[] eVarArr28 = {eVar, eVar2, eVar, eVar};
        o0 = eVarArr28;
        String[] strArr25 = {"ok", "path", "shred", "root"};
        p0 = strArr25;
        e[] eVarArr29 = {eVar, eVar2, eVar3, eVar};
        q0 = eVarArr29;
        String[] strArr26 = {"ok", ProfileManager.EXTRA_PROFILE_NAME};
        r0 = strArr26;
        e[] eVarArr30 = {eVar, eVar2};
        s0 = eVarArr30;
        String[] strArr27 = {"ok"};
        t0 = strArr27;
        e[] eVarArr31 = {eVar};
        u0 = eVarArr31;
        String[] strArr28 = {"ok", "on"};
        v0 = strArr28;
        e[] eVarArr32 = {eVar, eVar};
        w0 = eVarArr32;
        String[] strArr29 = {"ok", "hours", "mins", "secs"};
        x0 = strArr29;
        e[] eVarArr33 = {eVar, eVar3, eVar3, eVar3};
        y0 = eVarArr33;
        String[] strArr30 = {"ok", "on"};
        z0 = strArr30;
        e[] eVarArr34 = {eVar, eVar};
        A0 = eVarArr34;
        String[] strArr31 = {"ok", "dir", "repeat"};
        B0 = strArr31;
        e[] eVarArr35 = {eVar, eVar2, eVar3};
        C0 = eVarArr35;
        String[] strArr32 = {"ok", "scene", "elem", "start", "end"};
        D0 = strArr32;
        e[] eVarArr36 = {eVar, eVar2, eVar2, eVar2, eVar2};
        E0 = eVarArr36;
        String[] strArr33 = {"ok", "scene", "elem", "width", "colour"};
        F0 = strArr33;
        e[] eVarArr37 = {eVar, eVar2, eVar2, eVar3, eVar2};
        G0 = eVarArr37;
        String[] strArr34 = {"ok", "scene", "elem", "ori", "x", "y", "animMS"};
        H0 = strArr34;
        e[] eVarArr38 = {eVar, eVar2, eVar2, eVar2, eVar3, eVar3, eVar3};
        I0 = eVarArr38;
        String[] strArr35 = {"ok", "scene", "elem", "pos", "text"};
        J0 = strArr35;
        e[] eVarArr39 = {eVar, eVar2, eVar2, eVar2, eVar2};
        K0 = eVarArr39;
        String[] strArr36 = {"ok", "scene", "elem", "colour"};
        L0 = strArr36;
        e[] eVarArr40 = {eVar, eVar2, eVar2, eVar2};
        M0 = eVarArr40;
        String[] strArr37 = {"ok", "scene", "elem", "size"};
        N0 = strArr37;
        e[] eVarArr41 = {eVar, eVar2, eVar2, eVar3};
        O0 = eVarArr41;
        String[] strArr38 = {"ok", "scene", "elem", "vis", "animMS"};
        P0 = strArr38;
        e[] eVarArr42 = {eVar, eVar2, eVar2, eVar, eVar3};
        Q0 = eVarArr42;
        String[] strArr39 = {"ok", ProfileManager.EXTRA_PROFILE_NAME, "set"};
        R0 = strArr39;
        e[] eVarArr43 = {eVar, eVar2, eVar};
        S0 = eVarArr43;
        String[] strArr40 = {"ok", "path", "key", "remkey", "shred"};
        T0 = strArr40;
        e[] eVarArr44 = {eVar, eVar2, eVar2, eVar, eVar};
        U0 = eVarArr44;
        String[] strArr41 = {"ok", "path", "key", "remkey", "shred"};
        V0 = strArr41;
        e[] eVarArr45 = {eVar, eVar2, eVar2, eVar, eVar};
        W0 = eVarArr45;
        String[] strArr42 = {"ok", "title", "key", "overkeyg", "confirm", "back", "layout", "timeout"};
        X0 = strArr42;
        e[] eVarArr46 = {eVar, eVar2, eVar2, eVar, eVar, eVar2, eVar2, eVar3};
        Y0 = eVarArr46;
        String[] strArr43 = {"ok"};
        Z0 = strArr43;
        e[] eVarArr47 = {eVar};
        a1 = eVarArr47;
        String[] strArr44 = {""};
        b1 = strArr44;
        e eVar4 = e.None;
        e[] eVarArr48 = {eVar4};
        c1 = eVarArr48;
        String[] strArr45 = {"ok", "mode", "value"};
        d1 = strArr45;
        e[] eVarArr49 = {eVar, eVar2, eVar3};
        e1 = eVarArr49;
        String[] strArr46 = {"ok", "horizontal"};
        f1 = strArr46;
        e[] eVarArr50 = {eVar, eVar};
        g1 = eVarArr50;
        String[] strArr47 = {"ok", "src", "track", "timeout"};
        h1 = strArr47;
        String[] strArr48 = {"text", "prompt", "model", "timeout"};
        i1 = strArr48;
        e[] eVarArr51 = {eVar2, eVar2, eVar2, eVar3};
        j1 = eVarArr51;
        String[] strArr49 = {null, "screen"};
        k1 = strArr49;
        e[] eVarArr52 = {eVar4, eVar3};
        l1 = eVarArr52;
        String[] strArr50 = {"ok", ProfileManager.EXTRA_PROFILE_NAME};
        m1 = strArr50;
        e[] eVarArr53 = {eVar, eVar2};
        n1 = eVarArr53;
        String[] strArr51 = {"ok", ProfileManager.EXTRA_PROFILE_NAME, "pri", "par1", "par2", "return", "stop", "passthrough", "passthrough_list", "reset_return"};
        o1 = strArr51;
        String[] strArr52 = {"formattedDate", "inputType", "input", "inputFormat", "inputSeparator", "outputFormat", "outputFormatSeparator", "getAllDetails"};
        p1 = strArr52;
        String[] strArr53 = {"ok", "cam", "filename", "res", "gallery"};
        q1 = strArr53;
        e[] eVarArr54 = {eVar, eVar3, eVar2, eVar2, eVar};
        r1 = eVarArr54;
        String[] strArr54 = {"val", ProfileManager.EXTRA_PROFILE_NAME};
        s1 = strArr54;
        e[] eVarArr55 = {eVar2, eVar2};
        t1 = eVarArr55;
        String[] strArr55 = {"ok", "on"};
        u1 = strArr55;
        e[] eVarArr56 = {eVar, eVar};
        v1 = eVarArr56;
        String[] strArr56 = {"files", "path", "hidden"};
        w1 = strArr56;
        e[] eVarArr57 = {eVar2, eVar2, eVar};
        x1 = eVarArr57;
        String[] strArr57 = {"ok", ProfileManager.EXTRA_PROFILE_NAME, "data", "exclude"};
        y1 = strArr57;
        e[] eVarArr58 = {eVar, eVar2, eVar2, eVar};
        z1 = eVarArr58;
        String[] strArr58 = {"ok", "uri"};
        A1 = strArr58;
        e[] eVarArr59 = {eVar, eVar2};
        B1 = eVarArr59;
        String[] strArr59 = {"val", ProfileManager.EXTRA_PROFILE_NAME};
        C1 = strArr59;
        e[] eVarArr60 = {eVar2, eVar2};
        D1 = eVarArr60;
        String[] strArr60 = {"ok", "title", "code", "cncl", "rmbr", "full", "back", "layout"};
        E1 = strArr60;
        e[] eVarArr61 = {eVar, eVar2, eVar2, eVar, eVar, eVar, eVar2, eVar2};
        F1 = eVarArr61;
        String[] strArr61 = {"ok", "action"};
        G1 = strArr61;
        e[] eVarArr62 = {eVar, eVar2};
        H1 = eVarArr62;
        String[] strArr62 = {"ok", "on"};
        I1 = strArr62;
        e[] eVarArr63 = {eVar, eVar};
        J1 = eVarArr63;
        String[] strArr63 = {"ok", "on"};
        K1 = strArr63;
        e[] eVarArr64 = {eVar, eVar};
        L1 = eVarArr64;
        String[] strArr64 = {"ok", "secs"};
        M1 = strArr64;
        e[] eVarArr65 = {eVar, eVar3};
        N1 = eVarArr65;
        String[] strArr65 = {"ok", "path", "offset", "loop", "stream", "continue"};
        O1 = strArr65;
        e[] eVarArr66 = {eVar, eVar2, eVar3, eVar, eVar2, eVar};
        P1 = eVarArr66;
        String[] strArr66 = {"ok", "secs"};
        Q1 = strArr66;
        e[] eVarArr67 = {eVar, eVar3};
        R1 = eVarArr67;
        String[] strArr67 = {"ok"};
        S1 = strArr67;
        e[] eVarArr68 = {eVar};
        T1 = eVarArr68;
        String[] strArr68 = {"ok", "left", "center", "right"};
        U1 = strArr68;
        e[] eVarArr69 = {eVar, eVar2, eVar2, eVar2};
        V1 = eVarArr69;
        String[] strArr69 = {"ok", "on"};
        W1 = strArr69;
        e[] eVarArr70 = {eVar, eVar};
        X1 = eVarArr70;
        String[] strArr70 = {"ok", "title", "text", "overkeyg", "back", "layout", "timeout"};
        Y1 = strArr70;
        e[] eVarArr71 = {eVar, eVar2, eVar2, eVar, eVar2, eVar2, eVar3};
        Z1 = eVarArr71;
        String[] strArr71 = {"ok", "on"};
        a2 = strArr71;
        e[] eVarArr72 = {eVar, eVar};
        b2 = eVarArr72;
        String[] strArr72 = {null, "msg"};
        c2 = strArr72;
        e[] eVarArr73 = {eVar4, eVar2};
        d2 = eVarArr73;
        String[] strArr73 = {null, "msg"};
        e2 = strArr73;
        e[] eVarArr74 = {eVar4, eVar2};
        f2 = eVarArr74;
        String[] strArr74 = {"active", ProfileManager.EXTRA_PROFILE_NAME};
        g2 = strArr74;
        e[] eVarArr75 = {eVar, eVar2};
        h2 = eVarArr75;
        String[] strArr75 = {"content", "path"};
        i2 = strArr75;
        e[] eVarArr76 = {eVar2, eVar2};
        j2 = eVarArr76;
        String[] strArr76 = {"ok", "type"};
        k2 = strArr76;
        e[] eVarArr77 = {eVar, eVar2};
        l2 = eVarArr77;
        String[] strArr77 = {"ok", "path", "width", "height"};
        m2 = strArr77;
        e[] eVarArr78 = {eVar, eVar3, eVar3};
        n2 = eVarArr78;
        String[] strArr78 = {"ok", "path", "dir", "degrees"};
        o2 = strArr78;
        e[] eVarArr79 = {eVar, eVar2, eVar3};
        p2 = eVarArr79;
        String[] strArr79 = {"ok", "text", "eng", "voice", "stream", "pitch", "speed", "focus", "net"};
        q2 = strArr79;
        e[] eVarArr80 = {eVar, eVar2, eVar2, eVar2, eVar2, eVar3, eVar3, eVar, eVar};
        r2 = eVarArr80;
        String[] strArr80 = {"ok", "action", "targ", "pkg", "cls", "cat", "data", "mime", "exts"};
        s2 = strArr80;
        e[] eVarArr81 = {eVar, eVar2, eVar2, eVar2, eVar2, eVar2, eVar2, eVar2, e.StringArray};
        t2 = eVarArr81;
        String[] strArr81 = {"ok", "num", "text", "store"};
        u2 = strArr81;
        e[] eVarArr82 = {eVar, eVar2, eVar2, eVar};
        v2 = eVarArr82;
        String[] strArr82 = {"ok", "text", "append"};
        w2 = strArr82;
        e[] eVarArr83 = {eVar, eVar2, eVar};
        x2 = eVarArr83;
        String[] strArr83 = {"ok", ProfileManager.EXTRA_PROFILE_NAME};
        y2 = strArr83;
        e[] eVarArr84 = {eVar, eVar2};
        z2 = eVarArr84;
        String[] strArr84 = {"ok", ProfileManager.EXTRA_PROFILE_NAME, "term"};
        A2 = strArr84;
        e[] eVarArr85 = {eVar, eVar2, eVar2};
        B2 = eVarArr85;
        String[] strArr85 = {"output", "cmd", "root", "timeout"};
        C2 = strArr85;
        e[] eVarArr86 = {eVar2, eVar2, eVar, eVar3};
        D2 = eVarArr86;
        String[] strArr86 = {"ok", "path", "quality", "delmem"};
        E2 = strArr86;
        e[] eVarArr87 = {eVar, eVar2, eVar3, eVar};
        F2 = eVarArr87;
        String[] strArr87 = {"ok", "path"};
        G2 = strArr87;
        e[] eVarArr88 = {eVar, eVar2};
        H2 = eVarArr88;
        String[] strArr88 = {"ok", "on"};
        I2 = strArr88;
        e[] eVarArr89 = {eVar, eVar};
        J2 = eVarArr89;
        String[] strArr89 = {"ok", "offradios"};
        K2 = strArr89;
        e[] eVarArr90 = {eVar, eVar2};
        L2 = eVarArr90;
        String[] strArr90 = {"ok", "hours", "mins", "msg", "confirm"};
        M2 = strArr90;
        e[] eVarArr91 = {eVar, eVar3, eVar3, eVar2, eVar};
        N2 = eVarArr91;
        String[] strArr91 = {"ok", "on"};
        O2 = strArr91;
        e[] eVarArr92 = {eVar, eVar};
        P2 = eVarArr92;
        String[] strArr92 = {null, ProfileManager.EXTRA_PROFILE_NAME, "val", "structureOutput"};
        Q2 = strArr92;
        e[] eVarArr93 = {eVar4, eVar2, eVar2, eVar};
        R2 = eVarArr93;
        String[] strArr93 = {"ok", "key", "pass"};
        S2 = strArr93;
        e[] eVarArr94 = {eVar, eVar2, eVar2};
        T2 = eVarArr94;
        String[] strArr94 = {null, ProfileManager.EXTRA_PROFILE_NAME, "val"};
        U2 = strArr94;
        e[] eVarArr95 = {eVar4, eVar2, eVar2};
        V2 = eVarArr95;
        String[] strArr95 = {"ok", "on"};
        W2 = strArr95;
        e[] eVarArr96 = {eVar, eVar};
        X2 = eVarArr96;
        String[] strArr96 = {"ok", "ID"};
        Y2 = strArr96;
        e[] eVarArr97 = {eVar, eVar2};
        Z2 = eVarArr97;
        String[] strArr97 = {"ok", "path"};
        a3 = strArr97;
        e[] eVarArr98 = {eVar, eVar2};
        b3 = eVarArr98;
        String[] strArr98 = {"ok", ProfileManager.EXTRA_PROFILE_NAME, "type", "hoff", "voff", "exit", "wait"};
        c3 = strArr98;
        String[] strArr99 = {"ok"};
        d3 = strArr99;
        e[] eVarArr99 = {eVar};
        e3 = eVarArr99;
        String[] strArr100 = {"ok", "mode"};
        f3 = strArr100;
        e[] eVarArr100 = {eVar, eVar2};
        g3 = eVarArr100;
        String[] strArr101 = {"ok", "on"};
        h3 = strArr101;
        e[] eVarArr101 = {eVar, eVar};
        i3 = eVarArr101;
        String[] strArr102 = {"ok", "on"};
        j3 = strArr102;
        e[] eVarArr102 = {eVar, eVar};
        k3 = eVarArr102;
        String[] strArr103 = {"ok", "on"};
        l3 = strArr103;
        e[] eVarArr103 = {eVar, eVar};
        m3 = eVarArr103;
        String[] strArr104 = {"ok", "mode"};
        n3 = strArr104;
        e[] eVarArr104 = {eVar, eVar2};
        o3 = eVarArr104;
        String[] strArr105 = {"ok", "src"};
        p3 = strArr105;
        e[] eVarArr105 = {eVar, eVar2};
        q3 = eVarArr105;
        String[] strArr106 = {"ok"};
        r3 = strArr106;
        e[] eVarArr106 = {eVar};
        s3 = eVarArr106;
        String[] strArr107 = {"running", ProfileManager.EXTRA_PROFILE_NAME};
        t3 = strArr107;
        e[] eVarArr107 = {eVar, eVar2};
        u3 = eVarArr107;
        String[] strArr108 = {"ok", "text", "repeat"};
        v3 = strArr108;
        e[] eVarArr108 = {eVar, eVar2, eVar3};
        w3 = eVarArr108;
        String[] strArr109 = {"ok"};
        x3 = strArr109;
        e[] eVarArr109 = {eVar};
        y3 = eVarArr109;
        String[] strArr110 = {"ok", "on"};
        z3 = strArr110;
        e[] eVarArr110 = {eVar, eVar};
        A3 = eVarArr110;
        String[] strArr111 = {null, "ms"};
        B3 = strArr111;
        e[] eVarArr111 = {eVar4, eVar3};
        C3 = eVarArr111;
        String[] strArr112 = {"ok", "offon"};
        D3 = strArr112;
        e[] eVarArr112 = {eVar, eVar2};
        E3 = eVarArr112;
        String[] strArr113 = {"ok", "on"};
        F3 = strArr113;
        e[] eVarArr113 = {eVar, eVar};
        G3 = eVarArr113;
        String[] strArr114 = {"ok", "on"};
        H3 = strArr114;
        e[] eVarArr114 = {eVar, eVar};
        I3 = eVarArr114;
        String[] strArr115 = {"ok", "path", "deleteZip"};
        J3 = strArr115;
        e[] eVarArr115 = {eVar, eVar2, eVar};
        K3 = eVarArr115;
        String[] strArr116 = {"ok", "ms"};
        L3 = strArr116;
        e[] eVarArr116 = {eVar, eVar3};
        M3 = eVarArr116;
        String[] strArr117 = {"ok", "path", "text", "append"};
        N3 = strArr117;
        e[] eVarArr117 = {eVar, eVar2, eVar2, eVar};
        O3 = eVarArr117;
        String[] strArr118 = {"ok", "path", "level", "deleteOrig"};
        P3 = strArr118;
        e[] eVarArr118 = {eVar, eVar2, eVar, eVar3};
        Q3 = eVarArr118;
        R3 = new String[]{ALARM_VOL_LABEL, "alert", AUDIO_RECORD_LABEL, "audioRecordStop", BT_VOICE_VOL_LABEL, "browseURL", "button", CALL_LABEL, CALL_BLOCK_LABEL, CALL_DIVERT_LABEL, CALL_REVERT_LABEL, CALL_VOL_LABEL, CAR_MODE_LABEL, "clearKey", "sendCommand", "composeEmail", "composeMMS", "composeSMS", "convert", "createDir", "createScene", "cropImage", DECRYPT_DIR_LABEL, DECRYPT_FILE_LABEL, "deleteDir", "deleteFile", "destroyScene", DISABLE_LABEL, DISPLAY_AUTO_BRIGHT_LABEL, DISPLAY_AUTO_ROTATE_LABEL, DISPLAY_TIMEOUT_LABEL, "dpad", DTMF_VOL_LABEL, ELEMENT_BACK_COLOUR_LABEL, ELEMENT_BORDER_LABEL, ELEMENT_POSITION_LABEL, ELEMENT_TEXT_LABEL, ELEMENT_TEXT_COLOUR_LABEL, ELEMENT_TEXT_SIZE_LABEL, ELEMENT_VISIBILITY_LABEL, END_CALL_LABEL, ENABLE_PROFILE_LABEL, ENCRYPT_DIR_LABEL, ENCRYPT_FILE_LABEL, "enterKey", "exit", "flash", "flashLong", "filterImage", "flipImage", GET_LOCATION_LABEL, "getVoice", "global", "goHome", HAPTICS_LABEL, "hideScene", "httpRequest", "listFiles", "loadApp", "loadImage", "local", LOCK_LABEL, MEDIA_CONTROL_LABEL, MEDIA_VOL_LABEL, MIC_MUTE_LABEL, MOBILE_DATA_LABEL, MUSIC_BACK_LABEL, MUSIC_PLAY_LABEL, MUSIC_SKIP_LABEL, MUSIC_STOP_LABEL, "navigationBar", NIGHT_MODE_LABEL, NOTIFICATION_VOL_LABEL, PARSE_FORMAT_DATETIME_LABEL, PERFORM_TASK_LABEL, POPUP_LABEL, PROFILE_ACTIVE_LABEL, PULSE_LABEL, "readFile", "reboot", "resizeImage", RINGER_VOL_LABEL, "rotateImage", SAVE_IMAGE_LABEL, SAY_LABEL, "scanCard", SEND_INTENT_LABEL, SEND_SMS_LABEL, SET_CLIP_LABEL, SETTINGS_LABEL, SET_AIRPLANE_MODE_LABEL, SET_AIRPLANE_RADIOS_LABEL, SET_ALARM_LABEL, SET_AUTO_SYNC_LABEL, SET_BT_LABEL, SET_BT_ID_LABEL, "setGlobal", "setKey", "setLocal", SET_WALLPAPER_LABEL, SET_WIFI_LABEL, "shell", SHOW_SCENE_LABEL, "shutdown", SILENT_MODE_LABEL, SL4A_LABEL, SOUND_EFFECTS_LABEL, SPEAKERPHONE_LABEL, STATUS_BAR_LABEL, STAY_ON_LABEL, STOP_LOCATION_LABEL, SYSTEM_LOCK_LABEL, SYSTEM_VOL_LABEL, TAKE_CALL_LABEL, TAKE_PHOTO_LABEL, TASK_RUNNING_LABEL, "type", UNZIP_LABEL, USB_TETHER_LABEL, "vibrate", VIBRATE_PATTERN_LABEL, "wait", WIFI_TETHER_LABEL, WRITE_FILE_LABEL, ZIP_LABEL};
        S3 = new e[][]{eVarArr5, eVarArr6, eVarArr7, eVarArr8, eVarArr5, eVarArr9, eVarArr10, eVarArr11, eVarArr12, eVarArr13, eVarArr14, eVarArr5, eVarArr15, eVarArr16, eVarArr23, eVarArr18, eVarArr19, eVarArr20, eVarArr17, eVarArr21, eVarArr24, eVarArr25, eVarArr26, eVarArr27, eVarArr28, eVarArr29, eVarArr30, eVarArr31, eVarArr32, eVarArr34, eVarArr33, eVarArr35, eVarArr5, eVarArr36, eVarArr37, eVarArr38, eVarArr39, eVarArr40, eVarArr41, eVarArr42, eVarArr47, eVarArr43, eVarArr44, eVarArr45, eVarArr46, eVarArr48, eVarArr73, eVarArr74, eVarArr49, eVarArr50, eVarArr, eVarArr51, eVarArr55, eVarArr52, eVarArr56, eVarArr53, eVarArr22, eVarArr57, eVarArr58, eVarArr59, eVarArr60, eVarArr61, eVarArr62, eVarArr5, eVarArr63, eVarArr64, eVarArr65, eVarArr66, eVarArr67, eVarArr68, eVarArr69, eVarArr70, eVarArr5, eVarArr3, eVarArr2, eVarArr71, eVarArr75, eVarArr72, eVarArr76, eVarArr77, eVarArr78, eVarArr5, eVarArr79, eVarArr87, eVarArr80, eVarArr88, eVarArr81, eVarArr82, eVarArr83, eVarArr84, eVarArr89, eVarArr90, eVarArr91, eVarArr92, eVarArr96, eVarArr97, eVarArr93, eVarArr94, eVarArr95, eVarArr98, eVarArr114, eVarArr86, eVarArr4, eVarArr99, eVarArr100, eVarArr85, eVarArr101, eVarArr102, eVarArr103, eVarArr104, eVarArr105, eVarArr106, eVarArr5, eVarArr109, eVarArr54, eVarArr107, eVarArr108, eVarArr115, eVarArr110, eVarArr111, eVarArr112, eVarArr116, eVarArr113, eVarArr117, eVarArr118};
        T3 = new String[][]{strArr, strArr2, strArr3, strArr4, strArr, strArr5, strArr6, strArr7, strArr8, strArr9, strArr10, strArr, strArr11, strArr12, strArr19, strArr14, strArr15, strArr16, strArr13, strArr17, strArr20, strArr21, strArr22, strArr23, strArr24, strArr25, strArr26, strArr27, strArr28, strArr30, strArr29, strArr31, strArr, strArr32, strArr33, strArr34, strArr35, strArr36, strArr37, strArr38, strArr43, strArr39, strArr40, strArr41, strArr42, strArr44, strArr72, strArr73, strArr45, strArr46, strArr47, strArr48, strArr54, strArr49, strArr55, strArr50, strArr18, strArr56, strArr57, strArr58, strArr59, strArr60, strArr61, strArr, strArr62, strArr63, strArr64, strArr65, strArr66, strArr67, strArr68, strArr69, strArr, strArr52, strArr51, strArr70, strArr74, strArr71, strArr75, strArr76, strArr77, strArr, strArr78, strArr86, strArr79, strArr87, strArr80, strArr81, strArr82, strArr83, strArr88, strArr89, strArr90, strArr91, strArr95, strArr96, strArr92, strArr93, strArr94, strArr97, strArr114, strArr85, strArr98, strArr99, strArr100, strArr84, strArr101, strArr102, strArr103, strArr104, strArr105, strArr106, strArr, strArr109, strArr53, strArr107, strArr108, strArr115, strArr110, strArr111, strArr112, strArr116, strArr113, strArr117, strArr118};
        U3 = null;
        V3 = new String[]{"", "str", "int", "bool", "str[]"};
        W3 = null;
    }

    public c6(Context context, int i, String str, int i4, WebView webView, WebChromeClientCommon webChromeClientCommon, Bundle bundle, Handler handler, com.joaomgcd.taskerm.util.c<Pair<String, String>> cVar, com.joaomgcd.taskerm.util.c<Bundle> cVar2) {
        this.e = context;
        this.f = handler;
        this.g = webView;
        this.h = bundle;
        this.i = webChromeClientCommon;
        this.m = i;
        this.n = i4;
        this.o = str;
        this.b = "JSI" + i;
        this.c = cVar;
        this.d = cVar2;
        MyWebView.d(this.g);
    }

    public static void A(Context context, String str) {
        com.joaomgcd.taskerm.toast.d.e(context, str, 0).show();
    }

    public void B(String str) {
        com.joaomgcd.taskerm.toast.d.e(j(), str, 1).show();
    }

    private static String C(String str) {
        return "tk." + str + "(";
    }

    private static int D(String str, List<String> list) {
        int i = 0;
        int i4 = 0;
        int i5 = 0;
        char c4 = 65535;
        char c5 = 65535;
        int i6 = 0;
        char c6 = 65535;
        while (true) {
            if (i >= str.length()) {
                break;
            }
            char charAt = str.charAt(i);
            i4++;
            if (charAt == '(') {
                if (i5 == 0) {
                    i6 = i + 1;
                }
                i5++;
            } else if (i5 == 0) {
                if (!Character.isWhitespace(charAt)) {
                    r7.f("JSI", "non-whitespace before open bracket");
                    break;
                }
            } else if (charAt == '\"' && c4 != '\\') {
                if (c5 != '\"') {
                    if (c5 == 65535) {
                        i6 = i + 1;
                        c5 = '\"';
                        c6 = '\"';
                    }
                }
                c5 = 65535;
            } else if (charAt == '\'' && c4 != '\\') {
                if (c5 != '\'') {
                    if (c5 == 65535) {
                        i6 = i + 1;
                        c5 = '\'';
                        c6 = '\'';
                    }
                }
                c5 = 65535;
            } else if (charAt == ',') {
                if (c5 == 65535) {
                    String trim = str.substring(i6, i).trim();
                    if (trim.charAt(trim.length() - 1) == c6) {
                        trim = trim.substring(0, trim.length() - 1);
                    }
                    list.add(trim.trim());
                    i6 = i + 1;
                }
            } else if (charAt == ')' && c5 == 65535 && i5 - 1 == 0) {
                String trim2 = str.substring(i6, i).trim();
                if (trim2.charAt(trim2.length() - 1) == c6) {
                    trim2 = trim2.substring(0, trim2.length() - 1);
                }
                list.add(trim2.trim());
            }
            i++;
            c4 = charAt;
        }
        return i4;
    }

    private static String E(String str) {
        return str == null ? "" : str.replaceAll("\\\\", "\\\\\\\\").replaceAll("\n", "\\\\n").replaceAll("'", "\\\\'").replaceAll("\\\"", "\\\\\"").replace("</script>", "<' + '/script>").replace("\r", "");
    }

    private final boolean F(net.dinglisch.android.taskerm.c cVar) {
        return G(cVar, 60000L);
    }

    private final boolean G(net.dinglisch.android.taskerm.c cVar, long j) {
        return "true".equals(J(cVar, j, true));
    }

    private final String H(net.dinglisch.android.taskerm.c cVar) {
        return J(cVar, 60000L, false);
    }

    private final String I(net.dinglisch.android.taskerm.c cVar, long j) {
        return J(cVar, j, false);
    }

    private final String J(net.dinglisch.android.taskerm.c cVar, long j, boolean z4) {
        int indexOf;
        this.a.close();
        this.q = null;
        f fVar = f.Waiting;
        this.p = fVar;
        r7.f(this.b, "sendAction: " + cVar.getName() + " timeoutMS: " + j);
        String str = TASK_NAME_PREFIX + this.m + ConstantsCommonTaskerServer.ID_SEPARATOR + Long.toString(new Random().nextInt());
        b bVar = new b(str);
        ExtensionsContextKt.V2(j(), bVar, TaskerIntent.c(str));
        tn X12 = to.X1();
        X12.G(str);
        X12.D2(this.n + 2);
        X12.a0(cVar);
        String str2 = this.o;
        if (str2 != null && (indexOf = str2.indexOf(ConstantsCommonTaskerServer.ID_SEPARATOR)) != -1) {
            kq.r1(this.o.substring(0, indexOf), this.h);
        }
        ExecuteService.d6(j(), X12, 5, -1, -1, -1, null, kq.t0(this.h), this.o, this.h);
        this.a.block(j);
        dq.K3(j(), bVar);
        if (this.p == fVar) {
            this.p = f.Failure;
            synchronized (this.l) {
                try {
                    if (!K()) {
                        this.g.post(new c());
                    }
                } finally {
                }
            }
        }
        if (this.p == f.Success) {
            return z4 ? "true" : this.q == null ? "" : this.q;
        }
        if (z4) {
            return "false";
        }
        return null;
    }

    private boolean K() {
        return this.j;
    }

    private boolean L(String str, int i, int i4, boolean z4, boolean z5) {
        if (!r(str)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(i);
        cVar.s1(0, i4);
        cVar.m1(1, z4);
        cVar.m1(2, z5);
        return F(cVar);
    }

    public static final String[] _getImplementedActionDefinitions() {
        int length = R3.length;
        String[] strArr = new String[length];
        for (int i = 0; i < length; i++) {
            StringBuilder sb = new StringBuilder();
            e[] eVarArr = S3[i];
            String[] strArr2 = T3[i];
            String[] strArr3 = R3;
            sb.append(strArr3[i]);
            sb.append("\n");
            if (eVarArr[0] != e.None) {
                sb.append('[');
                sb.append(V3[eVarArr[0].ordinal()]);
                sb.append(' ');
                sb.append(strArr2[0]);
                sb.append("] ");
            }
            sb.append("(");
            r7.f("JSI", strArr3[i]);
            for (int i4 = 1; i4 < eVarArr.length; i4++) {
                if (i4 != 1) {
                    sb.append(", ");
                }
                sb.append(V3[eVarArr[i4].ordinal()]);
                sb.append(' ');
                sb.append(strArr2[i4]);
            }
            sb.append(")");
            strArr[i] = sb.toString();
        }
        return strArr;
    }

    public static void flashErrorBundle(Context context, Bundle bundle) {
        String str = vh.g(context, 2131886415, new Object[0]) + ": line " + bundle.getInt("l") + ": " + bundle.getString("m");
        dq.d0(context, str, new Object[0]);
        r7.k("JSI", str);
    }

    public static String formatConsoleMessageForLog(Context context, Bundle bundle) {
        return "line " + bundle.getInt("l") + ": " + bundle.getString("m");
    }

    public static HashMap<String, Integer> getArrayNames(Bundle bundle) {
        HashMap<String, Integer> hashMap = new HashMap<>();
        for (String str : bundle.keySet()) {
            if (kq.V0(str)) {
                String Y12 = kq.Y1(str);
                int parseInt = Integer.parseInt(str.substring(Y12.length()));
                if (bundle.containsKey(Y12)) {
                    r7.f("JSI", "getArrayNames: ignore array index, have base simple variable");
                } else {
                    int intValue = hashMap.containsKey(Y12) ? hashMap.get(Y12).intValue() : 0;
                    if (parseInt <= intValue) {
                        parseInt = intValue;
                    }
                    hashMap.put(Y12, Integer.valueOf(parseInt));
                }
            }
        }
        return hashMap;
    }

    public static List<List<String>> getFunctionArgs(String str, String str2, int i) {
        int indexOf;
        ArrayList arrayList = new ArrayList();
        try {
            int length = str2.length();
            int i4 = 0;
            while (i4 < str.length() && (indexOf = str.indexOf(str2, i4)) != -1 && indexOf < str.length()) {
                int i5 = indexOf + length;
                ArrayList arrayList2 = new ArrayList();
                int D4 = D(str.substring(i5), arrayList2);
                if (arrayList2.size() >= i) {
                    arrayList.add(arrayList2);
                } else {
                    r7.f("JSI", "func " + str2 + " expected min" + i + " args, got " + arrayList2.size());
                }
                i4 = i5 + length + D4;
            }
        } catch (Exception e4) {
            r7.H("JSI", "exception parsing JS", e4);
            r7.G("JSI", str);
        }
        return arrayList;
    }

    public static String getFunctionLabel(int i) {
        return R3[i];
    }

    public static int getFunctionNoArgs(int i) {
        return S3[i].length - 1;
    }

    public static String getFunctionTemplate(int i) {
        StringBuilder sb = new StringBuilder();
        sb.append(R3[i]);
        sb.append('(');
        for (int i4 = 1; i4 < S3[i].length; i4++) {
            if (i4 != 1) {
                sb.append(',');
            }
            sb.append(" ");
        }
        sb.append(");");
        return sb.toString();
    }

    public static String[] getLibraryLabels() {
        return r;
    }

    public static String getLibraryTemplate() {
        int ordinal;
        StringBuilder sb = new StringBuilder();
        sb.append("// v");
        sb.append(1);
        sb.append(" tv");
        sb.append("6.5.11");
        sb.append('\n');
        int i = 0;
        while (true) {
            String[] strArr = R3;
            if (i >= strArr.length) {
                return sb.toString();
            }
            e[] eVarArr = S3[i];
            String str = strArr[i];
            sb.append("function");
            sb.append(' ');
            sb.append(str);
            sb.append('(');
            for (int i4 = 1; i4 < eVarArr.length; i4++) {
                if (i4 != 1) {
                    sb.append(",");
                }
                sb.append("a");
                sb.append(i4);
            }
            sb.append("){");
            e eVar = eVarArr[0];
            if (eVar != e.None && (ordinal = eVar.ordinal()) != 0) {
                if (ordinal != 1) {
                    if (ordinal == 2) {
                        sb.append("return");
                        sb.append(' ');
                        sb.append(0);
                        sb.append(';');
                    } else if (ordinal == 3) {
                        sb.append("return");
                        sb.append(' ');
                        sb.append("true");
                        sb.append(';');
                    } else if (ordinal != 4) {
                        r7.k("JSI", "unknown return type " + eVarArr[0]);
                    } else {
                        r7.k("JSI", "getLibTemplate: JSI doesn't support str[] returns");
                    }
                } else if (str.equals("global")) {
                    sb.append("if(a1=='");
                    sb.append(kq.Z1(kq.I0(71)));
                    sb.append("'||a1=='");
                    sb.append(kq.I0(71));
                    sb.append("'){return '0';}else{return ' ';}");
                } else {
                    sb.append("return");
                    sb.append(" ' '");
                    sb.append(';');
                }
            }
            sb.append("}\n");
            i++;
        }
    }

    public static String getLibraryURL(int i) {
        return s[i];
    }

    public static List<String> getMatchingArgs(String str, String str2, int i, int i4, String str3) {
        Pattern compile = Pattern.compile(str3);
        ArrayList arrayList = null;
        for (List<String> list : getFunctionArgs(str, str2, i)) {
            if (list.size() >= i4 - 1) {
                String str4 = list.get(i4);
                if (compile.matcher(str4).matches()) {
                    if (arrayList == null) {
                        arrayList = new ArrayList();
                    }
                    arrayList.add(str4);
                }
            }
        }
        return arrayList;
    }

    public static int getNoArgs(e[] eVarArr) {
        return eVarArr.length - 1;
    }

    public static String getScriptFromAction(Context context, net.dinglisch.android.taskerm.c cVar, Bundle bundle) {
        String X3;
        if (cVar.j() == 129) {
            return cVar.N(0).w();
        }
        if (cVar.R0()) {
            return cVar.z0();
        }
        String N4 = kq.N(context, cVar.N(0).w(), bundle);
        if (Kid.b(context)) {
            X3 = vh.a(context.getResources(), "kid/js" + File.separator + Kid.h(N4));
        } else {
            X3 = dq.X(new File(dq.E2(N4)));
        }
        if (X3 == null) {
            return X3;
        }
        cVar.w1(X3);
        return X3;
    }

    public static String getWrappedBuiltinFunctions(String str) {
        StringBuilder sb = new StringBuilder();
        sb.append("<script type=\"text/javascript\">");
        o(str, R3, S3, sb);
        sb.append("</script>");
        return sb.toString();
    }

    public static void initWebSettings(WebView webView, boolean z4) {
        WebSettings settings = webView.getSettings();
        settings.setJavaScriptEnabled(true);
        settings.setJavaScriptCanOpenWindowsAutomatically(true);
        if (yd.a1.c()) {
            yd.a1.g(settings, WebSettings.PluginState.ON);
        }
        settings.setAllowContentAccess(true);
        if (yd.a1.b()) {
            yd.a1.f(settings, z4);
        }
    }

    public Context j() {
        return this.e;
    }

    private static void k(StringBuilder sb, String str, int i, Bundle bundle) {
        sb.append("var ");
        sb.append(kq.Z1(str));
        sb.append(" = [");
        for (int i4 = 1; i4 <= i; i4++) {
            String str2 = str + i4;
            String E4 = bundle.containsKey(str2) ? E(bundle.getString(str2)) : "undefined";
            if (i4 != 1) {
                sb.append(',');
            }
            sb.append('\'');
            sb.append(E4);
            sb.append('\'');
        }
        sb.append("]; ");
    }

    private static void l(StringBuilder sb, String str) {
        String Z12 = kq.Z1(str);
        String str2 = Z12 + "[ZWQDR]";
        String str3 = str + "'+(ZWQDR+1)";
        sb.append("if(");
        sb.append("typeof ");
        sb.append(Z12);
        sb.append("==\"object\" &&");
        sb.append(Z12);
        sb.append(" instanceof Array");
        sb.append("){");
        sb.append("for(ZWQDR=0;ZWQDR<" + Z12 + ".length;ZWQDR++){ ");
        sb.append("if(window['" + Z12 + "'+(ZWQDR+1)])  continue;");
        sb.append("if(" + str2 + "!=undefined && " + str2 + "!='undefined'){");
        sb.append(C("setLocal") + "'" + str3 + "," + str2 + ");");
        sb.append("}else{");
        StringBuilder sb2 = new StringBuilder();
        sb2.append(C("_clearLocal"));
        sb2.append("'");
        sb2.append(str3);
        sb2.append(");");
        sb.append(sb2.toString());
        sb.append('}');
        sb.append('}');
        sb.append('}');
    }

    public static boolean loadDirect(WebView webView, String str) {
        try {
            webView.loadDataWithBaseURL("file://", str, "text/html", "utf-8", null);
            return true;
        } catch (Throwable th2) {
            r7.I("JSI", "loadDirect", th2);
            return false;
        }
    }

    private static int m(int i, int i4, int i5, int i6) {
        return (i < i4 || i > i5) ? i6 : i;
    }

    private String n(String str) {
        return (str == null || str.equals("undefined")) ? "" : str;
    }

    private static void o(String str, String[] strArr, e[][] eVarArr, StringBuilder sb) {
        char c4 = 0;
        boolean z4 = str != null && str.contains("eval(");
        int length = strArr.length;
        int i = 0;
        int i4 = 0;
        while (i < length) {
            String str2 = strArr[i];
            if (str == null || str.contains(str2) || z4) {
                sb.append("var");
                sb.append(' ');
                sb.append(str2);
                sb.append('=');
                int length2 = eVarArr[i4].length;
                sb.append("function(");
                for (int i5 = 1; i5 < length2; i5++) {
                    if (i5 != 1) {
                        sb.append(",");
                    }
                    sb.append("a");
                    sb.append(i5);
                }
                sb.append(")");
                sb.append("{");
                if (eVarArr[i4][c4] != e.None) {
                    sb.append("return");
                    sb.append(' ');
                }
                sb.append(C(str2));
                for (int i6 = 1; i6 < length2; i6++) {
                    if (i6 != 1) {
                        sb.append(",");
                    }
                    sb.append("a");
                    sb.append(i6);
                }
                sb.append(")");
                sb.append("}");
                sb.append(";");
            }
            i4++;
            i++;
            c4 = 0;
        }
    }

    private boolean p(String str, int i) {
        if (r(str)) {
            return F(new net.dinglisch.android.taskerm.c(i));
        }
        return false;
    }

    private boolean q(String str, int i, int i4, boolean z4) {
        if (!r(str)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(i);
        if (i == 512) {
            cVar.s1(i4, !z4 ? 1 : 0);
        } else {
            cVar.l1(i4, z4 ? 1 : 0);
        }
        return F(cVar);
    }

    private boolean r(String str) {
        r7.f(this.b, "func: " + str + " stopping: " + this.j + " stopped: " + this.k);
        return !K();
    }

    public static c6 runPureScript(Context context, int i, String str, int i4, boolean z4, String str2, String str3, Bundle bundle, Handler handler) {
        WebView webView;
        kg.w0.J(null, bundle, false);
        String wrapScript = wrapScript(context, str2, true, str3, z4, bundle);
        if (wrapScript == null) {
            r7.G("JSI", "runPureScript: wrap script failed");
            return null;
        }
        r7.f("JSI" + i, "wrapped script\n" + wrapScript);
        try {
            webView = new WebView(context.getApplicationContext());
        } catch (Exception e4) {
            r7.H("JSI", "runPureScript", e4);
            webView = null;
        }
        if (webView == null) {
            return null;
        }
        webView.getSettings().setAllowFileAccess(true);
        WebChromeClientCommon z5 = z(context, i, handler);
        webView.setWebChromeClient(z5);
        initWebSettings(webView, true);
        c6 c6Var = new c6(context, i, str, i4, webView, z5, bundle, handler, null, null);
        webView.addJavascriptInterface(c6Var, TASKER_OBJECT_NAME);
        if (loadDirect(webView, wrapScript)) {
            return c6Var;
        }
        return null;
    }

    private int s(String str, String str2) {
        if ("gps".matches(str2)) {
            return 0;
        }
        if ("net".matches(str2)) {
            return 1;
        }
        if ("any".matches(str2)) {
            return 2;
        }
        r7.G("JSI", str + ": bad source: " + str2);
        return -1;
    }

    public static void scanCodeForVariables(String str, Set<String> set, boolean z4, boolean z5, boolean z6) {
        if (U3 == null) {
            U3 = Pattern.compile("(?<=global\\(\\s{0,5}[\"']%?)[\\w&&[^_]][\\w0-9\\.]+[\\w0-9&&[^_]](?=['\"])");
        }
        if (z4) {
            kq.t(U3, str, false);
        } else {
            kq.m(U3, str, set, z5, z6);
        }
    }

    public static boolean scriptHasDialogs(String str) {
        return false;
    }

    public static boolean scriptHasFunction(String str, String str2) {
        return Pattern.compile(str2 + "\\s*\\(").matcher(str).find();
    }

    public static boolean scriptHasFunctionWithMatchingArg(String str, String str2, int i, int i4, String str3) {
        return getMatchingArgs(str, str2, i, i4, str3) != null;
    }

    public static void sendMessageWithID(Handler handler, int i, int i4) {
        Message obtainMessage = handler.obtainMessage();
        obtainMessage.what = i;
        Bundle bundle = new Bundle();
        bundle.putInt(EXTRA_ID, i4);
        obtainMessage.setData(bundle);
        handler.sendMessage(obtainMessage);
    }

    private static int t(String str, String str2, String str3) {
        if ("undefined".equals(str)) {
            str = str2;
        }
        String[] strArr = a1.e;
        int v32 = dq.v3(str, strArr);
        if (v32 != -1) {
            return v32;
        }
        r7.G("JSI", str3 + ": unknown stream: " + str);
        return dq.v3(str2, strArr);
    }

    private static Set<String> u(String str) {
        return w(str, "(?:[\\s;}{]|^)var\\s+([\\w&&[^_]][\\w0-9\\.]+[\\w0-9&&[^_]])\\s*=\\s*(?:new\\s+Array\\s*\\(|\\[)");
    }

    private static Set<String> v(String str) {
        return w(str, "(?:[\\s;}{]|^)var\\s+([\\w&&[^_]][\\w0-9\\.]+[\\w0-9&&[^_]])");
    }

    private static Set<String> w(String str, String str2) {
        HashSet hashSet = new HashSet();
        Matcher matcher = Pattern.compile(str2, 0).matcher(str);
        while (matcher.find()) {
            String group = matcher.group(1);
            if (kq.W0("%" + group)) {
                hashSet.add(group);
            } else {
                r7.f("JSI", "getUserScriptVarsAux: ignoring local var name: " + group);
            }
        }
        return hashSet;
    }

    public static String wrapScript(Context context, String str, boolean z4, String str2, boolean z5, Bundle bundle) {
        StringBuilder sb = new StringBuilder();
        StringBuilder sb2 = new StringBuilder();
        StringBuilder sb3 = new StringBuilder();
        HashMap<String, Integer> arrayNames = getArrayNames(bundle);
        if (arrayNames.size() > 0) {
            for (Map.Entry<String, Integer> entry : arrayNames.entrySet()) {
                String key = entry.getKey();
                if (str.contains(kq.Z1(key))) {
                    k(sb, key, entry.getValue().intValue(), bundle);
                    l(sb2, key);
                }
            }
        }
        for (String str3 : bundle.keySet()) {
            if (str3 == null) {
                r7.k("JSI", "wrapScript: ignoring null name on local var list");
            } else if (!kq.V0(str3) && str.contains(kq.Z1(str3))) {
                sb.append(x(context, str3, bundle));
                sb2.append(y(str3));
            }
        }
        Set<String> u4 = u(str);
        Iterator<String> it = v(str).iterator();
        while (it.hasNext()) {
            sb3.append(y("%" + it.next()));
        }
        Iterator<String> it2 = u4.iterator();
        while (it2.hasNext()) {
            l(sb3, "%" + it2.next());
        }
        StringBuilder sb4 = new StringBuilder();
        int i = 0;
        if (!TextUtils.isEmpty(str2)) {
            String[] split = str2.split("\n");
            if (!dq.r(split)) {
                int length = split.length;
                int i4 = 0;
                while (i < length) {
                    String trim = split[i].trim();
                    if (trim.startsWith(File.separator)) {
                        trim = "file://" + trim;
                    }
                    Uri parse = Uri.parse(trim);
                    File file = dq.J2(parse, "file") ? new File(parse.getPath()) : null;
                    if (file == null) {
                        sb4.append("<script type=\"text/javascript\" src=\"");
                        sb4.append(trim);
                        sb4.append("\"></script>");
                    } else {
                        if (!file.exists()) {
                            r7.G("JSI", "wrapScript: non-existing library file: " + trim);
                            return null;
                        }
                        String X3 = dq.X(file);
                        if (X3 == null) {
                            r7.G("JSI", "wrapScript: failed to read library from " + file);
                            return null;
                        }
                        sb4.append("<script type=\"text/javascript\">");
                        sb4.append(X3);
                        sb4.append("</script>");
                    }
                    i++;
                    i4 = 1;
                }
                i = i4;
            }
        }
        StringBuilder sb5 = new StringBuilder();
        o(i == 0 ? str : null, R3, S3, sb5);
        if (sb5.length() > 0) {
            sb4.append("<script type=\"text/javascript\">");
            sb4.append((CharSequence) sb5);
            sb4.append("</script>");
        }
        sb4.append("<script type=\"text/javascript\">");
        if (z4) {
            sb4.append("try{");
            sb4.append((CharSequence) sb);
            sb4.append(str);
            sb4.append(";\n}finally{");
            sb4.append((CharSequence) sb3);
            sb4.append((CharSequence) sb2);
            if (z5) {
                sb4.append(C("exit") + ");");
            }
            sb4.append("}");
        } else {
            sb4.append((CharSequence) sb5);
        }
        sb4.append("</script>");
        return sb4.toString();
    }

    private static String x(Context context, String str, Bundle bundle) {
        return "var " + kq.Z1(str) + " = '" + E(kq.y0(context, str, bundle)) + "'; ";
    }

    private static String y(String str) {
        String Z12 = kq.Z1(str);
        String str2 = "'" + str + "'";
        return "if(typeof " + Z12 + "!=\"undefined\" &&(typeof " + Z12 + "!=\"object\"||" + Z12 + "==null||(!(" + Z12 + " instanceof Array)))){if(" + Z12 + "==undefined){" + C("_clearLocal") + str2 + ");}else{" + C("setLocal") + str2 + ',' + Z12 + ");}}";
    }

    private static WebChromeClientCommon z(Context context, int i, Handler handler) {
        WebChromeClientCommon webChromeClientCommon = new WebChromeClientCommon(context);
        webChromeClientCommon.setHandler(new a(handler, i));
        return webChromeClientCommon;
    }

    @JavascriptInterface
    public void _clearLocal(String str) {
        r("_clearLocal");
        if (!str.startsWith("%")) {
            str = "%" + str;
        }
        r7.f(this.b, "_clearLocal: " + str);
        this.h.remove(str);
    }

    public Handler _getHandler() {
        return this.f;
    }

    public Bundle _getLocalVars() {
        return this.h;
    }

    public WebView _getWebView() {
        return this.g;
    }

    public void _stop() {
        synchronized (this.l) {
            try {
                if (!this.k) {
                    this.j = true;
                    r7.f(this.b, "stop");
                    for (int i = 0; i <= 4; i++) {
                        Handler handler = this.f;
                        if (handler != null) {
                            handler.removeMessages(i);
                        }
                    }
                    WebView webView = this.g;
                    if (webView != null) {
                        webView.stopLoading();
                    }
                    this.a.open();
                    WebChromeClientCommon webChromeClientCommon = this.i;
                    if (webChromeClientCommon != null) {
                        webChromeClientCommon.destroy();
                    }
                    MyActivity.unbindAllReferences(this.g);
                    WebView webView2 = this.g;
                    if (webView2 != null) {
                        webView2.removeJavascriptInterface(TASKER_OBJECT_NAME);
                        this.g = null;
                    }
                    this.e = null;
                    this.f = null;
                    this.h = null;
                    this.i = null;
                    this.k = true;
                }
            } catch (Throwable th2) {
                throw th2;
            }
        }
        r7.f(this.b, "stop() finished");
    }

    @JavascriptInterface
    public boolean alarmVol(int i, boolean z4, boolean z5) {
        return L(ALARM_VOL_LABEL, 303, i, z4, z5);
    }

    @JavascriptInterface
    public String alert(String str, String str2, String str3, String str4, String str5, int i, boolean z4) {
        if (!r("alert")) {
            return null;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(377);
        String n = n(str2);
        if (TextUtils.isEmpty(n)) {
            n = ExtensionsContextKt.Z(j());
        }
        String n4 = n(str3);
        if (TextUtils.isEmpty(n4)) {
            n4 = "OK";
        }
        cVar.k0(1, n);
        cVar.k0(2, n(str));
        cVar.k0(3, n4);
        cVar.k0(4, n(str4));
        cVar.k0(5, n(str5));
        cVar.s1(6, i);
        cVar.m1(7, z4);
        return H(cVar);
    }

    @JavascriptInterface
    public boolean audioRecord(String str, String str2, String str3, String str4) {
        if (!r(AUDIO_RECORD_LABEL)) {
            return false;
        }
        int v32 = dq.v3(str2, a1.p);
        int v33 = dq.v3(str3, a1.k);
        int v34 = dq.v3(str4, a1.n);
        if (v32 == -1) {
            r7.G("JSI", "audioRecord: bad source: " + str2);
            return false;
        }
        if (v33 == -1) {
            r7.G("JSI", "audioRecord: bad codec: " + str3);
            return false;
        }
        if (v34 == -1) {
            r7.G("JSI", "audioRecord: bad format: " + str4);
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(455);
        cVar.k0(0, str);
        cVar.s1(1, v32);
        cVar.s1(3, v33);
        cVar.s1(4, v34);
        cVar.s1(2, 0);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean audioRecordStop() {
        if (r("audioRecordStop")) {
            return F(new net.dinglisch.android.taskerm.c(657));
        }
        return false;
    }

    @JavascriptInterface
    public boolean browseURL(String str) {
        if (!r("browseURL")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(104);
        cVar.k0(0, n(str));
        return F(cVar);
    }

    @JavascriptInterface
    public boolean btVoiceVol(int i, boolean z4, boolean z5) {
        return L(BT_VOICE_VOL_LABEL, 311, i, z4, z5);
    }

    @JavascriptInterface
    public boolean button(String str) {
        if (!r("button")) {
            return false;
        }
        int v32 = dq.v3(str, a1.f);
        if (v32 != -1) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(703);
            cVar.s1(0, v32);
            return F(cVar);
        }
        r7.G("JSI", "button: unknown button: " + str);
        return false;
    }

    @JavascriptInterface
    public boolean call(String str, boolean z4) {
        if (!r(CALL_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(90);
        cVar.k0(0, str);
        cVar.m1(1, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean callBlock(String str, boolean z4) {
        if (!r(CALL_BLOCK_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(95);
        cVar.k0(0, n(str));
        cVar.m1(1, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean callDivert(String str, String str2, boolean z4) {
        if (!r(CALL_DIVERT_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(97);
        cVar.k0(0, n(str));
        cVar.k0(1, n(str2));
        cVar.m1(2, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean callRevert(String str) {
        if (!r(CALL_REVERT_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(99);
        cVar.k0(0, n(str));
        cVar.m1(1, false);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean callVol(int i, boolean z4, boolean z5) {
        return L(CALL_VOL_LABEL, 306, i, z4, z5);
    }

    @JavascriptInterface
    public boolean carMode(boolean z4) {
        return q(CAR_MODE_LABEL, 988, 0, z4);
    }

    @JavascriptInterface
    public final boolean clearKey(String str) {
        return false;
    }

    @JavascriptInterface
    public final boolean composeEmail(String str, String str2, String str3) {
        if (!r("composeEmail")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(125);
        cVar.k0(0, n(str));
        cVar.k0(1, n(str2));
        cVar.k0(2, n(str3));
        return F(cVar);
    }

    @JavascriptInterface
    public final boolean composeMMS(String str, String str2, String str3, String str4) {
        if (!r("composeMMS")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(111);
        cVar.k0(0, n(str));
        cVar.k0(1, n(str2));
        cVar.k0(2, n(str3));
        cVar.k0(3, n(str4));
        return F(cVar);
    }

    @JavascriptInterface
    public final boolean composeSMS(String str, String str2) {
        if (!r("composeSMS")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(250);
        cVar.k0(0, n(str));
        cVar.k0(1, n(str2));
        return F(cVar);
    }

    @JavascriptInterface
    public final String convert(String str, String str2) {
        String str3;
        str3 = "undefined";
        if (r("convert")) {
            this.h.putString("%rer8ewhckxke", str);
            int v32 = dq.v3(str2, a1.J);
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(596);
            cVar.k0(0, "%rer8ewhckxke");
            cVar.s1(1, v32);
            cVar.k0(2, "");
            String H4 = H(cVar);
            str3 = H4 != null ? H4 : "undefined";
            this.h.remove("%rer8ewhckxke");
        }
        return str3;
    }

    @JavascriptInterface
    public boolean createDir(String str, boolean z4, boolean z5) {
        if (!r("createDir")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(409);
        cVar.k0(0, str);
        cVar.m1(1, z4);
        cVar.m1(2, z5);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean createScene(String str) {
        if (!r("createScene")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(46);
        cVar.k0(0, str);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean cropImage(int i, int i4, int i5, int i6) {
        if (!r("cropImage")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(189);
        cVar.s1(3, i6);
        cVar.s1(0, i);
        cVar.s1(1, i4);
        cVar.s1(2, i5);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean decryptDir(String str, String str2, boolean z4) {
        return false;
    }

    @JavascriptInterface
    public boolean decryptFile(String str, String str2, boolean z4) {
        return false;
    }

    @JavascriptInterface
    public boolean deleteDir(String str, boolean z4, boolean z5) {
        if (!r("deleteDir")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(408);
        cVar.k0(0, str);
        cVar.m1(1, z4);
        cVar.m1(2, z5);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean deleteFile(String str, int i, boolean z4) {
        if (!r("deleteFile")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(406);
        cVar.k0(0, str);
        cVar.s1(1, i);
        cVar.m1(2, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public void destroyScene(String str) {
        if (r("destroyScene")) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(49);
            cVar.k0(0, str);
            F(cVar);
        }
    }

    @JavascriptInterface
    public boolean disable() {
        return p(DISABLE_LABEL, 139);
    }

    @JavascriptInterface
    public boolean displayAutoBright(boolean z4) {
        return q(DISPLAY_AUTO_BRIGHT_LABEL, 808, 0, z4);
    }

    @JavascriptInterface
    public boolean displayAutoRotate(boolean z4) {
        return q(DISPLAY_AUTO_ROTATE_LABEL, 822, 0, z4);
    }

    @JavascriptInterface
    public boolean displayTimeout(int i, int i4, int i5) {
        if (!r(DISPLAY_TIMEOUT_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(812);
        cVar.s1(2, i);
        cVar.s1(1, i4);
        cVar.s1(0, i5);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean dpad(String str, int i) {
        if (!r("dpad")) {
            return false;
        }
        int v32 = dq.v3(str, a1.g);
        if (v32 != -1) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(701);
            cVar.s1(0, v32);
            cVar.s1(1, i);
            return F(cVar);
        }
        r7.G("JSI", "dpad: bad dir: " + str);
        return false;
    }

    @JavascriptInterface
    public boolean dtmfVol(int i, boolean z4, boolean z5) {
        return L(DTMF_VOL_LABEL, 309, i, z4, z5);
    }

    @JavascriptInterface
    public boolean elemBackColour(String str, String str2, String str3, String str4) {
        if (!r(ELEMENT_BACK_COLOUR_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(55);
        cVar.k0(0, str);
        cVar.k0(1, str2);
        cVar.k0(2, n(str3));
        cVar.k0(3, n(str4));
        return F(cVar);
    }

    @JavascriptInterface
    public boolean elemBorder(String str, String str2, int i, String str3) {
        if (!r(ELEMENT_BORDER_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(56);
        cVar.k0(0, str);
        cVar.k0(1, str2);
        cVar.s1(2, i);
        cVar.k0(3, n(str3));
        return F(cVar);
    }

    @JavascriptInterface
    public boolean elemPosition(String str, String str2, String str3, int i, int i4, int i5) {
        if (!r(ELEMENT_POSITION_LABEL)) {
            return false;
        }
        int i6 = "port".equals(str3) ? 0 : "land".equals(str3) ? 1 : -1;
        if (i6 == -1) {
            r7.G("JSI", "elemPosition: bad orientation: " + str3 + ", expected port or land");
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(57);
        cVar.k0(0, str);
        cVar.k0(1, str2);
        cVar.s1(2, i6);
        cVar.s1(3, i);
        cVar.s1(4, i4);
        cVar.s1(5, i5);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean elemText(String str, String str2, String str3, String str4) {
        if (!r(ELEMENT_TEXT_LABEL)) {
            return false;
        }
        int v32 = dq.v3(str3, jl.Q);
        if (v32 == -1) {
            r7.G("JSI", "elemText: bad pos: " + str3);
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(51);
        cVar.k0(0, str);
        cVar.k0(1, str2);
        cVar.k0(3, n(str4));
        cVar.s1(2, v32);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean elemTextColour(String str, String str2, String str3) {
        if (!r(ELEMENT_TEXT_COLOUR_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(54);
        cVar.k0(0, str);
        cVar.k0(1, str2);
        cVar.k0(2, n(str3));
        return F(cVar);
    }

    @JavascriptInterface
    public boolean elemTextSize(String str, String str2, int i) {
        if (!r(ELEMENT_TEXT_SIZE_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(71);
        cVar.k0(0, str);
        cVar.k0(1, str2);
        cVar.s1(2, i);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean elemVisibility(String str, String str2, boolean z4, int i) {
        if (!r(ELEMENT_VISIBILITY_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(65);
        cVar.k0(0, str);
        cVar.k0(1, str2);
        cVar.l1(2, z4 ? 1 : 0);
        cVar.s1(3, i);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean enableProfile(String str, boolean z4) {
        if (!r(ENABLE_PROFILE_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(159);
        cVar.k0(0, n(str));
        cVar.s1(1, z4 ? 1 : 0);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean encryptDir(String str, String str2, boolean z4, boolean z5) {
        return false;
    }

    @JavascriptInterface
    public boolean encryptFile(String str, String str2, boolean z4, boolean z5) {
        return false;
    }

    @JavascriptInterface
    public boolean endCall() {
        return p(END_CALL_LABEL, 733);
    }

    @JavascriptInterface
    public boolean enterKey(String str, String str2, boolean z4, boolean z5, String str3, String str4, int i) {
        return false;
    }

    @JavascriptInterface
    public void exit() {
        Handler handler;
        r("exit");
        synchronized (this.l) {
            try {
                if (!K() && (handler = this.f) != null) {
                    sendMessageWithID(handler, 1, this.m);
                }
            } catch (Throwable th2) {
                throw th2;
            }
        }
        synchronized (this) {
            try {
                Thread.sleep(200L);
            } catch (Exception unused) {
            }
        }
    }

    @JavascriptInterface
    public boolean filterImage(String str, int i) {
        if (!r("filterImage")) {
            return false;
        }
        int v32 = dq.v3(str, a1.A);
        if (v32 != -1) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(185);
            cVar.s1(0, v32);
            cVar.s1(1, i);
            return F(cVar);
        }
        r7.G("JSI", "filterImage: bad mode: " + str);
        return false;
    }

    @JavascriptInterface
    public void flash(final String str) {
        final Context j = j();
        if (j == null) {
            return;
        }
        if (str == null) {
            str = "";
        }
        if (r("flash")) {
            pg.w0.p0(new Runnable() {
                @Override
                public final void run() {
                    c6.A(j, str);
                }
            });
        }
    }

    @JavascriptInterface
    public void flashLong(final String str) {
        if (r("flashLong")) {
            pg.w0.p0(new Runnable() {
                @Override
                public final void run() {
                    c6.this.B(str);
                }
            });
        }
    }

    @JavascriptInterface
    public boolean flipImage(boolean z4) {
        if (!r("flipImage")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(190);
        cVar.s1(0, !z4 ? 1 : 0);
        return F(cVar);
    }

    public int getID() {
        return this.m;
    }

    @JavascriptInterface
    public boolean getLocation(String str, boolean z4, int i) {
        if (!r(GET_LOCATION_LABEL)) {
            return false;
        }
        int s4 = s(GET_LOCATION_LABEL, str);
        int m = m(i, 1, a1.c0(902, 1), a1.b0(902, 1));
        if (s4 == -1) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(902);
        cVar.s1(0, s4);
        cVar.s1(1, m);
        cVar.m1(3, z4);
        cVar.m1(2, false);
        return G(cVar, (m + 2) * 1000);
    }

    @JavascriptInterface
    public String getVoice(String str, String str2, int i) {
        int i4;
        if (r("getVoice")) {
            if ("free".matches(str2)) {
                i4 = 0;
            } else if ("web".matches(str2)) {
                i4 = 1;
            } else {
                r7.G("JSI", "getVoice: bad model: " + str2);
                i4 = -1;
            }
            if (i4 != -1) {
                net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(903);
                cVar.k0(0, n(str));
                cVar.s1(1, i4);
                cVar.s1(3, 20);
                cVar.s1(4, i);
                String I4 = I(cVar, (i + 2) * 1000);
                if (I4 != null) {
                    return I4;
                }
            }
        }
        return "undefined";
    }

    @JavascriptInterface
    public String global(String str) {
        if (r("global")) {
            if (!str.startsWith("%")) {
                str = "%" + str;
            }
            if (!kq.W0(str)) {
                return kq.B0(j(), str);
            }
            r7.G("JSI", "global: ignoring local var " + str);
        }
        return "undefined";
    }

    @JavascriptInterface
    public void goHome(int i) {
        if (r("goHome")) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(25);
            cVar.s1(0, i);
            F(cVar);
        }
    }

    @JavascriptInterface
    public final boolean haptics(boolean z4) {
        return q(HAPTICS_LABEL, 177, 0, z4);
    }

    @JavascriptInterface
    public void hideScene(String str) {
        if (r("hideScene")) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(48);
            cVar.k0(0, str);
            F(cVar);
        }
    }

    @JavascriptInterface
    public String httpRequest(String str, String str2, String str3, String str4, String str5, String str6, String str7, Integer num, boolean z4, boolean z5, boolean z6, boolean z7) {
        if (r("httpRequest")) {
            return H(com.joaomgcd.taskerm.action.net.h.K(n(str), n(str2), n(str3), n(str4), n(str5), n(str6), n(str7), num, Boolean.valueOf(z4), z5, Boolean.valueOf(z6), Boolean.valueOf(z7)));
        }
        return null;
    }

    @JavascriptInterface
    public String listFiles(String str, boolean z4) {
        if (r("listFiles")) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(412);
            cVar.k0(0, str);
            cVar.k0(1, "");
            cVar.m1(2, z4);
            cVar.m1(3, false);
            cVar.k0(5, "");
            String H4 = H(cVar);
            if (!TextUtils.isEmpty(H4)) {
                return H4;
            }
        }
        return null;
    }

    @JavascriptInterface
    public final boolean loadApp(String str, String str2, boolean z4) {
        if (!r("loadApp")) {
            return false;
        }
        AppBasic appBasic = App.get(j(), str);
        if (!appBasic.isInstalled()) {
            return false;
        }
        String W4 = ExtensionsContextKt.W(j(), appBasic.getPackageName());
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(20);
        cVar.i1(0, appBasic.getPackageName(), W4, appBasic.getName());
        cVar.k0(1, n(str2));
        cVar.m1(2, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public final boolean loadImage(String str) {
        if (!r("loadImage")) {
            return false;
        }
        g gVar = new g();
        if (str.startsWith(File.separator)) {
            str = "file://" + str;
        }
        if (!gVar.v(j().getContentResolver(), Uri.parse(str))) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(188);
        cVar.k1(0, gVar);
        return F(cVar);
    }

    @JavascriptInterface
    public String local(String str) {
        if (r("local")) {
            if (!str.startsWith("%")) {
                str = "%" + str;
            }
            if (kq.L1(str) && kq.W0(str)) {
                if (str.equals("%caller")) {
                    return this.o;
                }
                com.joaomgcd.taskerm.util.c<Bundle> cVar = this.d;
                if (cVar != null) {
                    cVar.a(this.h);
                }
                String u12 = kq.u1(j(), str, this.h, "js/local");
                return this.h.containsKey(u12) ? this.h.getString(u12) : "";
            }
            r7.G("JSI", "local: ignoring global var " + str);
        }
        return "undefined";
    }

    @JavascriptInterface
    public boolean lock(String str, String str2, boolean z4, boolean z5, boolean z6, String str3, String str4) {
        if (!r(LOCK_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(15);
        cVar.k0(0, n(str));
        cVar.k0(1, str2);
        cVar.m1(2, z4);
        cVar.m1(3, z5);
        cVar.m1(4, z6);
        cVar.k0(5, n(str3));
        cVar.k0(6, n(str4));
        return F(cVar);
    }

    @JavascriptInterface
    public boolean mediaControl(String str) {
        if (!r(MEDIA_CONTROL_LABEL)) {
            return false;
        }
        int v32 = dq.v3(str, a1.d);
        if (v32 != -1) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(443);
            cVar.s1(0, v32);
            return F(cVar);
        }
        r7.G("JSI", "mediaControl: unknown action: " + str);
        return false;
    }

    @JavascriptInterface
    public boolean mediaVol(int i, boolean z4, boolean z5) {
        return L(MEDIA_VOL_LABEL, 307, i, z4, z5);
    }

    @JavascriptInterface
    public final boolean micMute(boolean z4) {
        return q(MIC_MUTE_LABEL, 301, 0, z4);
    }

    @JavascriptInterface
    public final boolean mobileData(boolean z4) {
        return q(MOBILE_DATA_LABEL, 433, 0, z4);
    }

    @JavascriptInterface
    public boolean musicBack(int i) {
        if (!r(MUSIC_BACK_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(453);
        cVar.s1(0, i);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean musicPlay(String str, int i, boolean z4, String str2, boolean z5) {
        int t4;
        if (!r(MUSIC_PLAY_LABEL) || (t4 = t(str2, "media", MUSIC_PLAY_LABEL)) == -1) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(445);
        cVar.k0(0, str);
        cVar.s1(1, i);
        cVar.m1(2, z4);
        cVar.s1(3, t4);
        cVar.m1(4, z5);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean musicSkip(int i) {
        if (!r(MUSIC_SKIP_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(451);
        cVar.s1(0, i);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean musicStop() {
        if (!r(MUSIC_STOP_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(449);
        cVar.m1(0, false);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean navigationBar(String str, String str2, String str3) {
        if (!r("navigationBar")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(329);
        cVar.k0(0, n(str));
        cVar.k0(1, n(str2));
        cVar.k0(2, n(str3));
        return F(cVar);
    }

    @JavascriptInterface
    public boolean nightMode(boolean z4) {
        return q(NIGHT_MODE_LABEL, 989, 0, z4);
    }

    @JavascriptInterface
    public boolean notificationVol(int i, boolean z4, boolean z5) {
        return L(NOTIFICATION_VOL_LABEL, 305, i, z4, z5);
    }

    @JavascriptInterface
    public String parseFormatDateTime(int i, String str, String str2, String str3, String str4, String str5, boolean z4) {
        if (!r(PARSE_FORMAT_DATETIME_LABEL)) {
            return null;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(394);
        cVar.s1(1, i);
        cVar.k0(2, n(str));
        cVar.k0(3, n(str2));
        cVar.k0(4, n(str3));
        cVar.k0(5, n(str4));
        cVar.k0(6, n(str5));
        cVar.m1(8, z4);
        return H(cVar);
    }

    @JavascriptInterface
    public boolean performTask(String str, int i, String str2, String str3, String str4, boolean z4, boolean z5, String str5, boolean z6) {
        if (!r(PERFORM_TASK_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(130);
        cVar.k0(0, str);
        cVar.s1(1, i);
        cVar.k0(2, n(str2));
        cVar.k0(3, n(str3));
        cVar.k0(4, n(str4));
        cVar.m1(5, z4);
        cVar.m1(6, z5);
        cVar.k0(7, n(str5));
        cVar.m1(8, z6);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean popup(String str, String str2, boolean z4, String str3, String str4, int i) {
        if (!r(POPUP_LABEL)) {
            return false;
        }
        if (i > 600) {
            r7.G("JSI", "popup: max timeout is 600");
            return false;
        }
        if (i < 1) {
            r7.G("JSI", "popup: min timeout is 1");
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(550);
        cVar.k0(0, n(str));
        cVar.k0(1, n(str2));
        cVar.k0(2, n(str3));
        cVar.k0(3, n(str4));
        cVar.m1(5, z4);
        cVar.s1(4, i);
        return G(cVar, (i + 2) * 1000);
    }

    @JavascriptInterface
    public boolean profileActive(String str) {
        if (!r(PROFILE_ACTIVE_LABEL)) {
            return false;
        }
        uo v12 = to.v1(j());
        for (int i : MonitorService.E3()) {
            if (str.equals(v12.s(i))) {
                return true;
            }
        }
        return false;
    }

    @JavascriptInterface
    public boolean pulse(boolean z4) {
        return q(PULSE_LABEL, 259, 0, z4);
    }

    @JavascriptInterface
    public String readFile(String str) {
        if (r("readFile")) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(417);
            cVar.k0(0, str);
            cVar.k0(1, "");
            String H4 = H(cVar);
            if (H4 != null) {
                return H4;
            }
        }
        return "undefined";
    }

    @JavascriptInterface
    public boolean reboot(String str) {
        if (!r("reboot")) {
            return false;
        }
        if ("undefined".equals(str)) {
            str = RingModeSettings.RING_MODE_NORMAL;
        }
        int v32 = dq.v3(str, a1.b);
        if (v32 != -1) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(59);
            cVar.s1(0, v32);
            return F(cVar);
        }
        r7.G("JSI", "reboot: bad type: " + str);
        return false;
    }

    @JavascriptInterface
    public final boolean resizeImage(int i, int i4) {
        if (!r("resizeImage")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(193);
        cVar.s1(0, i);
        cVar.s1(1, i4);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean ringerVol(int i, boolean z4, boolean z5) {
        return L(RINGER_VOL_LABEL, 304, i, z4, z5);
    }

    @JavascriptInterface
    public final boolean rotateImage(String str, int i) {
        int i4;
        if (!r("rotateImage")) {
            return false;
        }
        if ("left".equals(str)) {
            i4 = 1;
        } else if ("right".equals(str)) {
            i4 = 0;
        } else {
            r7.G("JSI", "rotateImage: bad dir: " + str);
            i4 = -1;
        }
        int v32 = dq.v3(String.valueOf(i), a1.h);
        if (v32 == -1) {
            r7.G("JSI", "rotateImage: bad degree spec: " + i);
            return false;
        }
        if (i4 == -1) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(191);
        cVar.s1(0, i4);
        cVar.s1(1, v32);
        return F(cVar);
    }

    @JavascriptInterface
    public final boolean saveImage(String str, int i, boolean z4) {
        if (!r(SAVE_IMAGE_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(187);
        cVar.k0(0, str);
        cVar.s1(1, i);
        cVar.m1(2, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean say(String str, String str2, String str3, String str4, int i, int i4, boolean z4, boolean z5) {
        int t4;
        if (!r(SAY_LABEL) || (t4 = t(str4, "media", SAY_LABEL)) == -1) {
            return false;
        }
        int m = m(i, 0, a1.c0(559, 3), a1.b0(559, 3));
        int m4 = m(i4, 0, a1.c0(559, 4), a1.b0(559, 4));
        if ("undefined".equals(str2)) {
            str2 = "default";
        }
        if ("undefined".equals(str3)) {
            str3 = Locale.getDefault().getLanguage();
            if (TextUtils.isEmpty(str3)) {
                str3 = j().getResources().getConfiguration().locale.getLanguage();
            }
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(559);
        cVar.k0(0, str);
        cVar.k0(1, str2 + ConstantsCommonTaskerServer.ID_SEPARATOR + str3);
        cVar.s1(2, t4);
        cVar.s1(3, m);
        cVar.s1(4, m4);
        cVar.m1(6, z5);
        cVar.m1(5, z4);
        cVar.m1(7, false);
        return F(cVar);
    }

    @JavascriptInterface
    public final boolean scanCard(String str) {
        if (!r("scanCard")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(459);
        cVar.k0(0, n(str));
        return F(cVar);
    }

    @JavascriptInterface
    public boolean sendCommand(String str) {
        if (r("sendCommand")) {
            return F(com.joaomgcd.taskerm.action.tasker.a.J(str));
        }
        return false;
    }

    @android.webkit.JavascriptInterface
    public boolean sendIntent(java.lang.String r16, java.lang.String r17, java.lang.String r18, java.lang.String r19, java.lang.String r20, java.lang.String r21, java.lang.String r22, java.lang.String[] r23) {
        throw new UnsupportedOperationException("Method not decompiled: net.dinglisch.android.taskerm.c6.sendIntent(java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.String[]):boolean");
    }

    @JavascriptInterface
    public boolean sendSMS(String str, String str2, boolean z4) {
        if (!r(SEND_SMS_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(41);
        cVar.k0(1, str2);
        cVar.k0(0, str);
        cVar.m1(2, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean setAirplaneMode(boolean z4) {
        return q(SET_AIRPLANE_MODE_LABEL, 333, 0, z4);
    }

    @JavascriptInterface
    public boolean setAirplaneRadios(String str) {
        boolean z4;
        if (!r(SET_AIRPLANE_RADIOS_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(323);
        String[] split = str.split(",");
        if (dq.r(split)) {
            z4 = true;
        } else {
            boolean z5 = true;
            for (String str2 : split) {
                String trim = str2.trim();
                if (!TextUtils.isEmpty(trim)) {
                    if (trim.equals("bluetooth")) {
                        cVar.m1(0, true);
                    } else if (trim.equals("wimax")) {
                        cVar.m1(4, true);
                    } else if (trim.equals("wifi")) {
                        cVar.m1(3, true);
                    } else if (trim.equals("nfc")) {
                        cVar.m1(2, true);
                    } else if (trim.equals("cell")) {
                        cVar.m1(1, true);
                    } else {
                        r7.G("JSI", "unknown radio: " + trim);
                        z5 = false;
                    }
                }
            }
            z4 = z5;
        }
        return z4 ? F(cVar) : z4;
    }

    @JavascriptInterface
    public boolean setAlarm(int i, int i4, String str, boolean z4) {
        if (!r(SET_ALARM_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(566);
        cVar.k0(2, n(str));
        cVar.s1(0, i);
        cVar.s1(1, i4);
        cVar.m1(5, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean setAutoSync(boolean z4) {
        return q(SET_AUTO_SYNC_LABEL, 331, 0, z4);
    }

    @JavascriptInterface
    public boolean setBT(boolean z4) {
        return q(SET_BT_LABEL, 294, 0, z4);
    }

    @JavascriptInterface
    public boolean setBTID(String str) {
        if (!r(SET_BT_ID_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(295);
        cVar.k0(0, n(str));
        return F(cVar);
    }

    @JavascriptInterface
    public boolean setClip(String str, boolean z4) {
        if (!r(SET_CLIP_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(105);
        cVar.k0(0, str);
        cVar.m1(1, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public void setGlobal(String str, String str2) {
        setGlobal(str, str2, false);
    }

    public void setID(int i) {
        this.m = i;
    }

    @JavascriptInterface
    public final boolean setKey(String str, String str2) {
        if (!r("setKey")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(423);
        cVar.k0(0, n(str));
        cVar.k0(1, n(str2));
        return F(cVar);
    }

    @JavascriptInterface
    public void setLocal(String str, String str2) {
        r("setLocal");
        if (!str.startsWith("%")) {
            str = "%" + str;
        }
        if (!kq.L1(str) || !kq.W0(str)) {
            r7.G("JSI", "setLocal: bad local var name or reference: " + str);
            return;
        }
        String u12 = kq.u1(j(), str, this.h, "js/setlocal");
        r7.f(this.b, "setLocal: " + u12 + "->" + str2);
        this.h.putString(u12, str2);
        com.joaomgcd.taskerm.util.c<Pair<String, String>> cVar = this.c;
        if (cVar != null) {
            cVar.a(new Pair<>(u12, str2));
        }
    }

    @JavascriptInterface
    public boolean setWallpaper(String str) {
        if (!r(SET_WALLPAPER_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(109);
        cVar.k0(1, n(str));
        return F(cVar);
    }

    @JavascriptInterface
    public boolean setWifi(boolean z4) {
        return q(SET_WIFI_LABEL, 425, 0, z4);
    }

    @JavascriptInterface
    public boolean settings(String str) {
        int i;
        if (!r(SETTINGS_LABEL)) {
            return false;
        }
        int P4 = a1.P(30);
        int k02 = a1.k0(P4, 2);
        int i4 = 0;
        while (true) {
            if (i4 >= k02) {
                i = -1;
                break;
            }
            i = a1.t(P4, i4, 2);
            if (a1.v(i).toLowerCase().replaceAll("\\s*", "").replaceFirst("Settings", "").equals(str)) {
                break;
            }
            i4++;
        }
        if (i != -1) {
            return F(new net.dinglisch.android.taskerm.c(i));
        }
        r7.G("JSI", "settings: unknown settings: " + str);
        return false;
    }

    @JavascriptInterface
    public final String shell(String str, boolean z4, int i) {
        if (r("shell")) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(123);
            cVar.s1(1, i);
            cVar.k0(0, str);
            cVar.m1(2, z4);
            cVar.k0(3, "");
            String I4 = I(cVar, (i + 2) * 1000);
            if (I4 != null) {
                return I4;
            }
        }
        return "undefined";
    }

    @JavascriptInterface
    public boolean showScene(String str, String str2, int i, int i4, boolean z4, boolean z5) {
        if (!r(SHOW_SCENE_LABEL)) {
            return false;
        }
        int v32 = dq.v3(str2, dk.l0);
        if (i < -100 || i > 100) {
            r7.G(this.b, "showScene:bad hOffset: " + i);
            return false;
        }
        if (i4 < -100 || i4 > 100) {
            r7.G(this.b, "showScene:bad vOffset: " + i4);
            return false;
        }
        if (v32 == -1) {
            r7.G(this.b, "showScene:bad display type: " + str2);
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(47);
        cVar.k0(0, str);
        cVar.s1(1, v32);
        cVar.s1(2, i + 100);
        cVar.s1(3, i4 + 100);
        cVar.m1(5, z4);
        cVar.m1(7, true ^ z5);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean shutdown() {
        return reboot("shutdown");
    }

    @JavascriptInterface
    public boolean silentMode(String str) {
        if (!r(SILENT_MODE_LABEL)) {
            return false;
        }
        int i = str.equals("off") ? 0 : -1;
        if (str.equals("vibrate")) {
            i = 1;
        }
        if (str.equals("on")) {
            i = 2;
        }
        if (i != -1) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(310);
            cVar.s1(0, i);
            return F(cVar);
        }
        r7.G("JSI", "silentMode: bad mode: " + str);
        return false;
    }

    @JavascriptInterface
    public final boolean sl4a(String str, boolean z4) {
        if (!r(SL4A_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(112);
        cVar.k0(0, str);
        cVar.m1(1, z4);
        cVar.k0(2, "");
        return F(cVar);
    }

    @JavascriptInterface
    public final boolean soundEffects(boolean z4) {
        return q(SOUND_EFFECTS_LABEL, 136, 0, z4);
    }

    @JavascriptInterface
    public final boolean speakerphone(boolean z4) {
        return q(SPEAKERPHONE_LABEL, 254, 0, z4);
    }

    @JavascriptInterface
    public final boolean statusBar(boolean z4) {
        return q(STATUS_BAR_LABEL, 512, 0, z4);
    }

    @JavascriptInterface
    public final boolean stayOn(String str) {
        if (r(STAY_ON_LABEL)) {
            net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(820);
            if ("never".equals(str) || "ac".equals(str) || "usb".equals(str) || "any".equals(str)) {
                return F(cVar);
            }
            r7.G("JSI", "stayOn: bad mode: " + str);
        }
        return false;
    }

    @JavascriptInterface
    public final boolean stopLocation(String str) {
        int s4;
        if (!r(STOP_LOCATION_LABEL) || (s4 = s(STOP_LOCATION_LABEL, str)) == -1) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(901);
        cVar.s1(0, s4);
        return F(cVar);
    }

    @JavascriptInterface
    public final boolean systemLock() {
        return p(SYSTEM_LOCK_LABEL, 16);
    }

    @JavascriptInterface
    public boolean systemVol(int i, boolean z4, boolean z5) {
        return L(SYSTEM_VOL_LABEL, 308, i, z4, z5);
    }

    @JavascriptInterface
    public boolean takeCall() {
        return p(TAKE_CALL_LABEL, 731);
    }

    @JavascriptInterface
    public boolean takePhoto(int i, String str, String str2, boolean z4) {
        if (!r(TAKE_PHOTO_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(101);
        cVar.s1(0, i);
        cVar.k0(1, str);
        cVar.s1(2, 0);
        cVar.m1(3, z4);
        cVar.m1(4, false);
        cVar.k0(5, str2);
        cVar.k0(6, "auto");
        cVar.k0(7, "auto");
        cVar.k0(8, "auto");
        return F(cVar);
    }

    @JavascriptInterface
    public boolean taskRunning(String str) {
        if (r(TASK_RUNNING_LABEL)) {
            return ExecuteService.K4().contains(str);
        }
        return false;
    }

    @JavascriptInterface
    public final boolean type(String str, int i) {
        if (!r("type")) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(702);
        cVar.k0(0, str);
        cVar.s1(1, i);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean unzip(String str, boolean z4) {
        if (!r(UNZIP_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(422);
        cVar.k0(0, str);
        cVar.m1(1, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public final boolean usbTether(boolean z4) {
        return q(USB_TETHER_LABEL, 114, 0, z4);
    }

    @JavascriptInterface
    public void vibrate(int i) {
        if (r("vibrate")) {
            dq.L3(j(), i);
        }
    }

    @JavascriptInterface
    public boolean vibratePattern(String str) {
        if (!r(VIBRATE_PATTERN_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(62);
        cVar.k0(0, str);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean wait(int i) {
        if (!r("wait")) {
            return false;
        }
        long j = i;
        int i4 = (int) (j > 86400000 ? j / 86400000 : 0L);
        long j4 = (int) (j - (i4 * 86400000));
        int i5 = (int) (j4 > 3600000 ? j4 / 3600000 : 0L);
        long j5 = (int) (j4 - (i5 * 3600000));
        int i6 = (int) (j5 > 60000 ? j5 / 60000 : 0L);
        long j6 = (int) (j5 - (i6 * 60000));
        int i7 = (int) (j6 > 1000 ? j6 / 1000 : 0L);
        int i8 = (int) (j6 - (i7 * 1000));
        r7.f(this.b, "waitcomps:" + i8 + " " + i7 + " " + i6 + " " + i5 + " " + i4);
        long j7 = i4 > 0 ? 3600000L : i5 > 0 ? 60000L : i6 > 0 ? 1000L : i7 > 0 ? 100L : i8 / 3;
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(30);
        cVar.s1(0, i8);
        cVar.s1(1, i7);
        cVar.s1(2, i6);
        cVar.s1(3, i5);
        cVar.s1(4, i4);
        return G(cVar, (int) Math.max(j7 * 2, 10000L));
    }

    @JavascriptInterface
    public final boolean wifiTether(boolean z4) {
        return q(WIFI_TETHER_LABEL, 113, 0, z4);
    }

    @JavascriptInterface
    public boolean writeFile(String str, String str2, boolean z4) {
        if (!r(WRITE_FILE_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(410);
        cVar.k0(0, str);
        cVar.k0(1, n(str2));
        cVar.m1(2, z4);
        return F(cVar);
    }

    @JavascriptInterface
    public boolean zip(String str, int i, boolean z4) {
        if (!r(ZIP_LABEL)) {
            return false;
        }
        net.dinglisch.android.taskerm.c cVar = new net.dinglisch.android.taskerm.c(420);
        cVar.k0(0, str);
        cVar.m1(1, z4);
        cVar.s1(2, i);
        return F(cVar);
    }

    @JavascriptInterface
    public void setGlobal(String str, String str2, boolean z4) {
        if (r("setGlobal")) {
            if (!str.startsWith("%")) {
                str = "%" + str;
            }
            String str3 = str;
            if (!kq.c1(str3)) {
                r7.G(this.b, "setGlobal: ignoring invalid varname " + str3);
                return;
            }
            if (kq.W0(str3)) {
                r7.G(this.b, "setGlobal: ignoring local var " + str3);
                return;
            }
            r7.f(this.b, "setGlobal: " + str3 + "->" + str2);
            if (TextUtils.isEmpty(str2)) {
                kq.D(j(), str3);
            } else {
                kq.V1(j(), str3, str2, true, null, "setGlobal", z4 ? StructureType.Auto : null);
            }
        }
    }
}