2020-07-08 16:44:49 +00:00
|
|
|
.class public final Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;
|
|
|
|
.super Ljava/lang/Object;
|
|
|
|
.source "WidgetHome.kt"
|
|
|
|
|
|
|
|
|
|
|
|
# annotations
|
|
|
|
.annotation system Ldalvik/annotation/EnclosingClass;
|
|
|
|
value = Lcom/discord/widgets/home/WidgetHome;
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
.annotation system Ldalvik/annotation/InnerClass;
|
|
|
|
accessFlags = 0x19
|
|
|
|
name = "BackBehaviorFeatureFlag"
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
|
|
|
|
# static fields
|
|
|
|
.field public static final INSTANCE:Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;
|
|
|
|
|
|
|
|
.field public static isEnabled:Z
|
|
|
|
|
|
|
|
|
|
|
|
# direct methods
|
|
|
|
.method public static constructor <clinit>()V
|
|
|
|
.locals 3
|
|
|
|
|
|
|
|
new-instance v0, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;
|
|
|
|
|
|
|
|
invoke-direct {v0}, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;-><init>()V
|
|
|
|
|
|
|
|
sput-object v0, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;->INSTANCE:Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;
|
|
|
|
|
|
|
|
sget-object v0, Lcom/discord/utilities/cache/SharedPreferencesProvider;->INSTANCE:Lcom/discord/utilities/cache/SharedPreferencesProvider;
|
|
|
|
|
|
|
|
invoke-virtual {v0}, Lcom/discord/utilities/cache/SharedPreferencesProvider;->get()Landroid/content/SharedPreferences;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
sget-boolean v1, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;->isEnabled:Z
|
|
|
|
|
|
|
|
const-string v2, "CACHE_KEY_BACK_BEHAVIOR_EXPERIMENT_BUCKET"
|
|
|
|
|
|
|
|
invoke-interface {v0, v2, v1}, Landroid/content/SharedPreferences;->getBoolean(Ljava/lang/String;Z)Z
|
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
|
|
|
sput-boolean v0, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;->isEnabled:Z
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public constructor <init>()V
|
|
|
|
.locals 0
|
|
|
|
|
|
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public static final synthetic access$handleExperiment(Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;Lcom/discord/stores/StoreExperiments$Experiment;)V
|
|
|
|
.locals 0
|
|
|
|
|
|
|
|
invoke-direct {p0, p1}, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;->handleExperiment(Lcom/discord/stores/StoreExperiments$Experiment;)V
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method private final handleExperiment(Lcom/discord/stores/StoreExperiments$Experiment;)V
|
|
|
|
.locals 2
|
|
|
|
|
|
|
|
const/4 v0, 0x1
|
|
|
|
|
|
|
|
invoke-virtual {p1, v0}, Lcom/discord/stores/StoreExperiments$Experiment;->isEnabled(I)Z
|
|
|
|
|
|
|
|
move-result p1
|
|
|
|
|
|
|
|
sget-boolean v0, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;->isEnabled:Z
|
|
|
|
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
|
|
|
|
sget-object v0, Lcom/discord/utilities/cache/SharedPreferencesProvider;->INSTANCE:Lcom/discord/utilities/cache/SharedPreferencesProvider;
|
|
|
|
|
|
|
|
invoke-virtual {v0}, Lcom/discord/utilities/cache/SharedPreferencesProvider;->get()Landroid/content/SharedPreferences;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
new-instance v1, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag$handleExperiment$1;
|
|
|
|
|
|
|
|
invoke-direct {v1, p1}, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag$handleExperiment$1;-><init>(Z)V
|
|
|
|
|
|
|
|
invoke-static {v0, v1}, Lcom/discord/utilities/cache/SharedPreferenceExtensionsKt;->edit(Landroid/content/SharedPreferences;Lkotlin/jvm/functions/Function1;)V
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
|
|
|
|
# virtual methods
|
|
|
|
.method public final isEnabled()Z
|
|
|
|
.locals 1
|
|
|
|
|
|
|
|
sget-boolean v0, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;->isEnabled:Z
|
|
|
|
|
|
|
|
return v0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public final observeExperiment(Lcom/discord/app/AppFragment;)V
|
|
|
|
.locals 13
|
|
|
|
|
2020-09-16 23:45:23 +00:00
|
|
|
const-string v0, "fragment"
|
2020-07-08 16:44:49 +00:00
|
|
|
|
2020-09-22 06:09:03 +00:00
|
|
|
invoke-static {p1, v0}, Lk0/n/c/i;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
2020-07-08 16:44:49 +00:00
|
|
|
|
2020-09-16 23:45:23 +00:00
|
|
|
sget-object v0, Lcom/discord/stores/StoreStream;->Companion:Lcom/discord/stores/StoreStream$Companion;
|
2020-07-08 16:44:49 +00:00
|
|
|
|
2020-09-16 23:45:23 +00:00
|
|
|
invoke-virtual {v0}, Lcom/discord/stores/StoreStream$Companion;->getExperiments()Lcom/discord/stores/StoreExperiments;
|
2020-07-08 16:44:49 +00:00
|
|
|
|
2020-09-16 23:45:23 +00:00
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
const-string v1, "2020-06_android_back_button_behavior_v01"
|
2020-07-08 16:44:49 +00:00
|
|
|
|
2020-09-16 23:45:23 +00:00
|
|
|
const/4 v2, 0x0
|
2020-07-08 16:44:49 +00:00
|
|
|
|
|
|
|
const/4 v3, 0x2
|
|
|
|
|
2020-09-16 23:45:23 +00:00
|
|
|
invoke-static {v0, v1, v2, v3, v2}, Lcom/discord/stores/StoreExperiments;->getExperiment$default(Lcom/discord/stores/StoreExperiments;Ljava/lang/String;Lkotlin/jvm/functions/Function1;ILjava/lang/Object;)Lrx/Observable;
|
2020-07-08 16:44:49 +00:00
|
|
|
|
2020-09-16 23:45:23 +00:00
|
|
|
move-result-object v0
|
2020-07-08 16:44:49 +00:00
|
|
|
|
2020-09-16 23:45:23 +00:00
|
|
|
invoke-static {v0, p1, v2, v3, v2}, Lcom/discord/utilities/rx/ObservableExtensionsKt;->ui$default(Lrx/Observable;Lcom/discord/app/AppComponent;Lcom/discord/utilities/mg_recycler/MGRecyclerAdapterSimple;ILjava/lang/Object;)Lrx/Observable;
|
2020-07-08 16:44:49 +00:00
|
|
|
|
|
|
|
move-result-object v4
|
|
|
|
|
|
|
|
const-class v5, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;
|
|
|
|
|
2020-09-16 23:45:23 +00:00
|
|
|
new-instance v10, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag$observeExperiment$1;
|
|
|
|
|
|
|
|
invoke-direct {v10, p0}, Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag$observeExperiment$1;-><init>(Lcom/discord/widgets/home/WidgetHome$BackBehaviorFeatureFlag;)V
|
|
|
|
|
2020-07-08 16:44:49 +00:00
|
|
|
const/4 v6, 0x0
|
|
|
|
|
|
|
|
const/4 v7, 0x0
|
|
|
|
|
|
|
|
const/4 v8, 0x0
|
|
|
|
|
|
|
|
const/4 v9, 0x0
|
|
|
|
|
|
|
|
const/16 v11, 0x1e
|
|
|
|
|
|
|
|
const/4 v12, 0x0
|
|
|
|
|
|
|
|
invoke-static/range {v4 .. v12}, Lcom/discord/utilities/rx/ObservableExtensionsKt;->appSubscribe$default(Lrx/Observable;Ljava/lang/Class;Landroid/content/Context;Lkotlin/jvm/functions/Function1;Lkotlin/jvm/functions/Function1;Lkotlin/jvm/functions/Function0;Lkotlin/jvm/functions/Function1;ILjava/lang/Object;)V
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|