2021-06-27 20:44:35 +00:00
|
|
|
package defpackage;
|
|
|
|
|
|
|
|
import android.content.Context;
|
|
|
|
import android.view.View;
|
|
|
|
import c.a.d.o;
|
|
|
|
import c.a.z.r;
|
|
|
|
import c.a.z.s;
|
|
|
|
import com.discord.app.AppActivity;
|
|
|
|
import com.discord.stores.StoreInviteSettings;
|
|
|
|
import com.discord.stores.StoreStream;
|
|
|
|
import com.discord.utilities.intent.IntentUtils;
|
|
|
|
import com.discord.utilities.rx.ObservableExtensionsKt;
|
|
|
|
import com.discord.views.OverlayMenuView;
|
|
|
|
import java.util.Objects;
|
|
|
|
import kotlin.jvm.functions.Function0;
|
|
|
|
import kotlin.jvm.functions.Function1;
|
|
|
|
/* compiled from: java-style lambda group */
|
|
|
|
/* renamed from: e reason: default package */
|
|
|
|
public final class e implements View.OnClickListener {
|
|
|
|
public final /* synthetic */ int i;
|
|
|
|
public final /* synthetic */ Object j;
|
|
|
|
public final /* synthetic */ Object k;
|
|
|
|
|
|
|
|
public e(int i, Object obj, Object obj2) {
|
|
|
|
this.i = i;
|
|
|
|
this.j = obj;
|
|
|
|
this.k = obj2;
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override // android.view.View.OnClickListener
|
|
|
|
public final void onClick(View view) {
|
|
|
|
int i = this.i;
|
|
|
|
if (i == 0) {
|
|
|
|
OverlayMenuView overlayMenuView = (OverlayMenuView) this.j;
|
2021-07-03 23:36:06 +00:00
|
|
|
Long valueOf = Long.valueOf(((OverlayMenuView.a) this.k).f2120c.getChannel().h());
|
2021-06-27 20:44:35 +00:00
|
|
|
int i2 = OverlayMenuView.i;
|
|
|
|
Objects.requireNonNull(overlayMenuView);
|
|
|
|
if (valueOf != null) {
|
|
|
|
ObservableExtensionsKt.appSubscribe$default(ObservableExtensionsKt.ui$default(StoreInviteSettings.generateInvite$default(StoreStream.Companion.getInviteSettings(), valueOf.longValue(), null, 2, null), overlayMenuView, null, 2, null), OverlayMenuView.class, (Context) null, (Function1) null, new r(overlayMenuView), (Function0) null, (Function0) null, new s(overlayMenuView), 54, (Object) null);
|
|
|
|
} else {
|
2021-07-03 23:36:06 +00:00
|
|
|
o.g(overlayMenuView.getContext(), 2131890430, 0, null, 12);
|
2021-06-27 20:44:35 +00:00
|
|
|
}
|
|
|
|
} else if (i == 1) {
|
|
|
|
OverlayMenuView overlayMenuView2 = (OverlayMenuView) this.j;
|
2021-07-03 23:36:06 +00:00
|
|
|
Long valueOf2 = Long.valueOf(((OverlayMenuView.a) this.k).f2120c.getChannel().h());
|
2021-06-27 20:44:35 +00:00
|
|
|
int i3 = OverlayMenuView.i;
|
|
|
|
Objects.requireNonNull(overlayMenuView2);
|
|
|
|
overlayMenuView2.getContext().startActivity(IntentUtils.RouteBuilders.INSTANCE.connectVoice(valueOf2 != null ? valueOf2.longValue() : 0).setClass(overlayMenuView2.getContext(), AppActivity.Main.class).addFlags(268435456));
|
|
|
|
overlayMenuView2.l.mo1invoke();
|
|
|
|
} else {
|
|
|
|
throw null;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|