2021-09-09 06:47:34 +00:00
|
|
|
package com.discord.widgets.guilds.profile;
|
2021-08-03 07:33:18 +00:00
|
|
|
|
|
|
|
import android.os.Bundle;
|
|
|
|
import android.view.View;
|
|
|
|
import androidx.fragment.app.Fragment;
|
|
|
|
import androidx.fragment.app.FragmentManager;
|
2021-08-11 06:37:47 +00:00
|
|
|
import c.a.j.a;
|
2021-08-03 07:33:18 +00:00
|
|
|
import c.d.b.a.a;
|
2021-08-09 22:51:56 +00:00
|
|
|
import com.discord.R;
|
2021-08-03 07:33:18 +00:00
|
|
|
import com.discord.app.AppBottomSheet;
|
|
|
|
import com.discord.app.AppLog;
|
2021-09-09 06:47:34 +00:00
|
|
|
import com.discord.databinding.WidgetGuildIdentityMarketingSheetBinding;
|
2021-08-03 07:33:18 +00:00
|
|
|
import com.discord.tooltips.TooltipManager;
|
|
|
|
import com.discord.utilities.analytics.AnalyticsTracker;
|
|
|
|
import com.discord.utilities.viewbinding.FragmentViewBindingDelegate;
|
|
|
|
import com.discord.utilities.viewbinding.FragmentViewBindingDelegateKt;
|
|
|
|
import d0.z.d.m;
|
|
|
|
import java.lang.ref.WeakReference;
|
|
|
|
import java.util.Set;
|
|
|
|
import kotlin.jvm.internal.DefaultConstructorMarker;
|
|
|
|
import kotlin.reflect.KProperty;
|
2021-09-09 06:47:34 +00:00
|
|
|
/* compiled from: WidgetGuildIdentityMarketingSheet.kt */
|
|
|
|
public final class WidgetGuildIdentityMarketingSheet extends AppBottomSheet {
|
|
|
|
public static final /* synthetic */ KProperty[] $$delegatedProperties = {a.a0(WidgetGuildIdentityMarketingSheet.class, "binding", "getBinding()Lcom/discord/databinding/WidgetGuildIdentityMarketingSheetBinding;", 0)};
|
2021-08-03 07:33:18 +00:00
|
|
|
public static final Companion Companion = new Companion(null);
|
2021-09-09 06:47:34 +00:00
|
|
|
private final FragmentViewBindingDelegate binding$delegate = FragmentViewBindingDelegateKt.viewBinding$default(this, WidgetGuildIdentityMarketingSheet$binding$2.INSTANCE, null, 2, null);
|
|
|
|
private final long guildId;
|
2021-08-03 07:33:18 +00:00
|
|
|
private final TooltipManager tooltipManager;
|
|
|
|
|
2021-09-09 06:47:34 +00:00
|
|
|
/* compiled from: WidgetGuildIdentityMarketingSheet.kt */
|
2021-08-03 07:33:18 +00:00
|
|
|
public static final class Companion {
|
|
|
|
private Companion() {
|
|
|
|
}
|
|
|
|
|
|
|
|
public /* synthetic */ Companion(DefaultConstructorMarker defaultConstructorMarker) {
|
|
|
|
this();
|
|
|
|
}
|
|
|
|
|
2021-09-09 06:47:34 +00:00
|
|
|
public final void show(FragmentManager fragmentManager, long j) {
|
2021-08-03 07:33:18 +00:00
|
|
|
m.checkNotNullParameter(fragmentManager, "fragmentManager");
|
2021-09-09 06:47:34 +00:00
|
|
|
new WidgetGuildIdentityMarketingSheet(j).show(fragmentManager, "javaClass");
|
|
|
|
AnalyticsTracker.INSTANCE.trackGuildIdentityMarketingSheet();
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/* JADX INFO: super call moved to the top of the method (can break code semantics) */
|
2021-09-09 06:47:34 +00:00
|
|
|
public WidgetGuildIdentityMarketingSheet(long j) {
|
2021-08-03 07:33:18 +00:00
|
|
|
super(false, 1, null);
|
|
|
|
TooltipManager tooltipManager = null;
|
2021-09-09 06:47:34 +00:00
|
|
|
this.guildId = j;
|
2021-08-03 07:33:18 +00:00
|
|
|
AppLog appLog = AppLog.g;
|
|
|
|
m.checkNotNullParameter(appLog, "logger");
|
2021-08-11 06:37:47 +00:00
|
|
|
WeakReference<c.a.j.a> weakReference = a.b.a;
|
|
|
|
c.a.j.a aVar = weakReference != null ? weakReference.get() : null;
|
2021-08-03 07:33:18 +00:00
|
|
|
if (aVar == null) {
|
2021-08-11 06:37:47 +00:00
|
|
|
aVar = new c.a.j.a(appLog);
|
2021-08-03 07:33:18 +00:00
|
|
|
a.b.a = new WeakReference<>(aVar);
|
|
|
|
}
|
|
|
|
TooltipManager.a aVar2 = TooltipManager.a.d;
|
|
|
|
m.checkNotNullParameter(aVar, "floatingViewManager");
|
|
|
|
WeakReference<TooltipManager> weakReference2 = TooltipManager.a.a;
|
|
|
|
tooltipManager = weakReference2 != null ? weakReference2.get() : tooltipManager;
|
|
|
|
if (tooltipManager == null) {
|
2021-09-16 17:51:42 +00:00
|
|
|
tooltipManager = new TooltipManager((c.a.v.a) TooltipManager.a.b.getValue(), (Set) TooltipManager.a.f2187c.getValue(), 0, aVar, 4);
|
2021-08-03 07:33:18 +00:00
|
|
|
TooltipManager.a.a = new WeakReference<>(tooltipManager);
|
|
|
|
}
|
|
|
|
this.tooltipManager = tooltipManager;
|
|
|
|
}
|
|
|
|
|
2021-09-09 06:47:34 +00:00
|
|
|
private final WidgetGuildIdentityMarketingSheetBinding getBinding() {
|
|
|
|
return (WidgetGuildIdentityMarketingSheetBinding) this.binding$delegate.getValue((Fragment) this, $$delegatedProperties[0]);
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
@Override // com.discord.app.AppBottomSheet
|
|
|
|
public int getContentViewResId() {
|
2021-09-09 06:47:34 +00:00
|
|
|
return R.layout.widget_guild_identity_marketing_sheet;
|
|
|
|
}
|
|
|
|
|
|
|
|
public final long getGuildId() {
|
|
|
|
return this.guildId;
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
@Override // com.discord.app.AppBottomSheet, androidx.fragment.app.Fragment
|
|
|
|
public void onViewCreated(View view, Bundle bundle) {
|
|
|
|
m.checkNotNullParameter(view, "view");
|
|
|
|
super.onViewCreated(view, bundle);
|
|
|
|
setBottomSheetCollapsedStateDisabled();
|
2021-09-09 06:47:34 +00:00
|
|
|
this.tooltipManager.a(GuildProfileMarketingTooltip.INSTANCE);
|
|
|
|
getBinding().b.setOnClickListener(new WidgetGuildIdentityMarketingSheet$onViewCreated$1(this));
|
2021-09-16 17:51:42 +00:00
|
|
|
getBinding().f1849c.setOnClickListener(new WidgetGuildIdentityMarketingSheet$onViewCreated$2(this));
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
}
|