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

应用版本信息
应用名称:Նվագարկիչ
版本号:9.9.9
包名称:com.iptv.player

MD5 校验值:d7f913ab91d7343430e85d5ce2e5aff0

反编译源代码说明

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


package com.ottplay.ottplay.settings;

import android.content.ActivityNotFoundException;
import android.content.Intent;
import android.content.res.Configuration;
import android.os.Build;
import android.os.Bundle;
import android.provider.Settings;
import android.view.View;
import android.view.ViewGroup;
import android.widget.AdapterView;
import android.widget.ListAdapter;
import android.widget.ListView;
import androidx.appcompat.widget.Toolbar;
import androidx.constraintlayout.widget.ConstraintLayout;
import androidx.fragment.app.Fragment;
import androidx.fragment.app.FragmentManager;
import androidx.fragment.app.y;
import bg.g;
import bg.m;
import cg.c;
import cg.e;
import cg.f;
import com.google.android.material.switchmaterial.SwitchMaterial;
import com.iptv.player.R;
import com.ottplay.ottplay.ForegroundService;
import com.ottplay.ottplay.utils.Keys;
import com.tencent.mmkv.MMKV;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.List;
import java.util.Objects;
import l7.k;
import rc.i;
import xe.r;
import ye.b;

public class MoreSettingsActivity extends xe.a {

    public static final int f20440u = 0;

    public final List<g> f20441p = new ArrayList();

    public m f20442q;

    public SwitchMaterial f20443r;

    public Toolbar f20444s;

    public ListView f20445t;

    public class a implements AdapterView.OnItemClickListener {

        public class C0144a extends FragmentManager.j {

            public final FragmentManager f20447a;

            public C0144a(FragmentManager fragmentManager) {
                this.f20447a = fragmentManager;
            }

            @Override
            public void b(FragmentManager fragmentManager, Fragment fragment) {
                if (cg.a.a0(fragment.f10110x).equals("parental_control_tag")) {
                    if (f.w()) {
                        MoreSettingsActivity.this.f20443r.setChecked(!r1.isChecked());
                        f.S(MoreSettingsActivity.this.f20443r.isChecked());
                        f.T(false);
                    }
                    this.f20447a.h0(this);
                }
            }
        }

        public a() {
        }

        @Override
        public void onItemClick(AdapterView<?> adapterView, View view, int i10, long j10) {
            SwitchMaterial switchMaterial;
            String str = MoreSettingsActivity.this.f20441p.get(i10).f13634a;
            MoreSettingsActivity.this.f20443r = (SwitchMaterial) view.findViewById(R.id.f48250_resource_name_obfuscated_res_0x7f0b02ad);
            if (str == null) {
                return;
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f65300_resource_name_obfuscated_res_0x7f130264))) {
                MoreSettingsActivity.this.startActivity(new Intent(MoreSettingsActivity.this, (Class<?>) ParentalControlActivity.class));
            }
            boolean z10 = false;
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f63100_resource_name_obfuscated_res_0x7f130188))) {
                boolean z11 = c.f() && c.l().equals(Keys.getSCPRC());
                SwitchMaterial switchMaterial2 = MoreSettingsActivity.this.f20443r;
                if (switchMaterial2 == null || !z11) {
                    return;
                }
                switchMaterial2.setChecked(!switchMaterial2.isChecked());
                boolean isChecked = MoreSettingsActivity.this.f20443r.isChecked();
                k.a aVar = e.f14184a;
                xe.e.f44786a.o("FullScreenAtStart", isChecked);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66750_resource_name_obfuscated_res_0x7f1302f5))) {
                SwitchMaterial switchMaterial3 = MoreSettingsActivity.this.f20443r;
                if (switchMaterial3 == null) {
                    return;
                }
                switchMaterial3.setChecked(!switchMaterial3.isChecked());
                boolean isChecked2 = MoreSettingsActivity.this.f20443r.isChecked();
                k.a aVar2 = e.f14184a;
                xe.e.f44786a.o("RebootVideoPlayer", isChecked2);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66790_resource_name_obfuscated_res_0x7f1302f9))) {
                SwitchMaterial switchMaterial4 = MoreSettingsActivity.this.f20443r;
                if (switchMaterial4 == null) {
                    return;
                }
                switchMaterial4.setChecked(!switchMaterial4.isChecked());
                boolean isChecked3 = MoreSettingsActivity.this.f20443r.isChecked();
                k.a aVar3 = e.f14184a;
                xe.e.f44786a.o("ShowVideoBufferingIcon", isChecked3);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66710_resource_name_obfuscated_res_0x7f1302f1))) {
                if (MoreSettingsActivity.this.f20443r == null) {
                    return;
                }
                if (c.y() && !f.x() && f.u()) {
                    FragmentManager H = MoreSettingsActivity.this.H();
                    new r(true).w0(H, "parental_control_tag");
                    H.f10141m.f10370a.add(new y.a(new C0144a(H), false));
                } else {
                    MoreSettingsActivity.this.f20443r.setChecked(!r5.isChecked());
                    f.S(MoreSettingsActivity.this.f20443r.isChecked());
                }
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66730_resource_name_obfuscated_res_0x7f1302f3))) {
                SwitchMaterial switchMaterial5 = MoreSettingsActivity.this.f20443r;
                if (switchMaterial5 == null) {
                    return;
                }
                switchMaterial5.setChecked(!switchMaterial5.isChecked());
                boolean isChecked4 = MoreSettingsActivity.this.f20443r.isChecked();
                i iVar = c.f14183a;
                xe.e.f44786a.o("MultimediaTunneling", isChecked4);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66650_resource_name_obfuscated_res_0x7f1302eb))) {
                Intent intent = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent.putExtra("OptionsType", 21);
                MoreSettingsActivity.this.startActivity(intent);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66840_resource_name_obfuscated_res_0x7f1302fe))) {
                Intent intent2 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent2.putExtra("OptionsType", 12);
                MoreSettingsActivity.this.startActivity(intent2);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66910_resource_name_obfuscated_res_0x7f130305))) {
                Intent intent3 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent3.putExtra("OptionsType", 8);
                MoreSettingsActivity.this.startActivity(intent3);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66920_resource_name_obfuscated_res_0x7f130306))) {
                Intent intent4 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent4.putExtra("OptionsType", 9);
                MoreSettingsActivity.this.startActivity(intent4);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66830_resource_name_obfuscated_res_0x7f1302fd))) {
                Intent intent5 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent5.putExtra("OptionsType", 10);
                MoreSettingsActivity.this.startActivity(intent5);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f60700_resource_name_obfuscated_res_0x7f130098))) {
                Intent intent6 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent6.putExtra("OptionsType", 20);
                MoreSettingsActivity.this.startActivity(intent6);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66520_resource_name_obfuscated_res_0x7f1302de))) {
                Intent intent7 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent7.putExtra("OptionsType", 19);
                MoreSettingsActivity.this.startActivity(intent7);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66500_resource_name_obfuscated_res_0x7f1302dc))) {
                Intent intent8 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent8.putExtra("OptionsType", 7);
                MoreSettingsActivity.this.startActivity(intent8);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66490_resource_name_obfuscated_res_0x7f1302db))) {
                Intent intent9 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent9.putExtra("OptionsType", 2);
                MoreSettingsActivity.this.startActivity(intent9);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66550_resource_name_obfuscated_res_0x7f1302e1))) {
                Intent intent10 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent10.putExtra("OptionsType", 14);
                MoreSettingsActivity.this.startActivity(intent10);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66240_resource_name_obfuscated_res_0x7f1302c2))) {
                Intent intent11 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent11.putExtra("OptionsType", 0);
                MoreSettingsActivity.this.startActivity(intent11);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66340_resource_name_obfuscated_res_0x7f1302cc))) {
                Intent intent12 = new Intent(MoreSettingsActivity.this, (Class<?>) OptionsActivity.class);
                intent12.putExtra("OptionsType", 1);
                MoreSettingsActivity.this.startActivity(intent12);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66330_resource_name_obfuscated_res_0x7f1302cb))) {
                SwitchMaterial switchMaterial6 = MoreSettingsActivity.this.f20443r;
                if (switchMaterial6 == null) {
                    return;
                }
                switchMaterial6.setChecked(!switchMaterial6.isChecked());
                boolean isChecked5 = MoreSettingsActivity.this.f20443r.isChecked();
                MMKV mmkv = xe.e.f44797l;
                Objects.requireNonNull(mmkv);
                mmkv.putBoolean("ForceLandscapeInFullscreen", isChecked5);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f66230_resource_name_obfuscated_res_0x7f1302c1))) {
                SwitchMaterial switchMaterial7 = MoreSettingsActivity.this.f20443r;
                if (switchMaterial7 == null) {
                    return;
                }
                switchMaterial7.setChecked(!switchMaterial7.isChecked());
                boolean isChecked6 = MoreSettingsActivity.this.f20443r.isChecked();
                i iVar2 = c.f14183a;
                xe.e.f44786a.o("TrustInvalidSSL", isChecked6);
                MoreSettingsActivity moreSettingsActivity = MoreSettingsActivity.this;
                cg.a.W(moreSettingsActivity, moreSettingsActivity.getString(R.string.f59900_resource_name_obfuscated_res_0x7f130048), 1);
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f65130_resource_name_obfuscated_res_0x7f130253))) {
                boolean z12 = c.f() && c.l().equals(Keys.getSCPRC());
                SwitchMaterial switchMaterial8 = MoreSettingsActivity.this.f20443r;
                if (switchMaterial8 == null || !z12) {
                    return;
                }
                if (switchMaterial8.isChecked()) {
                    MoreSettingsActivity.this.f20443r.setChecked(false);
                    c.K(false);
                    cg.a.Z(MoreSettingsActivity.this.getApplicationContext(), ForegroundService.a.f20032d);
                } else {
                    int i11 = Build.VERSION.SDK_INT;
                    if (i11 < 29) {
                        MoreSettingsActivity.this.f20443r.setChecked(true);
                        c.K(true);
                        cg.a.Y(MoreSettingsActivity.this.getApplicationContext(), ForegroundService.a.f20031c);
                    } else if (Settings.canDrawOverlays(MoreSettingsActivity.this)) {
                        MoreSettingsActivity.this.f20443r.setChecked(true);
                        c.K(true);
                        cg.a.Y(MoreSettingsActivity.this.getApplicationContext(), ForegroundService.a.f20031c);
                    } else {
                        MoreSettingsActivity moreSettingsActivity2 = MoreSettingsActivity.this;
                        SimpleDateFormat simpleDateFormat = cg.a.f14170a;
                        if (i11 >= 29) {
                            try {
                                moreSettingsActivity2.startActivityForResult(new Intent("android.settings.action.MANAGE_OVERLAY_PERMISSION"), 1204);
                            } catch (ActivityNotFoundException e10) {
                                e10.printStackTrace();
                                cg.a.W(moreSettingsActivity2, moreSettingsActivity2.getString(R.string.f61380_resource_name_obfuscated_res_0x7f1300dc), 1);
                            } catch (Exception e11) {
                                e11.printStackTrace();
                                cg.a.W(moreSettingsActivity2, moreSettingsActivity2.getString(R.string.f61470_resource_name_obfuscated_res_0x7f1300e5), 0);
                            }
                        }
                    }
                }
            }
            if (str.equals(MoreSettingsActivity.this.getString(R.string.f65080_resource_name_obfuscated_res_0x7f13024e))) {
                if (c.f() && c.l().equals(Keys.getSCPRC())) {
                    z10 = true;
                }
                SwitchMaterial switchMaterial9 = MoreSettingsActivity.this.f20443r;
                if (switchMaterial9 == null || !z10) {
                    return;
                }
                switchMaterial9.setChecked(!switchMaterial9.isChecked());
                xe.e.f44786a.o("BackgroundPlay", MoreSettingsActivity.this.f20443r.isChecked());
            }
            if (!str.equals(MoreSettingsActivity.this.getString(R.string.f66810_resource_name_obfuscated_res_0x7f1302fb)) || (switchMaterial = MoreSettingsActivity.this.f20443r) == null) {
                return;
            }
            switchMaterial.setChecked(!switchMaterial.isChecked());
            boolean isChecked7 = MoreSettingsActivity.this.f20443r.isChecked();
            i iVar3 = c.f14183a;
            xe.e.f44786a.o("HardwareAccelerationForChannelDetails", isChecked7);
        }
    }

    @Override
    public void onActivityResult(int i10, int i11, Intent intent) {
        super.onActivityResult(i10, i11, intent);
        if (i10 == 1204 && Build.VERSION.SDK_INT >= 29 && Settings.canDrawOverlays(this)) {
            c.K(true);
            cg.a.Y(getApplicationContext(), ForegroundService.a.f20031c);
            this.f20442q.notifyDataSetChanged();
        }
    }

    @Override
    public void onConfigurationChanged(Configuration configuration) {
        super.onConfigurationChanged(configuration);
        ConstraintLayout.a aVar = (ConstraintLayout.a) this.f20444s.getLayoutParams();
        int dimensionPixelSize = getResources().getDimensionPixelSize(R.dimen.f33290_resource_name_obfuscated_res_0x7f0703d0);
        ((ViewGroup.MarginLayoutParams) aVar).height = dimensionPixelSize;
        this.f20444s.setMinimumHeight(dimensionPixelSize);
        ((ViewGroup.MarginLayoutParams) ((ConstraintLayout.a) this.f20445t.getLayoutParams())).topMargin = getResources().getDimensionPixelSize(R.dimen.f33290_resource_name_obfuscated_res_0x7f0703d0);
    }

    @Override
    public void onCreate(Bundle bundle) {
        super.onCreate(bundle);
        setContentView(R.layout.f56020_resource_name_obfuscated_res_0x7f0e0027);
        Toolbar toolbar = (Toolbar) findViewById(R.id.f52200_resource_name_obfuscated_res_0x7f0b0438);
        this.f20444s = toolbar;
        toolbar.setTitle(R.string.f63120_resource_name_obfuscated_res_0x7f13018a);
        this.f20444s.setNavigationIcon(R.drawable.f36350_resource_name_obfuscated_res_0x7f080123);
        this.f20444s.setNavigationOnClickListener(new b(this));
        this.f20445t = (ListView) findViewById(R.id.f52170_resource_name_obfuscated_res_0x7f0b0435);
        boolean z10 = c.f() && c.l().equals(Keys.getSCPRC());
        if (z10) {
            this.f20441p.add(new g(getString(R.string.f63100_resource_name_obfuscated_res_0x7f130188), 2));
        } else {
            this.f20441p.add(new g(getString(R.string.f63100_resource_name_obfuscated_res_0x7f130188), getString(R.string.f60100_resource_name_obfuscated_res_0x7f13005c), 3));
        }
        if (cg.a.g(this)) {
            if (z10) {
                this.f20441p.add(new g(getString(R.string.f65130_resource_name_obfuscated_res_0x7f130253), getString(R.string.f59820_resource_name_obfuscated_res_0x7f130040), 3));
            } else {
                this.f20441p.add(new g(getString(R.string.f65130_resource_name_obfuscated_res_0x7f130253), getString(R.string.f60100_resource_name_obfuscated_res_0x7f13005c), 3));
            }
        }
        this.f20441p.add(new g(getString(R.string.f66750_resource_name_obfuscated_res_0x7f1302f5), getString(R.string.f66740_resource_name_obfuscated_res_0x7f1302f4), 3));
        if (cg.a.g(this)) {
            this.f20441p.add(new g(getString(R.string.f66810_resource_name_obfuscated_res_0x7f1302fb), getString(R.string.f66800_resource_name_obfuscated_res_0x7f1302fa), 3));
        }
        this.f20441p.add(new g(getString(R.string.f66710_resource_name_obfuscated_res_0x7f1302f1), getString(R.string.f66720_resource_name_obfuscated_res_0x7f1302f2), 3));
        if (!cg.a.g(this)) {
            this.f20441p.add(new g(getString(R.string.f66330_resource_name_obfuscated_res_0x7f1302cb), getString(R.string.f66320_resource_name_obfuscated_res_0x7f1302ca), 3));
        }
        if (!cg.a.g(this)) {
            if (z10) {
                this.f20441p.add(new g(getString(R.string.f65080_resource_name_obfuscated_res_0x7f13024e), getString(R.string.f65070_resource_name_obfuscated_res_0x7f13024d), 3));
            } else {
                this.f20441p.add(new g(getString(R.string.f65080_resource_name_obfuscated_res_0x7f13024e), getString(R.string.f60100_resource_name_obfuscated_res_0x7f13005c), 3));
            }
        }
        this.f20441p.add(new g(getString(R.string.f65300_resource_name_obfuscated_res_0x7f130264), getString(R.string.f65240_resource_name_obfuscated_res_0x7f13025e), 1));
        this.f20441p.add(new g(getString(R.string.f66650_resource_name_obfuscated_res_0x7f1302eb), 0));
        if (cg.a.g(this)) {
            this.f20441p.add(new g(getString(R.string.f66520_resource_name_obfuscated_res_0x7f1302de), 0));
        }
        this.f20441p.add(new g(getString(R.string.f66500_resource_name_obfuscated_res_0x7f1302dc), getString(R.string.f66510_resource_name_obfuscated_res_0x7f1302dd), 1));
        this.f20441p.add(new g(getString(R.string.f66490_resource_name_obfuscated_res_0x7f1302db), getString(R.string.f66480_resource_name_obfuscated_res_0x7f1302da), 1));
        this.f20441p.add(new g(getString(R.string.f66840_resource_name_obfuscated_res_0x7f1302fe), 0));
        this.f20441p.add(new g(getString(R.string.f66910_resource_name_obfuscated_res_0x7f130305), 0));
        this.f20441p.add(new g(getString(R.string.f66920_resource_name_obfuscated_res_0x7f130306), 0));
        this.f20441p.add(new g(getString(R.string.f66830_resource_name_obfuscated_res_0x7f1302fd), 0));
        this.f20441p.add(new g(getString(R.string.f66550_resource_name_obfuscated_res_0x7f1302e1), 0));
        this.f20441p.add(new g(getString(R.string.f66240_resource_name_obfuscated_res_0x7f1302c2), 0));
        this.f20441p.add(new g(getString(R.string.f66340_resource_name_obfuscated_res_0x7f1302cc), 0));
        m mVar = new m(this, this.f20441p);
        this.f20442q = mVar;
        this.f20445t.setAdapter((ListAdapter) mVar);
        this.f20445t.setOnItemClickListener(new a());
    }
}