正在查看: BetterTogether v3.0.0 应用的 TrialEndReminderActivity.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
正在查看: BetterTogether v3.0.0 应用的 TrialEndReminderActivity.java JAVA 源代码文件
本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。
package com.bettertogether.screens.trialEnd;
import android.os.Bundle;
import android.view.View;
import androidx.activity.d0;
import androidx.constraintlayout.widget.ConstraintLayout;
import cd.a0;
import cf.f;
import com.bettertogether.base.BaseActivity;
import com.bettertogether.cache.preferences.PreferenceData;
import com.bettertogether.remote.model.common.GroupData;
import com.bettertogether.screens.trialEnd.TrialEndReminderActivity;
import com.bettertogether.subscription.SubscriptionPlansInAppActivity;
import com.google.android.material.textview.MaterialTextView;
import com.google.firebase.messaging.e;
import kotlin.Metadata;
import kotlin.jvm.internal.Intrinsics;
import kotlin.jvm.internal.g0;
import lq.m;
import lq.n;
import lq.o;
import lq.x;
import md.l;
import of.c;
import of.d;
import s8.h;
import xh.k;
import ys.a;
@Metadata
public final class TrialEndReminderActivity extends BaseActivity implements d {
public static final int f5044x = 0;
public GroupData f5045e;
public final x f5046i = n.b(new c(this, 0));
public final x f5047v = n.b(new c(this, 1));
public final m f5048w;
public TrialEndReminderActivity() {
h s10 = e.s(this);
this.f5048w = n.a(o.f13215d, new l(((a) s10.a).a(e.o(), new xs.c(g0.a(TrialEndReminderActivity.class))), new c(this, 2), 28));
}
@Override
public final View getView() {
ConstraintLayout constraintLayout = ((a0) this.f5046i.getValue()).f4111a;
Intrinsics.checkNotNullExpressionValue(constraintLayout, "binding.root");
return constraintLayout;
}
@Override
public final void initViews() {
Integer daysSinceStarted;
Integer daysSinceStarted2;
Bundle extras = getIntent().getExtras();
if (extras != null && extras.containsKey("group")) {
this.f5045e = (GroupData) extras.getSerializable("group");
}
final int i10 = 0;
((PreferenceData) this.f5047v.getValue()).r("paywall displayed", false);
x xVar = this.f5046i;
a0 a0Var = (a0) xVar.getValue();
MaterialTextView materialTextView = a0Var.f4114d;
final int i11 = 1;
Object[] objArr = new Object[1];
GroupData groupData = this.f5045e;
objArr[0] = String.valueOf((groupData == null || (daysSinceStarted2 = groupData.getDaysSinceStarted()) == null) ? 1 : daysSinceStarted2.intValue());
materialTextView.setText(h3.c.a(getString(2131952570, objArr), 0));
Object[] objArr2 = new Object[1];
GroupData groupData2 = this.f5045e;
objArr2[0] = String.valueOf(14 - ((groupData2 == null || (daysSinceStarted = groupData2.getDaysSinceStarted()) == null) ? 1 : daysSinceStarted.intValue()));
a0Var.f4115e.setText(getString(2131952573, objArr2));
((a0) xVar.getValue()).f4112b.setOnClickListener(new View.OnClickListener(this) {
public final TrialEndReminderActivity f15356e;
{
this.f15356e = this;
}
@Override
public final void onClick(View view) {
int i12 = i10;
TrialEndReminderActivity trialEndReminderActivity = this.f15356e;
switch (i12) {
case 0:
int i13 = TrialEndReminderActivity.f5044x;
Intrinsics.checkNotNullParameter(trialEndReminderActivity, "this$0");
trialEndReminderActivity.s();
break;
default:
int i14 = TrialEndReminderActivity.f5044x;
Intrinsics.checkNotNullParameter(trialEndReminderActivity, "this$0");
trialEndReminderActivity.s();
break;
}
}
});
((a0) xVar.getValue()).f4113c.setOnClickListener(new View.OnClickListener(this) {
public final TrialEndReminderActivity f15356e;
{
this.f15356e = this;
}
@Override
public final void onClick(View view) {
int i12 = i11;
TrialEndReminderActivity trialEndReminderActivity = this.f15356e;
switch (i12) {
case 0:
int i13 = TrialEndReminderActivity.f5044x;
Intrinsics.checkNotNullParameter(trialEndReminderActivity, "this$0");
trialEndReminderActivity.s();
break;
default:
int i14 = TrialEndReminderActivity.f5044x;
Intrinsics.checkNotNullParameter(trialEndReminderActivity, "this$0");
trialEndReminderActivity.s();
break;
}
}
});
getOnBackPressedDispatcher().a(this, new d0(this, 5));
}
@Override
public final ad.a providePresenter() {
return (of.a) this.f5048w.getValue();
}
public final void s() {
Integer daysSinceStarted;
Integer daysSinceStarted2;
x xVar = this.f5047v;
if (((PreferenceData) xVar.getValue()).c() || zf.d.f23196b) {
return;
}
int i10 = 0;
if (k.q()) {
GroupData groupData = this.f5045e;
if (groupData != null && (daysSinceStarted2 = groupData.getDaysSinceStarted()) != null) {
i10 = daysSinceStarted2.intValue();
}
GroupData groupData2 = this.f5045e;
startActivity(cf.d.q(this, i10, groupData2 != null ? groupData2.getId() : null, this.f5045e));
} else {
int i11 = SubscriptionPlansInAppActivity.W;
GroupData groupData3 = this.f5045e;
int intValue = (groupData3 == null || (daysSinceStarted = groupData3.getDaysSinceStarted()) == null) ? 0 : daysSinceStarted.intValue();
GroupData groupData4 = this.f5045e;
startActivity(f.q(this, intValue, groupData4 != null ? groupData4.getId() : null, false, 16));
}
((PreferenceData) xVar.getValue()).r("paywall displayed", true);
finish();
}
}