2021-06-27 20:44:35 +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;
|
|
|
|
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;
|
|
|
|
import d0.z.d.m;
|
|
|
|
import j0.k.b;
|
|
|
|
import j0.l.a.c;
|
|
|
|
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>>> {
|
|
|
|
public final /* synthetic */ List $data;
|
|
|
|
public final /* synthetic */ ViewEmbedGameInvite.Model $gameInviteModel;
|
|
|
|
public final /* synthetic */ WidgetIncomingShare this$0;
|
|
|
|
|
|
|
|
public WidgetIncomingShare$onSendClicked$2(WidgetIncomingShare widgetIncomingShare, List list, ViewEmbedGameInvite.Model model) {
|
|
|
|
this.this$0 = widgetIncomingShare;
|
|
|
|
this.$data = list;
|
|
|
|
this.$gameInviteModel = model;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* 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] */
|
|
|
|
@Override // j0.k.b
|
|
|
|
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) {
|
|
|
|
return c.j;
|
|
|
|
}
|
|
|
|
StoreMessages messages = StoreStream.Companion.getMessages();
|
2021-07-03 23:36:06 +00:00
|
|
|
long h = component2.h();
|
2021-06-27 20:44:35 +00:00
|
|
|
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;
|
2021-07-03 23:36:06 +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, 14464, null).F(new WidgetIncomingShare$onSendClicked$2$$special$$inlined$let$lambda$1(this, component1));
|
2021-06-27 20:44:35 +00:00
|
|
|
}
|
|
|
|
}
|