翰林优商.apk(点击下载) / SpeechVoicePopupWindowLandingActivity.java


package com.xlx.speech.voicereadsdk.ui.activity;

import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;
import androidx.recyclerview.widget.GridLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import com.mbridge.msdk.foundation.entity.CampaignEx;
import com.xlx.speech.b.a;
import com.xlx.speech.i.b;
import com.xlx.speech.m0.e;
import com.xlx.speech.m0.i0;
import com.xlx.speech.m0.j;
import com.xlx.speech.m0.m;
import com.xlx.speech.m0.s;
import com.xlx.speech.m0.u;
import com.xlx.speech.o.q0;
import com.xlx.speech.s.h;
import com.xlx.speech.s.i;
import com.xlx.speech.voicereadsdk.R;
import com.xlx.speech.voicereadsdk.bean.resp.OverPageResult;
import com.xlx.speech.voicereadsdk.bean.resp.SingleAdDetailResult;
import com.xlx.speech.voicereadsdk.constant.VoiceConstant;
import com.xlx.speech.voicereadsdk.ui.widget.CountDownCloseImg;
import com.xlx.speech.voicereadsdk.ui.widget.XzVoiceRoundImageView;
import java.util.HashMap;
import java.util.List;

public class SpeechVoicePopupWindowLandingActivity extends com.xlx.speech.t.a {
    public static final /* synthetic */ int t = 0;
    public RecyclerView c;
    public RecyclerView d;
    public XzVoiceRoundImageView e;
    public TextView f;
    public XzVoiceRoundImageView g;
    public TextView h;
    public TextView i;
    public CountDownCloseImg j;
    public h k;
    public i l;
    public OverPageResult m;
    public SingleAdDetailResult n;
    public String o;
    public e p;
    public String q;
    public ImageView r;
    public a.c s;

    public class a extends s {
        public final /* synthetic */ u b;

        public a(u uVar) {
            this.b = uVar;
        }

        @Override // com.xlx.speech.m0.s
        public void a(View view) {
            SpeechVoicePopupWindowLandingActivity speechVoicePopupWindowLandingActivity = SpeechVoicePopupWindowLandingActivity.this;
            m.a(speechVoicePopupWindowLandingActivity, speechVoicePopupWindowLandingActivity.j.h, this.b, speechVoicePopupWindowLandingActivity.n);
        }
    }

    /* access modifiers changed from: private */
    public /* synthetic */ void c() {
        i0.a(this.m.getLogId(), this.n.icpmOne);
    }

    public void b() {
        a.c a2;
        OverPageResult overPageResult = this.m;
        if (overPageResult != null) {
            this.q = overPageResult.getButtonMsg();
            this.i.setText(this.m.getAdContent());
            if (this.n.sloganType == 2) {
                this.i.setVisibility(4);
            } else {
                this.i.setVisibility(0);
            }
            this.h.setText(this.q);
            this.k = new h();
            this.c.setLayoutManager(new GridLayoutManager(this, 3));
            this.c.setAdapter(this.k);
            i iVar = new i();
            this.l = iVar;
            this.d.setAdapter(iVar);
            this.f.setText(this.m.getAdvertName());
            j.a().loadImage(this, this.m.getIconUrl(), this.e);
            String str = this.o;
            if (str != null) {
                j.a(this, str, this.g);
            } else {
                j.a().loadBlurImage(this, R.drawable.xlx_voice_question_bg, 25.0f, this.g);
            }
            if (this.m.getKeyword() != null) {
                this.k.a(this.m.getKeyword());
            }
            List<D> list = (List<D>) this.m.getRewardList();
            if (list != null && list.size() > 0) {
                this.d.setLayoutManager(new GridLayoutManager(this, list.size()));
                i iVar2 = this.l;
                iVar2.b = list;
                iVar2.notifyDataSetChanged();
            }
            if (this.m.getButtonType() == 1) {
                a2 = com.xlx.speech.b.a.b(this.h);
            } else {
                if (this.m.getButtonType() == 2) {
                    this.r.setVisibility(0);
                    a2 = com.xlx.speech.b.a.a(this.r);
                }
                u a3 = u.a(this, this.m.getAdId(), this.m.getLogId(), this.m.getPackageName());
                e eVar = new e(this, this.h, a3, this.q, this.m, this.n, this.s);
                this.p = eVar;
                a3.a(eVar);
                this.j.setVisibility(0);
                this.j.a(this.m.getDelaySeconds(), true, false, VoiceConstant.COUNT_DOWN_DISPLAY);
                this.j.setOnCountDownListener(new SpeechVoicePopupWindowLandingActivity$$ExternalSyntheticLambda0(this));
                this.j.setOnClickListener(new a(a3));
                HashMap hashMap = new HashMap();
                hashMap.put("reward", this.m.getReward());
                hashMap.put("ad_name", this.m.getAdvertName());
                hashMap.put("type", Integer.valueOf(this.m.getPageMode()));
                hashMap.put(CampaignEx.JSON_KEY_LANDING_TYPE, 1);
                b.a("landing_page_view", hashMap);
            }
            this.s = a2;
            u a32 = u.a(this, this.m.getAdId(), this.m.getLogId(), this.m.getPackageName());
            e eVar2 = new e(this, this.h, a32, this.q, this.m, this.n, this.s);
            this.p = eVar2;
            a32.a(eVar2);
            this.j.setVisibility(0);
            this.j.a(this.m.getDelaySeconds(), true, false, VoiceConstant.COUNT_DOWN_DISPLAY);
            this.j.setOnCountDownListener(new SpeechVoicePopupWindowLandingActivity$$ExternalSyntheticLambda0(this));
            this.j.setOnClickListener(new a(a32));
            HashMap hashMap2 = new HashMap();
            hashMap2.put("reward", this.m.getReward());
            hashMap2.put("ad_name", this.m.getAdvertName());
            hashMap2.put("type", Integer.valueOf(this.m.getPageMode()));
            hashMap2.put(CampaignEx.JSON_KEY_LANDING_TYPE, 1);
            b.a("landing_page_view", hashMap2);
        }
    }

    public void onBackPressed() {
    }

    @Override // com.xlx.speech.t.a
    public void onCreate(Bundle bundle) {
        super.onCreate(bundle);
        setContentView(R.layout.xlx_voice_activity_popup_window_landing);
        this.m = (OverPageResult) getIntent().getParcelableExtra("data");
        this.n = (SingleAdDetailResult) getIntent().getParcelableExtra("single_detail");
        this.o = getIntent().getStringExtra("poster_bg");
        this.c = (RecyclerView) findViewById(R.id.xlx_voice_rv_keyword);
        this.d = (RecyclerView) findViewById(R.id.xlx_voice_rv_progress);
        this.g = (XzVoiceRoundImageView) findViewById(R.id.xlx_voice_detail_ad_poster);
        this.e = (XzVoiceRoundImageView) findViewById(R.id.xlx_voice_detail_ad_icon);
        this.f = (TextView) findViewById(R.id.xlx_voice_tv_ad_name);
        this.h = (TextView) findViewById(R.id.xlx_voice_tv_download);
        this.i = (TextView) findViewById(R.id.xlx_voice_tv_download_description);
        this.j = (CountDownCloseImg) findViewById(R.id.xlx_voice_icon_back);
        this.r = (ImageView) findViewById(R.id.xlx_voice_iv_gesture);
        if (this.m == null) {
            new com.xlx.speech.e.b().a(this.n.logId, new q0(this));
            return;
        }
        b();
    }

    @Override // com.xlx.speech.t.a
    public void onDestroy() {
        super.onDestroy();
        e eVar = this.p;
        eVar.c.b(eVar);
    }

    @Override // com.xlx.speech.t.a
    public void onPause() {
        super.onPause();
        a.c cVar = this.s;
        if (cVar != null) {
            cVar.b();
        }
    }

    @Override // com.xlx.speech.t.a
    public void onResume() {
        super.onResume();
        a.c cVar = this.s;
        if (cVar != null) {
            cVar.c();
        }
    }
}