APK反编译源代码展示 - 南明离火平台提供

应用版本信息
应用名称:MiXplorer
版本号:6.67.3
包名称:com.mixplorer

MD5 校验值:13e9f681f5bed77188ac69741746def0

反编译源代码说明

ew1.java 文件包含反编译后的源代码,请注意,该内容仅供学习和参考使用,不得用于非法用途。


package libs;

import android.R;
import android.app.Activity;
import android.app.ActivityManager;
import android.app.PendingIntent;
import android.content.Intent;
import android.content.pm.ShortcutInfo;
import android.content.pm.ShortcutManager;
import android.graphics.Bitmap;
import android.graphics.Matrix;
import android.graphics.drawable.Icon;
import android.net.Uri;
import com.mixplorer.AppImpl;
import com.mixplorer.activities.BrowseActivity;
import com.mixplorer.activities.CodeEditorActivity;
import com.mixplorer.activities.ShortcutActivity;
import com.mixplorer.activities.TextEditorActivity;
import com.mixplorer.providers.FileProvider;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;

public abstract class ew1 {
    public static Intent a(Activity activity, Class cls, boolean z, is0 is0Var, String str, Bitmap bitmap, boolean z2) {
        Class cls2;
        Class cls3;
        Bitmap bitmap2;
        Intent intent;
        Intent createShortcutResultIntent;
        float f;
        if (is0Var != null) {
            try {
                if (!is0Var.a2) {
                    cls2 = cls;
                    if (cls2 == BrowseActivity.class) {
                        cls3 = ShortcutActivity.class;
                        if (is0Var != null) {
                            if (bitmap == null) {
                                try {
                                    bitmap2 = AppImpl.V1.Q(null, is0Var, is0Var.X(), false, null, true);
                                } catch (Throwable th) {
                                    th = th;
                                    bitmap2 = bitmap;
                                    xv1.j("SHCUT", "BMP", ui3.A(th));
                                    intent = new Intent(activity, (Class<?>) cls3);
                                    intent.putExtra("shortcut", true);
                                    intent.setFlags(603979776);
                                    String str2 = "com.mixplorer.ACTION_OPEN_SHORTCUT";
                                    if (is0Var != null) {
                                    }
                                    if (!z2) {
                                    }
                                    Intent intent2 = new Intent();
                                    intent2.setAction("com.android.launcher.action.INSTALL_SHORTCUT");
                                    intent2.putExtra("duplicate", false);
                                    intent2.putExtra("android.intent.extra.shortcut.INTENT", intent);
                                    intent2.putExtra("android.intent.extra.shortcut.NAME", str);
                                    if (bitmap2 != null) {
                                    }
                                    activity.sendBroadcast(intent2);
                                    return intent2;
                                }
                            } else {
                                bitmap2 = bitmap;
                            }
                            if (bitmap2 != null) {
                                try {
                                    float dimension = tw0.g.getResources().getDimension(R.dimen.app_icon_size);
                                    if (vf3.i()) {
                                        f = ((ActivityManager) tw0.g.getSystemService("activity")).getLauncherLargeIconSize();
                                    } else {
                                        f = 0.0f;
                                    }
                                    float max = Math.max(f, dimension);
                                    if (bitmap2.getWidth() > max) {
                                        float width = max / bitmap2.getWidth();
                                        Matrix matrix = new Matrix();
                                        matrix.postScale(width, width);
                                        bitmap2 = Bitmap.createBitmap(bitmap2, 0, 0, bitmap2.getWidth(), bitmap2.getHeight(), matrix, true);
                                    }
                                    if (d93.q > 0.0f && !"apk".equalsIgnoreCase(is0Var.P1)) {
                                        bitmap2 = la1.b(bitmap2);
                                    }
                                } catch (Throwable th2) {
                                    th = th2;
                                    xv1.j("SHCUT", "BMP", ui3.A(th));
                                    intent = new Intent(activity, (Class<?>) cls3);
                                    intent.putExtra("shortcut", true);
                                    intent.setFlags(603979776);
                                    String str22 = "com.mixplorer.ACTION_OPEN_SHORTCUT";
                                    if (is0Var != null) {
                                    }
                                    if (!z2) {
                                    }
                                    Intent intent22 = new Intent();
                                    intent22.setAction("com.android.launcher.action.INSTALL_SHORTCUT");
                                    intent22.putExtra("duplicate", false);
                                    intent22.putExtra("android.intent.extra.shortcut.INTENT", intent);
                                    intent22.putExtra("android.intent.extra.shortcut.NAME", str);
                                    if (bitmap2 != null) {
                                    }
                                    activity.sendBroadcast(intent22);
                                    return intent22;
                                }
                            }
                        } else {
                            bitmap2 = bitmap;
                        }
                        intent = new Intent(activity, (Class<?>) cls3);
                        intent.putExtra("shortcut", true);
                        intent.setFlags(603979776);
                        String str222 = "com.mixplorer.ACTION_OPEN_SHORTCUT";
                        if (is0Var != null) {
                            intent.putExtra("shortcut_fi_id", is0Var.p2);
                            intent.putExtra("shortcut_fi_dir", is0Var.a2);
                            if (is0Var.a2) {
                                str222 = "com.mixplorer.ACTION_OPEN_FOLDER";
                            }
                            intent.setAction(str222);
                            if (!z && (!vf3.t() || !is0Var.N1)) {
                                Uri U = ll.U(is0Var.c2);
                                if (ui3.x(is0Var.k())) {
                                    wv1.l(intent, U);
                                } else {
                                    wv1.m(intent, U, is0Var.k(), true);
                                }
                            }
                            Uri h = FileProvider.h(is0Var);
                            if (ui3.x(is0Var.k())) {
                                wv1.l(intent, h);
                            } else {
                                wv1.m(intent, h, is0Var.k(), true);
                            }
                        } else {
                            intent.setAction("com.mixplorer.ACTION_OPEN_SHORTCUT");
                        }
                        if (!z2 && vf3.s()) {
                            intent.removeExtra("mix_data_uri");
                            ShortcutInfo.Builder shortLabel = new ShortcutInfo.Builder(activity, System.currentTimeMillis() + "").setIntent(intent).setShortLabel(str);
                            shortLabel.setIcon((Icon) la1.h(bitmap2));
                            ShortcutInfo build = shortLabel.build();
                            ShortcutManager shortcutManager = (ShortcutManager) activity.getSystemService(ShortcutManager.class);
                            createShortcutResultIntent = shortcutManager.createShortcutResultIntent(build);
                            shortcutManager.requestPinShortcut(build, PendingIntent.getBroadcast(activity, 0, createShortcutResultIntent, z90.b(0)).getIntentSender());
                            return intent;
                        }
                        Intent intent222 = new Intent();
                        intent222.setAction("com.android.launcher.action.INSTALL_SHORTCUT");
                        intent222.putExtra("duplicate", false);
                        intent222.putExtra("android.intent.extra.shortcut.INTENT", intent);
                        intent222.putExtra("android.intent.extra.shortcut.NAME", str);
                        if (bitmap2 != null) {
                            intent222.putExtra("android.intent.extra.shortcut.ICON", bitmap2);
                        }
                        activity.sendBroadcast(intent222);
                        return intent222;
                    }
                    cls3 = cls2;
                    if (is0Var != null) {
                    }
                    intent = new Intent(activity, (Class<?>) cls3);
                    intent.putExtra("shortcut", true);
                    intent.setFlags(603979776);
                    String str2222 = "com.mixplorer.ACTION_OPEN_SHORTCUT";
                    if (is0Var != null) {
                    }
                    if (!z2) {
                    }
                    Intent intent2222 = new Intent();
                    intent2222.setAction("com.android.launcher.action.INSTALL_SHORTCUT");
                    intent2222.putExtra("duplicate", false);
                    intent2222.putExtra("android.intent.extra.shortcut.INTENT", intent);
                    intent2222.putExtra("android.intent.extra.shortcut.NAME", str);
                    if (bitmap2 != null) {
                    }
                    activity.sendBroadcast(intent2222);
                    return intent2222;
                }
            } catch (Throwable th3) {
                xv1.h("SHCUT", ui3.A(th3));
                fw1.c(activity, Integer.valueOf(com.mixplorer.R.string.failed), 0, false);
                return null;
            }
        }
        cls2 = cls;
        cls3 = cls2;
        if (is0Var != null) {
        }
        intent = new Intent(activity, (Class<?>) cls3);
        intent.putExtra("shortcut", true);
        intent.setFlags(603979776);
        String str22222 = "com.mixplorer.ACTION_OPEN_SHORTCUT";
        if (is0Var != null) {
        }
        if (!z2) {
        }
        Intent intent22222 = new Intent();
        intent22222.setAction("com.android.launcher.action.INSTALL_SHORTCUT");
        intent22222.putExtra("duplicate", false);
        intent22222.putExtra("android.intent.extra.shortcut.INTENT", intent);
        intent22222.putExtra("android.intent.extra.shortcut.NAME", str);
        if (bitmap2 != null) {
        }
        activity.sendBroadcast(intent22222);
        return intent22222;
    }

    public static void b(Activity activity, Intent intent, String str, Bitmap bitmap) {
        Intent createShortcutResultIntent;
        try {
            intent.putExtra("shortcut", true);
            if (vf3.s()) {
                intent.removeExtra("mix_data_uri");
                ShortcutInfo.Builder shortLabel = new ShortcutInfo.Builder(activity, System.currentTimeMillis() + "").setIntent(intent).setShortLabel(str);
                if (bitmap != null) {
                    shortLabel.setIcon((Icon) la1.h(bitmap));
                }
                ShortcutInfo build = shortLabel.build();
                ShortcutManager shortcutManager = (ShortcutManager) activity.getSystemService(ShortcutManager.class);
                createShortcutResultIntent = shortcutManager.createShortcutResultIntent(build);
                shortcutManager.requestPinShortcut(build, PendingIntent.getBroadcast(activity, 0, createShortcutResultIntent, z90.b(0)).getIntentSender());
                return;
            }
            Intent intent2 = new Intent();
            intent2.setAction("com.android.launcher.action.INSTALL_SHORTCUT");
            intent2.putExtra("duplicate", false);
            intent2.putExtra("android.intent.extra.shortcut.INTENT", intent);
            intent2.putExtra("android.intent.extra.shortcut.NAME", str);
            if (bitmap != null) {
                intent2.putExtra("android.intent.extra.shortcut.ICON", bitmap);
            }
            activity.sendBroadcast(intent2);
        } catch (Throwable th) {
            xv1.j("SHCUT", "SHORTCUT", ui3.A(th));
            fw1.c(activity, "SHORTCUT " + dn2.V(com.mixplorer.R.string.failed), 0, false);
        }
    }

    public static synchronized void c(BrowseActivity browseActivity, List list) {
        boolean z;
        String str;
        synchronized (ew1.class) {
            try {
                if (vf3.b() >= 25) {
                    z = true;
                } else {
                    z = false;
                }
                if (!z) {
                    return;
                }
                ArrayList arrayList = new ArrayList();
                if (c92.S(TextEditorActivity.class)) {
                    arrayList.add(new ShortcutInfo.Builder(browseActivity, "text-editor").setRank(arrayList.size()).setShortLabel(dn2.V(com.mixplorer.R.string.editor_text)).setLongLabel(dn2.V(com.mixplorer.R.string.editor_text)).setIcon((Icon) la1.h(la1.b(d93.a(com.mixplorer.R.mipmap.icon_editor_text, null)))).setIntent(new Intent("android.intent.action.VIEW", null, tw0.g, TextEditorActivity.class)).build());
                }
                if (c92.S(CodeEditorActivity.class)) {
                    arrayList.add(new ShortcutInfo.Builder(browseActivity, "code-editor").setRank(arrayList.size()).setShortLabel(dn2.V(com.mixplorer.R.string.editor_code)).setLongLabel(dn2.V(com.mixplorer.R.string.editor_code)).setIcon((Icon) la1.h(la1.b(d93.a(com.mixplorer.R.mipmap.icon_editor_code, null)))).setIntent(new Intent("android.intent.action.VIEW", null, tw0.g, CodeEditorActivity.class)).build());
                }
                Iterator it = list.iterator();
                while (it.hasNext()) {
                    vc0 vc0Var = (vc0) it.next();
                    String str2 = (String) vc0Var.d(0);
                    if (!do3.f(str2)) {
                        boolean booleanValue = ((Boolean) vc0Var.d(2)).booleanValue();
                        is0 v = is0.v(str2, "", hp1.g(str2), booleanValue);
                        Intent intent = new Intent(browseActivity, (Class<?>) BrowseActivity.class);
                        if (booleanValue) {
                            str = "com.mixplorer.ACTION_OPEN_FOLDER";
                        } else {
                            str = "com.mixplorer.ACTION_OPEN_SHORTCUT";
                        }
                        intent.setAction(str);
                        wv1.m(intent, FileProvider.h(v), null, false);
                        intent.setFlags(603979776);
                        String str3 = ((Object) vc0Var.g()) + "";
                        Bitmap x = c92.x(vc0Var.b(), 0, 0);
                        if (!"apk".equalsIgnoreCase(v.P1)) {
                            x = la1.b(x);
                        }
                        arrayList.add(new ShortcutInfo.Builder(browseActivity, "bookmark" + arrayList.size()).setRank(arrayList.size()).setShortLabel(str3).setLongLabel(str3).setIcon((Icon) la1.h(x)).setIntent(intent).build());
                        if (arrayList.size() == 4) {
                            break;
                        }
                    }
                }
                new yu1(new dn1(browseActivity, arrayList, 6)).start();
            } catch (Throwable th) {
                throw th;
            }
        }
    }
}