apkfuckery/com.discord/smali/androidx/preference/PreferenceGroup.smali
2020-07-08 16:44:49 +00:00

1032 lines
27 KiB
Smali

.class public abstract Landroidx/preference/PreferenceGroup;
.super Landroidx/preference/Preference;
.source "PreferenceGroup.java"
# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Landroidx/preference/PreferenceGroup$SavedState;,
Landroidx/preference/PreferenceGroup$OnExpandButtonClickListener;,
Landroidx/preference/PreferenceGroup$PreferencePositionCallback;
}
.end annotation
# static fields
.field public static final TAG:Ljava/lang/String; = "PreferenceGroup"
# instance fields
.field public mAttachedToHierarchy:Z
.field public final mClearRecycleCacheRunnable:Ljava/lang/Runnable;
.field public mCurrentPreferenceOrder:I
.field public final mHandler:Landroid/os/Handler;
.field public final mIdRecycleCache:Landroidx/collection/SimpleArrayMap;
.annotation system Ldalvik/annotation/Signature;
value = {
"Landroidx/collection/SimpleArrayMap<",
"Ljava/lang/String;",
"Ljava/lang/Long;",
">;"
}
.end annotation
.end field
.field public mInitialExpandedChildrenCount:I
.field public mOnExpandButtonClickListener:Landroidx/preference/PreferenceGroup$OnExpandButtonClickListener;
.field public mOrderingAsAdded:Z
.field public mPreferences:Ljava/util/List;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/List<",
"Landroidx/preference/Preference;",
">;"
}
.end annotation
.end field
# direct methods
.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;)V
.locals 1
const/4 v0, 0x0
invoke-direct {p0, p1, p2, v0}, Landroidx/preference/PreferenceGroup;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
return-void
.end method
.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
.locals 1
const/4 v0, 0x0
invoke-direct {p0, p1, p2, p3, v0}, Landroidx/preference/PreferenceGroup;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;II)V
return-void
.end method
.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;II)V
.locals 3
invoke-direct {p0, p1, p2, p3, p4}, Landroidx/preference/Preference;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;II)V
new-instance v0, Landroidx/collection/SimpleArrayMap;
invoke-direct {v0}, Landroidx/collection/SimpleArrayMap;-><init>()V
iput-object v0, p0, Landroidx/preference/PreferenceGroup;->mIdRecycleCache:Landroidx/collection/SimpleArrayMap;
new-instance v0, Landroid/os/Handler;
invoke-direct {v0}, Landroid/os/Handler;-><init>()V
iput-object v0, p0, Landroidx/preference/PreferenceGroup;->mHandler:Landroid/os/Handler;
const/4 v0, 0x1
iput-boolean v0, p0, Landroidx/preference/PreferenceGroup;->mOrderingAsAdded:Z
const/4 v1, 0x0
iput v1, p0, Landroidx/preference/PreferenceGroup;->mCurrentPreferenceOrder:I
iput-boolean v1, p0, Landroidx/preference/PreferenceGroup;->mAttachedToHierarchy:Z
const v1, 0x7fffffff
iput v1, p0, Landroidx/preference/PreferenceGroup;->mInitialExpandedChildrenCount:I
const/4 v2, 0x0
iput-object v2, p0, Landroidx/preference/PreferenceGroup;->mOnExpandButtonClickListener:Landroidx/preference/PreferenceGroup$OnExpandButtonClickListener;
new-instance v2, Landroidx/preference/PreferenceGroup$1;
invoke-direct {v2, p0}, Landroidx/preference/PreferenceGroup$1;-><init>(Landroidx/preference/PreferenceGroup;)V
iput-object v2, p0, Landroidx/preference/PreferenceGroup;->mClearRecycleCacheRunnable:Ljava/lang/Runnable;
new-instance v2, Ljava/util/ArrayList;
invoke-direct {v2}, Ljava/util/ArrayList;-><init>()V
iput-object v2, p0, Landroidx/preference/PreferenceGroup;->mPreferences:Ljava/util/List;
sget-object v2, Landroidx/preference/R$styleable;->PreferenceGroup:[I
invoke-virtual {p1, p2, v2, p3, p4}, Landroid/content/Context;->obtainStyledAttributes(Landroid/util/AttributeSet;[III)Landroid/content/res/TypedArray;
move-result-object p1
sget p2, Landroidx/preference/R$styleable;->PreferenceGroup_orderingFromXml:I
invoke-static {p1, p2, p2, v0}, Landroidx/core/content/res/TypedArrayUtils;->getBoolean(Landroid/content/res/TypedArray;IIZ)Z
move-result p2
iput-boolean p2, p0, Landroidx/preference/PreferenceGroup;->mOrderingAsAdded:Z
sget p2, Landroidx/preference/R$styleable;->PreferenceGroup_initialExpandedChildrenCount:I
invoke-virtual {p1, p2}, Landroid/content/res/TypedArray;->hasValue(I)Z
move-result p2
if-eqz p2, :cond_0
sget p2, Landroidx/preference/R$styleable;->PreferenceGroup_initialExpandedChildrenCount:I
invoke-static {p1, p2, p2, v1}, Landroidx/core/content/res/TypedArrayUtils;->getInt(Landroid/content/res/TypedArray;III)I
move-result p2
invoke-virtual {p0, p2}, Landroidx/preference/PreferenceGroup;->setInitialExpandedChildrenCount(I)V
:cond_0
invoke-virtual {p1}, Landroid/content/res/TypedArray;->recycle()V
return-void
.end method
.method private removePreferenceInt(Landroidx/preference/Preference;)Z
.locals 5
monitor-enter p0
:try_start_0
invoke-virtual {p1}, Landroidx/preference/Preference;->onPrepareForRemoval()V
invoke-virtual {p1}, Landroidx/preference/Preference;->getParent()Landroidx/preference/PreferenceGroup;
move-result-object v0
if-ne v0, p0, :cond_0
const/4 v0, 0x0
invoke-virtual {p1, v0}, Landroidx/preference/Preference;->assignParent(Landroidx/preference/PreferenceGroup;)V
:cond_0
iget-object v0, p0, Landroidx/preference/PreferenceGroup;->mPreferences:Ljava/util/List;
invoke-interface {v0, p1}, Ljava/util/List;->remove(Ljava/lang/Object;)Z
move-result v0
if-eqz v0, :cond_2
invoke-virtual {p1}, Landroidx/preference/Preference;->getKey()Ljava/lang/String;
move-result-object v1
if-eqz v1, :cond_1
iget-object v2, p0, Landroidx/preference/PreferenceGroup;->mIdRecycleCache:Landroidx/collection/SimpleArrayMap;
invoke-virtual {p1}, Landroidx/preference/Preference;->getId()J
move-result-wide v3
invoke-static {v3, v4}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
move-result-object v3
invoke-virtual {v2, v1, v3}, Landroidx/collection/SimpleArrayMap;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
iget-object v1, p0, Landroidx/preference/PreferenceGroup;->mHandler:Landroid/os/Handler;
iget-object v2, p0, Landroidx/preference/PreferenceGroup;->mClearRecycleCacheRunnable:Ljava/lang/Runnable;
invoke-virtual {v1, v2}, Landroid/os/Handler;->removeCallbacks(Ljava/lang/Runnable;)V
iget-object v1, p0, Landroidx/preference/PreferenceGroup;->mHandler:Landroid/os/Handler;
iget-object v2, p0, Landroidx/preference/PreferenceGroup;->mClearRecycleCacheRunnable:Ljava/lang/Runnable;
invoke-virtual {v1, v2}, Landroid/os/Handler;->post(Ljava/lang/Runnable;)Z
:cond_1
iget-boolean v1, p0, Landroidx/preference/PreferenceGroup;->mAttachedToHierarchy:Z
if-eqz v1, :cond_2
invoke-virtual {p1}, Landroidx/preference/Preference;->onDetached()V
:cond_2
monitor-exit p0
return v0
:catchall_0
move-exception p1
monitor-exit p0
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
throw p1
.end method
# virtual methods
.method public addItemFromInflater(Landroidx/preference/Preference;)V
.locals 0
invoke-virtual {p0, p1}, Landroidx/preference/PreferenceGroup;->addPreference(Landroidx/preference/Preference;)Z
return-void
.end method
.method public addPreference(Landroidx/preference/Preference;)Z
.locals 6
iget-object v0, p0, Landroidx/preference/PreferenceGroup;->mPreferences:Ljava/util/List;
invoke-interface {v0, p1}, Ljava/util/List;->contains(Ljava/lang/Object;)Z
move-result v0
const/4 v1, 0x1
if-eqz v0, :cond_0
return v1
:cond_0
invoke-virtual {p1}, Landroidx/preference/Preference;->getKey()Ljava/lang/String;
move-result-object v0
if-eqz v0, :cond_2
move-object v0, p0
:goto_0
invoke-virtual {v0}, Landroidx/preference/Preference;->getParent()Landroidx/preference/PreferenceGroup;
move-result-object v2
if-eqz v2, :cond_1
invoke-virtual {v0}, Landroidx/preference/Preference;->getParent()Landroidx/preference/PreferenceGroup;
move-result-object v0
goto :goto_0
:cond_1
invoke-virtual {p1}, Landroidx/preference/Preference;->getKey()Ljava/lang/String;
move-result-object v2
invoke-virtual {v0, v2}, Landroidx/preference/PreferenceGroup;->findPreference(Ljava/lang/CharSequence;)Landroidx/preference/Preference;
move-result-object v0
if-eqz v0, :cond_2
const-string v0, "PreferenceGroup"
new-instance v3, Ljava/lang/StringBuilder;
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
const-string v4, "Found duplicated key: \""
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
const-string v2, "\". This can cause unintended behaviour, please use unique keys for every preference."
invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v2
invoke-static {v0, v2}, Landroid/util/Log;->e(Ljava/lang/String;Ljava/lang/String;)I
:cond_2
invoke-virtual {p1}, Landroidx/preference/Preference;->getOrder()I
move-result v0
const v2, 0x7fffffff
if-ne v0, v2, :cond_4
iget-boolean v0, p0, Landroidx/preference/PreferenceGroup;->mOrderingAsAdded:Z
if-eqz v0, :cond_3
iget v0, p0, Landroidx/preference/PreferenceGroup;->mCurrentPreferenceOrder:I
add-int/lit8 v2, v0, 0x1
iput v2, p0, Landroidx/preference/PreferenceGroup;->mCurrentPreferenceOrder:I
invoke-virtual {p1, v0}, Landroidx/preference/Preference;->setOrder(I)V
:cond_3
instance-of v0, p1, Landroidx/preference/PreferenceGroup;
if-eqz v0, :cond_4
move-object v0, p1
check-cast v0, Landroidx/preference/PreferenceGroup;
iget-boolean v2, p0, Landroidx/preference/PreferenceGroup;->mOrderingAsAdded:Z
invoke-virtual {v0, v2}, Landroidx/preference/PreferenceGroup;->setOrderingAsAdded(Z)V
:cond_4
iget-object v0, p0, Landroidx/preference/PreferenceGroup;->mPreferences:Ljava/util/List;
invoke-static {v0, p1}, Ljava/util/Collections;->binarySearch(Ljava/util/List;Ljava/lang/Object;)I
move-result v0
if-gez v0, :cond_5
mul-int/lit8 v0, v0, -0x1
sub-int/2addr v0, v1
:cond_5
invoke-virtual {p0, p1}, Landroidx/preference/PreferenceGroup;->onPrepareAddPreference(Landroidx/preference/Preference;)Z
move-result v2
if-nez v2, :cond_6
const/4 p1, 0x0
return p1
:cond_6
monitor-enter p0
:try_start_0
iget-object v2, p0, Landroidx/preference/PreferenceGroup;->mPreferences:Ljava/util/List;
invoke-interface {v2, v0, p1}, Ljava/util/List;->add(ILjava/lang/Object;)V
monitor-exit p0
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
invoke-virtual {p0}, Landroidx/preference/Preference;->getPreferenceManager()Landroidx/preference/PreferenceManager;
move-result-object v0
invoke-virtual {p1}, Landroidx/preference/Preference;->getKey()Ljava/lang/String;
move-result-object v2
if-eqz v2, :cond_7
iget-object v3, p0, Landroidx/preference/PreferenceGroup;->mIdRecycleCache:Landroidx/collection/SimpleArrayMap;
invoke-virtual {v3, v2}, Landroidx/collection/SimpleArrayMap;->containsKey(Ljava/lang/Object;)Z
move-result v3
if-eqz v3, :cond_7
iget-object v3, p0, Landroidx/preference/PreferenceGroup;->mIdRecycleCache:Landroidx/collection/SimpleArrayMap;
invoke-virtual {v3, v2}, Landroidx/collection/SimpleArrayMap;->get(Ljava/lang/Object;)Ljava/lang/Object;
move-result-object v3
check-cast v3, Ljava/lang/Long;
invoke-virtual {v3}, Ljava/lang/Long;->longValue()J
move-result-wide v3
iget-object v5, p0, Landroidx/preference/PreferenceGroup;->mIdRecycleCache:Landroidx/collection/SimpleArrayMap;
invoke-virtual {v5, v2}, Landroidx/collection/SimpleArrayMap;->remove(Ljava/lang/Object;)Ljava/lang/Object;
goto :goto_1
:cond_7
invoke-virtual {v0}, Landroidx/preference/PreferenceManager;->getNextId()J
move-result-wide v3
:goto_1
invoke-virtual {p1, v0, v3, v4}, Landroidx/preference/Preference;->onAttachedToHierarchy(Landroidx/preference/PreferenceManager;J)V
invoke-virtual {p1, p0}, Landroidx/preference/Preference;->assignParent(Landroidx/preference/PreferenceGroup;)V
iget-boolean v0, p0, Landroidx/preference/PreferenceGroup;->mAttachedToHierarchy:Z
if-eqz v0, :cond_8
invoke-virtual {p1}, Landroidx/preference/Preference;->onAttached()V
:cond_8
invoke-virtual {p0}, Landroidx/preference/Preference;->notifyHierarchyChanged()V
return v1
:catchall_0
move-exception p1
:try_start_1
monitor-exit p0
:try_end_1
.catchall {:try_start_1 .. :try_end_1} :catchall_0
throw p1
.end method
.method public dispatchRestoreInstanceState(Landroid/os/Bundle;)V
.locals 3
invoke-super {p0, p1}, Landroidx/preference/Preference;->dispatchRestoreInstanceState(Landroid/os/Bundle;)V
invoke-virtual {p0}, Landroidx/preference/PreferenceGroup;->getPreferenceCount()I
move-result v0
const/4 v1, 0x0
:goto_0
if-ge v1, v0, :cond_0
invoke-virtual {p0, v1}, Landroidx/preference/PreferenceGroup;->getPreference(I)Landroidx/preference/Preference;
move-result-object v2
invoke-virtual {v2, p1}, Landroidx/preference/Preference;->dispatchRestoreInstanceState(Landroid/os/Bundle;)V
add-int/lit8 v1, v1, 0x1
goto :goto_0
:cond_0
return-void
.end method
.method public dispatchSaveInstanceState(Landroid/os/Bundle;)V
.locals 3
invoke-super {p0, p1}, Landroidx/preference/Preference;->dispatchSaveInstanceState(Landroid/os/Bundle;)V
invoke-virtual {p0}, Landroidx/preference/PreferenceGroup;->getPreferenceCount()I
move-result v0
const/4 v1, 0x0
:goto_0
if-ge v1, v0, :cond_0
invoke-virtual {p0, v1}, Landroidx/preference/PreferenceGroup;->getPreference(I)Landroidx/preference/Preference;
move-result-object v2
invoke-virtual {v2, p1}, Landroidx/preference/Preference;->dispatchSaveInstanceState(Landroid/os/Bundle;)V
add-int/lit8 v1, v1, 0x1
goto :goto_0
:cond_0
return-void
.end method
.method public findPreference(Ljava/lang/CharSequence;)Landroidx/preference/Preference;
.locals 4
.param p1 # Ljava/lang/CharSequence;
.annotation build Landroidx/annotation/NonNull;
.end annotation
.end param
.annotation build Landroidx/annotation/Nullable;
.end annotation
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Landroidx/preference/Preference;",
">(",
"Ljava/lang/CharSequence;",
")TT;"
}
.end annotation
if-eqz p1, :cond_4
invoke-virtual {p0}, Landroidx/preference/Preference;->getKey()Ljava/lang/String;
move-result-object v0
invoke-static {v0, p1}, Landroid/text/TextUtils;->equals(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Z
move-result v0
if-eqz v0, :cond_0
return-object p0
:cond_0
invoke-virtual {p0}, Landroidx/preference/PreferenceGroup;->getPreferenceCount()I
move-result v0
const/4 v1, 0x0
:goto_0
if-ge v1, v0, :cond_3
invoke-virtual {p0, v1}, Landroidx/preference/PreferenceGroup;->getPreference(I)Landroidx/preference/Preference;
move-result-object v2
invoke-virtual {v2}, Landroidx/preference/Preference;->getKey()Ljava/lang/String;
move-result-object v3
invoke-static {v3, p1}, Landroid/text/TextUtils;->equals(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Z
move-result v3
if-eqz v3, :cond_1
return-object v2
:cond_1
instance-of v3, v2, Landroidx/preference/PreferenceGroup;
if-eqz v3, :cond_2
check-cast v2, Landroidx/preference/PreferenceGroup;
invoke-virtual {v2, p1}, Landroidx/preference/PreferenceGroup;->findPreference(Ljava/lang/CharSequence;)Landroidx/preference/Preference;
move-result-object v2
if-eqz v2, :cond_2
return-object v2
:cond_2
add-int/lit8 v1, v1, 0x1
goto :goto_0
:cond_3
const/4 p1, 0x0
return-object p1
:cond_4
new-instance p1, Ljava/lang/IllegalArgumentException;
const-string v0, "Key cannot be null"
invoke-direct {p1, v0}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
throw p1
.end method
.method public getInitialExpandedChildrenCount()I
.locals 1
iget v0, p0, Landroidx/preference/PreferenceGroup;->mInitialExpandedChildrenCount:I
return v0
.end method
.method public getOnExpandButtonClickListener()Landroidx/preference/PreferenceGroup$OnExpandButtonClickListener;
.locals 1
.annotation build Landroidx/annotation/Nullable;
.end annotation
.annotation build Landroidx/annotation/RestrictTo;
value = {
.enum Landroidx/annotation/RestrictTo$Scope;->LIBRARY_GROUP_PREFIX:Landroidx/annotation/RestrictTo$Scope;
}
.end annotation
iget-object v0, p0, Landroidx/preference/PreferenceGroup;->mOnExpandButtonClickListener:Landroidx/preference/PreferenceGroup$OnExpandButtonClickListener;
return-object v0
.end method
.method public getPreference(I)Landroidx/preference/Preference;
.locals 1
iget-object v0, p0, Landroidx/preference/PreferenceGroup;->mPreferences:Ljava/util/List;
invoke-interface {v0, p1}, Ljava/util/List;->get(I)Ljava/lang/Object;
move-result-object p1
check-cast p1, Landroidx/preference/Preference;
return-object p1
.end method
.method public getPreferenceCount()I
.locals 1
iget-object v0, p0, Landroidx/preference/PreferenceGroup;->mPreferences:Ljava/util/List;
invoke-interface {v0}, Ljava/util/List;->size()I
move-result v0
return v0
.end method
.method public isAttached()Z
.locals 1
.annotation build Landroidx/annotation/RestrictTo;
value = {
.enum Landroidx/annotation/RestrictTo$Scope;->LIBRARY:Landroidx/annotation/RestrictTo$Scope;
}
.end annotation
iget-boolean v0, p0, Landroidx/preference/PreferenceGroup;->mAttachedToHierarchy:Z
return v0
.end method
.method public isOnSameScreenAsChildren()Z
.locals 1
const/4 v0, 0x1
return v0
.end method
.method public isOrderingAsAdded()Z
.locals 1
iget-boolean v0, p0, Landroidx/preference/PreferenceGroup;->mOrderingAsAdded:Z
return v0
.end method
.method public notifyDependencyChange(Z)V
.locals 3
invoke-super {p0, p1}, Landroidx/preference/Preference;->notifyDependencyChange(Z)V
invoke-virtual {p0}, Landroidx/preference/PreferenceGroup;->getPreferenceCount()I
move-result v0
const/4 v1, 0x0
:goto_0
if-ge v1, v0, :cond_0
invoke-virtual {p0, v1}, Landroidx/preference/PreferenceGroup;->getPreference(I)Landroidx/preference/Preference;
move-result-object v2
invoke-virtual {v2, p0, p1}, Landroidx/preference/Preference;->onParentChanged(Landroidx/preference/Preference;Z)V
add-int/lit8 v1, v1, 0x1
goto :goto_0
:cond_0
return-void
.end method
.method public onAttached()V
.locals 3
invoke-super {p0}, Landroidx/preference/Preference;->onAttached()V
const/4 v0, 0x1
iput-boolean v0, p0, Landroidx/preference/PreferenceGroup;->mAttachedToHierarchy:Z
invoke-virtual {p0}, Landroidx/preference/PreferenceGroup;->getPreferenceCount()I
move-result v0
const/4 v1, 0x0
:goto_0
if-ge v1, v0, :cond_0
invoke-virtual {p0, v1}, Landroidx/preference/PreferenceGroup;->getPreference(I)Landroidx/preference/Preference;
move-result-object v2
invoke-virtual {v2}, Landroidx/preference/Preference;->onAttached()V
add-int/lit8 v1, v1, 0x1
goto :goto_0
:cond_0
return-void
.end method
.method public onDetached()V
.locals 3
invoke-super {p0}, Landroidx/preference/Preference;->onDetached()V
const/4 v0, 0x0
iput-boolean v0, p0, Landroidx/preference/PreferenceGroup;->mAttachedToHierarchy:Z
invoke-virtual {p0}, Landroidx/preference/PreferenceGroup;->getPreferenceCount()I
move-result v1
:goto_0
if-ge v0, v1, :cond_0
invoke-virtual {p0, v0}, Landroidx/preference/PreferenceGroup;->getPreference(I)Landroidx/preference/Preference;
move-result-object v2
invoke-virtual {v2}, Landroidx/preference/Preference;->onDetached()V
add-int/lit8 v0, v0, 0x1
goto :goto_0
:cond_0
return-void
.end method
.method public onPrepareAddPreference(Landroidx/preference/Preference;)Z
.locals 1
invoke-virtual {p0}, Landroidx/preference/Preference;->shouldDisableDependents()Z
move-result v0
invoke-virtual {p1, p0, v0}, Landroidx/preference/Preference;->onParentChanged(Landroidx/preference/Preference;Z)V
const/4 p1, 0x1
return p1
.end method
.method public onRestoreInstanceState(Landroid/os/Parcelable;)V
.locals 2
if-eqz p1, :cond_1
invoke-virtual {p1}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
move-result-object v0
const-class v1, Landroidx/preference/PreferenceGroup$SavedState;
invoke-virtual {v0, v1}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z
move-result v0
if-nez v0, :cond_0
goto :goto_0
:cond_0
check-cast p1, Landroidx/preference/PreferenceGroup$SavedState;
iget v0, p1, Landroidx/preference/PreferenceGroup$SavedState;->mInitialExpandedChildrenCount:I
iput v0, p0, Landroidx/preference/PreferenceGroup;->mInitialExpandedChildrenCount:I
invoke-virtual {p1}, Landroid/view/AbsSavedState;->getSuperState()Landroid/os/Parcelable;
move-result-object p1
invoke-super {p0, p1}, Landroidx/preference/Preference;->onRestoreInstanceState(Landroid/os/Parcelable;)V
return-void
:cond_1
:goto_0
invoke-super {p0, p1}, Landroidx/preference/Preference;->onRestoreInstanceState(Landroid/os/Parcelable;)V
return-void
.end method
.method public onSaveInstanceState()Landroid/os/Parcelable;
.locals 3
invoke-super {p0}, Landroidx/preference/Preference;->onSaveInstanceState()Landroid/os/Parcelable;
move-result-object v0
new-instance v1, Landroidx/preference/PreferenceGroup$SavedState;
iget v2, p0, Landroidx/preference/PreferenceGroup;->mInitialExpandedChildrenCount:I
invoke-direct {v1, v0, v2}, Landroidx/preference/PreferenceGroup$SavedState;-><init>(Landroid/os/Parcelable;I)V
return-object v1
.end method
.method public removeAll()V
.locals 3
monitor-enter p0
:try_start_0
iget-object v0, p0, Landroidx/preference/PreferenceGroup;->mPreferences:Ljava/util/List;
invoke-interface {v0}, Ljava/util/List;->size()I
move-result v1
add-int/lit8 v1, v1, -0x1
:goto_0
if-ltz v1, :cond_0
const/4 v2, 0x0
invoke-interface {v0, v2}, Ljava/util/List;->get(I)Ljava/lang/Object;
move-result-object v2
check-cast v2, Landroidx/preference/Preference;
invoke-direct {p0, v2}, Landroidx/preference/PreferenceGroup;->removePreferenceInt(Landroidx/preference/Preference;)Z
add-int/lit8 v1, v1, -0x1
goto :goto_0
:cond_0
monitor-exit p0
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
invoke-virtual {p0}, Landroidx/preference/Preference;->notifyHierarchyChanged()V
return-void
:catchall_0
move-exception v0
:try_start_1
monitor-exit p0
:try_end_1
.catchall {:try_start_1 .. :try_end_1} :catchall_0
throw v0
.end method
.method public removePreference(Landroidx/preference/Preference;)Z
.locals 0
invoke-direct {p0, p1}, Landroidx/preference/PreferenceGroup;->removePreferenceInt(Landroidx/preference/Preference;)Z
move-result p1
invoke-virtual {p0}, Landroidx/preference/Preference;->notifyHierarchyChanged()V
return p1
.end method
.method public removePreferenceRecursively(Ljava/lang/CharSequence;)Z
.locals 1
.param p1 # Ljava/lang/CharSequence;
.annotation build Landroidx/annotation/NonNull;
.end annotation
.end param
invoke-virtual {p0, p1}, Landroidx/preference/PreferenceGroup;->findPreference(Ljava/lang/CharSequence;)Landroidx/preference/Preference;
move-result-object p1
if-nez p1, :cond_0
const/4 p1, 0x0
return p1
:cond_0
invoke-virtual {p1}, Landroidx/preference/Preference;->getParent()Landroidx/preference/PreferenceGroup;
move-result-object v0
invoke-virtual {v0, p1}, Landroidx/preference/PreferenceGroup;->removePreference(Landroidx/preference/Preference;)Z
move-result p1
return p1
.end method
.method public setInitialExpandedChildrenCount(I)V
.locals 2
const v0, 0x7fffffff
if-eq p1, v0, :cond_0
invoke-virtual {p0}, Landroidx/preference/Preference;->hasKey()Z
move-result v0
if-nez v0, :cond_0
new-instance v0, Ljava/lang/StringBuilder;
invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V
invoke-virtual {p0}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
move-result-object v1
invoke-virtual {v1}, Ljava/lang/Class;->getSimpleName()Ljava/lang/String;
move-result-object v1
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
const-string v1, " should have a key defined if it contains an expandable preference"
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v0
const-string v1, "PreferenceGroup"
invoke-static {v1, v0}, Landroid/util/Log;->e(Ljava/lang/String;Ljava/lang/String;)I
:cond_0
iput p1, p0, Landroidx/preference/PreferenceGroup;->mInitialExpandedChildrenCount:I
return-void
.end method
.method public setOnExpandButtonClickListener(Landroidx/preference/PreferenceGroup$OnExpandButtonClickListener;)V
.locals 0
.param p1 # Landroidx/preference/PreferenceGroup$OnExpandButtonClickListener;
.annotation build Landroidx/annotation/Nullable;
.end annotation
.end param
.annotation build Landroidx/annotation/RestrictTo;
value = {
.enum Landroidx/annotation/RestrictTo$Scope;->LIBRARY_GROUP_PREFIX:Landroidx/annotation/RestrictTo$Scope;
}
.end annotation
iput-object p1, p0, Landroidx/preference/PreferenceGroup;->mOnExpandButtonClickListener:Landroidx/preference/PreferenceGroup$OnExpandButtonClickListener;
return-void
.end method
.method public setOrderingAsAdded(Z)V
.locals 0
iput-boolean p1, p0, Landroidx/preference/PreferenceGroup;->mOrderingAsAdded:Z
return-void
.end method
.method public sortPreferences()V
.locals 1
monitor-enter p0
:try_start_0
iget-object v0, p0, Landroidx/preference/PreferenceGroup;->mPreferences:Ljava/util/List;
invoke-static {v0}, Ljava/util/Collections;->sort(Ljava/util/List;)V
monitor-exit p0
return-void
:catchall_0
move-exception v0
monitor-exit p0
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
throw v0
.end method