导航菜单

页面标题

页面副标题

Chaupal v3.2 - u.java 源代码

正在查看: Chaupal v3.2 应用的 u.java JAVA 源代码文件

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


package hd;

import android.app.Activity;
import android.app.Dialog;
import android.content.ActivityNotFoundException;
import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.os.Build;
import android.os.Bundle;
import android.os.Parcelable;
import android.text.SpannableString;
import android.text.TextUtils;
import android.text.style.StyleSpan;
import android.util.Base64;
import android.view.View;
import android.widget.CheckBox;
import android.widget.ImageView;
import android.widget.TextView;
import android.widget.Toast;
import androidx.activity.ComponentActivity;
import androidx.appcompat.widget.AppCompatButton;
import androidx.browser.customtabs.d;
import androidx.core.view.n0;
import androidx.core.view.o0;
import androidx.core.view.p0;
import androidx.fragment.app.Fragment;
import androidx.fragment.app.FragmentManager;
import com.google.android.gms.measurement.api.AppMeasurementSdk;
import com.razorpay.R;
import com.yupptv.ott.MainActivity;
import com.yupptv.ott.OTTApplication;
import com.yupptv.ott.SplashScreenActivity;
import com.yupptv.ott.WebViewActivity;
import com.yupptv.ott.activity.LoadScreenActivity;
import com.yupptv.ott.enums.ButtonType;
import com.yupptv.ott.enums.DialogType;
import com.yupptv.ott.enums.ListType;
import com.yupptv.ott.enums.OTPType;
import com.yupptv.ott.enums.PageType;
import com.yupptv.ott.enums.PosterType;
import com.yupptv.ott.enums.ScreenType;
import com.yupptv.ott.fragments.ActivateDeviceFragment;
import com.yupptv.ott.fragments.PaymentsFragment;
import com.yupptv.ott.fragments.VideoSignInFragment;
import com.yupptv.ott.fragments.a1;
import com.yupptv.ott.fragments.c1;
import com.yupptv.ott.fragments.d1;
import com.yupptv.ott.fragments.e1;
import com.yupptv.ott.fragments.f1;
import com.yupptv.ott.fragments.g1;
import com.yupptv.ott.fragments.h1;
import com.yupptv.ott.fragments.i1;
import com.yupptv.ott.fragments.l0;
import com.yupptv.ott.fragments.n1;
import com.yupptv.ott.fragments.onboarding.SignInFragment;
import com.yupptv.ott.fragments.onboarding.SignupFragmentStep2;
import com.yupptv.ott.fragments.onboarding.f0;
import com.yupptv.ott.fragments.onboarding.s;
import com.yupptv.ott.fragments.payment.NewPackageFragment;
import com.yupptv.ott.fragments.t2;
import com.yupptv.ott.fragments.v0;
import com.yupptv.ott.fragments.w2;
import com.yupptv.ott.fragments.x0;
import com.yupptv.ott.fragments.x1;
import com.yupptv.ott.fragments.y0;
import com.yupptv.ott.fragments.z0;
import com.yupptv.ott.widget.HeaderItemWithControls;
import com.yupptv.ottsdk.OttSDK;
import com.yupptv.ottsdk.enums.TenantBuildType;
import com.yupptv.ottsdk.managers.Application.AppManager;
import com.yupptv.ottsdk.managers.MediaCatalog.MediaCatalogManager;
import com.yupptv.ottsdk.managers.Preferences.PreferenceManager;
import com.yupptv.ottsdk.managers.User.UserManager;
import com.yupptv.ottsdk.model.Banner;
import com.yupptv.ottsdk.model.BottomTemplate;
import com.yupptv.ottsdk.model.Card;
import com.yupptv.ottsdk.model.ContentPage;
import com.yupptv.ottsdk.model.DeeplinkInfo;
import com.yupptv.ottsdk.model.Error;
import com.yupptv.ottsdk.model.Menu;
import com.yupptv.ottsdk.model.Networks;
import com.yupptv.ottsdk.model.NotificationDetailsInfo;
import com.yupptv.ottsdk.model.User;
import com.yupptv.ottsdk.model.payments.PackagesV2;
import com.yupptv.ottsdk.model.user.Configs;
import com.yupptv.ottsdk.utils.OttLog;
import com.yupptv.ottsdk.utils.SessionListener;
import hd.a;
import in.startv.hotstar.hotstarlauncher.VersionNotSupportedException;
import java.net.URLEncoder;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Objects;
import org.json.JSONException;
import org.json.JSONObject;

public class u {
    public static boolean a = false;
    public static String b = "";
    public static boolean c = false;
    public static String d = null;
    public static String e = null;
    public static String f = "";
    public static String g = "";
    public static String h = "hd.u";
    public static String i = com.yupptv.ott.a.I;
    public static String j = " ";

    class a implements oc.d {
        final String a;
        final androidx.fragment.app.h b;
        final String c;
        final String d;

        class C0135a implements MediaCatalogManager.MediaCatalogCallback<ContentPage> {
            C0135a() {
            }

            @Override
            public void onSuccess(ContentPage contentPage) {
                androidx.fragment.app.h hVar = a.this.b;
                if (hVar == null) {
                    return;
                }
                String pageType = contentPage.getPageInfo().getPageType();
                a aVar = a.this;
                u.v0(hVar, contentPage, pageType, aVar.a, aVar.d, "");
            }

            @Override
            public void onFailure(Error error) {
                if (TextUtils.isEmpty(error.getMessage())) {
                    return;
                }
                Toast.makeText((Context) a.this.b, (CharSequence) error.getMessage(), 0).show();
            }
        }

        a(String str, androidx.fragment.app.h hVar, String str2, String str3) {
            this.a = str;
            this.b = hVar;
            this.c = str2;
            this.d = str3;
        }

        @Override
        public void a(AppCompatButton appCompatButton, Object obj, ButtonType buttonType) {
            String str;
            cc.b.B0().b2("Bottom Overlay");
            try {
                str = (String) appCompatButton.getTag();
                if (str == null || str.equalsIgnoreCase("")) {
                    str = this.a;
                }
            } catch (Exception unused) {
                str = this.a;
            }
            if (obj == null && !buttonType.equals(ButtonType.DELETE_RECORD) && !buttonType.equals(ButtonType.UPGRADE) && !buttonType.equals(ButtonType.SUBSCRIBE) && !buttonType.equals(ButtonType.DELETE_RECORD_FROM_VIEWALL)) {
                this.b.J1();
                this.b.s4(buttonType);
                this.b.D4(this.c);
                if (e0.h0(this.b)) {
                    this.b.H2(str);
                    return;
                } else {
                    androidx.fragment.app.h hVar = this.b;
                    Toast.makeText((Context) hVar, (CharSequence) hVar.getResources().getString(2131952922), 0).show();
                    return;
                }
            }
            if (buttonType.equals(ButtonType.BROWSE_EPISODES)) {
                a.C0133a c0133a = hd.a.a;
                c0133a.f(OTTApplication.o()).cancelAll();
                c0133a.f(OTTApplication.o()).getPageContent(this.a, new C0135a());
                return;
            }
            if (buttonType.equals(ButtonType.DELETE_RECORD)) {
                MainActivity mainActivity = this.b;
                if (mainActivity == null || !(mainActivity instanceof MainActivity) || mainActivity.g1.equalsIgnoreCase("search")) {
                    return;
                }
                this.b.c4();
                return;
            }
            if (buttonType.equals(ButtonType.UPGRADE)) {
                this.b.d2(r.j0, r.i1, 29);
                return;
            }
            if (buttonType.equals(ButtonType.SUBSCRIBE)) {
                this.b.x2 = true;
                cc.b.B0().b2("bottom dialog");
                this.b.F3(false, null, new String[0]);
            } else {
                if (buttonType.equals(ButtonType.WATCH_EPISODE)) {
                    this.b.J1();
                    this.b.s4(buttonType);
                    this.b.D4(this.c);
                    this.b.H2(str);
                    return;
                }
                if (buttonType.equals(ButtonType.DELETE_RECORD_FROM_VIEWALL)) {
                    this.b.f4();
                } else if (buttonType.equals(ButtonType.SIGNIN)) {
                    this.b.y3(false, -1);
                }
            }
        }

        @Override
        public void onDismiss() {
            androidx.fragment.app.h hVar;
            androidx.fragment.app.h hVar2;
            try {
                androidx.fragment.app.h hVar3 = this.b;
                Objects.requireNonNull(hVar3);
                hVar3.isFinishing();
                String str = this.c;
                if (str != null && str.equalsIgnoreCase("Search_Page") && (hVar2 = this.b) != null && !hVar2.isFinishing()) {
                    MainActivity mainActivity = this.b;
                    if (mainActivity instanceof MainActivity) {
                        mainActivity.j4();
                    }
                }
                String str2 = this.c;
                if (str2 == null || !str2.equalsIgnoreCase("Favourites_Page") || (hVar = this.b) == null || hVar.isFinishing()) {
                    return;
                }
                MainActivity mainActivity2 = this.b;
                if (mainActivity2 instanceof MainActivity) {
                    mainActivity2.a4();
                }
            } catch (Exception unused) {
            }
        }
    }

    class b implements SessionListener {
        final Context a;

        b(Context context) {
            this.a = context;
        }

        public void onSessionExpired(Error error) {
            u.k(this.a);
        }
    }

    class c implements SessionListener {
        final Context a;

        c(Context context) {
            this.a = context;
        }

        public void onSessionExpired(Error error) {
            u.k(this.a);
        }
    }

    class d implements AppManager.AppManagerCallback<JSONObject> {
        final Context a;

        d(Context context) {
            this.a = context;
        }

        public void onSuccess(JSONObject jSONObject) {
            u.E(this.a);
        }

        public void onFailure(Error error) {
            u.E(this.a);
        }
    }

    class e implements UserManager.UserCallback<String> {
        final String a;
        final Context b;

        e(String str, Context context) {
            this.a = str;
            this.b = context;
        }

        @Override
        public void onSuccess(String str) {
            if (this.a.equalsIgnoreCase("ENG")) {
                OTTApplication.O(this.b);
            }
            hd.a.a.b(OTTApplication.o());
            OttSDK.setLocaleEnglish(this.b);
            u.o(this.b);
        }

        @Override
        public void onFailure(Error error) {
        }
    }

    class f implements MediaCatalogManager.MediaCatalogCallback<NotificationDetailsInfo> {
        final Context a;
        final String b;
        final String c;
        final String d;
        final oc.e e;

        f(Context context, String str, String str2, String str3, oc.e eVar) {
            this.a = context;
            this.b = str;
            this.c = str2;
            this.d = str3;
            this.e = eVar;
        }

        @Override
        public void onSuccess(NotificationDetailsInfo notificationDetailsInfo) {
            if (notificationDetailsInfo == null) {
                this.e.a();
            } else if (notificationDetailsInfo.isShowNotification()) {
                u.G0(this.a, this.b, this.c, this.d, this.e);
            } else {
                this.e.a();
            }
        }

        @Override
        public void onFailure(Error error) {
            this.e.a();
        }
    }

    class g implements MediaCatalogManager.MediaCatalogCallback<JSONObject> {
        g() {
        }

        @Override
        public void onSuccess(JSONObject jSONObject) {
        }

        @Override
        public void onFailure(Error error) {
        }
    }

    static class h {
        static final int[] a;
        static final int[] b;
        static final int[] c;

        static {
            int[] iArr = new int[DialogType.values().length];
            c = iArr;
            try {
                iArr[DialogType.PACKAGE_INFO_DIALOG.ordinal()] = 1;
            } catch (NoSuchFieldError unused) {
            }
            try {
                c[DialogType.MESSAGE_DIALOG.ordinal()] = 2;
            } catch (NoSuchFieldError unused2) {
            }
            try {
                c[DialogType.COUNTRIES_DIALOG.ordinal()] = 3;
            } catch (NoSuchFieldError unused3) {
            }
            try {
                c[DialogType.SESSION_EXPIRED_DIALOG.ordinal()] = 4;
            } catch (NoSuchFieldError unused4) {
            }
            try {
                c[DialogType.DELINK_DEVICE.ordinal()] = 5;
            } catch (NoSuchFieldError unused5) {
            }
            try {
                c[DialogType.PAYMENT_OPTIONS.ordinal()] = 6;
            } catch (NoSuchFieldError unused6) {
            }
            try {
                c[DialogType.CONTINUE_WATCHING_DIALOG.ordinal()] = 7;
            } catch (NoSuchFieldError unused7) {
            }
            try {
                c[DialogType.REMOVE_FROM_CONTINUE_WATCHING.ordinal()] = 8;
            } catch (NoSuchFieldError unused8) {
            }
            try {
                c[DialogType.CONTINUE_LOGOUT_DIALOG.ordinal()] = 9;
            } catch (NoSuchFieldError unused9) {
            }
            try {
                c[DialogType.APP_UPDATE.ordinal()] = 10;
            } catch (NoSuchFieldError unused10) {
            }
            try {
                c[DialogType.RECORD.ordinal()] = 11;
            } catch (NoSuchFieldError unused11) {
            }
            try {
                c[DialogType.PAYMENT_CONFIRMATION_DIALOG.ordinal()] = 12;
            } catch (NoSuchFieldError unused12) {
            }
            try {
                c[DialogType.LEAVE_PAGE_DIALOG.ordinal()] = 13;
            } catch (NoSuchFieldError unused13) {
            }
            try {
                c[DialogType.REGISTRATION_SUCCESS_DIALOG.ordinal()] = 14;
            } catch (NoSuchFieldError unused14) {
            }
            try {
                c[DialogType.REMOVE_LINKED_DEVICE_DIALOG.ordinal()] = 15;
            } catch (NoSuchFieldError unused15) {
            }
            try {
                c[DialogType.LINKED_DEVICE_LIMIT_DIALOG.ordinal()] = 16;
            } catch (NoSuchFieldError unused16) {
            }
            try {
                c[DialogType.STARTOVER_DIALOG.ordinal()] = 17;
            } catch (NoSuchFieldError unused17) {
            }
            try {
                c[DialogType.PLAYER_ACTIVE_SCREEN_DIALOG.ordinal()] = 18;
            } catch (NoSuchFieldError unused18) {
            }
            try {
                c[DialogType.SETTINGS_ACTIVE_SCREEN_DIALOG.ordinal()] = 19;
            } catch (NoSuchFieldError unused19) {
            }
            try {
                c[DialogType.REMOVE_SAVED_CARD_DIALOG.ordinal()] = 20;
            } catch (NoSuchFieldError unused20) {
            }
            try {
                c[DialogType.CHANGE_PLAN_DIALOG.ordinal()] = 21;
            } catch (NoSuchFieldError unused21) {
            }
            try {
                c[DialogType.ORDER_SUMMARY_DIALOG.ordinal()] = 22;
            } catch (NoSuchFieldError unused22) {
            }
            try {
                c[DialogType.TAX_INFO_DIALOG.ordinal()] = 23;
            } catch (NoSuchFieldError unused23) {
            }
            try {
                c[DialogType.ERROR_MESSAGE_DIALOG.ordinal()] = 24;
            } catch (NoSuchFieldError unused24) {
            }
            try {
                c[DialogType.SIGNIN_SIGNUP_INFO_DIALOG.ordinal()] = 25;
            } catch (NoSuchFieldError unused25) {
            }
            try {
                c[DialogType.FEEDBACK_RATING_DIALOG.ordinal()] = 26;
            } catch (NoSuchFieldError unused26) {
            }
            try {
                c[DialogType.GDPR_COOKIE_POLICY_DIALOG.ordinal()] = 27;
            } catch (NoSuchFieldError unused27) {
            }
            try {
                c[DialogType.WEBVIEW_NAVIGATION_DIALOG.ordinal()] = 28;
            } catch (NoSuchFieldError unused28) {
            }
            try {
                c[DialogType.OFFLINE_DELETE_DIALOG.ordinal()] = 29;
            } catch (NoSuchFieldError unused29) {
            }
            try {
                c[DialogType.PACKAGE_SUBSCRIBE_DIALOG.ordinal()] = 30;
            } catch (NoSuchFieldError unused30) {
            }
            try {
                c[DialogType.DONT_HAVE_SUBSCRIPTION_DIALOG.ordinal()] = 31;
            } catch (NoSuchFieldError unused31) {
            }
            try {
                c[DialogType.NEED_SUBSCRIPTION_DIALOG.ordinal()] = 32;
            } catch (NoSuchFieldError unused32) {
            }
            try {
                c[DialogType.VOUCHER_APPLY_FAILURE_DIALOG.ordinal()] = 33;
            } catch (NoSuchFieldError unused33) {
            }
            try {
                c[DialogType.SUBSCRIBE_RENT_INFO_DIALOG.ordinal()] = 34;
            } catch (NoSuchFieldError unused34) {
            }
            try {
                c[DialogType.PARENTAL_CONTROL_PASSCODE_DIALOG.ordinal()] = 35;
            } catch (NoSuchFieldError unused35) {
            }
            try {
                c[DialogType.UPDATE_AGE_DOB_DIALOG.ordinal()] = 36;
            } catch (NoSuchFieldError unused36) {
            }
            try {
                c[DialogType.USER_PROFILE_PASSCODE_DIALOG.ordinal()] = 37;
            } catch (NoSuchFieldError unused37) {
            }
            try {
                c[DialogType.ADD_USER_PROFILE_PASSCODE_DIALOG.ordinal()] = 38;
            } catch (NoSuchFieldError unused38) {
            }
            try {
                c[DialogType.AFTER_DARK_PASSCODE_DIALOG.ordinal()] = 39;
            } catch (NoSuchFieldError unused39) {
            }
            try {
                c[DialogType.ENVIRONMENT_LIST_DIALOG.ordinal()] = 40;
            } catch (NoSuchFieldError unused40) {
            }
            try {
                c[DialogType.LOGIN_TYPE_DIALOG.ordinal()] = 41;
            } catch (NoSuchFieldError unused41) {
            }
            try {
                c[DialogType.INSERT_PASSWORD_DIALOG.ordinal()] = 42;
            } catch (NoSuchFieldError unused42) {
            }
            try {
                c[DialogType.CANCEL_DOWNLOAD_DIALOG.ordinal()] = 43;
            } catch (NoSuchFieldError unused43) {
            }
            try {
                c[DialogType.FORGOT_PWD_VIA_WEB_DIALOG.ordinal()] = 44;
            } catch (NoSuchFieldError unused44) {
            }
            try {
                c[DialogType.DIALOG_SORTING_SEARCH.ordinal()] = 45;
            } catch (NoSuchFieldError unused45) {
            }
            try {
                c[DialogType.NAVIGATE_TO_APP_INFO_NOTIFICATION.ordinal()] = 46;
            } catch (NoSuchFieldError unused46) {
            }
            int[] iArr2 = new int[ScreenType.values().length];
            b = iArr2;
            try {
                iArr2[ScreenType.SIGNUP.ordinal()] = 1;
            } catch (NoSuchFieldError unused47) {
            }
            try {
                b[ScreenType.SIGNUP2.ordinal()] = 2;
            } catch (NoSuchFieldError unused48) {
            }
            try {
                b[ScreenType.SIGNIN.ordinal()] = 3;
            } catch (NoSuchFieldError unused49) {
            }
            try {
                b[ScreenType.UPDATE_PASSWORD.ordinal()] = 4;
            } catch (NoSuchFieldError unused50) {
            }
            try {
                b[ScreenType.PAYMENTS_MAIN.ordinal()] = 5;
            } catch (NoSuchFieldError unused51) {
            }
            try {
                b[ScreenType.PACKAGES_MAIN.ordinal()] = 6;
            } catch (NoSuchFieldError unused52) {
            }
            try {
                b[ScreenType.USER_PROFILE.ordinal()] = 7;
            } catch (NoSuchFieldError unused53) {
            }
            try {
                b[ScreenType.PAYMENTS.ordinal()] = 8;
            } catch (NoSuchFieldError unused54) {
            }
            try {
                b[ScreenType.UPDATE_CARD.ordinal()] = 9;
            } catch (NoSuchFieldError unused55) {
            }
            try {
                b[ScreenType.UPDATE_EMAIL_MOBILE.ordinal()] = 10;
            } catch (NoSuchFieldError unused56) {
            }
            try {
                b[ScreenType.ACTIVE_PACKAGES.ordinal()] = 11;
            } catch (NoSuchFieldError unused57) {
            }
            try {
                b[ScreenType.TRANSACTIONS.ordinal()] = 12;
            } catch (NoSuchFieldError unused58) {
            }
            try {
                b[ScreenType.FORGOT_PASSWORD.ordinal()] = 13;
            } catch (NoSuchFieldError unused59) {
            }
            try {
                b[ScreenType.VIEW_LANGUAGES.ordinal()] = 14;
            } catch (NoSuchFieldError unused60) {
            }
            try {
                b[ScreenType.CHANGE_EMAIL_ID.ordinal()] = 15;
            } catch (NoSuchFieldError unused61) {
            }
            try {
                b[ScreenType.CHANGE_FULL_NAME.ordinal()] = 16;
            } catch (NoSuchFieldError unused62) {
            }
            try {
                b[ScreenType.CHANGE_MOBILE_NUMBER.ordinal()] = 17;
            } catch (NoSuchFieldError unused63) {
            }
            try {
                b[ScreenType.USER_PROFILES.ordinal()] = 18;
            } catch (NoSuchFieldError unused64) {
            }
            try {
                b[ScreenType.CREATE_USER_PROFILES.ordinal()] = 19;
            } catch (NoSuchFieldError unused65) {
            }
            try {
                b[ScreenType.FORGOT_PIN.ordinal()] = 20;
            } catch (NoSuchFieldError unused66) {
            }
            try {
                b[ScreenType.REDEEM_VOUCHER.ordinal()] = 21;
            } catch (NoSuchFieldError unused67) {
            }
            try {
                b[ScreenType.FILTER_CONTENT.ordinal()] = 22;
            } catch (NoSuchFieldError unused68) {
            }
            try {
                b[ScreenType.GIFTPACK_SCREEN.ordinal()] = 23;
            } catch (NoSuchFieldError unused69) {
            }
            try {
                b[ScreenType.MOBILEPAYMENT.ordinal()] = 24;
            } catch (NoSuchFieldError unused70) {
            }
            try {
                b[ScreenType.EMAILPAYMENT.ordinal()] = 25;
            } catch (NoSuchFieldError unused71) {
            }
            try {
                b[ScreenType.CARDPAYMENT.ordinal()] = 26;
            } catch (NoSuchFieldError unused72) {
            }
            try {
                b[ScreenType.SELECTEDPAYMENTS.ordinal()] = 27;
            } catch (NoSuchFieldError unused73) {
            }
            try {
                b[ScreenType.SAVED_CARDS.ordinal()] = 28;
            } catch (NoSuchFieldError unused74) {
            }
            try {
                b[ScreenType.ADD_NEWCARD.ordinal()] = 29;
            } catch (NoSuchFieldError unused75) {
            }
            try {
                b[ScreenType.MY_QUESTIONS.ordinal()] = 30;
            } catch (NoSuchFieldError unused76) {
            }
            try {
                b[ScreenType.FULL_SCREEN.ordinal()] = 31;
            } catch (NoSuchFieldError unused77) {
            }
            try {
                b[ScreenType.PAYMENT_ORDER_SUMMARY.ordinal()] = 32;
            } catch (NoSuchFieldError unused78) {
            }
            try {
                b[ScreenType.PAYMENT_GATEWAYS.ordinal()] = 33;
            } catch (NoSuchFieldError unused79) {
            }
            try {
                b[ScreenType.PAYPAL_PAYMENT.ordinal()] = 34;
            } catch (NoSuchFieldError unused80) {
            }
            try {
                b[ScreenType.FAVOURITES.ordinal()] = 35;
            } catch (NoSuchFieldError unused81) {
            }
            try {
                b[ScreenType.PURCHASED_ITEMS.ordinal()] = 36;
            } catch (NoSuchFieldError unused82) {
            }
            try {
                b[ScreenType.OFFLINE_VIDEO.ordinal()] = 37;
            } catch (NoSuchFieldError unused83) {
            }
            try {
                b[ScreenType.VIDEO_QUALITY.ordinal()] = 38;
            } catch (NoSuchFieldError unused84) {
            }
            try {
                b[ScreenType.APP_SETTINGS.ordinal()] = 39;
            } catch (NoSuchFieldError unused85) {
            }
            try {
                b[ScreenType.APP_THEME.ordinal()] = 40;
            } catch (NoSuchFieldError unused86) {
            }
            try {
                b[ScreenType.CONTENT_FILTER.ordinal()] = 41;
            } catch (NoSuchFieldError unused87) {
            }
            try {
                b[ScreenType.ACTIVATE_DEVICE.ordinal()] = 42;
            } catch (NoSuchFieldError unused88) {
            }
            int[] iArr3 = new int[PageType.values().length];
            a = iArr3;
            try {
                iArr3[PageType.Content.ordinal()] = 1;
            } catch (NoSuchFieldError unused89) {
            }
            try {
                a[PageType.Details.ordinal()] = 2;
            } catch (NoSuchFieldError unused90) {
            }
            try {
                a[PageType.List.ordinal()] = 3;
            } catch (NoSuchFieldError unused91) {
            }
            try {
                a[PageType.Player.ordinal()] = 4;
            } catch (NoSuchFieldError unused92) {
            }
            try {
                a[PageType.Error.ordinal()] = 5;
            } catch (NoSuchFieldError unused93) {
            }
        }
    }

    class i implements oc.e {
        final String a;
        final String b;
        final Context c;

        class a implements MediaCatalogManager.MediaCatalogCallback<DeeplinkInfo> {
            a() {
            }

            @Override
            public void onSuccess(DeeplinkInfo deeplinkInfo) {
                Object obj = i.this.c;
                if (obj instanceof MainActivity) {
                    ((MainActivity) obj).Q2();
                }
                if (deeplinkInfo == null || deeplinkInfo.getContentCode() == null || deeplinkInfo.getContentCode().trim().length() <= 0 || deeplinkInfo.getPartnerCode() == null || deeplinkInfo.getPartnerCode().trim().length() <= 0) {
                    return;
                }
                HashMap hashMap = new HashMap();
                hashMap.put(AppMeasurementSdk.ConditionalUserProperty.VALUE, "1");
                u.E0((MainActivity) i.this.c, hashMap);
                u.N0(i.this.c, deeplinkInfo.getContentCode(), deeplinkInfo.getContentType(), -1, i.this.a, deeplinkInfo.getPartnerCode(), deeplinkInfo.getUrl());
            }

            @Override
            public void onFailure(Error error) {
                Object obj = i.this.c;
                if (obj instanceof MainActivity) {
                    ((MainActivity) obj).Q2();
                }
                if (error != null) {
                    hd.h.b("detailsFragmentDeepLinkError", " " + error.getMessage());
                }
            }
        }

        i(String str, String str2, Context context) {
            this.a = str;
            this.b = str2;
            this.c = context;
        }

        @Override
        public void a() {
            String str;
            if (u.c && hd.a.a.g(OTTApplication.o()).getLoggedUser() != null) {
                if (this.a.contains("trailer")) {
                    str = u.e;
                } else {
                    String str2 = u.d;
                    str = (str2 == null || str2.isEmpty()) ? "" : u.d.split("-")[1];
                }
                OttLog.error(u.h, " contentType: " + u.i + " channelName: " + this.b + " contentId: " + str);
                String str3 = u.i;
                if (str3 != null && str3.equalsIgnoreCase("epg") && hd.d.u) {
                    u.r(this.b, "true", u.i, str, this.c);
                    return;
                } else if (hd.d.v) {
                    u.r("", "false", u.i, str, this.c);
                    return;
                }
            }
            hd.a.a.f(OTTApplication.o()).getDeeplinkInfo(this.a, new a());
        }
    }

    class j implements MediaCatalogManager.MediaCatalogCallback<JSONObject> {
        final String a;
        final String b;
        final Context c;

        j(String str, String str2, Context context) {
            this.a = str;
            this.b = str2;
            this.c = context;
        }

        @Override
        public void onSuccess(JSONObject jSONObject) {
            String str;
            str = "";
            String str2 = this.a;
            if (jSONObject != null) {
                try {
                    str = jSONObject.has("token") ? jSONObject.getString("token") : "";
                    if (jSONObject.has("contentId")) {
                        str2 = jSONObject.getString("contentId");
                    }
                } catch (JSONException unused) {
                }
                try {
                    u.C(str, str2, this.b, this.c);
                } catch (Exception unused2) {
                }
            }
        }

        @Override
        public void onFailure(Error error) {
            if (TextUtils.isEmpty(error.getMessage())) {
                return;
            }
            Toast.makeText(this.c, error.getMessage(), 0).show();
        }
    }

    class k implements UserManager.UserCallback<String> {
        final oc.o a;
        final Context b;

        k(oc.o oVar, Context context) {
            this.a = oVar;
            this.b = context;
        }

        @Override
        public void onSuccess(String str) {
            Context context;
            this.a.a(str);
            if (TextUtils.isEmpty(str) || (context = this.b) == null) {
                return;
            }
            Toast.makeText(context, str, 0).show();
        }

        @Override
        public void onFailure(Error error) {
            Context context;
            if (TextUtils.isEmpty(error.getMessage()) || (context = this.b) == null) {
                return;
            }
            Toast.makeText(context, error.getMessage(), 0).show();
        }
    }

    class l implements MediaCatalogManager.MediaCatalogCallback<List<BottomTemplate>> {
        l() {
        }

        @Override
        public void onSuccess(List<BottomTemplate> list) {
            int size;
            if (list == null || (size = list.size()) <= 0) {
                return;
            }
            for (int i = 0; i < size; i++) {
                BottomTemplate bottomTemplate = list.get(i);
                String code = bottomTemplate.getCode();
                e0.o.put(code, u.h(code, bottomTemplate.getRows()));
            }
        }

        @Override
        public void onFailure(Error error) {
        }
    }

    class m implements UserManager.UserCallback<String> {
        m() {
        }

        @Override
        public void onSuccess(String str) {
            OttLog.error("contentPath", "send");
        }

        @Override
        public void onFailure(Error error) {
            OttLog.error("contentPath", "error message" + error.getMessage());
        }
    }

    class n implements UserManager.UserCallback<String> {
        n() {
        }

        @Override
        public void onSuccess(String str) {
        }

        @Override
        public void onFailure(Error error) {
        }
    }

    class o implements SessionListener {
        final Context a;

        o(Context context) {
            this.a = context;
        }

        public void onSessionExpired(Error error) {
            u.k(this.a);
        }
    }

    public static void A(androidx.fragment.app.h hVar, String str) {
        hVar.startActivity(new Intent("android.intent.action.VIEW", Uri.parse(str)));
    }

    public static void A0() {
        OTTApplication w = OTTApplication.w();
        if (!hd.d.r || w == null) {
            return;
        }
        e0.l(w, "");
    }

    private static void B(Context context) {
        if (context == 0 || !(context instanceof MainActivity)) {
            return;
        }
        MainActivity mainActivity = (MainActivity) context;
        mainActivity.x2 = true;
        if (mainActivity.U2()) {
            mainActivity.Y1(true, "");
        }
        mainActivity.E3(null, true, r.F1);
    }

    public static void B0(Context context) {
        OTTApplication.x(context).d(new Intent(hd.e.I));
    }

    public static void C(String str, String str2, String str3, Context context) {
        B0(context);
        wd.a aVar = new wd.a(context);
        if (str3 == null || str3.isEmpty() || !str3.equalsIgnoreCase("epg")) {
            aVar.e("VOD");
        } else {
            aVar.e("LIVE");
        }
        if (str2 != null && !str2.isEmpty()) {
            aVar.d(str2);
        }
        a.C0133a c0133a = hd.a.a;
        if (c0133a.g(OTTApplication.o()) != null && c0133a.g(OTTApplication.o()).getLoggedUser() != null) {
            User loggedUser = c0133a.g(OTTApplication.o()).getLoggedUser();
            aVar.h(String.valueOf(loggedUser.getUserId().intValue()));
            aVar.g(loggedUser.getEmail());
        }
        HashMap hashMap = new HashMap();
        if (str != null && !str.isEmpty()) {
            hashMap.put("TOKEN", str);
        }
        hashMap.put("DEVICE_TYPE", "android");
        hashMap.put("DSN", "");
        aVar.f(hashMap);
        try {
            aVar.i();
        } catch (IllegalArgumentException unused) {
        } catch (VersionNotSupportedException unused2) {
            aVar.c();
        } catch (ActivityNotFoundException unused3) {
            aVar.c();
        }
    }

    public static void C0(Context context) {
        MainActivity mainActivity = (MainActivity) context;
        Fragment j0 = mainActivity.getSupportFragmentManager().j0(2131427847);
        Fragment j02 = mainActivity.getSupportFragmentManager().j0(2131429166);
        if ((j0 instanceof a1) || (j0 instanceof t2)) {
            if (!(j02 instanceof tc.i) || ((tc.i) j02).g0 == null) {
                OTTApplication.x(context).d(new Intent(hd.e.J));
            }
        }
    }

    public static void D(androidx.fragment.app.h hVar, ListType listType, String str, String str2, String str3, int i2, String str4) {
        Bundle bundle = new Bundle();
        bundle.putString("navfrom", str);
        bundle.putString("inputString", str2);
        bundle.putString("auth_token", str3);
        bundle.putInt("max_session_count", i2);
        bundle.putString(r.O1, str4);
        hVar.getSupportFragmentManager().q().c(2131428566, mc.e.O(listType, bundle), "linkedDevice").g(listType.getValue()).j();
    }

    public static void D0(String str) {
        if (str == null || str.isEmpty()) {
            return;
        }
        OttLog.error("contentPath", str);
        hd.a.a.b(OTTApplication.o()).getUserManager().sendClickData(str, new m());
    }

    public static void E(Context context) {
        if (context instanceof Activity) {
            Intent intent = new Intent(context, (Class<?>) SplashScreenActivity.class);
            intent.addFlags(67108864);
            intent.addFlags(268468224);
            intent.putExtra("signout", true);
            context.startActivity(intent);
            ((Activity) context).finish();
            OTTApplication.m0 = false;
        }
    }

    public static void E0(androidx.appcompat.app.e eVar, HashMap<String, String> hashMap) {
        String str;
        String str2;
        Configs c2 = hd.a.a.c(OTTApplication.o());
        if (c2 == null || c2.getSupportMyreco() == null || !c2.getSupportMyreco().equals("true")) {
            return;
        }
        JSONObject jSONObject = new JSONObject();
        try {
            jSONObject.put("eventType", "Playback");
            jSONObject.put("eventName", "Played");
            StringBuilder sb2 = new StringBuilder();
            sb2.append("Android_");
            String str3 = Build.VERSION.RELEASE;
            sb2.append(str3);
            jSONObject.put("userAgent", sb2.toString());
            jSONObject.put("network", v.c(eVar));
            jSONObject.put("sdkVersion", String.valueOf(str3));
            jSONObject.put("appVersion", "3.2");
            jSONObject.put("device", "Android");
            jSONObject.put(AppMeasurementSdk.ConditionalUserProperty.VALUE, (!hashMap.containsKey(AppMeasurementSdk.ConditionalUserProperty.VALUE) || hashMap.get(AppMeasurementSdk.ConditionalUserProperty.VALUE) == null) ? 1 : Integer.parseInt(hashMap.get(AppMeasurementSdk.ConditionalUserProperty.VALUE)));
            if (hashMap.containsKey("carousal_name")) {
                jSONObject.put("trackingId", (!hashMap.containsKey("tracking_id") || hashMap.get("tracking_id") == null) ? "" : hashMap.get("tracking_id"));
                jSONObject.put("originSource", (!hashMap.containsKey("origin_source") || hashMap.get("origin_source") == null) ? "" : hashMap.get("origin_source"));
                jSONObject.put("originMedium", (!hashMap.containsKey("origin_medium") || hashMap.get("origin_medium") == null) ? "" : hashMap.get("origin_medium"));
                jSONObject.put("originName", (!hashMap.containsKey("carousal_name") || hashMap.get("carousal_name") == null) ? "" : hashMap.get("carousal_name"));
                jSONObject.put("contentPath", (!hashMap.containsKey("target_path") || hashMap.get("target_path") == null) ? "" : hashMap.get("target_path"));
                jSONObject.put("tabName", (!hashMap.containsKey("tabName") || hashMap.get("tabName") == null) ? "" : hashMap.get("tabName"));
                jSONObject.put("carouselPosition", (!hashMap.containsKey("carousal_position") || hashMap.get("carousal_position") == null || Integer.parseInt(hashMap.get("carousal_position")) == -1) ? "" : String.valueOf(hashMap.get("carousal_position")));
                jSONObject.put("contentPosition", (!hashMap.containsKey("content_position") || hashMap.get("content_position") == null || Integer.parseInt(hashMap.get("content_position")) == -1) ? "" : String.valueOf(hashMap.get("content_position")));
                if (!hashMap.containsKey("contentAudioLanguage") || hashMap.get("contentAudioLanguage") == null) {
                    str = "audioLanguage";
                    str2 = "";
                } else {
                    str2 = hashMap.get("contentAudioLanguage");
                    str = "audioLanguage";
                }
                jSONObject.put(str, str2);
            } else {
                jSONObject.put("originName", (!hashMap.containsKey("originName") || hashMap.get("originName") == null) ? cc.e.n().d() : hashMap.get("originName"));
                jSONObject.put("contentPath", cc.e.n().v());
                jSONObject.put("tabName", (!hashMap.containsKey("tabName") || hashMap.get("tabName") == null || hashMap.get("tabName").isEmpty()) ? cc.e.n().t() : hashMap.get("tabName"));
                jSONObject.put("carouselPosition", cc.e.n().c() != -1 ? String.valueOf(cc.e.n().c()) : "");
                jSONObject.put("contentPosition", cc.e.n().j() != -1 ? String.valueOf(cc.e.n().j()) : "");
                jSONObject.put("trackingId", (!hashMap.containsKey("tracking_id") || hashMap.get("tracking_id") == null) ? (cc.e.n().u() == null || cc.e.n().u().isEmpty()) ? "" : cc.e.n().u() : hashMap.get("tracking_id"));
                jSONObject.put("originSource", (cc.e.n().p() == null || cc.e.n().p().isEmpty()) ? "AppOpen" : cc.e.n().p());
                jSONObject.put("originMedium", (cc.e.n().o() == null || cc.e.n().o().isEmpty()) ? "carousel" : cc.e.n().o());
                jSONObject.put("audioLanguage", (!hashMap.containsKey("contentAudioLanguage") || hashMap.get("contentAudioLanguage") == null) ? "" : hashMap.get("contentAudioLanguage"));
            }
            if (hd.e.s) {
                jSONObject.put("originMedium", "Notification");
                jSONObject.put("tabName", "");
                hd.e.s = false;
            }
        } catch (JSONException unused) {
        }
        hd.a.a.b(OTTApplication.o()).getUserManager().sendMyrecoEvents(jSONObject, new n());
    }

    public static void F(String str, androidx.fragment.app.h hVar) {
        w(hVar);
        Bundle bundle = new Bundle();
        if (hVar instanceof MainActivity) {
            ((MainActivity) hVar).a1 = str;
        }
        e1 e1Var = new e1();
        bundle.putString(r.z, str);
        e1Var.setArguments(bundle);
        hVar.getSupportFragmentManager().q().c(2131427848, e1Var, "navigationfragment").j();
    }

    public static void F0(androidx.fragment.app.h hVar, DialogType dialogType, Object obj, oc.d dVar) {
        if (hVar != null) {
            com.yupptv.ott.fragments.g.r1(dialogType, null, obj, dVar).show(hVar.getSupportFragmentManager(), "dialog_bookmark_remove");
        }
    }

    public static void G(String str, String str2, androidx.fragment.app.h hVar) {
        Bundle bundle = new Bundle();
        if (hVar instanceof MainActivity) {
            ((MainActivity) hVar).a1 = str;
        }
        e1 e1Var = new e1();
        bundle.putString(r.z, str);
        String str3 = r.I0;
        if (str2 == null) {
            str2 = "";
        }
        bundle.putString(str3, str2);
        e1Var.setArguments(bundle);
        hVar.getSupportFragmentManager().q().c(2131427848, e1Var, "navigationfragment").j();
    }

    public static void G0(Context context, String str, String str2, String str3, oc.e eVar) {
        ImageView imageView;
        String str4;
        String str5;
        Dialog dialog = new Dialog(context);
        dialog.setContentView(2131624036);
        ImageView imageView2 = (ImageView) dialog.findViewById(2131427888);
        TextView textView = (TextView) dialog.findViewById(2131427891);
        TextView textView2 = (TextView) dialog.findViewById(2131427890);
        TextView textView3 = (TextView) dialog.findViewById(2131428638);
        CheckBox checkBox = (CheckBox) dialog.findViewById(2131428040);
        TextView textView4 = (TextView) dialog.findViewById(R.id.cancel_action);
        TextView textView5 = (TextView) dialog.findViewById(2131428042);
        textView2.setText(context.getResources().getString(2131951948, hd.d.f));
        a.C0133a c0133a = hd.a.a;
        Configs c2 = c0133a.c(OTTApplication.o());
        if (com.yupptv.ott.a.h && OTTApplication.i0 != null) {
            c2 = OTTApplication.D();
        }
        String cpPopupText = c2.getCpPopupText() != null ? c2.getCpPopupText() : "";
        try {
            hd.h.b(h, "popup text " + cpPopupText.toString());
            if (cpPopupText.isEmpty()) {
                imageView = imageView2;
            } else {
                JSONObject jSONObject = new JSONObject(cpPopupText);
                if (jSONObject.has("title")) {
                    String replace = jSONObject.has("title") ? jSONObject.getString("title").replace("[App Name]", str) : "";
                    SpannableString spannableString = new SpannableString(replace);
                    int indexOf = replace.indexOf(str);
                    imageView = imageView2;
                    spannableString.setSpan(new StyleSpan(1), indexOf, str.length() + indexOf, 33);
                    textView.setText(spannableString);
                } else {
                    imageView = imageView2;
                }
                if (jSONObject.has("subtitle")) {
                    textView3.setText(jSONObject.has("subtitle") ? jSONObject.getString("subtitle") : "");
                }
                if (jSONObject.has("check")) {
                    textView5.setText(jSONObject.has("check") ? jSONObject.getString("check") : "");
                }
                if (jSONObject.has("note")) {
                    textView2.setText(jSONObject.has("note") ? jSONObject.getString("note").replace("[App Name]", str) : "");
                }
            }
            List networkList = c0133a.d(OTTApplication.o()).getNetworkList();
            if (networkList != null) {
                str5 = str3;
                for (int i2 = 0; i2 < networkList.size(); i2++) {
                    if (((Networks) networkList.get(i2)).getCustomAttributes().getPartnerCode() != null && ((Networks) networkList.get(i2)).getCustomAttributes().getPartnerCode().trim().length() > 0) {
                        if (((Networks) networkList.get(i2)).getCustomAttributes().getPartnerCode().equalsIgnoreCase(str2)) {
                            str5 = ((Networks) networkList.get(i2)).getIconUrl();
                        }
                    }
                }
                str4 = str2;
            } else {
                str4 = str2;
                str5 = str3;
            }
            com.bumptech.glide.b.u(context).u(hd.a.a.f(OTTApplication.o()).getImageAbsolutePath(str5)).F0(imageView);
            dialog.show();
            dialog.setCancelable(false);
            textView4.setOnClickListener(new s(str4, dialog));
            dialog.findViewById(2131429247).setOnClickListener(new t(eVar, checkBox, str4, dialog));
        } catch (JSONException e2) {
            throw new RuntimeException(e2);
        }
    }

    private static void H(Context context, String str) {
        if (context == 0 || !(context instanceof MainActivity)) {
            return;
        }
        MainActivity mainActivity = (MainActivity) context;
        mainActivity.x2 = true;
        if (mainActivity.U2()) {
            mainActivity.Y1(true, "");
        }
        mainActivity.F3(false, str, j);
    }

    public static void H0(androidx.fragment.app.h hVar, DialogType dialogType, PackagesV2 packagesV2, oc.h hVar2) {
        if (hVar != null) {
            FragmentManager supportFragmentManager = hVar.getSupportFragmentManager();
            try {
                if (h.c[dialogType.ordinal()] != 1) {
                    return;
                }
                com.yupptv.ott.fragments.i0 B0 = com.yupptv.ott.fragments.i0.B0(dialogType, packagesV2, hVar2);
                supportFragmentManager.q().j();
                B0.show(supportFragmentManager, "packInfoDialog");
            } catch (IllegalStateException unused) {
            }
        }
    }

    private static void I(Context context) {
        if (hd.a.a.g(OTTApplication.o()).getLoggedUser() == null && context != 0 && (context instanceof MainActivity)) {
            ComponentActivity componentActivity = (MainActivity) context;
            Intent intent = new Intent((Context) componentActivity, (Class<?>) LoadScreenActivity.class);
            String str = r.i;
            ScreenType screenType = ScreenType.SIGNIN;
            intent.putExtra(str, screenType);
            intent.putExtra(r.y0, screenType.getValue());
            intent.putExtra(r.C0, cc.d.p);
            componentActivity.f5(cc.d.p);
            componentActivity.startActivityForResult(intent, 15);
        }
    }

    public static void I0(androidx.fragment.app.h hVar, DialogType dialogType, HashMap hashMap, Object obj, oc.d dVar) {
        if (hVar != null) {
            com.yupptv.ott.fragments.g.r1(dialogType, hashMap, obj, dVar).show(hVar.getSupportFragmentManager(), "dialog_bottom_player_rendering");
        }
    }

    private static void J(Context context) {
        if (hd.a.a.g(OTTApplication.o()).getLoggedUser() == null && context != 0 && (context instanceof MainActivity)) {
            ComponentActivity componentActivity = (MainActivity) context;
            Intent intent = new Intent((Context) componentActivity, (Class<?>) LoadScreenActivity.class);
            intent.putExtra(r.i, ScreenType.SIGNUP);
            intent.putExtra(r.C0, cc.d.q);
            componentActivity.f5(cc.d.q);
            componentActivity.startActivityForResult(intent, 16);
        }
    }

    public static void J0(androidx.fragment.app.h hVar, DialogType dialogType, HashMap hashMap, oc.h hVar2) {
        if (hVar != null) {
            FragmentManager supportFragmentManager = hVar.getSupportFragmentManager();
            try {
                switch (h.c[dialogType.ordinal()]) {
                    case 2:
                        com.yupptv.ott.fragments.i0 C0 = com.yupptv.ott.fragments.i0.C0(DialogType.MESSAGE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C0.show(supportFragmentManager, "msgDialog");
                        break;
                    case 3:
                        com.yupptv.ott.fragments.i0 C02 = com.yupptv.ott.fragments.i0.C0(DialogType.COUNTRIES_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C02.show(supportFragmentManager, "countriesDialog");
                        break;
                    case 4:
                        com.yupptv.ott.fragments.i0 C03 = com.yupptv.ott.fragments.i0.C0(DialogType.SESSION_EXPIRED_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C03.show(supportFragmentManager, "sessionExpiredDialog");
                        break;
                    case 5:
                        com.yupptv.ott.fragments.i0 C04 = com.yupptv.ott.fragments.i0.C0(DialogType.DELINK_DEVICE, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C04.show(supportFragmentManager, "delinkDevice");
                        break;
                    case 6:
                        com.yupptv.ott.fragments.i0 C05 = com.yupptv.ott.fragments.i0.C0(DialogType.PAYMENT_OPTIONS, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C05.show(supportFragmentManager, "payment_options");
                        break;
                    case 7:
                        com.yupptv.ott.fragments.i0 C06 = com.yupptv.ott.fragments.i0.C0(DialogType.CONTINUE_WATCHING_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C06.show(supportFragmentManager, "continuewatching");
                        break;
                    case 8:
                        com.yupptv.ott.fragments.i0 C07 = com.yupptv.ott.fragments.i0.C0(DialogType.REMOVE_FROM_CONTINUE_WATCHING, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C07.show(supportFragmentManager, "remove_from_continue_watching");
                        break;
                    case 9:
                        com.yupptv.ott.fragments.i0 C08 = com.yupptv.ott.fragments.i0.C0(DialogType.CONTINUE_LOGOUT_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C08.show(supportFragmentManager, "continuelogout");
                        break;
                    case 10:
                        com.yupptv.ott.fragments.i0 C09 = com.yupptv.ott.fragments.i0.C0(DialogType.APP_UPDATE, hashMap, hVar2);
                        supportFragmentManager.q().e(C09, "appupdate");
                        supportFragmentManager.q().j();
                        C09.show(supportFragmentManager, "appupdate");
                        break;
                    case 11:
                        com.yupptv.ott.fragments.i0 C010 = com.yupptv.ott.fragments.i0.C0(DialogType.RECORD, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C010.show(supportFragmentManager, "recording");
                        break;
                    case 12:
                        com.yupptv.ott.fragments.i0 C011 = com.yupptv.ott.fragments.i0.C0(DialogType.PAYMENT_CONFIRMATION_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C011.show(supportFragmentManager, "paymentconfirmationdialog");
                        break;
                    case 13:
                        com.yupptv.ott.fragments.i0 C012 = com.yupptv.ott.fragments.i0.C0(DialogType.LEAVE_PAGE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C012.show(supportFragmentManager, "leavepagedialog");
                        break;
                    case 14:
                        com.yupptv.ott.fragments.i0 C013 = com.yupptv.ott.fragments.i0.C0(DialogType.REGISTRATION_SUCCESS_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C013.show(supportFragmentManager, "registrationsuccessdialog");
                        break;
                    case 15:
                        com.yupptv.ott.fragments.i0 C014 = com.yupptv.ott.fragments.i0.C0(DialogType.REMOVE_LINKED_DEVICE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C014.show(supportFragmentManager, "removelinkeddevicedialog");
                        break;
                    case 16:
                        com.yupptv.ott.fragments.i0 C015 = com.yupptv.ott.fragments.i0.C0(DialogType.LINKED_DEVICE_LIMIT_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C015.show(supportFragmentManager, "linkedDeviceLimitDialog");
                        break;
                    case 17:
                        com.yupptv.ott.fragments.i0 C016 = com.yupptv.ott.fragments.i0.C0(DialogType.STARTOVER_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().e(C016, "startoverdialog");
                        supportFragmentManager.q().j();
                        C016.show(supportFragmentManager, "startoverdialog");
                        break;
                    case 18:
                        com.yupptv.ott.fragments.i0 C017 = com.yupptv.ott.fragments.i0.C0(DialogType.PLAYER_ACTIVE_SCREEN_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C017.show(supportFragmentManager, "playerActiveScreenDialog");
                        break;
                    case 19:
                        com.yupptv.ott.fragments.i0 C018 = com.yupptv.ott.fragments.i0.C0(DialogType.SETTINGS_ACTIVE_SCREEN_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C018.show(supportFragmentManager, "settingActiveScreenDialog");
                        break;
                    case 20:
                        com.yupptv.ott.fragments.i0 C019 = com.yupptv.ott.fragments.i0.C0(DialogType.REMOVE_SAVED_CARD_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C019.show(supportFragmentManager, "remove_saved_card_dialog");
                        break;
                    case 21:
                        com.yupptv.ott.fragments.i0 C020 = com.yupptv.ott.fragments.i0.C0(DialogType.CHANGE_PLAN_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C020.show(supportFragmentManager, "CHANGE_PLAN_DIALOG");
                        break;
                    case 22:
                        com.yupptv.ott.fragments.i0 C021 = com.yupptv.ott.fragments.i0.C0(DialogType.ORDER_SUMMARY_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C021.show(supportFragmentManager, "ORDER_SUMMARY_DIALOG");
                        break;
                    case 23:
                        com.yupptv.ott.fragments.i0 C022 = com.yupptv.ott.fragments.i0.C0(DialogType.TAX_INFO_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C022.show(supportFragmentManager, "TAX_INFO_DIALOG");
                        break;
                    case 24:
                        com.yupptv.ott.fragments.i0 C023 = com.yupptv.ott.fragments.i0.C0(DialogType.ERROR_MESSAGE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C023.show(supportFragmentManager, "ERROR_MESSAGE_DIALOG");
                        break;
                    case 25:
                        com.yupptv.ott.fragments.i0 C024 = com.yupptv.ott.fragments.i0.C0(DialogType.SIGNIN_SIGNUP_INFO_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C024.show(supportFragmentManager, "SIGNIN_SIGNUP_INFO_DIALOG");
                        break;
                    case 26:
                        com.yupptv.ott.fragments.i0.C0(DialogType.FEEDBACK_RATING_DIALOG, hashMap, hVar2).show(supportFragmentManager, "feedbackratingdialog");
                        break;
                    case 27:
                        com.yupptv.ott.fragments.i0 C025 = com.yupptv.ott.fragments.i0.C0(DialogType.GDPR_COOKIE_POLICY_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C025.show(supportFragmentManager, "gdprcookiepolicy");
                        break;
                    case 28:
                        com.yupptv.ott.fragments.i0 C026 = com.yupptv.ott.fragments.i0.C0(DialogType.WEBVIEW_NAVIGATION_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C026.show(supportFragmentManager, "webviewNavigation");
                        break;
                    case 29:
                        com.yupptv.ott.fragments.i0 C027 = com.yupptv.ott.fragments.i0.C0(DialogType.OFFLINE_DELETE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C027.show(supportFragmentManager, "offlineDelete");
                        break;
                    case 30:
                        com.yupptv.ott.fragments.i0 C028 = com.yupptv.ott.fragments.i0.C0(DialogType.PACKAGE_SUBSCRIBE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C028.show(supportFragmentManager, "showsubscription");
                        break;
                    case 31:
                        com.yupptv.ott.fragments.i0 C029 = com.yupptv.ott.fragments.i0.C0(DialogType.DONT_HAVE_SUBSCRIPTION_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C029.show(supportFragmentManager, "dont_have_subscription_dialog");
                        break;
                    case 32:
                        com.yupptv.ott.fragments.i0 C030 = com.yupptv.ott.fragments.i0.C0(DialogType.NEED_SUBSCRIPTION_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C030.show(supportFragmentManager, "need_subscription_dialog");
                        break;
                    case 33:
                        com.yupptv.ott.fragments.i0 C031 = com.yupptv.ott.fragments.i0.C0(DialogType.VOUCHER_APPLY_FAILURE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C031.show(supportFragmentManager, "VOUCHER_FAILURE_INFO_DIALOG");
                        break;
                    case 34:
                        com.yupptv.ott.fragments.i0 C032 = com.yupptv.ott.fragments.i0.C0(DialogType.SUBSCRIBE_RENT_INFO_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C032.show(supportFragmentManager, "SIGNIN_SIGNUP_INFO_DIALOG");
                        break;
                    case 35:
                        com.yupptv.ott.fragments.i0 C033 = com.yupptv.ott.fragments.i0.C0(DialogType.PARENTAL_CONTROL_PASSCODE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C033.show(supportFragmentManager, "PARENT_CONTROLLING_PASSCODE_DIALOG");
                        break;
                    case 36:
                        com.yupptv.ott.fragments.i0 C034 = com.yupptv.ott.fragments.i0.C0(DialogType.UPDATE_AGE_DOB_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C034.show(supportFragmentManager, "UPDATE_AGE_DOB_DIALOG");
                        break;
                    case 37:
                        com.yupptv.ott.fragments.i0 C035 = com.yupptv.ott.fragments.i0.C0(DialogType.USER_PROFILE_PASSCODE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C035.show(supportFragmentManager, "USER_PROFILE_PASSCODE_DIALOG");
                        break;
                    case 38:
                        com.yupptv.ott.fragments.i0 C036 = com.yupptv.ott.fragments.i0.C0(DialogType.ADD_USER_PROFILE_PASSCODE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C036.show(supportFragmentManager, "ADD_USER_PROFILE_PASSCODE_DIALOG");
                        break;
                    case 39:
                        com.yupptv.ott.fragments.i0 C037 = com.yupptv.ott.fragments.i0.C0(DialogType.AFTER_DARK_PASSCODE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C037.show(supportFragmentManager, "AFTER_DARK_AGREE_DIALOG");
                        break;
                    case 40:
                        com.yupptv.ott.fragments.i0 C038 = com.yupptv.ott.fragments.i0.C0(DialogType.ENVIRONMENT_LIST_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C038.show(supportFragmentManager, "ENVIRONMENT_LIST_DIALOG");
                        break;
                    case 41:
                        com.yupptv.ott.fragments.i0 C039 = com.yupptv.ott.fragments.i0.C0(DialogType.LOGIN_TYPE_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C039.show(supportFragmentManager, "LOGIN_TYPE_DIALOG");
                        break;
                    case 42:
                        com.yupptv.ott.fragments.i0 C040 = com.yupptv.ott.fragments.i0.C0(DialogType.INSERT_PASSWORD_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C040.show(supportFragmentManager, "INSERT_PASSWORD_DIALOG");
                        break;
                    case 43:
                        com.yupptv.ott.fragments.i0 C041 = com.yupptv.ott.fragments.i0.C0(DialogType.CANCEL_DOWNLOAD_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C041.show(supportFragmentManager, "CANCEL_DOWNLOAD_DIALOG");
                        break;
                    case 44:
                        com.yupptv.ott.fragments.i0 C042 = com.yupptv.ott.fragments.i0.C0(DialogType.FORGOT_PWD_VIA_WEB_DIALOG, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C042.show(supportFragmentManager, "forgotPwdMsgDialog");
                        break;
                    case 45:
                        com.yupptv.ott.fragments.i0 C043 = com.yupptv.ott.fragments.i0.C0(dialogType, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C043.show(supportFragmentManager, "dialog_sorting_search");
                        break;
                    case 46:
                        DialogType dialogType2 = DialogType.NAVIGATE_TO_APP_INFO_NOTIFICATION;
                        com.yupptv.ott.fragments.i0 C044 = com.yupptv.ott.fragments.i0.C0(dialogType2, hashMap, hVar2);
                        supportFragmentManager.q().j();
                        C044.show(supportFragmentManager, dialogType2.getValue());
                        break;
                }
            } catch (IllegalStateException unused) {
            }
        }
    }

    public static void K(Context context, String str, boolean z) {
        String str2;
        a.C0133a c0133a = hd.a.a;
        Configs c2 = c0133a.c(OTTApplication.o());
        String siteURL = (c2 == null || c2.getSiteURL() == null) ? "" : c2.getSiteURL();
        hd.h.a("siteurl>>", siteURL);
        PreferenceManager g2 = c0133a.g(OTTApplication.o());
        if (g2 == null) {
            Toast.makeText(context, context.getResources().getString(2131952830), 0).show();
            ((MainActivity) context).Q2();
            return;
        }
        String sessionId = g2.getSessionId() != null ? g2.getSessionId() : "";
        String deviceUniqueId = g2.getDeviceUniqueId() != null ? g2.getDeviceUniqueId() : "";
        String str3 = ("bi===" + deviceUniqueId + "&&&si===" + sessionId + "&&&ci===" + g2.getYuppDeviceId() + "&&&theme===") + "&&&theme===w";
        if (com.yupptv.ott.a.h) {
            str3 = str3 + "&&&lang===" + str.toLowerCase();
        }
        String str4 = str3 + "&&&source===Account";
        hd.h.a("url>>", "siteurl>>2 " + str4);
        String encodeToString = Base64.encodeToString(str4.getBytes(), 2);
        try {
            encodeToString = URLEncoder.encode(encodeToString, "UTF-8");
        } catch (Exception unused) {
        }
        if (z) {
            if (siteURL.endsWith("/")) {
                str2 = siteURL + "profiles/create-user-profile?ut=" + encodeToString;
            } else {
                str2 = siteURL + "/profiles/create-user-profile?ut=" + encodeToString;
            }
        } else if (siteURL.endsWith("/")) {
            str2 = siteURL + "profiles/manage-user-profile?ut=" + encodeToString;
        } else {
            str2 = siteURL + "/profiles/manage-user-profile?ut=" + encodeToString;
        }
        hd.h.a("DEBUG", "siteurl " + str2);
        MainActivity mainActivity = (MainActivity) context;
        j0(mainActivity, r.y1, str2, true);
        mainActivity.Q2();
    }

    public static com.yupptv.ott.fragments.g K0(androidx.fragment.app.h hVar, DialogType dialogType, HashMap hashMap, Object obj, oc.d dVar) {
        FragmentManager supportFragmentManager = hVar.getSupportFragmentManager();
        com.yupptv.ott.fragments.g r1 = com.yupptv.ott.fragments.g.r1(dialogType, hashMap, obj, dVar);
        r1.show(supportFragmentManager, "dialog_bottom_player_rendering");
        return r1;
    }

    public static void L(androidx.fragment.app.h hVar, ListType listType, List list, String str, int i2, String str2) {
        B0(hVar);
        Intent intent = new Intent((Context) hVar, (Class<?>) LoadScreenActivity.class);
        intent.putExtra("listType", true);
        intent.putExtra(r.j, listType);
        intent.putExtra(r.y0, str);
        intent.putExtra("streamPollKey", str2);
        intent.putParcelableArrayListExtra("activePackagesResponse", (ArrayList) list);
        if (str.equalsIgnoreCase(r.g1)) {
            hVar.startActivityForResult(intent, i2);
        } else {
            str.equalsIgnoreCase(r.f1);
            hVar.startActivity(intent);
        }
    }

    public static void L0(androidx.fragment.app.h hVar, DialogType dialogType, Object obj, oc.d dVar) {
        if (hVar != null) {
            com.yupptv.ott.fragments.g.r1(dialogType, null, obj, dVar).show(hVar.getSupportFragmentManager(), "dialog_topsheet");
        }
    }

    public static void M(androidx.fragment.app.h hVar, ScreenType screenType, String str, int i2, String str2, String str3) {
        B0(hVar);
        O0(screenType, str);
        Intent intent = new Intent((Context) hVar, (Class<?>) LoadScreenActivity.class);
        intent.putExtra(r.i, screenType);
        intent.putExtra(r.y0, str);
        intent.putExtra(r.i0, str2);
        intent.putExtra(r.R, str3);
        hVar.startActivityForResult(intent, i2);
    }

    public static com.yupptv.ott.fragments.g M0(androidx.fragment.app.h hVar, DialogType dialogType, HashMap hashMap, Object obj, oc.d dVar) {
        FragmentManager supportFragmentManager = hVar.getSupportFragmentManager();
        com.yupptv.ott.fragments.g r1 = com.yupptv.ott.fragments.g.r1(dialogType, hashMap, obj, dVar);
        r1.show(supportFragmentManager, "dialog_voucher_bottom_rendering");
        return r1;
    }

    public static void N(androidx.fragment.app.h hVar, ScreenType screenType, String str, String str2, int i2) {
        B0(hVar);
        O0(screenType, str);
        Intent intent = new Intent((Context) hVar, (Class<?>) LoadScreenActivity.class);
        intent.putExtra(r.i, screenType);
        intent.putExtra(r.y0, str);
        String str3 = r.K0;
        if (str2 == null) {
            str2 = "";
        }
        intent.putExtra(str3, str2);
        hVar.startActivityForResult(intent, i2);
    }

    public static void N0(Context context, String str, String str2, int i2, String str3, String str4, String str5) {
        hd.h.b("startNewActivity:DeepLink", str + " " + str2);
        if (str == null) {
            return;
        }
        D0(str3);
        String str6 = "";
        List networkList = hd.a.a.d(OTTApplication.o()).getNetworkList();
        if (networkList != null) {
            for (int i3 = 0; i3 < networkList.size(); i3++) {
                if (((Networks) networkList.get(i3)).getCustomAttributes().getPartnerCode() != null && ((Networks) networkList.get(i3)).getCustomAttributes().getPartnerCode().trim().length() > 0 && ((Networks) networkList.get(i3)).getCustomAttributes().getPartnerCode().equalsIgnoreCase(str4)) {
                    str6 = ((Networks) networkList.get(i3)).getDeeplinkInfo();
                }
            }
        }
        OttLog.error("TAG DeepLink ", " Content Code :: " + str);
        OttLog.error("TAG DeepLink ", " Package Name :: " + str6);
        if (str6 == null || str6.isEmpty() || context == 0) {
            hd.h.a("NavigationUtils::", "No Package Name Available");
            return;
        }
        Intent launchIntentForPackage = context.getPackageManager().getLaunchIntentForPackage(str6);
        if (launchIntentForPackage == null) {
            launchIntentForPackage = new Intent("android.intent.action.VIEW");
            launchIntentForPackage.setData(Uri.parse("market://details?id=" + str6));
        } else if (str.trim().isEmpty()) {
            if (context instanceof MainActivity) {
                str3 = ((MainActivity) context).a1;
            }
            if (str4 != null && str4.contains("sonyliv")) {
                str = str + "&redirectionApi=watcho:///" + str3;
            }
            launchIntentForPackage.putExtra("contentCode", str);
            if (str2 != null) {
                OttLog.error("TAG DeepLink ", " Content Type :: " + str2);
                launchIntentForPackage.putExtra("contentType", str2);
            }
        } else {
            launchIntentForPackage = new Intent("android.intent.action.VIEW");
            launchIntentForPackage.setPackage(str6);
            if (context instanceof MainActivity) {
                str3 = ((MainActivity) context).a1;
            }
            if (str4 != null && str4.contains("sonyliv")) {
                str = str + "&redirectionApi=watcho:///" + str3;
            }
            if (str6.equalsIgnoreCase("com.viewlift.hoichoi")) {
                if (str5 == null || str5.trim().length() <= 0) {
                    str5 = str;
                }
                str = str5;
            }
            OttLog.error("TAG DeepLink ", " Content Code hoi:: " + str);
            launchIntentForPackage.setData(Uri.parse(str));
        }
        try {
            OttLog.error("TAG DeepLink ", " Content Code :: " + str);
            context.startActivity(launchIntentForPackage);
        } catch (ActivityNotFoundException e2) {
            hd.h.b("activityNotFoundOnDeepLinking", e2.getMessage());
            Toast.makeText(context, "Google Playstore app not available", 1).show();
        }
    }

    public static void O(androidx.fragment.app.h hVar, ScreenType screenType, String str, String str2, int i2, PaymentsFragment.PurchaseItem purchaseItem) {
        O0(screenType, str);
        Intent intent = new Intent((Context) hVar, (Class<?>) LoadScreenActivity.class);
        intent.putExtra(r.i, screenType);
        intent.putExtra(r.y0, str);
        String str3 = r.K0;
        if (str2 == null) {
            str2 = "";
        }
        intent.putExtra(str3, str2);
        intent.putExtra("purchaseItem", purchaseItem);
        hVar.startActivityForResult(intent, i2);
    }

    private static void O0(ScreenType screenType, String str) {
        try {
            int i2 = h.b[screenType.ordinal()];
            if (i2 != 1) {
                if (i2 != 3) {
                    if ((i2 == 5 || i2 == 6) && str.equalsIgnoreCase(r.g1)) {
                        cc.d.d().f(cc.d.U);
                    }
                } else if (str.equalsIgnoreCase(r.g1)) {
                    cc.d.d().f(cc.d.T);
                } else if (str.equalsIgnoreCase(r.h1)) {
                    cc.d.d().f(cc.d.b0);
                }
            } else if (str.equalsIgnoreCase(r.g1)) {
                cc.d.d().f(cc.d.S);
            } else if (str.equalsIgnoreCase(r.h1)) {
                cc.d.d().f(cc.d.a0);
            }
        } catch (NullPointerException unused) {
        }
    }

    public static void P(androidx.fragment.app.h hVar, ScreenType screenType, String str, String str2, int i2, String str3, String str4, long j2, List list, Double d2, String str5, String str6, String str7, String str8) {
        O0(screenType, str);
        Intent intent = new Intent((Context) hVar, (Class<?>) LoadScreenActivity.class);
        intent.putExtra(r.i, screenType);
        intent.putExtra(r.y0, str);
        intent.putExtra(r.K0, str2 == null ? "" : str2);
        intent.putExtra(r.Q, str3);
        intent.putExtra(r.c0, j2);
        intent.putExtra(r.V, str4);
        intent.putExtra(r.U, d2);
        intent.putExtra(r.Y, str5);
        intent.putExtra(r.X, str6);
        intent.putExtra(r.i0, str7);
        intent.putExtra(r.Z, str8);
        intent.putParcelableArrayListExtra(r.R, (ArrayList) list);
        hVar.startActivityForResult(intent, i2);
    }

    public static void P0(String str, String str2) {
        hd.a.a.f(OTTApplication.o()).getUpdateNotificationDetails(str, str2, new g());
    }

    public static void Q(androidx.fragment.app.h hVar, ScreenType screenType, String str, String str2, int i2, boolean z, boolean z2) {
        B0(hVar);
        O0(screenType, str);
        Intent intent = new Intent((Context) hVar, (Class<?>) LoadScreenActivity.class);
        intent.putExtra(r.i, screenType);
        intent.putExtra(r.y0, str);
        intent.putExtra(r.n, z);
        intent.putExtra(r.o, z2);
        String str3 = r.K0;
        if (str2 == null) {
            str2 = "";
        }
        intent.putExtra(str3, str2);
        hVar.startActivityForResult(intent, i2);
    }

    public static void Q0(View view, String str, String str2, int i2, Context context, oc.o oVar) {
        OttSDK ottSDK = OttSDK.getInstance();
        if (ottSDK == null || ottSDK.getUserManager() == null) {
            return;
        }
        ottSDK.getUserManager().userLiked(str2, i2, new k(oVar, context));
    }

    public static void R(androidx.fragment.app.h hVar, ScreenType screenType, String str, String str2, int i2, boolean z, boolean z2, HashMap hashMap) {
        B0(hVar);
        O0(screenType, str);
        if (hVar != null) {
            Intent intent = new Intent((Context) hVar, (Class<?>) LoadScreenActivity.class);
            intent.putExtra(r.i, screenType);
            intent.putExtra(r.y0, str);
            intent.putExtra(r.n, z);
            intent.putExtra(r.o, z2);
            String str3 = r.K0;
            if (str2 == null) {
                str2 = "";
            }
            intent.putExtra(str3, str2);
            intent.putExtra(r.H0, hashMap);
            hVar.startActivityForResult(intent, i2);
        }
    }

    private static void R0(String str, Context context) {
        hd.a.a.b(OTTApplication.o()).getUserManager().updateUserDisplayPreference(str, new e(str, context));
    }

    public static void S(Activity activity, ScreenType screenType, String str) {
        B0(activity);
        Intent intent = new Intent(activity, (Class<?>) LoadScreenActivity.class);
        intent.putExtra(r.i, screenType);
        intent.putExtra(r.y0, str);
        activity.startActivity(intent);
        if (str.equalsIgnoreCase("settings")) {
            return;
        }
        activity.finish();
    }

    private static void T(androidx.fragment.app.h hVar, String str, Boolean bool) {
        String str2;
        hd.h.a("navigateCardWebview>>", "isInternalBrowser>>" + bool + "targetPath>>" + str);
        if (hVar != null && !str.startsWith("http")) {
            str.startsWith("https");
        }
        User loggedUser = hd.a.a.g(OTTApplication.o()).getLoggedUser();
        if (loggedUser == null) {
            i(hVar, str, bool);
            return;
        }
        if (loggedUser.getStatus().intValue() == 0) {
            i(hVar, str, bool);
            return;
        }
        String externalUserId = loggedUser.getExternalUserId();
        String substring = str.substring(str.length() - 1);
        if (str.contains("?") && str.contains("&") && !substring.equalsIgnoreCase("?")) {
            str2 = str + "&sub=" + externalUserId;
        } else if (substring.equalsIgnoreCase("?") || substring.equalsIgnoreCase("&")) {
            str2 = str + "sub=" + externalUserId;
        } else {
            str2 = str + "?sub=" + externalUserId;
        }
        hd.h.a("finalTargetPath>>", "" + str2);
        i(hVar, str2, bool);
    }

    public static void U(androidx.fragment.app.h hVar, PaymentsFragment.PurchaseItem purchaseItem, String str, boolean z) {
        nc.f fVar = new nc.f();
        Bundle bundle = new Bundle();
        bundle.putParcelable("PurchaseItem", purchaseItem);
        bundle.putString(r.y0, str);
        fVar.setArguments(bundle);
        if (z) {
            hVar.getSupportFragmentManager().q().c(2131428566, fVar, "orderSummaryFragment").g("orderSummaryFragment").j();
        } else {
            hVar.getSupportFragmentManager().q().c(2131428566, fVar, "orderSummaryFragment").j();
        }
    }

    public static void V(androidx.fragment.app.h hVar, ButtonType buttonType, String str, String str2) {
        if (hVar != null) {
            B0(hVar);
            if (hVar.getSupportFragmentManager().k0("navigationfragment") != null) {
                hVar.getSupportFragmentManager().q().p(hVar.getSupportFragmentManager().k0("navigationfragment")).j();
            }
            MainActivity mainActivity = (MainActivity) hVar;
            mainActivity.D4(str2);
            mainActivity.s4(buttonType);
            mainActivity.H2(str);
        }
    }

    public static void W(androidx.fragment.app.h hVar, ListType listType, Bundle bundle) {
        B0(hVar);
        hVar.getSupportFragmentManager().q().c(2131428566, mc.l.X0(listType, bundle), "account").g(listType.getValue()).j();
    }

    public static void X(androidx.fragment.app.h hVar, Bundle bundle, ScreenType screenType) {
        if (screenType != null) {
            switch (h.b[screenType.ordinal()]) {
                case 1:
                    hVar.getSupportFragmentManager().q().r(2131428566, new com.yupptv.ott.fragments.onboarding.c0(), "signup").g("sign_up").j();
                    break;
                case 2:
                    SignupFragmentStep2 signupFragmentStep2 = new SignupFragmentStep2();
                    if (bundle != null) {
                        signupFragmentStep2.setArguments(bundle);
                    }
                    hVar.getSupportFragmentManager().q().r(2131428566, signupFragmentStep2, "signup2").g("sign_up2").j();
                    break;
                case 3:
                    Fragment videoSignInFragment = hd.d.b ? new VideoSignInFragment() : new SignInFragment();
                    if (bundle != null) {
                        videoSignInFragment.setArguments(bundle);
                    }
                    hVar.getSupportFragmentManager().q().r(2131428566, videoSignInFragment, "signin").g("sign_in").j();
                    break;
                case 4:
                    hVar.getSupportFragmentManager().q().r(2131428566, new f0(), "updatepwd").g("updatePwd").j();
                    break;
                case 5:
                case 6:
                    hVar.getSupportFragmentManager().q().r(2131428566, new h1(), "paymentsmainfragment").g("paymentsmainfragment").j();
                    break;
                case 7:
                    com.yupptv.ott.fragments.onboarding.g0 g0Var = new com.yupptv.ott.fragments.onboarding.g0();
                    if (bundle != null) {
                        g0Var.setArguments(bundle);
                    }
                    hVar.getSupportFragmentManager().q().r(2131428566, g0Var, "userprofile").g("userprofile").j();
                    break;
                case 8:
                    NewPackageFragment newPackageFragment = new NewPackageFragment();
                    if (bundle != null) {
                        newPackageFragment.setArguments(bundle);
                    }
                    hVar.getSupportFragmentManager().q().r(2131428566, newPackageFragment, "packagefragment").g("packagefragment").j();
                    break;
                case 9:
                    hVar.getSupportFragmentManager().q().r(2131428566, new nc.n(), "updateCard").g("updateCard").j();
                    break;
                case 10:
                    hVar.getSupportFragmentManager().q().r(2131428566, com.yupptv.ott.fragments.onboarding.e0.l0(screenType, bundle), "updateMobile").g("updateMobile").j();
                    break;
                case 13:
                    com.yupptv.ott.fragments.onboarding.l lVar = new com.yupptv.ott.fragments.onboarding.l();
                    if (bundle != null) {
                        lVar.setArguments(bundle);
                    }
                    hVar.getSupportFragmentManager().q().c(2131428566, lVar, "address").g("address").j();
                    break;
                case 14:
                    com.yupptv.ott.fragments.onboarding.e eVar = new com.yupptv.ott.fragments.onboarding.e();
                    if (bundle != null) {
                        eVar.setArguments(bundle);
                    }
                    hVar.getSupportFragmentManager().q().r(2131428566, eVar, "languages").g("languages").j();
                    break;
                case 15:
                case 16:
                    hVar.getSupportFragmentManager().q().r(2131428566, com.yupptv.ott.fragments.onboarding.a.M(screenType, bundle), "change_email_id").g("changeEmail").j();
                    break;
                case 17:
                    hVar.getSupportFragmentManager().q().r(2131428566, com.yupptv.ott.fragments.onboarding.b.N(screenType, bundle), "change_mobile_number").g("changeMobileNo").j();
                    break;
                case 18:
                    n1 O = n1.O();
                    if (bundle != null) {
                        O.setArguments(bundle);
                    }
                    hVar.getSupportFragmentManager().q().r(2131428566, O, "userprofiles").g("userprofiles").j();
                    break;
                case 19:
                    hVar.getSupportFragmentManager().q().r(2131428566, com.yupptv.ott.fragments.q.L(), "createuserprofiles").g("createuserprofiles").j();
                    break;
                case 20:
                    hVar.getSupportFragmentManager().q().r(2131428566, new com.yupptv.ott.fragments.onboarding.m(), "forgotpin").g("forgotpin").j();
                    break;
                case 21:
                    hVar.getSupportFragmentManager().q().r(2131428566, new nc.l(), "RedeemVoucherFragment").g("RedeemVoucherFragment").j();
                    break;
                case 22:
                    hVar.getSupportFragmentManager().q().r(2131428566, new x0(), "FilterFragment").g("FilterFragment").j();
                    break;
            }
        }
    }

    public static void Y(androidx.fragment.app.h hVar, ScreenType screenType, Bundle bundle) {
        hd.h.a("screen type", "" + screenType);
        if (screenType != null) {
            int i2 = h.b[screenType.ordinal()];
            if (i2 == 1) {
                com.yupptv.ott.fragments.onboarding.c0 c0Var = new com.yupptv.ott.fragments.onboarding.c0();
                if (bundle != null) {
                    c0Var.setArguments(bundle);
                }
                hVar.getSupportFragmentManager().q().r(2131428566, c0Var, "signup").g("sign_up").j();
            }
            if (i2 == 3) {
                SignInFragment signInFragment = new SignInFragment();
                if (bundle != null) {
                    signInFragment.setArguments(bundle);
                }
                hVar.getSupportFragmentManager().q().r(2131428566, signInFragment, "signin").g("sign_in").j();
                return;
            }
            if (i2 == 14) {
                com.yupptv.ott.fragments.onboarding.n nVar = new com.yupptv.ott.fragments.onboarding.n();
                if (bundle != null) {
                    nVar.setArguments(bundle);
                }
                hVar.getSupportFragmentManager().q().r(2131428566, nVar, "languages").g("languages").j();
                return;
            }
            if (i2 == 5 || i2 == 6) {
                h1 h1Var = new h1();
                if (bundle != null) {
                    h1Var.setArguments(bundle);
                }
                hVar.getSupportFragmentManager().q().r(2131428566, h1Var, "paymentsmainfragment").g("paymentsmainfragment").j();
                return;
            }
            if (i2 == 7) {
                com.yupptv.ott.fragments.onboarding.g0 g0Var = new com.yupptv.ott.fragments.onboarding.g0();
                if (bundle != null) {
                    g0Var.setArguments(bundle);
                }
                hVar.getSupportFragmentManager().q().r(2131428566, g0Var, "userprofile").g("userprofile").j();
                return;
            }
            if (i2 == 8) {
                NewPackageFragment newPackageFragment = new NewPackageFragment();
                if (bundle != null) {
                    newPackageFragment.setArguments(bundle);
                }
                hVar.getSupportFragmentManager().q().r(2131428566, newPackageFragment, "packagefragment").g("packagefragment").j();
                return;
            }
            switch (i2) {
                case 18:
                    n1 n1Var = new n1();
                    if (bundle != null) {
                        n1Var.setArguments(bundle);
                    }
                    hVar.getSupportFragmentManager().q().r(2131428566, n1Var, "userprofiles").g("userprofiles").j();
                    break;
                case 19:
                    com.yupptv.ott.fragments.q qVar = new com.yupptv.ott.fragments.q();
                    if (bundle != null) {
                        qVar.setArguments(bundle);
                    }
                    hVar.getSupportFragmentManager().q().r(2131428566, qVar, "createuserprofiles").g("createuserprofiles").j();
                    break;
                case 20:
                    hVar.getSupportFragmentManager().q().r(2131428566, new com.yupptv.ott.fragments.onboarding.m(), "forgotpin").g("createuserprofiles").j();
                    break;
                default:
                    int i3 = 2131427847;
                    switch (i2) {
                        case 23:
                            f1 f1Var = new f1();
                            if (bundle != null) {
                                f1Var.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131428566, f1Var, "gifgpack").g("gifgpack").j();
                            break;
                        case 24:
                            i1 i1Var = new i1();
                            if (bundle != null) {
                                i1Var.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131428566, i1Var, "mobilepay").g("mobilepay").j();
                            break;
                        case 25:
                            g1 g1Var = new g1();
                            if (bundle != null) {
                                g1Var.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131428566, g1Var, "emailpay").g("emailpay").j();
                            break;
                        case 26:
                            com.yupptv.ott.fragments.m mVar = new com.yupptv.ott.fragments.m();
                            if (bundle != null) {
                                mVar.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131428566, mVar, "ccdetails").g("ccdetails").j();
                            break;
                        case 27:
                            x1 x1Var = new x1();
                            if (bundle != null) {
                                x1Var.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131428566, x1Var, "AddNewCardFragment").g("AddNewCardFragment").j();
                            break;
                        case 28:
                            nc.m mVar2 = new nc.m();
                            if (bundle != null) {
                                mVar2.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131428566, mVar2, "SavedCardsFragment").g("SavedCardsFragment").j();
                            break;
                        case 29:
                            nc.a aVar = new nc.a();
                            if (bundle != null) {
                                aVar.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131428566, aVar, "AddNewCardFragment").g("AddNewCardFragment").j();
                            break;
                        case 30:
                            d1 d1Var = new d1();
                            if (bundle != null) {
                                d1Var.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().c(2131428566, d1Var, "MyQuestionFragment").g("MyQuestionFragment").j();
                            break;
                        case 31:
                            y0 y0Var = new y0();
                            if (bundle != null) {
                                y0Var.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().c(2131428566, y0Var, "FullScreenImageFragment").g("FullScreenImageFragment").j();
                            break;
                        case 32:
                            nc.e eVar = new nc.e();
                            if (bundle != null) {
                                eVar.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131428566, eVar, "orderSummaryfragment").g("orderSummaryfragment").j();
                            break;
                        case 33:
                            nc.k kVar = new nc.k();
                            if (bundle != null) {
                                kVar.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131428566, kVar, "paymentnewgatewaysfragment").g("paymentnewgatewaysfragment").j();
                            break;
                        case 34:
                            nc.i iVar = new nc.i();
                            if (bundle != null) {
                                iVar.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131428566, iVar, "PayPalPaymentFragment").g("PayPalPaymentFragment").j();
                            break;
                        case 35:
                            e1 e1Var = new e1();
                            if (bundle != null) {
                                e1Var.setArguments(bundle);
                            }
                            if (hVar instanceof MainActivity) {
                                ((MainActivity) hVar).a1 = "favorites";
                            }
                            hVar.getSupportFragmentManager().q().c(2131427847, e1Var, "navigationfragment").j();
                            break;
                        case 36:
                            if ((hVar.getSupportFragmentManager().j0(2131427847) instanceof z0) && hVar.getSupportFragmentManager().k0("purchasedItem") != null) {
                                hVar.getSupportFragmentManager().q().p(hVar.getSupportFragmentManager().k0("purchasedItem")).j();
                            }
                            if (hVar instanceof MainActivity) {
                                ((MainActivity) hVar).z(false);
                            }
                            z0 z0Var = new z0();
                            if (bundle != null) {
                                z0Var.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131427847, z0Var, "purchasedItem").g("purchasedItem").j();
                            break;
                        case 37:
                            FragmentManager supportFragmentManager = hVar.getSupportFragmentManager();
                            if (supportFragmentManager.k0("navigationfragment") != null) {
                                supportFragmentManager.q().p(hVar.getSupportFragmentManager().k0("navigationfragment")).j();
                            }
                            if ((supportFragmentManager.j0(2131427847) instanceof z0) && supportFragmentManager.k0("offlindownload") != null) {
                                supportFragmentManager.q().p(supportFragmentManager.k0("offlindownload")).j();
                            }
                            if (hVar instanceof MainActivity) {
                                MainActivity mainActivity = (MainActivity) hVar;
                                mainActivity.z(false);
                                mainActivity.O5(false);
                            }
                            xc.b bVar = new xc.b();
                            if (bundle != null) {
                                bVar.setArguments(bundle);
                                if (bundle.containsKey(r.U0) && !TextUtils.isEmpty(bundle.getString(r.U0)) && bundle.getString(r.U0).equalsIgnoreCase("Details_Page")) {
                                    i3 = 2131428004;
                                }
                            }
                            hVar.getSupportFragmentManager().q().r(i3, bVar, "offlindownload").g("offlindownload").j();
                            break;
                        case 38:
                            if (hVar != null && (hVar instanceof MainActivity)) {
                                MainActivity mainActivity2 = (MainActivity) hVar;
                                mainActivity2.z(false);
                                mainActivity2.Y1(false, "");
                            }
                            hVar.getSupportFragmentManager().q().r(2131427847, new mc.m(), "VideoQuality").g("VideoQuality").j();
                            break;
                        case 39:
                            if (hVar != null && (hVar instanceof MainActivity)) {
                                MainActivity mainActivity3 = (MainActivity) hVar;
                                mainActivity3.z(false);
                                mainActivity3.Y1(false, "");
                            }
                            mc.a aVar2 = new mc.a();
                            if (bundle != null) {
                                aVar2.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131427847, new mc.a(), "AppSettings").g("AppSettings").j();
                            break;
                        case 40:
                            if (hVar != null && (hVar instanceof MainActivity)) {
                                MainActivity mainActivity4 = (MainActivity) hVar;
                                mainActivity4.z(false);
                                mainActivity4.Y1(false, "");
                            }
                            mc.b bVar2 = new mc.b();
                            if (bundle != null) {
                                bVar2.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131427847, new mc.b(), "AppTheme").g("AppTheme").j();
                            break;
                        case 41:
                            if ((hVar.getSupportFragmentManager().j0(2131427847) instanceof z0) && hVar.getSupportFragmentManager().k0("contentfilter") != null) {
                                hVar.getSupportFragmentManager().q().p(hVar.getSupportFragmentManager().k0("contentfilter")).j();
                            }
                            if (hVar instanceof MainActivity) {
                                ((MainActivity) hVar).z(false);
                            }
                            a0 y = a0.y(hVar);
                            if (y.f("IS_FIRST_TIME_APP_OPEN").booleanValue()) {
                                AppManager d2 = hd.a.a.d(OTTApplication.o());
                                if (d2.getNetworkList() == null || d2.getNetworkList().size() <= 0) {
                                    y.T("SUBSCRIBED_CONTENT_PARTNERS", "");
                                } else {
                                    y.C("IS_FIRST_TIME_APP_OPEN", Boolean.FALSE);
                                    StringBuilder sb2 = new StringBuilder();
                                    for (int i4 = 0; i4 < d2.getNetworkList().size(); i4++) {
                                        sb2.append(",");
                                        sb2.append(((Networks) d2.getNetworkList().get(i4)).getCode());
                                    }
                                    String substring = sb2.toString().startsWith(",") ? sb2.substring(1, sb2.length()) : "";
                                    if (sb2.toString().endsWith(",")) {
                                        substring = sb2.substring(0, sb2.length() - 1);
                                    }
                                    if (substring != null && !substring.equalsIgnoreCase("") && substring.length() > 0) {
                                        y.T("SUBSCRIBED_CONTENT_PARTNERS", substring);
                                    }
                                }
                            }
                            com.yupptv.ott.fragments.onboarding.o oVar = new com.yupptv.ott.fragments.onboarding.o();
                            if (bundle != null) {
                                oVar.setArguments(bundle);
                            }
                            hVar.getSupportFragmentManager().q().r(2131427847, oVar, "contentfilter").g("contentfilter").j();
                            break;
                        case 42:
                            if (hVar != null && (hVar instanceof MainActivity)) {
                                ((MainActivity) hVar).h4();
                                break;
                            }
                            break;
                    }
            }
        }
    }

    public static void Z(androidx.fragment.app.h hVar, ScreenType screenType, String str, boolean z, boolean z2, int i2, Integer num, String str2) {
        B0(hVar);
        if (screenType == ScreenType.OTP_VERIFY) {
            hVar.getSupportFragmentManager().q().r(2131428566, com.yupptv.ott.fragments.onboarding.g.P(screenType, str, i2, z2, num), "ForgotOTPVerification").g("ForgotOTPVerification").j();
            return;
        }
        if (screenType == ScreenType.RESET_PASSWORD) {
            hVar.getSupportFragmentManager().q().r(2131428566, com.yupptv.ott.fragments.onboarding.z.p0(screenType, str, i2, z2, num), "resetpwd").g("resetpasswd").j();
            return;
        }
        if (screenType == ScreenType.SUCCESS_RESET_PASSWORD) {
            hVar.getSupportFragmentManager().q().r(2131428566, com.yupptv.ott.fragments.onboarding.d0.g0(screenType, str, i2, z2, num, str2), "successresetpwd").g("successresetpwd").j();
        } else if (screenType == ScreenType.UPDATE_PASSWORD) {
            hVar.getSupportFragmentManager().q().r(2131428566, f0.T(screenType, str), "updatepwd").g("updatepwd").j();
        } else if (screenType == ScreenType.VIEW_LANGUAGES) {
            hVar.getSupportFragmentManager().q().r(2131428566, com.yupptv.ott.fragments.onboarding.n.f0(screenType, z, z2), "languages").g("languages").j();
        }
    }

    public static void a0(androidx.fragment.app.h hVar, String str, OTPType oTPType, String str2, String str3, Bundle bundle) {
        hVar.getSupportFragmentManager().q().r(2131428566, s.x0(str, oTPType, str2, str3, bundle), "updateMobile").g("updateMobile").j();
    }

    public static void b0(androidx.fragment.app.h hVar, String str, OTPType oTPType, String str2, String str3, String str4, Bundle bundle) {
        hVar.getSupportFragmentManager().q().r(2131428566, s.y0(str, oTPType, str2, str3, str4, bundle), "verifyMobile").g("verifyMobile").j();
    }

    public static void c0(androidx.fragment.app.h hVar, String str, OTPType oTPType, String str2, String str3, String str4, boolean z, Bundle bundle) {
        hVar.getSupportFragmentManager().q().r(2131428566, s.z0(str, oTPType, str2, str3, str4, z, bundle, "false", "", -1, -1), "verifyMobile").g("verifyMobile").j();
    }

    public static void d0(androidx.fragment.app.h hVar, String str, OTPType oTPType, String str2, String str3, String str4, boolean z, Bundle bundle, String str5, String str6, int i2, int i3) {
        hVar.getSupportFragmentManager().q().r(2131428566, s.z0(str, oTPType, str2, str3, str4, z, bundle, str5, str6, i2, i3), "verifyMobile").g("verifyMobile").j();
    }

    public static void e0(androidx.fragment.app.h hVar, String str, String str2) {
        Intent intent = new Intent((Context) hVar, (Class<?>) WebViewActivity.class);
        intent.putExtra("load_fragment", str);
        if (str2 != null) {
            intent.putExtra(r.r0, str2);
        }
        hVar.startActivity(intent);
    }

    public static void f0(androidx.fragment.app.h hVar, String str, String str2, String str3) {
        B0(hVar);
        Intent intent = new Intent((Context) hVar, (Class<?>) WebViewActivity.class);
        intent.putExtra("load_fragment", str);
        if (str2 != null) {
            intent.putExtra(r.r0, str2);
        }
        String str4 = r.I0;
        if (str3 == null) {
            str3 = "";
        }
        intent.putExtra(str4, str3);
        hVar.startActivity(intent);
    }

    public static void g0(androidx.fragment.app.h hVar, String str, String str2) {
        h0(hVar, str, str2, null);
    }

    public static sc.b h(java.lang.String r20, java.util.List<com.yupptv.ottsdk.model.BottomTemplate.Row> r21) {
        throw new UnsupportedOperationException("Method not decompiled: hd.u.h(java.lang.String, java.util.List):sc.b");
    }

    public static void h0(androidx.fragment.app.h hVar, String str, String str2, String str3) {
        B0(hVar);
        Intent intent = new Intent((Context) hVar, (Class<?>) WebViewActivity.class);
        intent.putExtra("load_fragment", str);
        if (str2 != null) {
            intent.putExtra(r.r0, str2);
        }
        if (str3 != null) {
            intent.putExtra(r.I0, str3);
        }
        int i2 = cc.b.B0().F0().equalsIgnoreCase("player") ? 10 : 101;
        cc.b.B0().K1("");
        hVar.startActivityForResult(intent, i2);
    }

    private static void i(androidx.fragment.app.h hVar, String str, Boolean bool) {
        if (bool.booleanValue()) {
            j(hVar, str, false);
        } else {
            A(hVar, str);
        }
    }

    public static void i0(androidx.fragment.app.h hVar, String str, String str2, String str3, Fragment fragment) {
        Intent intent = new Intent((Context) hVar, (Class<?>) WebViewActivity.class);
        intent.putExtra(r.t0, str);
        if (str2 != null) {
            intent.putExtra(r.r0, str2);
        }
        String str4 = r.R;
        if (str3 == null) {
            str3 = "";
        }
        intent.putExtra(str4, str3);
        fragment.startActivityForResult(intent, 99);
    }

    public static void j(Activity activity, String str, boolean z) {
        d.a aVar = new d.a();
        aVar.g(androidx.core.content.a.getColor(activity, 2131100058));
        aVar.h(true);
        aVar.e(2);
        aVar.b(h0.g(activity.getResources().getDrawable(2131230900)));
        if (z) {
            aVar.f(false);
        } else {
            aVar.f(true);
        }
        k0(activity, aVar.a(), Uri.parse(str));
    }

    public static void j0(androidx.fragment.app.h hVar, String str, String str2, boolean z) {
        Intent intent = new Intent((Context) hVar, (Class<?>) WebViewActivity.class);
        intent.putExtra("load_fragment", str);
        if (str2 != null) {
            intent.putExtra(r.r0, str2);
        }
        intent.putExtra(r.s0, z);
        hVar.startActivityForResult(intent, 101);
    }

    public static void k(Context context) {
        if (OTTApplication.m0) {
            return;
        }
        OTTApplication.m0 = true;
        a0 y = a0.y(context);
        hd.a.a.g(OTTApplication.o()).setDisplayLanguage("ENG");
        y.E("ENG");
        y.K(false);
        R0("ENG", context);
    }

    public static void k0(Activity activity, androidx.browser.customtabs.d dVar, Uri uri) {
        if (activity == null || uri == null) {
            return;
        }
        try {
            String uri2 = uri.toString();
            dVar.a.setPackage("com.android.chrome");
            if (uri2.length() > 0) {
                if (uri2.contains("http") || uri2.contains("https")) {
                    dVar.a(activity, uri);
                }
            }
        } catch (Exception unused) {
        }
    }

    public static void l(Context context, String str, String str2) {
        n(context, b, f, g, Boolean.valueOf(str.contains("trailer")), new i(str, str2, context));
    }

    public static void l0(androidx.fragment.app.h hVar, List list, String str, String str2, String str3, Object obj, String str4, boolean z, String str5, String str6, String str7, boolean z2, String str8, String str9, boolean z3) {
        nc.b bVar = new nc.b();
        Bundle bundle = new Bundle();
        bundle.putParcelableArrayList(r.R, (ArrayList) list);
        bundle.putString(r.Q, str);
        bundle.putString(r.U, str2);
        bundle.putString(r.V, str3);
        bundle.putString(r.Z, str4);
        bundle.putString(r.W, str6);
        bundle.putBoolean(r.a0, z2);
        bundle.putString(r.b0, str8);
        bundle.putString(r.c0, str9);
        bundle.putString("ChannelsMovies", str7);
        bundle.putString("Currency", str5);
        bundle.putParcelable(r.T, (Parcelable) obj);
        bundle.putBoolean("FromTab", z);
        bVar.setArguments(bundle);
        if (z3) {
            hVar.getSupportFragmentManager().q().c(z ? 2131427847 : 2131428566, bVar, "promocodefragment").g("promocodefragment").j();
        } else {
            hVar.getSupportFragmentManager().q().c(z ? 2131427847 : 2131428566, bVar, "promocodefragment").j();
        }
    }

    public static void m(OttSDK ottSDK) {
        try {
            hd.a.a.f(OTTApplication.o()).getAllBottomTemplates(new l());
        } catch (Exception e2) {
            hd.h.b("TAG", "crash template :: " + e2.getMessage());
        }
    }

    public static void m0(androidx.fragment.app.h hVar, List list, String str, String str2, String str3, Object obj, String str4, String str5, boolean z, boolean z2, String str6, String str7) {
        nc.j jVar = new nc.j();
        Bundle bundle = new Bundle();
        bundle.putParcelableArrayList(r.R, (ArrayList) list);
        bundle.putString(r.Q, str);
        bundle.putString(r.U, str2);
        bundle.putString(r.V, str3);
        bundle.putString(r.Z, str4);
        bundle.putString(r.W, str5);
        bundle.putBoolean(r.a0, z2);
        bundle.putString(r.b0, str6);
        bundle.putString(r.c0, str7);
        bundle.putParcelable(r.T, (Parcelable) obj);
        jVar.setArguments(bundle);
        androidx.fragment.app.d0 q = hVar.getSupportFragmentManager().q();
        int i2 = z ? 2131427847 : 2131428566;
        ScreenType screenType = ScreenType.PAYMENT_GATEWAYS_SCREEN;
        q.c(i2, jVar, screenType.toString()).g(screenType.toString()).j();
    }

    public static void n(Context context, String str, String str2, String str3, Boolean bool, oc.e eVar) {
        a.C0133a c0133a = hd.a.a;
        if (c0133a.g(OTTApplication.o()) == null || c0133a.g(OTTApplication.o()).getLoggedUser() == null || bool.booleanValue() || !hd.d.w) {
            eVar.a();
        } else {
            c0133a.f(OTTApplication.o()).getNotificationDetails(str, new f(context, str2, str, str3, eVar));
        }
    }

    public static void n0(androidx.fragment.app.h hVar, Banner banner) {
        B0(hVar);
        if (banner == null || banner.getTarget() == null || banner.getTarget().getPath() == null) {
            return;
        }
        String path = banner.getTarget().getPath();
        if (banner.getTarget() != null && banner.getTarget().getPageAttributes() != null && banner.getTarget().getPageAttributes().getTvShowName() != null) {
            cc.b.B0().Z1(banner.getTarget().getPageAttributes().getTvShowName());
        }
        if (path.trim().length() == 0) {
            return;
        }
        if (hVar != null && (hVar instanceof MainActivity)) {
            MainActivity mainActivity = (MainActivity) hVar;
            if (mainActivity.U2()) {
                cc.c.d().l(mainActivity.B2(), null, banner, null, cc.c.d0, mainActivity.u2());
            }
        }
        String str = "";
        if (banner.getMetadata() != null && banner.getMetadata().getGamezop() != null) {
            String gamezop = banner.getMetadata().getGamezop();
            hd.h.a("gameZopValue>>", "" + gamezop);
            if (!banner.getIsInternal().booleanValue() || !gamezop.equalsIgnoreCase("true")) {
                T(hVar, path, Boolean.FALSE);
                return;
            }
            String str2 = r.i1;
            if (banner.getTitle() != null && !banner.getTitle().isEmpty()) {
                str = banner.getTitle();
            }
            f0(hVar, str2, path, str);
            return;
        }
        if (banner.getMetadata() != null && banner.getMetadata().getHungamaGame() != null) {
            String hungamaGame = banner.getMetadata().getHungamaGame();
            hd.h.a("hungamaGameValue>>", "" + hungamaGame);
            if (!banner.getIsInternal().booleanValue() || !hungamaGame.equalsIgnoreCase("true")) {
                T(hVar, path, Boolean.FALSE);
                return;
            }
            String str3 = r.i1;
            if (banner.getTitle() != null && !banner.getTitle().isEmpty()) {
                str = banner.getTitle();
            }
            f0(hVar, str3, path, str);
            return;
        }
        if (banner.getMetadata() != null && banner.getMetadata().getPlanId() != null) {
            j = banner.getMetadata().getPlanId();
        }
        if (!banner.getIsInternal().booleanValue()) {
            if (banner.getIsInternal().booleanValue() || !path.startsWith("http")) {
                f0(hVar, r.p1, path, banner.getTitle());
                return;
            } else {
                A(hVar, path);
                return;
            }
        }
        if (path.contains("signup")) {
            J(hVar);
            return;
        }
        if (path.contains("signin")) {
            I(hVar);
            return;
        }
        if (path.contains("package") || path.equalsIgnoreCase("subscribe") || path.equalsIgnoreCase("plans") || path.contains("plans/list")) {
            H(hVar, "");
            return;
        }
        if (path.contains("flexi")) {
            B(hVar);
            return;
        }
        if ((banner.getIsDeeplinking() == null || !banner.getIsDeeplinking().equalsIgnoreCase("true")) && (banner.getTarget() == null || banner.getTarget().getPageAttributes() == null || banner.getTarget().getPageAttributes().getIsDeeplinking() == null || banner.getTarget().getPageAttributes().getIsDeeplinking().trim().length() <= 0 || !banner.getTarget().getPageAttributes().getIsDeeplinking().equalsIgnoreCase("true"))) {
            if (path.startsWith("http")) {
                f0(hVar, r.p1, path, banner.getTitle());
                return;
            }
            if (hVar instanceof MainActivity) {
                ((MainActivity) hVar).Y1(false, "");
            }
            G(path, banner.getTitle(), hVar);
            return;
        }
        if (banner.getTarget().getPageAttributes().getNetworkCode() != null) {
            b = banner.getTarget().getPageAttributes().getNetworkCode();
        }
        if (banner.getNetworkIcon() != null) {
            g = banner.getNetworkIcon();
        }
        if (banner.getTarget().getPageAttributes().getNetworkName() != null) {
            f = banner.getTarget().getPageAttributes().getNetworkName();
        }
        l(hVar, banner.getTarget().getPath(), banner.getTitle());
        if (banner.getTarget().getPageAttributes().getContentType() != null) {
            i = banner.getTarget().getPageAttributes().getMediaContentType();
        }
        if (banner.getTarget().getPageAttributes().getContentType() != null) {
            d = banner.getTarget().getPageAttributes().getContentType();
        }
        if (banner.getTarget().getPageAttributes().getTrailerAssetId() != null) {
            e = banner.getTarget().getPageAttributes().getTrailerAssetId();
        }
        if (banner.getTarget().getPageAttributes().getIsSdk() == null || !banner.getTarget().getPageAttributes().getIsSdk().equalsIgnoreCase("true")) {
            c = false;
        } else {
            c = true;
        }
        String path2 = banner.getTarget().getPath();
        if (banner.getTitle() != null && !banner.getTitle().isEmpty()) {
            str = banner.getTitle();
        }
        l(hVar, path2, str);
    }

    public static void o(Context context) {
        cc.c.d().k(null);
        hd.a.a.d(OTTApplication.o()).getConfigurationData((TenantBuildType) null, new d(context));
    }

    public static void o0(androidx.fragment.app.h hVar, String str, String str2) {
        B0(hVar);
        Bundle bundle = new Bundle();
        v0 v0Var = new v0();
        bundle.putString(r.q, str);
        v0Var.setArguments(bundle);
        if (hVar.getSupportFragmentManager().k0("navigationfragment") != null) {
            hVar.getSupportFragmentManager().q().p(hVar.getSupportFragmentManager().k0("navigationfragment")).j();
        }
        hVar.getSupportFragmentManager().q().b((TextUtils.isEmpty(str2) || !str2.equalsIgnoreCase(cc.c.A1)) ? 2131427847 : 2131428004, v0Var).g(PageType.Error.getValue()).j();
    }

    public static Fragment p(String str, String str2, int i2) {
        Bundle bundle = new Bundle();
        a1 a1Var = new a1();
        bundle.putString(r.I0, str);
        bundle.putString(r.z, str2);
        bundle.putInt(r.A, i2);
        bundle.putString(r.C0, str);
        a1Var.setArguments(bundle);
        return a1Var;
    }

    public static void p0(androidx.fragment.app.h hVar, String str, String str2, int i2, String str3) {
        Bundle bundle = new Bundle();
        jc.d dVar = new jc.d();
        bundle.putString(r.I0, str != null ? str : "");
        bundle.putString(r.z, str2);
        bundle.putInt(r.A, i2);
        String str4 = r.C0;
        if (str3 == null) {
            str3 = "";
        }
        bundle.putString(str4, str3);
        dVar.setArguments(bundle);
        hVar.getSupportFragmentManager().q().s(android.R.anim.fade_in, android.R.anim.fade_out).b(2131427847, dVar).g(str).j();
    }

    public static Fragment q(String str, String str2, String str3, int i2) {
        Bundle bundle = new Bundle();
        a1 a1Var = new a1();
        bundle.putString(r.I0, str);
        bundle.putString(r.z, str2);
        bundle.putInt(r.A, i2);
        bundle.putString(r.C0, str);
        bundle.putString(r.B, str3);
        a1Var.setArguments(bundle);
        return a1Var;
    }

    public static void q0(androidx.fragment.app.h hVar, PageType pageType, Object obj, int i2) {
        B0(hVar);
        z0 z0Var = new z0();
        Bundle bundle = new Bundle();
        if (obj instanceof HeaderItemWithControls) {
            HeaderItemWithControls headerItemWithControls = (HeaderItemWithControls) obj;
            bundle.putParcelable(r.J0, (Parcelable) obj);
            if (i2 >= 0) {
                bundle.putInt(r.s, i2);
                bundle.putString(r.I0, headerItemWithControls.j().get(i2).getName());
            } else {
                bundle.putString(r.I0, headerItemWithControls.h());
            }
            bundle.putString(r.C0, cc.c.a0 + headerItemWithControls.h());
            if (hVar instanceof MainActivity) {
                ((MainActivity) hVar).a1 = headerItemWithControls.b().getViewAllTargetPath();
            }
        } else {
            bundle.putString(r.I0, (String) obj);
        }
        bundle.putString(r.c, cc.c.a0);
        z0Var.setArguments(bundle);
        hVar.getSupportFragmentManager().q().b(2131427847, z0Var).g(pageType.getValue()).j();
    }

    public static void r(String str, String str2, String str3, String str4, Context context) {
        hd.a.a.f(OTTApplication.o()).getHotstarDetails(str, str2, new j(str4, str3, context));
    }

    public static void r0(androidx.fragment.app.h hVar, PageType pageType, Object obj, String str) {
        B0(hVar);
        hd.h.a("NavigationUtils>>", "cardType>>" + str);
        cc.b.B0().C1("View All");
        Fragment c1Var = str.equalsIgnoreCase(PosterType.CONTENT_POSTER.getValue()) ? new c1() : new z0();
        Bundle bundle = new Bundle();
        if (obj instanceof HeaderItemWithControls) {
            HeaderItemWithControls headerItemWithControls = (HeaderItemWithControls) obj;
            bundle.putParcelable(r.J0, (Parcelable) obj);
            bundle.putString(r.I0, headerItemWithControls.h());
            bundle.putString(r.C0, cc.c.a0 + headerItemWithControls.h());
            if (hVar instanceof MainActivity) {
                ((MainActivity) hVar).a1 = headerItemWithControls.b().getViewAllTargetPath();
            }
        } else {
            bundle.putString(r.I0, (String) obj);
        }
        bundle.putString(r.c, cc.c.a0);
        c1Var.setArguments(bundle);
        if (hVar == null || hVar.getSupportFragmentManager() == null || hVar.getSupportFragmentManager().q() == null) {
            return;
        }
        if (pageType == PageType.Details) {
            hVar.getSupportFragmentManager().q().s(android.R.anim.fade_in, android.R.anim.fade_out).q(2131428004, c1Var).g(pageType.getValue()).j();
        } else {
            hVar.getSupportFragmentManager().q().s(android.R.anim.fade_in, android.R.anim.fade_out).b(2131427847, c1Var).g(pageType.getValue()).j();
        }
    }

    public static Fragment s(String str, String str2, int i2) {
        Bundle bundle = new Bundle();
        mc.l lVar = new mc.l();
        bundle.putSerializable("type", ListType.SETTINGS_MENU);
        lVar.setArguments(bundle);
        return lVar;
    }

    public static void s0(androidx.fragment.app.Fragment r27, androidx.fragment.app.h r28, java.lang.Object r29, java.lang.String r30, java.lang.String r31, java.lang.String r32) {
        throw new UnsupportedOperationException("Method not decompiled: hd.u.s0(androidx.fragment.app.Fragment, androidx.fragment.app.h, java.lang.Object, java.lang.String, java.lang.String, java.lang.String):void");
    }

    public static Fragment t(String str, String str2, int i2) {
        Bundle bundle = new Bundle();
        nc.h hVar = new nc.h();
        bundle.putString(r.I0, str);
        bundle.putString(r.z, str2);
        bundle.putInt(r.A, i2);
        bundle.putString(r.C0, str);
        bundle.putString(r.y0, "tab");
        hVar.setArguments(bundle);
        return hVar;
    }

    public static void t0(androidx.fragment.app.h hVar, String str) {
        boolean z;
        B0(hVar);
        a0.y(hVar);
        User loggedUser = hd.a.a.g(OTTApplication.o()).getLoggedUser();
        cc.e.n().T(str);
        Bundle bundle = new Bundle();
        MainActivity mainActivity = (MainActivity) hVar;
        String str2 = "";
        if (mainActivity != null) {
            mainActivity.Y1(false, "");
        }
        if (hVar == null) {
            return;
        }
        MainActivity mainActivity2 = (MainActivity) hVar;
        List<Menu> list = mainActivity2.Q1;
        if (list != null) {
            int size = list.size();
            z = false;
            for (int i2 = 0; i2 < size; i2++) {
                if (str.equalsIgnoreCase(String.valueOf(mainActivity2.Q1.get(i2).getTargetPath()))) {
                    str2 = String.valueOf(mainActivity2.Q1.get(i2).getCode());
                    z = true;
                }
            }
        } else {
            z = false;
        }
        if (str.contains("package") || str.contains("pricing") || str.contains("plans") || str.contains("plans/list")) {
            H(hVar, str);
            return;
        }
        if (str.contains("flexi")) {
            B(hVar);
            return;
        }
        if (str.contains("signup")) {
            J(hVar);
            return;
        }
        if (str.contains("signin")) {
            I(hVar);
            return;
        }
        if (str.contains(".html")) {
            j(hVar, str, false);
            return;
        }
        if (str.contains("redeem") && mainActivity != null) {
            if (!com.yupptv.ott.a.K) {
                mainActivity.x3();
                return;
            } else if (hd.a.r(OTTApplication.o()).getLoggedUser() == null) {
                mainActivity.y3(false, 10003);
                return;
            } else {
                mainActivity.F3(true, null, new String[0]);
                return;
            }
        }
        if (str.contains("activate")) {
            com.yupptv.ott.a.j = true;
            com.yupptv.ott.a.k = str;
            if (loggedUser != null) {
                z(hVar, str);
                return;
            } else {
                I(hVar);
                return;
            }
        }
        if (z) {
            mainActivity2.r5(str2);
            return;
        }
        e1 e1Var = new e1();
        bundle.putString(r.z, str);
        e1Var.setArguments(bundle);
        if (hVar instanceof MainActivity) {
            mainActivity2.a1 = str;
        }
        hVar.getSupportFragmentManager().q().c(2131427848, e1Var, "navigationfragment").j();
    }

    public static Fragment u(String str, String str2, int i2) {
        Bundle bundle = new Bundle();
        jc.d dVar = new jc.d();
        bundle.putString(r.I0, str);
        bundle.putString(r.z, str2);
        bundle.putInt(r.A, i2);
        bundle.putString(r.C0, str);
        dVar.setArguments(bundle);
        return dVar;
    }

    public static void u0(androidx.fragment.app.h hVar, String str, String str2, String str3) {
        B0(hVar);
        Bundle bundle = new Bundle();
        if (hVar == null) {
            return;
        }
        cc.b.B0().h2(str3);
        MainActivity mainActivity = (MainActivity) hVar;
        int size = mainActivity.Q1.size();
        boolean z = false;
        for (int i2 = 0; i2 < size; i2++) {
            if (str.equalsIgnoreCase(String.valueOf(mainActivity.Q1.get(i2).getTargetPath()))) {
                mainActivity.Q1.get(i2).getCode();
                z = true;
            }
        }
        if (z) {
            return;
        }
        e1 e1Var = new e1();
        bundle.putString(r.z, str);
        if (str2 != null) {
            bundle.putString(r.U0, str2);
        }
        e1Var.setArguments(bundle);
        if (hVar instanceof MainActivity) {
            mainActivity.a1 = str;
        }
        hVar.getSupportFragmentManager().q().c(2131427848, e1Var, "navigationfragment").j();
    }

    public static Fragment v(String str, String str2) {
        Bundle bundle = new Bundle();
        w2 w2Var = new w2();
        bundle.putString("Browser", str);
        if (str2 != null) {
            bundle.putString(r.r0, str2);
        }
        w2Var.setArguments(bundle);
        return w2Var;
    }

    public static void v0(androidx.fragment.app.h r20, java.lang.Object r21, java.lang.String r22, java.lang.String r23, java.lang.String r24, java.lang.String r25) {
        throw new UnsupportedOperationException("Method not decompiled: hd.u.v0(androidx.fragment.app.h, java.lang.Object, java.lang.String, java.lang.String, java.lang.String, java.lang.String):void");
    }

    private static void w(androidx.fragment.app.h hVar) {
        if (hVar != null) {
            n0.a(hVar.getWindow(), false);
            p0 p0Var = new p0(hVar.getWindow(), hVar.getWindow().getDecorView());
            p0Var.a(o0.m.b());
            p0Var.b(2);
        }
    }

    public static void w0(androidx.fragment.app.h hVar) {
        hVar.getSupportFragmentManager().q().s(android.R.anim.fade_in, android.R.anim.fade_out).q(2131427847, new l0()).j();
    }

    public static void x(String str, Dialog dialog, View view) {
        P0(str, "true");
        dialog.dismiss();
    }

    public static void x0(Context context) {
        a.C0133a c0133a = hd.a.a;
        c0133a.b(OTTApplication.o()).getUserManager().sessionListener(new o(context));
        c0133a.f(OTTApplication.o()).sessionListener(new b(context));
        c0133a.b(OTTApplication.o()).getPaymentManager().sessionListener(new c(context));
    }

    public static void y(oc.e eVar, CheckBox checkBox, String str, Dialog dialog, View view) {
        eVar.a();
        if (checkBox.isChecked()) {
            P0(str, "false");
        } else {
            P0(str, "true");
        }
        StringBuilder sb2 = new StringBuilder();
        sb2.append("doNotShowAgain.isChecked()");
        sb2.append(checkBox.isChecked() ? "true" : "false");
        hd.h.b("OTTApplication", sb2.toString());
        hd.h.b("OTTApplication", " networkCode  :  " + str + "  showNotification :  " + checkBox.isChecked());
        dialog.dismiss();
    }

    public static void y0(androidx.fragment.app.h hVar, String str, Card card) {
        if (hVar instanceof MainActivity) {
            ((MainActivity) hVar).A3(OTTApplication.B, card);
        }
    }

    public static void z(Context context, String str) {
        String lastPathSegment = Uri.parse(str).getLastPathSegment();
        Intent intent = new Intent(context, (Class<?>) ActivateDeviceFragment.class);
        intent.putExtra("activationCode", lastPathSegment);
        intent.putExtra("isFromDeeplink", true);
        context.startActivity(intent);
    }

    private static void z0(cc.b bVar) {
        HashMap hashMap = new HashMap();
        hashMap.put(cc.a.o0, bVar.p0() != null ? bVar.p0() : "");
        hashMap.put(cc.a.l0, bVar.r0() != null ? bVar.r0() : "");
        hashMap.put(cc.a.m0, bVar.z0() != null ? bVar.z0() : "");
        hashMap.put(cc.a.n0, bVar.s0() != null ? bVar.s0() : "");
        hashMap.put(cc.a.s0, bVar.w0() != null ? bVar.w0() : "");
        hashMap.put(cc.a.q0, bVar.X0() != null ? bVar.X0() : "");
        hashMap.put(cc.a.r0, bVar.U0() != null ? bVar.U0() : "");
        hashMap.put(cc.a.p0, bVar.q0() != null ? bVar.q0() : "");
        cc.c.d().r(cc.a.Y, hashMap);
    }
}