红果免费短剧 v6.2.3.32版本的 MD5 值为:a6b05492607eab2c8a25f26d2f238ae0

以下内容为反编译后的 d.java 源代码,内容仅作参考


package com.dragon.read.coldstart.bigredpacket.luckycatui;

import android.animation.Animator;
import android.animation.AnimatorSet;
import android.animation.ObjectAnimator;
import android.content.Context;
import android.content.Intent;
import android.view.View;
import android.view.Window;
import android.widget.ImageView;
import android.widget.TextView;
import com.bytedance.apm.agent.v2.instrumentation.ClickAgent;
import com.bytedance.ug.sdk.luckycat.api.e.a;
import com.bytedance.ug.sdk.luckycat.impl.bigredpacket.model.RedPacketModel;
import com.dragon.read.app.ActivityRecordManager;
import com.dragon.read.app.App;
import com.dragon.read.base.ui.util.callback.SimpleAnimatorListener;
import com.dragon.read.base.util.LogWrapper;
import com.dragon.read.coldstart.bigredpacket.ForceShowRedPacketModel;
import com.dragon.read.component.biz.api.NsUgDepend;
import com.dragon.read.pop.b;
import com.dragon.read.widget.dialog.AbsQueueDialog;
import com.phoenix.read.R;
import com.ss.android.common.animate.CubicBezierInterpolator;
import java.util.Arrays;
import java.util.Calendar;
import java.util.Locale;
import kotlin.Unit;
import kotlin.jvm.functions.Function0;
import kotlin.jvm.internal.DefaultConstructorMarker;
import kotlin.jvm.internal.Intrinsics;
import kotlin.jvm.internal.StringCompanionObject;
import org.json.JSONObject;

public final class d extends AbsQueueDialog implements com.bytedance.ug.sdk.luckycat.api.e.a {

    public static final a f46358a = new a(null);
    private TextView A;
    private ImageView B;
    private ImageView C;

    public View f46359b;

    public a.InterfaceC1129a f46360c;
    public AnimatorSet d;
    public AnimatorSet e;
    public AnimatorSet f;
    public AnimatorSet g;
    public String h;
    public String i;
    public boolean j;
    public boolean k;
    public boolean l;
    public boolean m;
    public RedPacketModel n;
    private View o;
    private View p;
    private ImageView q;
    private TextView r;
    private View s;
    private TextView t;
    private TextView u;
    private TextView v;
    private TextView w;
    private View x;
    private ImageView y;
    private TextView z;

    private static final String k() {
        return f46358a.a();
    }

    public static final class a {
        public a(DefaultConstructorMarker defaultConstructorMarker) {
            this();
        }

        private a() {
        }

        public final String a() {
            boolean z;
            boolean z2;
            long j;
            double random;
            double d;
            long j2;
            Calendar calendar = Calendar.getInstance();
            calendar.setTimeInMillis(System.currentTimeMillis());
            int i = calendar.get(11);
            boolean z3 = true;
            LogWrapper.debug("LuckyRedPacketDialog", "todayHour= %d", Integer.valueOf(i));
            if (i >= 0 && i < 10) {
                z = true;
            } else {
                z = false;
            }
            if (z) {
                random = Math.random() * 80000;
                j = 20000;
            } else {
                if (10 <= i && i < 14) {
                    z2 = true;
                } else {
                    z2 = false;
                }
                if (z2) {
                    d = 100000L;
                    random = Math.random() * d;
                    j2 = (long) (random + d);
                    if (j2 < 1000) {
                        String valueOf = String.valueOf(j2);
                        StringBuilder sb = new StringBuilder();
                        String substring = valueOf.substring(0, valueOf.length() - 3);
                        Intrinsics.checkNotNullExpressionValue(substring, "this as java.lang.String…ing(startIndex, endIndex)");
                        sb.append(substring);
                        sb.append(",");
                        String substring2 = valueOf.substring(valueOf.length() - 3);
                        Intrinsics.checkNotNullExpressionValue(substring2, "this as java.lang.String).substring(startIndex)");
                        sb.append(substring2);
                        String sb2 = sb.toString();
                        Intrinsics.checkNotNullExpressionValue(sb2, "{\n                val nu….toString()\n            }");
                        return sb2;
                    }
                    return String.valueOf(j2);
                }
                if (14 > i || i >= 18) {
                    z3 = false;
                }
                j = 200000;
                if (z3) {
                    random = Math.random() * 100000;
                } else {
                    random = Math.random() * 200000;
                    j = 300000;
                }
            }
            d = j;
            j2 = (long) (random + d);
            if (j2 < 1000) {
            }
        }
    }

    private final void i() {
        this.d = null;
        this.e = null;
        this.f = null;
        this.g = null;
    }

    public final void a() {
        NsUgDepend.IMPL.playAudio("http://lf3-reading.fqnovelpic.com/obj/novel-common/audio_open_lucky_red_packet.wav", new Function0<Unit>() {
            @Override
            public Unit invoke() {
                invoke2();
                return Unit.INSTANCE;
            }

            public final void invoke2() {
                LogWrapper.info("LuckyRedPacketDialog", "playOpenTips finish", new Object[0]);
            }
        });
    }

    private final void h() {
        View view = this.f46359b;
        if (view == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClOpen");
            view = null;
        }
        view.setVisibility(0);
        AnimatorSet animatorSet = this.d;
        if (animatorSet != null) {
            animatorSet.start();
        }
        AnimatorSet animatorSet2 = this.f;
        if (animatorSet2 != null) {
            animatorSet2.start();
        }
    }

    public final void b() {
        AnimatorSet animatorSet = this.d;
        if (animatorSet != null) {
            animatorSet.cancel();
        }
        AnimatorSet animatorSet2 = this.e;
        if (animatorSet2 != null) {
            animatorSet2.cancel();
        }
        AnimatorSet animatorSet3 = this.f;
        if (animatorSet3 != null) {
            animatorSet3.cancel();
        }
        AnimatorSet animatorSet4 = this.g;
        if (animatorSet4 != null) {
            animatorSet4.cancel();
        }
    }

    @Override
    public void realDismiss() {
        super.realDismiss();
        b();
        i();
        a.InterfaceC1129a interfaceC1129a = this.f46360c;
        if (interfaceC1129a != null) {
            interfaceC1129a.b();
        }
    }

    private final void g() {
        ImageView imageView = this.q;
        View view = null;
        if (imageView == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mIvClose");
            imageView = null;
        }
        imageView.setOnClickListener(new b());
        View view2 = this.f46359b;
        if (view2 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClOpen");
        } else {
            view = view2;
        }
        view.setOnClickListener(new c());
    }

    private final void j() {
        String d = com.dragon.read.coldstart.bigredpacket.a.a.a().d(ActivityRecordManager.inst().getCurrentVisibleActivity());
        Intrinsics.checkNotNullExpressionValue(d, "inst().getCurrentPositio…).currentVisibleActivity)");
        com.dragon.read.coldstart.bigredpacket.custom.d.a(d, NsUgDepend.IMPL.getStoreTopChannel(ActivityRecordManager.inst().getCurrentVisibleActivity()), "old");
    }

    private final void d() {
        ((ImageView) findViewById(R.id.cen)).setImageResource(R.drawable.bqn);
        ((ImageView) findViewById(R.id.cet)).setImageResource(R.drawable.cp7);
        ImageView imageView = this.C;
        ImageView imageView2 = null;
        if (imageView == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mIvOpenButton");
            imageView = null;
        }
        imageView.setImageResource(R.drawable.bqq);
        ImageView imageView3 = this.B;
        if (imageView3 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mIvBgOpenButton");
            imageView3 = null;
        }
        imageView3.setImageResource(R.drawable.bqo);
        ImageView imageView4 = this.q;
        if (imageView4 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mIvClose");
        } else {
            imageView2 = imageView4;
        }
        imageView2.setImageResource(R.drawable.br_);
    }

    private final void e() {
        View view = this.s;
        TextView textView = null;
        if (view == null) {
            Intrinsics.throwUninitializedPropertyAccessException("clRewardAmountStyleView");
            view = null;
        }
        view.setVisibility(8);
        View view2 = this.x;
        if (view2 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("clPlainTextStyleView");
            view2 = null;
        }
        view2.setVisibility(0);
        ImageView imageView = this.y;
        if (imageView == null) {
            Intrinsics.throwUninitializedPropertyAccessException("ivLoginIconView");
            imageView = null;
        }
        imageView.setImageResource(R.drawable.ccd);
        TextView textView2 = this.z;
        if (textView2 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("tvMainTextView");
            textView2 = null;
        }
        textView2.setText(App.context().getString(R.string.bia));
        TextView textView3 = this.A;
        if (textView3 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("tvSubTextView");
        } else {
            textView = textView3;
        }
        textView.setText("恭喜发财,大吉大利");
    }

    private final void f() {
        String str;
        View view = this.s;
        TextView textView = null;
        if (view == null) {
            Intrinsics.throwUninitializedPropertyAccessException("clRewardAmountStyleView");
            view = null;
        }
        view.setVisibility(0);
        View view2 = this.x;
        if (view2 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("clPlainTextStyleView");
            view2 = null;
        }
        view2.setVisibility(8);
        TextView textView2 = this.t;
        if (textView2 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mTvTitle");
            textView2 = null;
        }
        if (com.dragon.read.polaris.userimport.k.f75055a.d()) {
            str = "新朋友见面礼";
        } else {
            str = "恭喜你收到现金红包";
        }
        textView2.setText(str);
        TextView textView3 = this.w;
        if (textView3 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mTvRewardTips");
            textView3 = null;
        }
        textView3.setText(this.i);
        TextView textView4 = this.w;
        if (textView4 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mTvRewardTips");
            textView4 = null;
        }
        textView4.setVisibility(0);
        TextView textView5 = this.u;
        if (textView5 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mTvRewardAmount");
            textView5 = null;
        }
        textView5.setText(this.h);
        TextView textView6 = this.v;
        if (textView6 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mTvRewardType");
        } else {
            textView = textView6;
        }
        textView.setText(com.dragon.read.polaris.tools.g.b("rmb"));
    }

    private final void c() {
        View findViewById = findViewById(R.id.aul);
        Intrinsics.checkNotNullExpressionValue(findViewById, "findViewById(R.id.cl_bg_bottom)");
        this.p = findViewById;
        View findViewById2 = findViewById(R.id.auo);
        Intrinsics.checkNotNullExpressionValue(findViewById2, "findViewById(R.id.cl_bg_top)");
        this.o = findViewById2;
        View findViewById3 = findViewById(R.id.f);
        Intrinsics.checkNotNullExpressionValue(findViewById3, "findViewById(R.id.iv_close)");
        this.q = (ImageView) findViewById3;
        View findViewById4 = findViewById(R.id.hl);
        Intrinsics.checkNotNullExpressionValue(findViewById4, "findViewById(R.id.tv_bottom_tips)");
        this.r = (TextView) findViewById4;
        View findViewById5 = findViewById(R.id.awh);
        Intrinsics.checkNotNullExpressionValue(findViewById5, "findViewById(R.id.cl_style_reward_amount)");
        this.s = findViewById5;
        View findViewById6 = findViewById(R.id.j8);
        Intrinsics.checkNotNullExpressionValue(findViewById6, "findViewById(R.id.tv_title)");
        this.t = (TextView) findViewById6;
        View findViewById7 = findViewById(R.id.fo1);
        Intrinsics.checkNotNullExpressionValue(findViewById7, "findViewById(R.id.tv_reward_amount)");
        this.u = (TextView) findViewById7;
        View findViewById8 = findViewById(R.id.fon);
        Intrinsics.checkNotNullExpressionValue(findViewById8, "findViewById(R.id.tv_reward_type)");
        this.v = (TextView) findViewById8;
        View findViewById9 = findViewById(R.id.fol);
        Intrinsics.checkNotNullExpressionValue(findViewById9, "findViewById(R.id.tv_reward_tips)");
        this.w = (TextView) findViewById9;
        View findViewById10 = findViewById(R.id.aw1);
        Intrinsics.checkNotNullExpressionValue(findViewById10, "findViewById(R.id.cl_open)");
        this.f46359b = findViewById10;
        View findViewById11 = findViewById(R.id.cer);
        Intrinsics.checkNotNullExpressionValue(findViewById11, "findViewById(R.id.iv_bg_open_button)");
        this.B = (ImageView) findViewById11;
        View findViewById12 = findViewById(R.id.cld);
        Intrinsics.checkNotNullExpressionValue(findViewById12, "findViewById(R.id.iv_open_button)");
        this.C = (ImageView) findViewById12;
        View findViewById13 = findViewById(R.id.awg);
        Intrinsics.checkNotNullExpressionValue(findViewById13, "findViewById(R.id.cl_style_plain_text)");
        this.x = findViewById13;
        View findViewById14 = findViewById(R.id.clo);
        Intrinsics.checkNotNullExpressionValue(findViewById14, "findViewById(R.id.iv_plain_logo)");
        this.y = (ImageView) findViewById14;
        View findViewById15 = findViewById(R.id.fki);
        Intrinsics.checkNotNullExpressionValue(findViewById15, "findViewById(R.id.tv_plain_main_text)");
        this.z = (TextView) findViewById15;
        View findViewById16 = findViewById(R.id.fkj);
        Intrinsics.checkNotNullExpressionValue(findViewById16, "findViewById(R.id.tv_plain_sub_text)");
        this.A = (TextView) findViewById16;
        d();
    }

    @Override
    public void realShow() {
        super.realShow();
        ImageView imageView = this.B;
        ImageView imageView2 = null;
        if (imageView == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mIvBgOpenButton");
            imageView = null;
        }
        this.d = a(imageView, 1.0f, 1.2f, 500L);
        ImageView imageView3 = this.B;
        if (imageView3 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mIvBgOpenButton");
            imageView3 = null;
        }
        this.e = a(imageView3, 1.2f, 1.0f, 600L);
        ImageView imageView4 = this.C;
        if (imageView4 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mIvOpenButton");
            imageView4 = null;
        }
        this.f = a(imageView4, 1.0f, 1.1f, 500L);
        ImageView imageView5 = this.C;
        if (imageView5 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mIvOpenButton");
        } else {
            imageView2 = imageView5;
        }
        this.g = a(imageView2, 1.1f, 1.0f, 600L);
        AnimatorSet animatorSet = this.d;
        if (animatorSet != null) {
            animatorSet.addListener(new C1720d());
        }
        AnimatorSet animatorSet2 = this.e;
        if (animatorSet2 != null) {
            animatorSet2.addListener(new e());
        }
        AnimatorSet animatorSet3 = this.f;
        if (animatorSet3 != null) {
            animatorSet3.addListener(new f());
        }
        AnimatorSet animatorSet4 = this.g;
        if (animatorSet4 != null) {
            animatorSet4.addListener(new g());
        }
        h();
        j();
    }

    public static final class C1720d extends SimpleAnimatorListener {
        C1720d() {
        }

        @Override
        public void onAnimationEnd(Animator animator) {
            super.onAnimationEnd(animator);
            AnimatorSet animatorSet = d.this.e;
            if (animatorSet != null) {
                animatorSet.start();
            }
        }
    }

    public static final class e extends SimpleAnimatorListener {
        e() {
        }

        @Override
        public void onAnimationEnd(Animator animator) {
            super.onAnimationEnd(animator);
            AnimatorSet animatorSet = d.this.d;
            if (animatorSet != null) {
                animatorSet.start();
            }
        }
    }

    public static final class f extends SimpleAnimatorListener {
        f() {
        }

        @Override
        public void onAnimationEnd(Animator animator) {
            super.onAnimationEnd(animator);
            AnimatorSet animatorSet = d.this.g;
            if (animatorSet != null) {
                animatorSet.start();
            }
        }
    }

    public static final class g extends SimpleAnimatorListener {
        g() {
        }

        @Override
        public void onAnimationEnd(Animator animator) {
            super.onAnimationEnd(animator);
            AnimatorSet animatorSet = d.this.f;
            if (animatorSet != null) {
                animatorSet.start();
            }
        }
    }

    public static final class b implements View.OnClickListener {
        b() {
        }

        @Override
        public final void onClick(View view) {
            ClickAgent.onClick(view);
            a.InterfaceC1129a interfaceC1129a = d.this.f46360c;
            if (interfaceC1129a != null) {
                interfaceC1129a.a();
            }
            App.sendLocalBroadcast(new Intent("red_packet_close"));
            d.this.a(com.bytedance.ies.android.loki.ability.method.a.c.f17356a);
            com.dragon.read.coldstart.bigredpacket.custom.d.a(-204, "close by user", 0, 4, null);
        }
    }

    public final void a(String str) {
        String d = com.dragon.read.coldstart.bigredpacket.a.a.a().d(ActivityRecordManager.inst().getCurrentVisibleActivity());
        Intrinsics.checkNotNullExpressionValue(d, "inst().getCurrentPositio…).currentVisibleActivity)");
        com.dragon.read.coldstart.bigredpacket.custom.d.a(d, NsUgDepend.IMPL.getStoreTopChannel(ActivityRecordManager.inst().getCurrentVisibleActivity()), "old", str);
    }

    public d(Context context) {
        super(context, android.R.style.Theme.Translucent.NoTitleBar);
        Intrinsics.checkNotNullParameter(context, "context");
        this.h = "";
        this.i = "";
        this.j = true;
        this.k = true;
        Window window = getWindow();
        if (window != null) {
            window.addFlags(512);
            window.addFlags(67108864);
            window.setWindowAnimations(R.style.u7);
            window.getDecorView().setSystemUiVisibility(androidx.core.view.accessibility.b.d);
        }
        setCanceledOnTouchOutside(false);
        super.setEnableDarkMask(true);
        setContentView(R.layout.r1);
        c();
        g();
    }

    public static final class c implements View.OnClickListener {
        c() {
        }

        @Override
        public final void onClick(View view) {
            ClickAgent.onClick(view);
            b.InterfaceC2859b interfaceC2859b = d.this.popTicket;
            if (interfaceC2859b != null) {
                interfaceC2859b.b();
            }
            d.this.b();
            View view2 = d.this.f46359b;
            View view3 = null;
            if (view2 == null) {
                Intrinsics.throwUninitializedPropertyAccessException("mClOpen");
                view2 = null;
            }
            view2.setClickable(false);
            d.this.a();
            View view4 = d.this.f46359b;
            if (view4 == null) {
                Intrinsics.throwUninitializedPropertyAccessException("mClOpen");
                view4 = null;
            }
            ObjectAnimator ofFloat = ObjectAnimator.ofFloat(view4, "rotationY", 0.0f, 90.0f);
            Intrinsics.checkNotNullExpressionValue(ofFloat, "ofFloat(mClOpen, \"rotationY\", 0.0f, 90f)");
            ofFloat.setInterpolator(new CubicBezierInterpolator(0.42d, 0.0d, 0.58d, 1.0d));
            ofFloat.setDuration(300L);
            View view5 = d.this.f46359b;
            if (view5 == null) {
                Intrinsics.throwUninitializedPropertyAccessException("mClOpen");
            } else {
                view3 = view5;
            }
            final ObjectAnimator ofFloat2 = ObjectAnimator.ofFloat(view3, "rotationY", 90.0f, 0.0f);
            Intrinsics.checkNotNullExpressionValue(ofFloat2, "ofFloat(mClOpen, \"rotationY\", 90f, 0.0f)");
            ofFloat2.setInterpolator(new CubicBezierInterpolator(0.42d, 0.0d, 0.58d, 1.0d));
            ofFloat2.setDuration(300L);
            final d dVar = d.this;
            ofFloat2.addListener(new SimpleAnimatorListener() {

                public static final class a extends SimpleAnimatorListener {

                    final d f46364a;

                    a(d dVar) {
                        this.f46364a = dVar;
                    }

                    @Override
                    public void onAnimationEnd(Animator animator) {
                        super.onAnimationEnd(animator);
                        a.InterfaceC1129a interfaceC1129a = this.f46364a.f46360c;
                        if (interfaceC1129a != null) {
                            interfaceC1129a.a(true);
                        }
                        com.dragon.read.coldstart.bigredpacket.a.b.a(com.dragon.read.coldstart.bigredpacket.a.b.f46285a, this.f46364a.getOwnerActivity(), this.f46364a.h, this.f46364a.i, this.f46364a.j, this.f46364a.k, this.f46364a.l, this.f46364a.m, this.f46364a.n instanceof ForceShowRedPacketModel, null, androidx.core.view.accessibility.b.f2360b, null);
                    }
                }

                @Override
                public void onAnimationEnd(Animator animator) {
                    super.onAnimationEnd(animator);
                    d dVar2 = d.this;
                    dVar2.a(new a(dVar2));
                }
            });
            ofFloat.addListener(new SimpleAnimatorListener() {
                @Override
                public void onAnimationEnd(Animator animator) {
                    super.onAnimationEnd(animator);
                    ofFloat2.start();
                }
            });
            ofFloat.start();
            d.this.a("collect");
        }
    }

    public final void a(Animator.AnimatorListener animatorListener) {
        View view = this.f46359b;
        if (view == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClOpen");
            view = null;
        }
        view.setVisibility(4);
        View view2 = this.o;
        if (view2 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClBgTop");
            view2 = null;
        }
        ObjectAnimator ofFloat = ObjectAnimator.ofFloat(view2, "alpha", 1.0f, 0.0f);
        View view3 = this.o;
        if (view3 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClBgTop");
            view3 = null;
        }
        ObjectAnimator ofFloat2 = ObjectAnimator.ofFloat(view3, "scaleX", 1.0f, 1.2f);
        View view4 = this.o;
        if (view4 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClBgTop");
            view4 = null;
        }
        ObjectAnimator ofFloat3 = ObjectAnimator.ofFloat(view4, "scaleY", 1.0f, 1.2f);
        View view5 = this.o;
        if (view5 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClBgTop");
            view5 = null;
        }
        ObjectAnimator ofFloat4 = ObjectAnimator.ofFloat(view5, "translationY", 0.0f, -com.bytedance.ug.sdk.luckycat.utils.i.a(getContext(), 310.0f));
        AnimatorSet animatorSet = new AnimatorSet();
        animatorSet.setInterpolator(new CubicBezierInterpolator(0.42d, 0.0d, 0.58d, 1.0d));
        animatorSet.setDuration(300L);
        animatorSet.playTogether(ofFloat, ofFloat2, ofFloat3, ofFloat4);
        View view6 = this.p;
        if (view6 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClBgBottom");
            view6 = null;
        }
        ObjectAnimator ofFloat5 = ObjectAnimator.ofFloat(view6, "alpha", 1.0f, 0.0f);
        View view7 = this.p;
        if (view7 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClBgBottom");
            view7 = null;
        }
        ObjectAnimator ofFloat6 = ObjectAnimator.ofFloat(view7, "scaleX", 1.0f, 1.2f);
        View view8 = this.p;
        if (view8 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClBgBottom");
            view8 = null;
        }
        ObjectAnimator ofFloat7 = ObjectAnimator.ofFloat(view8, "scaleY", 1.0f, 1.2f);
        View view9 = this.p;
        if (view9 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mClBgBottom");
            view9 = null;
        }
        ObjectAnimator ofFloat8 = ObjectAnimator.ofFloat(view9, "translationY", 0.0f, com.bytedance.ug.sdk.luckycat.utils.i.a(getContext(), 178.0f));
        AnimatorSet animatorSet2 = new AnimatorSet();
        animatorSet2.setInterpolator(new CubicBezierInterpolator(0.42d, 0.0d, 0.58d, 1.0d));
        animatorSet2.setDuration(300L);
        animatorSet2.playTogether(ofFloat5, ofFloat6, ofFloat7, ofFloat8);
        animatorSet2.addListener(animatorListener);
        animatorSet.start();
        animatorSet2.start();
    }

    @Override
    public void a(RedPacketModel redPacketModel, a.InterfaceC1129a interfaceC1129a) {
        boolean z;
        boolean z2;
        boolean z3;
        boolean z4;
        boolean z5;
        boolean z6;
        boolean z7;
        boolean z8;
        this.f46360c = interfaceC1129a;
        this.n = redPacketModel;
        com.dragon.read.polaris.model.h d = com.dragon.read.coldstart.bigredpacket.a.a.a().d();
        if (d != null) {
            z = d.d;
        } else {
            z = true;
        }
        this.j = z;
        if (d != null) {
            z2 = d.e;
        } else {
            z2 = true;
        }
        this.k = z2;
        if (d != null) {
            z3 = d.f;
        } else {
            z3 = false;
        }
        this.l = z3;
        if (d != null) {
            z4 = d.g;
        } else {
            z4 = false;
        }
        this.m = z4;
        if (d != null) {
            z5 = d.f74252c;
        } else {
            z5 = true;
        }
        TextView textView = null;
        if (redPacketModel != null) {
            try {
                String str = new JSONObject(redPacketModel.getRawData()).optString("extra", "");
                Intrinsics.checkNotNullExpressionValue(str, "str");
                if (str.length() > 0) {
                    z6 = true;
                } else {
                    z6 = false;
                }
                if (!z6) {
                    str = null;
                }
                if (str != null) {
                    if (z5) {
                        String formatPrice = RedPacketModel.getFormatPrice(new JSONObject(str).optInt("red_packet_amount"));
                        Intrinsics.checkNotNullExpressionValue(formatPrice, "getFormatPrice(rewardAmount)");
                        this.h = formatPrice;
                        this.i = "立即提现";
                    }
                    Unit unit = Unit.INSTANCE;
                }
            } catch (Throwable th) {
                th.printStackTrace();
                Unit unit2 = Unit.INSTANCE;
            }
        }
        if (this.i.length() == 0) {
            z7 = true;
        } else {
            z7 = false;
        }
        if (z7) {
            this.i = "最高";
            this.h = "29";
        }
        if (d != null && d.f74250a) {
            z8 = true;
        } else {
            z8 = false;
        }
        if (z8) {
            e();
        } else {
            f();
        }
        StringCompanionObject stringCompanionObject = StringCompanionObject.INSTANCE;
        Locale locale = Locale.getDefault();
        String string = App.context().getString(R.string.bi5);
        Intrinsics.checkNotNullExpressionValue(string, "context().getString(R.st…dpacket_bottom_tips_text)");
        String format = String.format(locale, string, Arrays.copyOf(new Object[]{f46358a.a()}, 1));
        Intrinsics.checkNotNullExpressionValue(format, "format(locale, format, *args)");
        TextView textView2 = this.r;
        if (textView2 == null) {
            Intrinsics.throwUninitializedPropertyAccessException("mTvBottomTips");
        } else {
            textView = textView2;
        }
        textView.setText(format);
        d();
    }

    private final AnimatorSet a(View view, float f2, float f3, long j) {
        ObjectAnimator ofFloat = ObjectAnimator.ofFloat(view, "scaleX", f2, f3);
        ObjectAnimator ofFloat2 = ObjectAnimator.ofFloat(view, "scaleY", f2, f3);
        AnimatorSet animatorSet = new AnimatorSet();
        animatorSet.setInterpolator(new CubicBezierInterpolator(0.42d, 0.0d, 0.58d, 1.0d));
        animatorSet.playTogether(ofFloat, ofFloat2);
        animatorSet.setDuration(j);
        return animatorSet;
    }
}