apkfuckery/com.discord/smali/androidx/preference/PreferenceManager$SimplePreferenceComparisonCallback.smali

203 lines
4.2 KiB
Smali
Raw Normal View History

2020-05-17 12:40:10 +00:00
.class public Landroidx/preference/PreferenceManager$SimplePreferenceComparisonCallback;
.super Landroidx/preference/PreferenceManager$PreferenceComparisonCallback;
.source "PreferenceManager.java"
# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
value = Landroidx/preference/PreferenceManager;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
accessFlags = 0x9
name = "SimplePreferenceComparisonCallback"
.end annotation
# direct methods
.method public constructor <init>()V
.locals 0
invoke-direct {p0}, Landroidx/preference/PreferenceManager$PreferenceComparisonCallback;-><init>()V
return-void
.end method
# virtual methods
.method public arePreferenceContentsTheSame(Landroidx/preference/Preference;Landroidx/preference/Preference;)Z
.locals 3
invoke-virtual {p1}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
move-result-object v0
invoke-virtual {p2}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
move-result-object v1
const/4 v2, 0x0
if-eq v0, v1, :cond_0
return v2
:cond_0
if-ne p1, p2, :cond_1
invoke-virtual {p1}, Landroidx/preference/Preference;->wasDetached()Z
move-result v0
if-eqz v0, :cond_1
return v2
:cond_1
invoke-virtual {p1}, Landroidx/preference/Preference;->getTitle()Ljava/lang/CharSequence;
move-result-object v0
invoke-virtual {p2}, Landroidx/preference/Preference;->getTitle()Ljava/lang/CharSequence;
move-result-object v1
invoke-static {v0, v1}, Landroid/text/TextUtils;->equals(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Z
move-result v0
if-nez v0, :cond_2
return v2
:cond_2
invoke-virtual {p1}, Landroidx/preference/Preference;->getSummary()Ljava/lang/CharSequence;
move-result-object v0
invoke-virtual {p2}, Landroidx/preference/Preference;->getSummary()Ljava/lang/CharSequence;
move-result-object v1
invoke-static {v0, v1}, Landroid/text/TextUtils;->equals(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Z
move-result v0
if-nez v0, :cond_3
return v2
:cond_3
invoke-virtual {p1}, Landroidx/preference/Preference;->getIcon()Landroid/graphics/drawable/Drawable;
move-result-object v0
invoke-virtual {p2}, Landroidx/preference/Preference;->getIcon()Landroid/graphics/drawable/Drawable;
move-result-object v1
if-eq v0, v1, :cond_5
if-eqz v0, :cond_4
invoke-virtual {v0, v1}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-nez v0, :cond_5
:cond_4
return v2
:cond_5
invoke-virtual {p1}, Landroidx/preference/Preference;->isEnabled()Z
move-result v0
invoke-virtual {p2}, Landroidx/preference/Preference;->isEnabled()Z
move-result v1
if-eq v0, v1, :cond_6
return v2
:cond_6
invoke-virtual {p1}, Landroidx/preference/Preference;->isSelectable()Z
move-result v0
invoke-virtual {p2}, Landroidx/preference/Preference;->isSelectable()Z
move-result v1
if-eq v0, v1, :cond_7
return v2
:cond_7
instance-of v0, p1, Landroidx/preference/TwoStatePreference;
if-eqz v0, :cond_8
move-object v0, p1
check-cast v0, Landroidx/preference/TwoStatePreference;
invoke-virtual {v0}, Landroidx/preference/TwoStatePreference;->isChecked()Z
move-result v0
move-object v1, p2
check-cast v1, Landroidx/preference/TwoStatePreference;
invoke-virtual {v1}, Landroidx/preference/TwoStatePreference;->isChecked()Z
move-result v1
if-eq v0, v1, :cond_8
return v2
:cond_8
instance-of v0, p1, Landroidx/preference/DropDownPreference;
if-eqz v0, :cond_9
if-eq p1, p2, :cond_9
return v2
:cond_9
const/4 p1, 0x1
return p1
.end method
.method public arePreferenceItemsTheSame(Landroidx/preference/Preference;Landroidx/preference/Preference;)Z
.locals 3
invoke-virtual {p1}, Landroidx/preference/Preference;->getId()J
move-result-wide v0
invoke-virtual {p2}, Landroidx/preference/Preference;->getId()J
move-result-wide p1
cmp-long v2, v0, p1
if-nez v2, :cond_0
const/4 p1, 0x1
goto :goto_0
:cond_0
const/4 p1, 0x0
:goto_0
return p1
.end method