2021-08-03 07:33:18 +00:00
|
|
|
package com.discord.widgets.share;
|
|
|
|
|
|
|
|
import com.discord.api.activity.Activity;
|
|
|
|
import com.discord.api.application.Application;
|
|
|
|
import com.discord.api.channel.Channel;
|
|
|
|
import com.discord.models.user.MeUser;
|
|
|
|
import com.discord.stores.StoreMessages;
|
|
|
|
import com.discord.stores.StoreStream;
|
2022-02-10 02:59:54 +00:00
|
|
|
import com.discord.utilities.captcha.CaptchaHelper;
|
2021-08-03 07:33:18 +00:00
|
|
|
import com.discord.utilities.messagesend.MessageResult;
|
|
|
|
import com.discord.utilities.view.extensions.ViewExtensions;
|
|
|
|
import com.discord.widgets.chat.list.ViewEmbedGameInvite;
|
|
|
|
import com.google.android.material.textfield.TextInputLayout;
|
2021-11-02 06:38:17 +00:00
|
|
|
import d0.z.d.m;
|
|
|
|
import j0.k.b;
|
|
|
|
import j0.l.a.c;
|
2021-08-03 07:33:18 +00:00
|
|
|
import java.util.List;
|
|
|
|
import kotlin.Pair;
|
|
|
|
import rx.Observable;
|
|
|
|
/* compiled from: WidgetIncomingShare.kt */
|
|
|
|
public final class WidgetIncomingShare$onSendClicked$2<T, R> implements b<Pair<? extends MeUser, ? extends Channel>, Observable<? extends Pair<? extends MeUser, ? extends MessageResult>>> {
|
2022-02-10 02:59:54 +00:00
|
|
|
public final /* synthetic */ CaptchaHelper.CaptchaPayload $captchaPayload;
|
2021-08-03 07:33:18 +00:00
|
|
|
public final /* synthetic */ List $data;
|
|
|
|
public final /* synthetic */ ViewEmbedGameInvite.Model $gameInviteModel;
|
|
|
|
public final /* synthetic */ WidgetIncomingShare this$0;
|
|
|
|
|
2022-02-10 02:59:54 +00:00
|
|
|
public WidgetIncomingShare$onSendClicked$2(WidgetIncomingShare widgetIncomingShare, List list, ViewEmbedGameInvite.Model model, CaptchaHelper.CaptchaPayload captchaPayload) {
|
2021-08-03 07:33:18 +00:00
|
|
|
this.this$0 = widgetIncomingShare;
|
|
|
|
this.$data = list;
|
|
|
|
this.$gameInviteModel = model;
|
2022-02-10 02:59:54 +00:00
|
|
|
this.$captchaPayload = captchaPayload;
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/* Return type fixed from 'java.lang.Object' to match base method */
|
|
|
|
/* JADX DEBUG: Method arguments types fixed to match base method, original types: [java.lang.Object] */
|
2021-11-02 06:38:17 +00:00
|
|
|
@Override // j0.k.b
|
2021-08-03 07:33:18 +00:00
|
|
|
public /* bridge */ /* synthetic */ Observable<? extends Pair<? extends MeUser, ? extends MessageResult>> call(Pair<? extends MeUser, ? extends Channel> pair) {
|
|
|
|
return call((Pair<MeUser, Channel>) pair);
|
|
|
|
}
|
|
|
|
|
|
|
|
public final Observable<? extends Pair<MeUser, MessageResult>> call(Pair<MeUser, Channel> pair) {
|
|
|
|
MeUser component1 = pair.component1();
|
|
|
|
Channel component2 = pair.component2();
|
|
|
|
if (component2 == null) {
|
2021-12-02 18:53:44 +00:00
|
|
|
return c.k;
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
StoreMessages messages = StoreStream.Companion.getMessages();
|
|
|
|
long h = component2.h();
|
|
|
|
m.checkNotNullExpressionValue(component1, "meUser");
|
|
|
|
TextInputLayout textInputLayout = WidgetIncomingShare.access$getBinding$p(this.this$0).d;
|
|
|
|
m.checkNotNullExpressionValue(textInputLayout, "binding.externalShareComment");
|
|
|
|
String textOrEmpty = ViewExtensions.getTextOrEmpty(textInputLayout);
|
|
|
|
List list = this.$data;
|
|
|
|
ViewEmbedGameInvite.Model model = this.$gameInviteModel;
|
|
|
|
Application application = model != null ? model.getApplication() : null;
|
|
|
|
ViewEmbedGameInvite.Model model2 = this.$gameInviteModel;
|
|
|
|
Activity activity = model2 != null ? model2.getActivity() : null;
|
|
|
|
ViewEmbedGameInvite.Model model3 = this.$gameInviteModel;
|
2022-02-10 02:59:54 +00:00
|
|
|
return StoreMessages.sendMessage$default(messages, h, component1, textOrEmpty, null, list, null, null, null, application, activity, model3 != null ? model3.getMessageActivity() : null, null, null, null, this.$captchaPayload, 14464, null).F(new WidgetIncomingShare$onSendClicked$2$$special$$inlined$let$lambda$1(this, component1));
|
2021-08-03 07:33:18 +00:00
|
|
|
}
|
|
|
|
}
|