forked from Juby210/discord-jadx
174 lines
10 KiB
Java
174 lines
10 KiB
Java
package com.discord.widgets.channels.list;
|
|
|
|
import c.d.b.a.a;
|
|
import com.discord.api.channel.Channel;
|
|
import com.discord.api.guild.GuildMaxVideoChannelUsers;
|
|
import com.discord.api.guildscheduledevent.GuildScheduledEvent;
|
|
import com.discord.api.guildscheduledevent.GuildScheduledEventStatus;
|
|
import com.discord.models.guild.Guild;
|
|
import com.discord.utilities.channel.GuildChannelsInfo;
|
|
import com.discord.widgets.channels.list.WidgetChannelListModel;
|
|
import com.discord.widgets.channels.list.items.ChannelListItemVoiceChannel;
|
|
import com.discord.widgets.channels.list.items.ChannelListItemVoiceUser;
|
|
import d0.z.d.o;
|
|
import java.util.ArrayList;
|
|
import java.util.Collection;
|
|
import java.util.HashSet;
|
|
import java.util.Iterator;
|
|
import java.util.List;
|
|
import java.util.Map;
|
|
import java.util.Set;
|
|
import kotlin.jvm.functions.Function0;
|
|
/* compiled from: WidgetChannelListModel.kt */
|
|
public final class WidgetChannelListModel$Companion$guildListBuilder$$inlined$forEach$lambda$5 extends o implements Function0<ChannelListItemVoiceChannel> {
|
|
public final /* synthetic */ WidgetChannelListModel$Companion$guildListBuilder$4 $areAllChildThreadsRead$4$inlined;
|
|
public final /* synthetic */ WidgetChannelListModel$Companion$guildListBuilder$5 $areAnyChildThreadsSelected$5$inlined;
|
|
public final /* synthetic */ boolean $canSeeGuildRoleSubscriptions$inlined;
|
|
public final /* synthetic */ Channel $channel;
|
|
public final /* synthetic */ Set $channelsWithActiveThreads$inlined;
|
|
public final /* synthetic */ Set $collapsedCategories$inlined;
|
|
public final /* synthetic */ Map $directories$inlined;
|
|
public final /* synthetic */ Map $directoryEvents$inlined;
|
|
public final /* synthetic */ HashSet $forceViewCategories$inlined;
|
|
public final /* synthetic */ WidgetChannelListModel$Companion$guildListBuilder$$inlined$forEach$lambda$2 $getVocalChannelData$2;
|
|
public final /* synthetic */ GuildChannelsInfo $guild$inlined;
|
|
public final /* synthetic */ List $guildScheduledEvents$inlined;
|
|
public final /* synthetic */ HashSet $hiddenChannelsIds$inlined;
|
|
public final /* synthetic */ boolean $isGuildHub$inlined;
|
|
public final /* synthetic */ WidgetChannelListModel$Companion$guildListBuilder$3 $isThreadUnread$3$inlined;
|
|
public final /* synthetic */ ArrayList $items$inlined;
|
|
public final /* synthetic */ Map $joinedThreads$inlined;
|
|
public final /* synthetic */ Map $mentionCounts$inlined;
|
|
public final /* synthetic */ Map $messageAcks$inlined;
|
|
public final /* synthetic */ Long $permissions;
|
|
public final /* synthetic */ Channel $selectedChannel$inlined;
|
|
public final /* synthetic */ long $selectedGuildId$inlined;
|
|
public final /* synthetic */ long $selectedVoiceChannelId$inlined;
|
|
public final /* synthetic */ Map $stageChannels$inlined;
|
|
public final /* synthetic */ Map $stageInstances$inlined;
|
|
public final /* synthetic */ Map $threadParentMap$inlined;
|
|
public final /* synthetic */ WidgetChannelListModel$Companion$guildListBuilder$2 $tryRemoveEmptyCategory$2$inlined;
|
|
public final /* synthetic */ Set $unreadChannelIds$inlined;
|
|
public final /* synthetic */ Map $voiceStates$inlined;
|
|
|
|
/* JADX INFO: super call moved to the top of the method (can break code semantics) */
|
|
public WidgetChannelListModel$Companion$guildListBuilder$$inlined$forEach$lambda$5(WidgetChannelListModel$Companion$guildListBuilder$$inlined$forEach$lambda$2 widgetChannelListModel$Companion$guildListBuilder$$inlined$forEach$lambda$2, Channel channel, Long l, GuildChannelsInfo guildChannelsInfo, HashSet hashSet, boolean z2, Channel channel2, Map map, Set set, long j, WidgetChannelListModel$Companion$guildListBuilder$5 widgetChannelListModel$Companion$guildListBuilder$5, Set set2, WidgetChannelListModel$Companion$guildListBuilder$3 widgetChannelListModel$Companion$guildListBuilder$3, HashSet hashSet2, WidgetChannelListModel$Companion$guildListBuilder$4 widgetChannelListModel$Companion$guildListBuilder$4, long j2, Map map2, boolean z3, Set set3, List list, Map map3, Map map4, Map map5, Map map6, ArrayList arrayList, WidgetChannelListModel$Companion$guildListBuilder$2 widgetChannelListModel$Companion$guildListBuilder$2, Map map7, Map map8, Map map9) {
|
|
super(0);
|
|
this.$getVocalChannelData$2 = widgetChannelListModel$Companion$guildListBuilder$$inlined$forEach$lambda$2;
|
|
this.$channel = channel;
|
|
this.$permissions = l;
|
|
this.$guild$inlined = guildChannelsInfo;
|
|
this.$forceViewCategories$inlined = hashSet;
|
|
this.$isGuildHub$inlined = z2;
|
|
this.$selectedChannel$inlined = channel2;
|
|
this.$mentionCounts$inlined = map;
|
|
this.$unreadChannelIds$inlined = set;
|
|
this.$selectedGuildId$inlined = j;
|
|
this.$areAnyChildThreadsSelected$5$inlined = widgetChannelListModel$Companion$guildListBuilder$5;
|
|
this.$collapsedCategories$inlined = set2;
|
|
this.$isThreadUnread$3$inlined = widgetChannelListModel$Companion$guildListBuilder$3;
|
|
this.$hiddenChannelsIds$inlined = hashSet2;
|
|
this.$areAllChildThreadsRead$4$inlined = widgetChannelListModel$Companion$guildListBuilder$4;
|
|
this.$selectedVoiceChannelId$inlined = j2;
|
|
this.$voiceStates$inlined = map2;
|
|
this.$canSeeGuildRoleSubscriptions$inlined = z3;
|
|
this.$channelsWithActiveThreads$inlined = set3;
|
|
this.$guildScheduledEvents$inlined = list;
|
|
this.$stageInstances$inlined = map3;
|
|
this.$stageChannels$inlined = map4;
|
|
this.$threadParentMap$inlined = map5;
|
|
this.$joinedThreads$inlined = map6;
|
|
this.$items$inlined = arrayList;
|
|
this.$tryRemoveEmptyCategory$2$inlined = widgetChannelListModel$Companion$guildListBuilder$2;
|
|
this.$messageAcks$inlined = map7;
|
|
this.$directories$inlined = map8;
|
|
this.$directoryEvents$inlined = map9;
|
|
}
|
|
|
|
/* JADX DEBUG: Multi-variable search result rejected for r4v1, resolved type: java.lang.Object */
|
|
/* JADX WARN: Multi-variable type inference failed */
|
|
/* JADX WARNING: Removed duplicated region for block: B:36:0x0043 A[SYNTHETIC] */
|
|
@Override // kotlin.jvm.functions.Function0
|
|
/* renamed from: invoke */
|
|
public final ChannelListItemVoiceChannel mo1invoke() {
|
|
boolean z2;
|
|
boolean z3;
|
|
boolean z4;
|
|
WidgetChannelListModel.Companion.VocalChannelData invoke = this.$getVocalChannelData$2.invoke(this.$channel);
|
|
ChannelListItemVoiceChannel channelListItemVoiceChannel = null;
|
|
if (invoke != null) {
|
|
Iterator it = this.$guildScheduledEvents$inlined.iterator();
|
|
while (true) {
|
|
if (!it.hasNext()) {
|
|
break;
|
|
}
|
|
Object next = it.next();
|
|
GuildScheduledEvent guildScheduledEvent = (GuildScheduledEvent) next;
|
|
if (guildScheduledEvent.m() == GuildScheduledEventStatus.ACTIVE) {
|
|
Long b = guildScheduledEvent.b();
|
|
long h = this.$channel.h();
|
|
if (b != null && b.longValue() == h) {
|
|
z4 = true;
|
|
continue;
|
|
if (z4) {
|
|
channelListItemVoiceChannel = next;
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
z4 = false;
|
|
continue;
|
|
if (z4) {
|
|
}
|
|
}
|
|
GuildScheduledEvent guildScheduledEvent2 = (GuildScheduledEvent) channelListItemVoiceChannel;
|
|
Collection collection = (Collection) a.c(this.$channel, this.$voiceStates$inlined);
|
|
if (collection != null) {
|
|
if (!collection.isEmpty()) {
|
|
Iterator it2 = collection.iterator();
|
|
while (true) {
|
|
if (it2.hasNext()) {
|
|
if (((ChannelListItemVoiceUser) it2.next()).getVoiceState().j()) {
|
|
z3 = true;
|
|
break;
|
|
}
|
|
} else {
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
z3 = false;
|
|
if (z3) {
|
|
z2 = true;
|
|
Channel channel = this.$channel;
|
|
boolean textChannelSelected = invoke.getTextChannelSelected();
|
|
boolean voiceChannelSelected = invoke.getVoiceChannelSelected();
|
|
Long l = this.$permissions;
|
|
int mentionCount = invoke.getMentionCount();
|
|
boolean unread = invoke.getUnread();
|
|
int numUsersConnected = invoke.getNumUsersConnected();
|
|
boolean locked = invoke.getLocked();
|
|
Guild guild = this.$guild$inlined.getGuild();
|
|
if (guild == null || (r3 = guild.getMaxVideoChannelUsers()) == null) {
|
|
GuildMaxVideoChannelUsers guildMaxVideoChannelUsers = GuildMaxVideoChannelUsers.Unlimited.INSTANCE;
|
|
}
|
|
channelListItemVoiceChannel = new ChannelListItemVoiceChannel(channel, textChannelSelected, voiceChannelSelected, l, mentionCount, unread, numUsersConnected, locked, z2, guildMaxVideoChannelUsers, invoke.isGuildRoleSubscriptionLockedChannel(), invoke.isGuildRoleSubscriptionChannel(), guildScheduledEvent2);
|
|
}
|
|
}
|
|
z2 = false;
|
|
Channel channel = this.$channel;
|
|
boolean textChannelSelected = invoke.getTextChannelSelected();
|
|
boolean voiceChannelSelected = invoke.getVoiceChannelSelected();
|
|
Long l = this.$permissions;
|
|
int mentionCount = invoke.getMentionCount();
|
|
boolean unread = invoke.getUnread();
|
|
int numUsersConnected = invoke.getNumUsersConnected();
|
|
boolean locked = invoke.getLocked();
|
|
Guild guild = this.$guild$inlined.getGuild();
|
|
GuildMaxVideoChannelUsers guildMaxVideoChannelUsers = GuildMaxVideoChannelUsers.Unlimited.INSTANCE;
|
|
channelListItemVoiceChannel = new ChannelListItemVoiceChannel(channel, textChannelSelected, voiceChannelSelected, l, mentionCount, unread, numUsersConnected, locked, z2, guildMaxVideoChannelUsers, invoke.isGuildRoleSubscriptionLockedChannel(), invoke.isGuildRoleSubscriptionChannel(), guildScheduledEvent2);
|
|
}
|
|
return channelListItemVoiceChannel;
|
|
}
|
|
}
|