apkfuckery/com.discord/smali/m.smali

969 lines
24 KiB
Smali
Raw Normal View History

2020-05-17 12:40:10 +00:00
.class public final Lm;
.super Ljava/lang/Object;
2020-07-14 22:43:59 +00:00
.source "MediaEngineLegacy.kt"
2020-05-17 12:40:10 +00:00
# interfaces
2020-07-14 22:43:59 +00:00
.implements Lcom/discord/rtcconnection/mediaengine/MediaEngine;
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
# static fields
.field public static final i:Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
# instance fields
.field public final a:Ljava/util/ArrayList;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/ArrayList<",
"Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection;",
">;"
}
.end annotation
.end field
.field public b:Lcom/hammerandchisel/libdiscord/Discord;
.field public final c:Ljava/util/ArrayList;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/ArrayList<",
"Lcom/discord/rtcconnection/mediaengine/MediaEngine$b;",
">;"
}
.end annotation
.end field
.field public d:Ljava/util/List;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/List<",
"Lf/a/h/r/a;",
">;"
}
.end annotation
.end field
.field public final e:Landroid/content/Context;
.field public final f:Ljava/util/concurrent/ExecutorService;
.field public final g:Lcom/discord/rtcconnection/mediaengine/MediaEngine$OpenSLESConfig;
.field public final h:Lcom/discord/utilities/logging/Logger;
2020-05-17 12:40:10 +00:00
# direct methods
2020-07-14 22:43:59 +00:00
.method public static constructor <clinit>()V
.locals 2
const-class v0, Lm;
invoke-virtual {v0}, Ljava/lang/Class;->getSimpleName()Ljava/lang/String;
move-result-object v0
const-string v1, "MediaEngineLegacy::class.java.simpleName"
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0, v1}, Li0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
sput-object v0, Lm;->i:Ljava/lang/String;
return-void
.end method
.method public constructor <init>(Landroid/content/Context;Ljava/util/concurrent/ExecutorService;Lcom/discord/rtcconnection/mediaengine/MediaEngine$OpenSLESConfig;Lcom/discord/utilities/logging/Logger;)V
.locals 0
2020-05-17 12:40:10 +00:00
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
2020-07-14 22:43:59 +00:00
iput-object p1, p0, Lm;->e:Landroid/content/Context;
iput-object p2, p0, Lm;->f:Ljava/util/concurrent/ExecutorService;
iput-object p3, p0, Lm;->g:Lcom/discord/rtcconnection/mediaengine/MediaEngine$OpenSLESConfig;
iput-object p4, p0, Lm;->h:Lcom/discord/utilities/logging/Logger;
new-instance p1, Ljava/util/ArrayList;
invoke-direct {p1}, Ljava/util/ArrayList;-><init>()V
iput-object p1, p0, Lm;->a:Ljava/util/ArrayList;
new-instance p1, Ljava/util/ArrayList;
invoke-direct {p1}, Ljava/util/ArrayList;-><init>()V
iput-object p1, p0, Lm;->c:Ljava/util/ArrayList;
2020-05-17 12:40:10 +00:00
return-void
.end method
2020-07-14 22:43:59 +00:00
.method public static final n(Lm;[Ljava/lang/String;)Ljava/util/List;
.locals 10
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
const/4 v0, 0x0
if-eqz p0, :cond_4
new-instance p0, Ljava/util/ArrayList;
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
array-length v1, p1
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {p0, v1}, Ljava/util/ArrayList;-><init>(I)V
array-length v1, p1
const/4 v2, 0x0
2020-05-17 12:40:10 +00:00
2020-07-08 16:44:49 +00:00
const/4 v3, 0x0
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
:goto_0
if-ge v3, v1, :cond_1
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
aget-object v4, p1, v3
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
sget-object v5, Ljava/util/Locale;->ROOT:Ljava/util/Locale;
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
const-string v6, "Locale.ROOT"
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v5, v6}, Li0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v4, :cond_0
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v4, v5}, Ljava/lang/String;->toUpperCase(Ljava/util/Locale;)Ljava/lang/String;
2020-05-17 12:40:10 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v4
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v5, "(this as java.lang.String).toUpperCase(locale)"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v4, v5}, Li0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {p0, v4}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
add-int/lit8 v3, v3, 0x1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
new-instance p0, Lkotlin/TypeCastException;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string p1, "null cannot be cast to non-null type java.lang.String"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {p0, p1}, Lkotlin/TypeCastException;-><init>(Ljava/lang/String;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
throw p0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_1
new-instance p1, Ln;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {p1}, Ln;-><init>()V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {p0, p1}, Li0/i/l;->sortedWith(Ljava/lang/Iterable;Ljava/util/Comparator;)Ljava/util/List;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object p0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance p1, Ljava/util/ArrayList;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/16 v1, 0xa
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {p0, v1}, Lf/i/a/b/i1/e;->collectionSizeOrDefault(Ljava/lang/Iterable;I)I
move-result v1
invoke-direct {p1, v1}, Ljava/util/ArrayList;-><init>(I)V
invoke-interface {p0}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object p0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:goto_1
invoke-interface {p0}, Ljava/util/Iterator;->hasNext()Z
move-result v1
if-eqz v1, :cond_3
invoke-interface {p0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v1
add-int/lit8 v9, v2, 0x1
if-ltz v2, :cond_2
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-object v4, v1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
check-cast v4, Ljava/lang/String;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
mul-int/lit8 v2, v2, 0x2
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
add-int/lit8 v7, v2, 0x65
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance v1, Lf/a/h/r/a;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
add-int/lit8 v2, v7, 0x1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v2}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v8
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v6, "video"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-object v3, v1
move v5, v9
invoke-direct/range {v3 .. v8}, Lf/a/h/r/a;-><init>(Ljava/lang/String;ILjava/lang/String;ILjava/lang/Integer;)V
invoke-virtual {p1, v1}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
move v2, v9
goto :goto_1
:cond_2
invoke-static {}, Lf/i/a/b/i1/e;->throwIndexOverflow()V
throw v0
:cond_3
return-object p1
:cond_4
throw v0
.end method
.method public static final o(Lm;Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection;)V
.locals 2
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
if-eqz v0, :cond_0
const/4 v1, 0x0
invoke-virtual {v0, v1}, Lcom/hammerandchisel/libdiscord/Discord;->setLocalVoiceLevelChangedCallback(Lcom/hammerandchisel/libdiscord/Discord$LocalVoiceLevelChangedCallback;)V
2020-07-08 16:44:49 +00:00
:cond_0
2020-07-16 18:51:06 +00:00
iget-object p0, p0, Lm;->a:Ljava/util/ArrayList;
2020-07-14 22:43:59 +00:00
2020-07-16 18:51:06 +00:00
invoke-virtual {p0, p1}, Ljava/util/ArrayList;->remove(Ljava/lang/Object;)Z
2020-07-14 22:43:59 +00:00
2020-07-08 16:44:49 +00:00
return-void
2020-07-14 22:43:59 +00:00
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public static final p(Lm;Lkotlin/jvm/functions/Function0;)Ljava/util/concurrent/Future;
.locals 1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object p0, p0, Lm;->f:Ljava/util/concurrent/ExecutorService;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance v0, Ls;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v0, p1}, Ls;-><init>(Lkotlin/jvm/functions/Function0;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-interface {p0, v0}, Ljava/util/concurrent/ExecutorService;->submit(Ljava/lang/Runnable;)Ljava/util/concurrent/Future;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object p0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
return-object p0
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
# virtual methods
.method public a()Lrx/Observable;
.locals 2
.annotation system Ldalvik/annotation/Signature;
value = {
"()",
"Lrx/Observable<",
"Lkotlin/Unit;",
">;"
}
.end annotation
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->d:Ljava/util/List;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v0, 0x1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_0
:cond_0
const/4 v0, 0x0
:goto_0
2020-07-08 16:44:49 +00:00
if-eqz v0, :cond_1
2020-07-14 22:43:59 +00:00
sget-object v0, Lkotlin/Unit;->a:Lkotlin/Unit;
new-instance v1, Lq0/l/e/j;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v1, v0}, Lq0/l/e/j;-><init>(Ljava/lang/Object;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v0, "Observable.just(Unit)"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v1, v0}, Li0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
return-object v1
2020-07-08 16:44:49 +00:00
:cond_1
2020-07-14 22:43:59 +00:00
invoke-virtual {p0}, Lm;->r()V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-nez v0, :cond_2
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance v0, Ljava/lang/IllegalStateException;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v1, "Failed to initialize native media engine"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v0, v1}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0}, Lrx/Observable;->t(Ljava/lang/Throwable;)Lrx/Observable;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v1, "Observable.error(Illegal\u2026ze native media engine\"))"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0, v1}, Li0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
return-object v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_2
new-instance v0, Lq;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v0, p0}, Lq;-><init>(Lm;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
sget-object v1, Lrx/Emitter$BackpressureMode;->d:Lrx/Emitter$BackpressureMode;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0, v1}, Lrx/Observable;->n(Lrx/functions/Action1;Lrx/Emitter$BackpressureMode;)Lrx/Observable;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v1, "Observable.create({ emit\u2026er.BackpressureMode.NONE)"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0, v1}, Li0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance v1, Lm$d;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v1, p0}, Lm$d;-><init>(Lm;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, v1}, Lrx/Observable;->r(Lrx/functions/Action1;)Lrx/Observable;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
sget-object v1, Lm$e;->d:Lm$e;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, v1}, Lrx/Observable;->C(Lq0/k/b;)Lrx/Observable;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v1, "getSupportedVideoCodecs(\u2026s }\n .map { Unit }"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0, v1}, Li0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
return-object v0
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public b(Z)V
.locals 1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, p1}, Lcom/hammerandchisel/libdiscord/Discord;->setEchoCancellation(Z)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
return-void
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public c(Z)V
.locals 1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, p1}, Lcom/hammerandchisel/libdiscord/Discord;->setNoiseCancellation(Z)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
return-void
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public d()Lrx/Observable;
.locals 2
.annotation system Ldalvik/annotation/Signature;
value = {
"()",
"Lrx/Observable<",
"Lcom/discord/rtcconnection/mediaengine/MediaEngine$AudioInfo;",
">;"
}
.end annotation
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance v0, Lm$c;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v0, p0}, Lm$c;-><init>(Lm;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
sget-object v1, Lrx/Emitter$BackpressureMode;->h:Lrx/Emitter$BackpressureMode;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0, v1}, Lrx/Observable;->n(Lrx/functions/Action1;Lrx/Emitter$BackpressureMode;)Lrx/Observable;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v1, "Observable.create({ emit\u2026.BackpressureMode.LATEST)"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0, v1}, Li0/n/c/h;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
return-object v0
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public e(I)V
.locals 1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, p1}, Lcom/hammerandchisel/libdiscord/Discord;->setVideoInputDevice(I)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
return-void
.end method
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
.method public f(JLcom/discord/rtcconnection/mediaengine/MediaEngine$a;Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$Type;Lkotlin/jvm/functions/Function1;)Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection;
.locals 18
2020-07-14 22:43:59 +00:00
.annotation system Ldalvik/annotation/Signature;
value = {
"(J",
"Lcom/discord/rtcconnection/mediaengine/MediaEngine$a;",
"Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$Type;",
"Lkotlin/jvm/functions/Function1<",
"-",
"Ljava/lang/Exception;",
"Lkotlin/Unit;",
">;)",
"Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection;"
}
.end annotation
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-object/from16 v6, p0
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
const/4 v7, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz p4, :cond_5
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
iget-object v0, v6, Lm;->d:Ljava/util/List;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v0, 0x1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
const/4 v0, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:goto_0
if-nez v0, :cond_1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance v0, Ljava/lang/IllegalStateException;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v1, "connect called on unprepared media engine."
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v0, v1}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-object/from16 v1, p5
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-interface {v1, v0}, Lkotlin/jvm/functions/Function1;->invoke(Ljava/lang/Object;)Ljava/lang/Object;
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
return-object v7
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_1
2020-07-16 18:51:06 +00:00
iget-object v11, v6, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
if-eqz v11, :cond_3
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
iget-object v0, v6, Lm;->h:Lcom/discord/utilities/logging/Logger;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
sget-object v1, Lm;->i:Ljava/lang/String;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance v2, Ljava/lang/StringBuilder;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v2}, Ljava/lang/StringBuilder;-><init>()V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v3, "Connecting with options: "
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
2020-07-16 18:51:06 +00:00
move-object/from16 v14, p3
2020-07-14 22:43:59 +00:00
2020-07-16 18:51:06 +00:00
invoke-virtual {v2, v14}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
2020-07-14 22:43:59 +00:00
invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
2020-07-08 16:44:49 +00:00
move-result-object v2
2020-07-14 22:43:59 +00:00
const/4 v3, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v4, 0x4
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v5, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static/range {v0 .. v5}, Lcom/discord/utilities/logging/Logger;->i$default(Lcom/discord/utilities/logging/Logger;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;ILjava/lang/Object;)V
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
new-instance v8, Lm$a;
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-object v0, v8
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-object/from16 v1, p0
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-object/from16 v2, p3
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-object/from16 v3, p4
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-wide/from16 v4, p1
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
invoke-direct/range {v0 .. v5}, Lm$a;-><init>(Lm;Lcom/discord/rtcconnection/mediaengine/MediaEngine$a;Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$Type;J)V
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
new-instance v0, Lf/a/h/r/b/e;
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
iget-object v9, v6, Lm;->f:Ljava/util/concurrent/ExecutorService;
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
iget-object v10, v6, Lm;->h:Lcom/discord/utilities/logging/Logger;
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
iget-object v12, v6, Lm;->d:Ljava/util/List;
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
if-eqz v12, :cond_2
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
invoke-static {v8}, Lf/i/a/b/i1/e;->listOf1(Ljava/lang/Object;)Ljava/util/List;
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-result-object v17
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-object v8, v0
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-object/from16 v13, p4
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-wide/from16 v14, p1
2020-07-14 22:43:59 +00:00
2020-07-16 18:51:06 +00:00
move-object/from16 v16, p3
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
invoke-direct/range {v8 .. v17}, Lf/a/h/r/b/e;-><init>(Ljava/util/concurrent/ExecutorService;Lcom/discord/utilities/logging/Logger;Lcom/hammerandchisel/libdiscord/Discord;Ljava/util/List;Lcom/discord/rtcconnection/mediaengine/MediaEngineConnection$Type;JLcom/discord/rtcconnection/mediaengine/MediaEngine$a;Ljava/util/List;)V
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
move-object v7, v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_2
const-string v0, "supportedVideoCodecs"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0}, Li0/n/c/h;->throwUninitializedPropertyAccessException(Ljava/lang/String;)V
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
throw v7
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_3
:goto_1
2020-07-16 18:51:06 +00:00
if-eqz v7, :cond_4
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
iget-object v0, v6, Lm;->a:Ljava/util/ArrayList;
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
invoke-virtual {v0, v7}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance v0, Lm$b;
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
invoke-direct {v0, v7}, Lm$b;-><init>(Lf/a/h/r/b/e;)V
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
invoke-virtual {v6, v0}, Lm;->q(Lkotlin/jvm/functions/Function1;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_4
2020-07-16 18:51:06 +00:00
return-object v7
2020-07-08 16:44:49 +00:00
2020-07-15 19:49:36 +00:00
:cond_5
2020-07-16 18:51:06 +00:00
const-string v0, "connectionType"
2020-07-15 19:49:36 +00:00
2020-07-16 18:51:06 +00:00
invoke-static {v0}, Li0/n/c/h;->c(Ljava/lang/String;)V
2020-07-15 19:49:36 +00:00
2020-07-16 18:51:06 +00:00
throw v7
2020-07-14 22:43:59 +00:00
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public g(F)V
.locals 3
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/high16 v1, 0x43960000 # 300.0f
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v2, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v2, p1}, Ljava/lang/Math;->max(FF)F
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result p1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v1, p1}, Ljava/lang/Math;->min(FF)F
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result p1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/high16 v1, 0x42c80000 # 100.0f
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
div-float/2addr p1, v1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, p1}, Lcom/hammerandchisel/libdiscord/Discord;->setSpeakerVolume(F)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
return-void
.end method
2020-07-08 16:44:49 +00:00
2020-07-16 18:51:06 +00:00
.method public getConnections()Ljava/util/List;
.locals 1
2020-07-15 19:49:36 +00:00
2020-07-16 18:51:06 +00:00
iget-object v0, p0, Lm;->a:Ljava/util/ArrayList;
2020-07-14 22:43:59 +00:00
return-object v0
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public h(Z)V
.locals 1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, p1}, Lcom/hammerandchisel/libdiscord/Discord;->setNoiseSuppression(Z)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
return-void
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public i()Lcom/hammerandchisel/libdiscord/Discord;
.locals 1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
return-object v0
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public j(Lkotlin/jvm/functions/Function1;)V
.locals 2
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lkotlin/jvm/functions/Function1<",
"-[",
"Lco/discord/media_engine/VideoInputDeviceDescription;",
"Lkotlin/Unit;",
">;)V"
}
.end annotation
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {p0}, Lm;->r()V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance v1, Lr;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v1, p1}, Lr;-><init>(Lkotlin/jvm/functions/Function1;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, v1}, Lcom/hammerandchisel/libdiscord/Discord;->getVideoInputDevices(Lcom/hammerandchisel/libdiscord/Discord$GetVideoInputDevicesCallback;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
return-void
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public k()Ljava/util/concurrent/ExecutorService;
.locals 1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->f:Ljava/util/concurrent/ExecutorService;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
return-object v0
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public l(Z)V
.locals 1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, p1}, Lcom/hammerandchisel/libdiscord/Discord;->setAutomaticGainControl(Z)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
return-void
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public m(Lkotlin/jvm/functions/Function1;)V
.locals 2
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lkotlin/jvm/functions/Function1<",
"-",
"Lcom/discord/rtcconnection/mediaengine/MediaEngine$LocalVoiceStatus;",
"Lkotlin/Unit;",
">;)V"
}
.end annotation
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz p1, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {p0}, Lm;->r()V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
new-instance v1, Lm$f;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v1, p1}, Lm$f;-><init>(Lkotlin/jvm/functions/Function1;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, v1}, Lcom/hammerandchisel/libdiscord/Discord;->setLocalVoiceLevelChangedCallback(Lcom/hammerandchisel/libdiscord/Discord$LocalVoiceLevelChangedCallback;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
iget-object p1, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz p1, :cond_1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v0, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {p1, v0}, Lcom/hammerandchisel/libdiscord/Discord;->setLocalVoiceLevelChangedCallback(Lcom/hammerandchisel/libdiscord/Discord$LocalVoiceLevelChangedCallback;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_1
:goto_0
return-void
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public final q(Lkotlin/jvm/functions/Function1;)V
.locals 9
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lkotlin/jvm/functions/Function1<",
"-",
"Lcom/discord/rtcconnection/mediaengine/MediaEngine$b;",
"Lkotlin/Unit;",
">;)V"
}
.end annotation
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->c:Ljava/util/ArrayList;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-interface {v0}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:goto_0
invoke-interface {v0}, Ljava/util/Iterator;->hasNext()Z
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result v1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v1, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-interface {v0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
check-cast v1, Lcom/discord/rtcconnection/mediaengine/MediaEngine$b;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:try_start_0
invoke-interface {p1, v1}, Lkotlin/jvm/functions/Function1;->invoke(Ljava/lang/Object;)Ljava/lang/Object;
:try_end_0
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:catch_0
move-exception v5
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v2, p0, Lm;->h:Lcom/discord/utilities/logging/Logger;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
sget-object v3, Lm;->i:Ljava/lang/String;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v6, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/16 v7, 0x8
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v8, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v4, "Error in listener"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static/range {v2 .. v8}, Lcom/discord/utilities/logging/Logger;->e$default(Lcom/discord/utilities/logging/Logger;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;Ljava/util/Map;ILjava/lang/Object;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
return-void
.end method
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
.method public final r()V
.locals 9
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
return-void
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_0
iget-object v1, p0, Lm;->h:Lcom/discord/utilities/logging/Logger;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
sget-object v2, Lm;->i:Ljava/lang/String;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v0, "initializing voice engine. OpenSL ES: "
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0}, Lf/e/b/a/a;->D(Ljava/lang/String;)Ljava/lang/StringBuilder;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v3, p0, Lm;->g:Lcom/discord/rtcconnection/mediaengine/MediaEngine$OpenSLESConfig;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result-object v3
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v4, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v5, 0x4
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v6, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static/range {v1 .. v6}, Lcom/discord/utilities/logging/Logger;->i$default(Lcom/discord/utilities/logging/Logger;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;ILjava/lang/Object;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v0, p0, Lm;->g:Lcom/discord/rtcconnection/mediaengine/MediaEngine$OpenSLESConfig;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-virtual {v0}, Ljava/lang/Enum;->ordinal()I
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-result v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v1, 0x1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eq v0, v1, :cond_2
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v2, 0x2
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eq v0, v2, :cond_1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_1
invoke-static {v1}, Lorg/webrtc/voiceengine/WebRtcAudioManager;->setBlacklistDeviceForOpenSLESUsage(Z)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:cond_2
const/4 v0, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static {v0}, Lorg/webrtc/voiceengine/WebRtcAudioManager;->setBlacklistDeviceForOpenSLESUsage(Z)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:goto_0
new-instance v0, Lm$g;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v0, p0}, Lm$g;-><init>(Lm;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
sput-object v0, Lorg/webrtc/Logging;->externalReporter:Lorg/webrtc/Logging$ExternalReporter;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:try_start_0
new-instance v0, Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v2, p0, Lm;->e:Landroid/content/Context;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-direct {v0, v2}, Lcom/hammerandchisel/libdiscord/Discord;-><init>(Landroid/content/Context;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iput-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
:try_end_0
.catch Ljava/lang/ExceptionInInitializerError; {:try_start_0 .. :try_end_0} :catch_1
.catch Ljava/lang/UnsatisfiedLinkError; {:try_start_0 .. :try_end_0} :catch_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:catchall_0
move-exception v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-object v5, v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v2, p0, Lm;->h:Lcom/discord/utilities/logging/Logger;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
sget-object v3, Lm;->i:Ljava/lang/String;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v6, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/16 v7, 0x8
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v8, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v4, "Unable to initialize voice engine, new error discovered"
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static/range {v2 .. v8}, Lcom/discord/utilities/logging/Logger;->e$default(Lcom/discord/utilities/logging/Logger;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;Ljava/util/Map;ILjava/lang/Object;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_1
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
:catch_0
move-exception v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
move-object v5, v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v2, p0, Lm;->h:Lcom/discord/utilities/logging/Logger;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
sget-object v3, Lm;->i:Ljava/lang/String;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v6, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/16 v7, 0x8
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v8, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v4, "Unable to initialize voice engine."
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static/range {v2 .. v8}, Lcom/discord/utilities/logging/Logger;->e$default(Lcom/discord/utilities/logging/Logger;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;Ljava/util/Map;ILjava/lang/Object;)V
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
goto :goto_1
2020-07-08 16:44:49 +00:00
:catch_1
move-exception v0
2020-07-14 22:43:59 +00:00
move-object v5, v0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
iget-object v2, p0, Lm;->h:Lcom/discord/utilities/logging/Logger;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
sget-object v3, Lm;->i:Ljava/lang/String;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v6, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/16 v7, 0x8
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const/4 v8, 0x0
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
const-string v4, "Unable to initialize voice engine."
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
invoke-static/range {v2 .. v8}, Lcom/discord/utilities/logging/Logger;->e$default(Lcom/discord/utilities/logging/Logger;Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;Ljava/util/Map;ILjava/lang/Object;)V
:goto_1
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
2020-07-08 16:44:49 +00:00
2020-07-14 22:43:59 +00:00
if-eqz v0, :cond_3
invoke-virtual {v0, v1}, Lcom/hammerandchisel/libdiscord/Discord;->enableBuiltInAEC(Z)V
:cond_3
iget-object v0, p0, Lm;->b:Lcom/hammerandchisel/libdiscord/Discord;
if-eqz v0, :cond_4
sget-object v0, Lm$h;->d:Lm$h;
invoke-virtual {p0, v0}, Lm;->q(Lkotlin/jvm/functions/Function1;)V
:cond_4
return-void
2020-05-17 12:40:10 +00:00
.end method