mirror of
https://github.com/Pinball3D/Rabbit-R1.git
synced 2025-01-09 13:43:22 +00:00
2101 lines
67 KiB
Smali
2101 lines
67 KiB
Smali
.class public final Landroidx/viewpager2/widget/ViewPager2;
|
|
.super Landroid/view/ViewGroup;
|
|
.source "ViewPager2.java"
|
|
|
|
|
|
# annotations
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
value = {
|
|
Landroidx/viewpager2/widget/ViewPager2$PageAwareAccessibilityProvider;,
|
|
Landroidx/viewpager2/widget/ViewPager2$BasicAccessibilityProvider;,
|
|
Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;,
|
|
Landroidx/viewpager2/widget/ViewPager2$RecyclerViewImpl;,
|
|
Landroidx/viewpager2/widget/ViewPager2$LinearLayoutManagerImpl;,
|
|
Landroidx/viewpager2/widget/ViewPager2$PagerSnapHelperImpl;,
|
|
Landroidx/viewpager2/widget/ViewPager2$OnPageChangeCallback;,
|
|
Landroidx/viewpager2/widget/ViewPager2$SavedState;,
|
|
Landroidx/viewpager2/widget/ViewPager2$SmoothScrollToPosition;,
|
|
Landroidx/viewpager2/widget/ViewPager2$PageTransformer;,
|
|
Landroidx/viewpager2/widget/ViewPager2$DataSetChangeObserver;,
|
|
Landroidx/viewpager2/widget/ViewPager2$OffscreenPageLimit;,
|
|
Landroidx/viewpager2/widget/ViewPager2$ScrollState;,
|
|
Landroidx/viewpager2/widget/ViewPager2$Orientation;
|
|
}
|
|
.end annotation
|
|
|
|
|
|
# static fields
|
|
.field public static final OFFSCREEN_PAGE_LIMIT_DEFAULT:I = -0x1
|
|
|
|
.field public static final ORIENTATION_HORIZONTAL:I = 0x0
|
|
|
|
.field public static final ORIENTATION_VERTICAL:I = 0x1
|
|
|
|
.field public static final SCROLL_STATE_DRAGGING:I = 0x1
|
|
|
|
.field public static final SCROLL_STATE_IDLE:I = 0x0
|
|
|
|
.field public static final SCROLL_STATE_SETTLING:I = 0x2
|
|
|
|
.field static sFeatureEnhancedA11yEnabled:Z = true
|
|
|
|
|
|
# instance fields
|
|
.field mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.field mCurrentItem:I
|
|
|
|
.field private mCurrentItemDataSetChangeObserver:Landroidx/recyclerview/widget/RecyclerView$AdapterDataObserver;
|
|
|
|
.field mCurrentItemDirty:Z
|
|
|
|
.field private mExternalPageChangeCallbacks:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
.field private mFakeDragger:Landroidx/viewpager2/widget/FakeDrag;
|
|
|
|
.field mLayoutManager:Landroidx/recyclerview/widget/LinearLayoutManager;
|
|
|
|
.field private mOffscreenPageLimit:I
|
|
|
|
.field private mPageChangeEventDispatcher:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
.field private mPageTransformerAdapter:Landroidx/viewpager2/widget/PageTransformerAdapter;
|
|
|
|
.field private mPagerSnapHelper:Landroidx/recyclerview/widget/PagerSnapHelper;
|
|
|
|
.field private mPendingAdapterState:Landroid/os/Parcelable;
|
|
|
|
.field private mPendingCurrentItem:I
|
|
|
|
.field mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.field private mSavedItemAnimator:Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;
|
|
|
|
.field private mSavedItemAnimatorPresent:Z
|
|
|
|
.field mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
.field private final mTmpChildRect:Landroid/graphics/Rect;
|
|
|
|
.field private final mTmpContainerRect:Landroid/graphics/Rect;
|
|
|
|
.field private mUserInputEnabled:Z
|
|
|
|
|
|
# direct methods
|
|
.method static constructor <clinit>()V
|
|
.locals 0
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Landroid/content/Context;)V
|
|
.locals 3
|
|
|
|
.line 163
|
|
invoke-direct {p0, p1}, Landroid/view/ViewGroup;-><init>(Landroid/content/Context;)V
|
|
|
|
.line 130
|
|
new-instance v0, Landroid/graphics/Rect;
|
|
|
|
invoke-direct {v0}, Landroid/graphics/Rect;-><init>()V
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpContainerRect:Landroid/graphics/Rect;
|
|
|
|
.line 131
|
|
new-instance v0, Landroid/graphics/Rect;
|
|
|
|
invoke-direct {v0}, Landroid/graphics/Rect;-><init>()V
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpChildRect:Landroid/graphics/Rect;
|
|
|
|
.line 133
|
|
new-instance v0, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
const/4 v1, 0x3
|
|
|
|
invoke-direct {v0, v1}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;-><init>(I)V
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mExternalPageChangeCallbacks:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
const/4 v0, 0x0
|
|
|
|
iput-boolean v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDirty:Z
|
|
|
|
.line 138
|
|
new-instance v1, Landroidx/viewpager2/widget/ViewPager2$1;
|
|
|
|
invoke-direct {v1, p0}, Landroidx/viewpager2/widget/ViewPager2$1;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
iput-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDataSetChangeObserver:Landroidx/recyclerview/widget/RecyclerView$AdapterDataObserver;
|
|
|
|
const/4 v1, -0x1
|
|
|
|
iput v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
const/4 v2, 0x0
|
|
|
|
iput-object v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimator:Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;
|
|
|
|
iput-boolean v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimatorPresent:Z
|
|
|
|
const/4 v0, 0x1
|
|
|
|
iput-boolean v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mUserInputEnabled:Z
|
|
|
|
iput v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mOffscreenPageLimit:I
|
|
|
|
.line 164
|
|
invoke-direct {p0, p1, v2}, Landroidx/viewpager2/widget/ViewPager2;->initialize(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
.locals 3
|
|
|
|
.line 168
|
|
invoke-direct {p0, p1, p2}, Landroid/view/ViewGroup;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
|
|
.line 130
|
|
new-instance v0, Landroid/graphics/Rect;
|
|
|
|
invoke-direct {v0}, Landroid/graphics/Rect;-><init>()V
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpContainerRect:Landroid/graphics/Rect;
|
|
|
|
.line 131
|
|
new-instance v0, Landroid/graphics/Rect;
|
|
|
|
invoke-direct {v0}, Landroid/graphics/Rect;-><init>()V
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpChildRect:Landroid/graphics/Rect;
|
|
|
|
.line 133
|
|
new-instance v0, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
const/4 v1, 0x3
|
|
|
|
invoke-direct {v0, v1}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;-><init>(I)V
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mExternalPageChangeCallbacks:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
const/4 v0, 0x0
|
|
|
|
iput-boolean v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDirty:Z
|
|
|
|
.line 138
|
|
new-instance v1, Landroidx/viewpager2/widget/ViewPager2$1;
|
|
|
|
invoke-direct {v1, p0}, Landroidx/viewpager2/widget/ViewPager2$1;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
iput-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDataSetChangeObserver:Landroidx/recyclerview/widget/RecyclerView$AdapterDataObserver;
|
|
|
|
const/4 v1, -0x1
|
|
|
|
iput v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
const/4 v2, 0x0
|
|
|
|
iput-object v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimator:Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;
|
|
|
|
iput-boolean v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimatorPresent:Z
|
|
|
|
const/4 v0, 0x1
|
|
|
|
iput-boolean v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mUserInputEnabled:Z
|
|
|
|
iput v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mOffscreenPageLimit:I
|
|
|
|
.line 169
|
|
invoke-direct {p0, p1, p2}, Landroidx/viewpager2/widget/ViewPager2;->initialize(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
|
|
.locals 2
|
|
|
|
.line 173
|
|
invoke-direct {p0, p1, p2, p3}, Landroid/view/ViewGroup;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;I)V
|
|
|
|
.line 130
|
|
new-instance p3, Landroid/graphics/Rect;
|
|
|
|
invoke-direct {p3}, Landroid/graphics/Rect;-><init>()V
|
|
|
|
iput-object p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpContainerRect:Landroid/graphics/Rect;
|
|
|
|
.line 131
|
|
new-instance p3, Landroid/graphics/Rect;
|
|
|
|
invoke-direct {p3}, Landroid/graphics/Rect;-><init>()V
|
|
|
|
iput-object p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpChildRect:Landroid/graphics/Rect;
|
|
|
|
.line 133
|
|
new-instance p3, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
const/4 v0, 0x3
|
|
|
|
invoke-direct {p3, v0}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;-><init>(I)V
|
|
|
|
iput-object p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mExternalPageChangeCallbacks:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
const/4 p3, 0x0
|
|
|
|
iput-boolean p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDirty:Z
|
|
|
|
.line 138
|
|
new-instance v0, Landroidx/viewpager2/widget/ViewPager2$1;
|
|
|
|
invoke-direct {v0, p0}, Landroidx/viewpager2/widget/ViewPager2$1;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDataSetChangeObserver:Landroidx/recyclerview/widget/RecyclerView$AdapterDataObserver;
|
|
|
|
const/4 v0, -0x1
|
|
|
|
iput v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
const/4 v1, 0x0
|
|
|
|
iput-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimator:Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;
|
|
|
|
iput-boolean p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimatorPresent:Z
|
|
|
|
const/4 p3, 0x1
|
|
|
|
iput-boolean p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mUserInputEnabled:Z
|
|
|
|
iput v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mOffscreenPageLimit:I
|
|
|
|
.line 174
|
|
invoke-direct {p0, p1, p2}, Landroidx/viewpager2/widget/ViewPager2;->initialize(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;II)V
|
|
.locals 1
|
|
|
|
.line 181
|
|
invoke-direct {p0, p1, p2, p3, p4}, Landroid/view/ViewGroup;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;II)V
|
|
|
|
.line 130
|
|
new-instance p3, Landroid/graphics/Rect;
|
|
|
|
invoke-direct {p3}, Landroid/graphics/Rect;-><init>()V
|
|
|
|
iput-object p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpContainerRect:Landroid/graphics/Rect;
|
|
|
|
.line 131
|
|
new-instance p3, Landroid/graphics/Rect;
|
|
|
|
invoke-direct {p3}, Landroid/graphics/Rect;-><init>()V
|
|
|
|
iput-object p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpChildRect:Landroid/graphics/Rect;
|
|
|
|
.line 133
|
|
new-instance p3, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
const/4 p4, 0x3
|
|
|
|
invoke-direct {p3, p4}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;-><init>(I)V
|
|
|
|
iput-object p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mExternalPageChangeCallbacks:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
const/4 p3, 0x0
|
|
|
|
iput-boolean p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDirty:Z
|
|
|
|
.line 138
|
|
new-instance p4, Landroidx/viewpager2/widget/ViewPager2$1;
|
|
|
|
invoke-direct {p4, p0}, Landroidx/viewpager2/widget/ViewPager2$1;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
iput-object p4, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDataSetChangeObserver:Landroidx/recyclerview/widget/RecyclerView$AdapterDataObserver;
|
|
|
|
const/4 p4, -0x1
|
|
|
|
iput p4, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
const/4 v0, 0x0
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimator:Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;
|
|
|
|
iput-boolean p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimatorPresent:Z
|
|
|
|
const/4 p3, 0x1
|
|
|
|
iput-boolean p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mUserInputEnabled:Z
|
|
|
|
iput p4, p0, Landroidx/viewpager2/widget/ViewPager2;->mOffscreenPageLimit:I
|
|
|
|
.line 182
|
|
invoke-direct {p0, p1, p2}, Landroidx/viewpager2/widget/ViewPager2;->initialize(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private enforceChildFillListener()Landroidx/recyclerview/widget/RecyclerView$OnChildAttachStateChangeListener;
|
|
.locals 1
|
|
|
|
.line 270
|
|
new-instance v0, Landroidx/viewpager2/widget/ViewPager2$4;
|
|
|
|
invoke-direct {v0, p0}, Landroidx/viewpager2/widget/ViewPager2$4;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method private initialize(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
.locals 2
|
|
|
|
sget-boolean v0, Landroidx/viewpager2/widget/ViewPager2;->sFeatureEnhancedA11yEnabled:Z
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
.line 187
|
|
new-instance v0, Landroidx/viewpager2/widget/ViewPager2$PageAwareAccessibilityProvider;
|
|
|
|
invoke-direct {v0, p0}, Landroidx/viewpager2/widget/ViewPager2$PageAwareAccessibilityProvider;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
goto :goto_0
|
|
|
|
.line 188
|
|
:cond_0
|
|
new-instance v0, Landroidx/viewpager2/widget/ViewPager2$BasicAccessibilityProvider;
|
|
|
|
invoke-direct {v0, p0}, Landroidx/viewpager2/widget/ViewPager2$BasicAccessibilityProvider;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
:goto_0
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 190
|
|
new-instance v0, Landroidx/viewpager2/widget/ViewPager2$RecyclerViewImpl;
|
|
|
|
invoke-direct {v0, p0, p1}, Landroidx/viewpager2/widget/ViewPager2$RecyclerViewImpl;-><init>(Landroidx/viewpager2/widget/ViewPager2;Landroid/content/Context;)V
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 191
|
|
invoke-static {}, Landroidx/core/view/ViewCompat;->generateViewId()I
|
|
|
|
move-result v1
|
|
|
|
invoke-virtual {v0, v1}, Landroidx/recyclerview/widget/RecyclerView;->setId(I)V
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
const/high16 v1, 0x20000
|
|
|
|
.line 192
|
|
invoke-virtual {v0, v1}, Landroidx/recyclerview/widget/RecyclerView;->setDescendantFocusability(I)V
|
|
|
|
.line 194
|
|
new-instance v0, Landroidx/viewpager2/widget/ViewPager2$LinearLayoutManagerImpl;
|
|
|
|
invoke-direct {v0, p0, p1}, Landroidx/viewpager2/widget/ViewPager2$LinearLayoutManagerImpl;-><init>(Landroidx/viewpager2/widget/ViewPager2;Landroid/content/Context;)V
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mLayoutManager:Landroidx/recyclerview/widget/LinearLayoutManager;
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 195
|
|
invoke-virtual {v1, v0}, Landroidx/recyclerview/widget/RecyclerView;->setLayoutManager(Landroidx/recyclerview/widget/RecyclerView$LayoutManager;)V
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
const/4 v1, 0x1
|
|
|
|
.line 196
|
|
invoke-virtual {v0, v1}, Landroidx/recyclerview/widget/RecyclerView;->setScrollingTouchSlop(I)V
|
|
|
|
.line 197
|
|
invoke-direct {p0, p1, p2}, Landroidx/viewpager2/widget/ViewPager2;->setOrientation(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
|
|
iget-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 199
|
|
new-instance p2, Landroid/view/ViewGroup$LayoutParams;
|
|
|
|
const/4 v0, -0x1
|
|
|
|
invoke-direct {p2, v0, v0}, Landroid/view/ViewGroup$LayoutParams;-><init>(II)V
|
|
|
|
invoke-virtual {p1, p2}, Landroidx/recyclerview/widget/RecyclerView;->setLayoutParams(Landroid/view/ViewGroup$LayoutParams;)V
|
|
|
|
iget-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 201
|
|
invoke-direct {p0}, Landroidx/viewpager2/widget/ViewPager2;->enforceChildFillListener()Landroidx/recyclerview/widget/RecyclerView$OnChildAttachStateChangeListener;
|
|
|
|
move-result-object p2
|
|
|
|
invoke-virtual {p1, p2}, Landroidx/recyclerview/widget/RecyclerView;->addOnChildAttachStateChangeListener(Landroidx/recyclerview/widget/RecyclerView$OnChildAttachStateChangeListener;)V
|
|
|
|
.line 205
|
|
new-instance p1, Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
invoke-direct {p1, p0}, Landroidx/viewpager2/widget/ScrollEventAdapter;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
iput-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
.line 207
|
|
new-instance p1, Landroidx/viewpager2/widget/FakeDrag;
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
invoke-direct {p1, p0, p2, v0}, Landroidx/viewpager2/widget/FakeDrag;-><init>(Landroidx/viewpager2/widget/ViewPager2;Landroidx/viewpager2/widget/ScrollEventAdapter;Landroidx/recyclerview/widget/RecyclerView;)V
|
|
|
|
iput-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mFakeDragger:Landroidx/viewpager2/widget/FakeDrag;
|
|
|
|
.line 208
|
|
new-instance p1, Landroidx/viewpager2/widget/ViewPager2$PagerSnapHelperImpl;
|
|
|
|
invoke-direct {p1, p0}, Landroidx/viewpager2/widget/ViewPager2$PagerSnapHelperImpl;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
iput-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPagerSnapHelper:Landroidx/recyclerview/widget/PagerSnapHelper;
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 209
|
|
invoke-virtual {p1, p2}, Landroidx/recyclerview/widget/PagerSnapHelper;->attachToRecyclerView(Landroidx/recyclerview/widget/RecyclerView;)V
|
|
|
|
iget-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
.line 212
|
|
invoke-virtual {p1, p2}, Landroidx/recyclerview/widget/RecyclerView;->addOnScrollListener(Landroidx/recyclerview/widget/RecyclerView$OnScrollListener;)V
|
|
|
|
.line 214
|
|
new-instance p1, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
const/4 p2, 0x3
|
|
|
|
invoke-direct {p1, p2}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;-><init>(I)V
|
|
|
|
iput-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageChangeEventDispatcher:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
.line 215
|
|
invoke-virtual {p2, p1}, Landroidx/viewpager2/widget/ScrollEventAdapter;->setOnPageChangeCallback(Landroidx/viewpager2/widget/ViewPager2$OnPageChangeCallback;)V
|
|
|
|
.line 219
|
|
new-instance p1, Landroidx/viewpager2/widget/ViewPager2$2;
|
|
|
|
invoke-direct {p1, p0}, Landroidx/viewpager2/widget/ViewPager2$2;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
.line 237
|
|
new-instance p2, Landroidx/viewpager2/widget/ViewPager2$3;
|
|
|
|
invoke-direct {p2, p0}, Landroidx/viewpager2/widget/ViewPager2$3;-><init>(Landroidx/viewpager2/widget/ViewPager2;)V
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageChangeEventDispatcher:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
.line 249
|
|
invoke-virtual {v0, p1}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;->addOnPageChangeCallback(Landroidx/viewpager2/widget/ViewPager2$OnPageChangeCallback;)V
|
|
|
|
iget-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageChangeEventDispatcher:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
.line 250
|
|
invoke-virtual {p1, p2}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;->addOnPageChangeCallback(Landroidx/viewpager2/widget/ViewPager2$OnPageChangeCallback;)V
|
|
|
|
iget-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageChangeEventDispatcher:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 253
|
|
invoke-virtual {p1, p2, v0}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onInitialize(Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;Landroidx/recyclerview/widget/RecyclerView;)V
|
|
|
|
iget-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageChangeEventDispatcher:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mExternalPageChangeCallbacks:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
.line 254
|
|
invoke-virtual {p1, p2}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;->addOnPageChangeCallback(Landroidx/viewpager2/widget/ViewPager2$OnPageChangeCallback;)V
|
|
|
|
.line 258
|
|
new-instance p1, Landroidx/viewpager2/widget/PageTransformerAdapter;
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mLayoutManager:Landroidx/recyclerview/widget/LinearLayoutManager;
|
|
|
|
invoke-direct {p1, p2}, Landroidx/viewpager2/widget/PageTransformerAdapter;-><init>(Landroidx/recyclerview/widget/LinearLayoutManager;)V
|
|
|
|
iput-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageTransformerAdapter:Landroidx/viewpager2/widget/PageTransformerAdapter;
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageChangeEventDispatcher:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
.line 259
|
|
invoke-virtual {p2, p1}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;->addOnPageChangeCallback(Landroidx/viewpager2/widget/ViewPager2$OnPageChangeCallback;)V
|
|
|
|
iget-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
const/4 p2, 0x0
|
|
|
|
.line 261
|
|
invoke-virtual {p1}, Landroidx/recyclerview/widget/RecyclerView;->getLayoutParams()Landroid/view/ViewGroup$LayoutParams;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-virtual {p0, p1, p2, v0}, Landroidx/viewpager2/widget/ViewPager2;->attachViewToParent(Landroid/view/View;ILandroid/view/ViewGroup$LayoutParams;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private registerCurrentItemDataSetTracker(Landroidx/recyclerview/widget/RecyclerView$Adapter;)V
|
|
.locals 0
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Landroidx/recyclerview/widget/RecyclerView$Adapter<",
|
|
"*>;)V"
|
|
}
|
|
.end annotation
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDataSetChangeObserver:Landroidx/recyclerview/widget/RecyclerView$AdapterDataObserver;
|
|
|
|
.line 478
|
|
invoke-virtual {p1, p0}, Landroidx/recyclerview/widget/RecyclerView$Adapter;->registerAdapterDataObserver(Landroidx/recyclerview/widget/RecyclerView$AdapterDataObserver;)V
|
|
|
|
:cond_0
|
|
return-void
|
|
.end method
|
|
|
|
.method private restorePendingState()V
|
|
.locals 4
|
|
|
|
iget v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
const/4 v1, -0x1
|
|
|
|
if-ne v0, v1, :cond_0
|
|
|
|
return-void
|
|
|
|
.line 350
|
|
:cond_0
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getAdapter()Landroidx/recyclerview/widget/RecyclerView$Adapter;
|
|
|
|
move-result-object v0
|
|
|
|
if-nez v0, :cond_1
|
|
|
|
return-void
|
|
|
|
:cond_1
|
|
iget-object v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingAdapterState:Landroid/os/Parcelable;
|
|
|
|
if-eqz v2, :cond_3
|
|
|
|
.line 355
|
|
instance-of v3, v0, Landroidx/viewpager2/adapter/StatefulAdapter;
|
|
|
|
if-eqz v3, :cond_2
|
|
|
|
.line 356
|
|
move-object v3, v0
|
|
|
|
check-cast v3, Landroidx/viewpager2/adapter/StatefulAdapter;
|
|
|
|
invoke-interface {v3, v2}, Landroidx/viewpager2/adapter/StatefulAdapter;->restoreState(Landroid/os/Parcelable;)V
|
|
|
|
:cond_2
|
|
const/4 v2, 0x0
|
|
|
|
iput-object v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingAdapterState:Landroid/os/Parcelable;
|
|
|
|
:cond_3
|
|
iget v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
.line 361
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView$Adapter;->getItemCount()I
|
|
|
|
move-result v0
|
|
|
|
add-int/lit8 v0, v0, -0x1
|
|
|
|
invoke-static {v2, v0}, Ljava/lang/Math;->min(II)I
|
|
|
|
move-result v0
|
|
|
|
const/4 v2, 0x0
|
|
|
|
invoke-static {v2, v0}, Ljava/lang/Math;->max(II)I
|
|
|
|
move-result v0
|
|
|
|
iput v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItem:I
|
|
|
|
iput v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 363
|
|
invoke-virtual {v1, v0}, Landroidx/recyclerview/widget/RecyclerView;->scrollToPosition(I)V
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 364
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onRestorePendingState()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method private setOrientation(Landroid/content/Context;Landroid/util/AttributeSet;)V
|
|
.locals 8
|
|
|
|
.line 299
|
|
sget-object v0, Landroidx/viewpager2/R$styleable;->ViewPager2:[I
|
|
|
|
invoke-virtual {p1, p2, v0}, Landroid/content/Context;->obtainStyledAttributes(Landroid/util/AttributeSet;[I)Landroid/content/res/TypedArray;
|
|
|
|
move-result-object v0
|
|
|
|
.line 300
|
|
sget-object v3, Landroidx/viewpager2/R$styleable;->ViewPager2:[I
|
|
|
|
const/4 v6, 0x0
|
|
|
|
const/4 v7, 0x0
|
|
|
|
move-object v1, p0
|
|
|
|
move-object v2, p1
|
|
|
|
move-object v4, p2
|
|
|
|
move-object v5, v0
|
|
|
|
invoke-static/range {v1 .. v7}, Landroidx/core/view/ViewCompat;->saveAttributeDataForStyleable(Landroid/view/View;Landroid/content/Context;[ILandroid/util/AttributeSet;Landroid/content/res/TypedArray;II)V
|
|
|
|
.line 303
|
|
:try_start_0
|
|
sget p1, Landroidx/viewpager2/R$styleable;->ViewPager2_android_orientation:I
|
|
|
|
const/4 p2, 0x0
|
|
|
|
.line 304
|
|
invoke-virtual {v0, p1, p2}, Landroid/content/res/TypedArray;->getInt(II)I
|
|
|
|
move-result p1
|
|
|
|
.line 303
|
|
invoke-virtual {p0, p1}, Landroidx/viewpager2/widget/ViewPager2;->setOrientation(I)V
|
|
:try_end_0
|
|
.catchall {:try_start_0 .. :try_end_0} :catchall_0
|
|
|
|
.line 306
|
|
invoke-virtual {v0}, Landroid/content/res/TypedArray;->recycle()V
|
|
|
|
return-void
|
|
|
|
:catchall_0
|
|
move-exception p0
|
|
|
|
invoke-virtual {v0}, Landroid/content/res/TypedArray;->recycle()V
|
|
|
|
.line 307
|
|
throw p0
|
|
.end method
|
|
|
|
.method private unregisterCurrentItemDataSetTracker(Landroidx/recyclerview/widget/RecyclerView$Adapter;)V
|
|
.locals 0
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Landroidx/recyclerview/widget/RecyclerView$Adapter<",
|
|
"*>;)V"
|
|
}
|
|
.end annotation
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDataSetChangeObserver:Landroidx/recyclerview/widget/RecyclerView$AdapterDataObserver;
|
|
|
|
.line 484
|
|
invoke-virtual {p1, p0}, Landroidx/recyclerview/widget/RecyclerView$Adapter;->unregisterAdapterDataObserver(Landroidx/recyclerview/widget/RecyclerView$AdapterDataObserver;)V
|
|
|
|
:cond_0
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public addItemDecoration(Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;)V
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 1159
|
|
invoke-virtual {p0, p1}, Landroidx/recyclerview/widget/RecyclerView;->addItemDecoration(Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public addItemDecoration(Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;I)V
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 1178
|
|
invoke-virtual {p0, p1, p2}, Landroidx/recyclerview/widget/RecyclerView;->addItemDecoration(Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public beginFakeDrag()Z
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mFakeDragger:Landroidx/viewpager2/widget/FakeDrag;
|
|
|
|
.line 720
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/FakeDrag;->beginFakeDrag()Z
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public canScrollHorizontally(I)Z
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 862
|
|
invoke-virtual {p0, p1}, Landroidx/recyclerview/widget/RecyclerView;->canScrollHorizontally(I)Z
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public canScrollVertically(I)Z
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 867
|
|
invoke-virtual {p0, p1}, Landroidx/recyclerview/widget/RecyclerView;->canScrollVertically(I)Z
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method protected dispatchRestoreInstanceState(Landroid/util/SparseArray;)V
|
|
.locals 3
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
value = {
|
|
"(",
|
|
"Landroid/util/SparseArray<",
|
|
"Landroid/os/Parcelable;",
|
|
">;)V"
|
|
}
|
|
.end annotation
|
|
|
|
.line 370
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getId()I
|
|
|
|
move-result v0
|
|
|
|
invoke-virtual {p1, v0}, Landroid/util/SparseArray;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v0
|
|
|
|
check-cast v0, Landroid/os/Parcelable;
|
|
|
|
.line 371
|
|
instance-of v1, v0, Landroidx/viewpager2/widget/ViewPager2$SavedState;
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
.line 372
|
|
check-cast v0, Landroidx/viewpager2/widget/ViewPager2$SavedState;
|
|
|
|
iget v0, v0, Landroidx/viewpager2/widget/ViewPager2$SavedState;->mRecyclerViewId:I
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 373
|
|
invoke-virtual {v1}, Landroidx/recyclerview/widget/RecyclerView;->getId()I
|
|
|
|
move-result v1
|
|
|
|
.line 374
|
|
invoke-virtual {p1, v0}, Landroid/util/SparseArray;->get(I)Ljava/lang/Object;
|
|
|
|
move-result-object v2
|
|
|
|
check-cast v2, Landroid/os/Parcelable;
|
|
|
|
invoke-virtual {p1, v1, v2}, Landroid/util/SparseArray;->put(ILjava/lang/Object;)V
|
|
|
|
.line 375
|
|
invoke-virtual {p1, v0}, Landroid/util/SparseArray;->remove(I)V
|
|
|
|
.line 378
|
|
:cond_0
|
|
invoke-super {p0, p1}, Landroid/view/ViewGroup;->dispatchRestoreInstanceState(Landroid/util/SparseArray;)V
|
|
|
|
.line 381
|
|
invoke-direct {p0}, Landroidx/viewpager2/widget/ViewPager2;->restorePendingState()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public endFakeDrag()Z
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mFakeDragger:Landroidx/viewpager2/widget/FakeDrag;
|
|
|
|
.line 756
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/FakeDrag;->endFakeDrag()Z
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public fakeDragBy(F)Z
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mFakeDragger:Landroidx/viewpager2/widget/FakeDrag;
|
|
|
|
.line 742
|
|
invoke-virtual {p0, p1}, Landroidx/viewpager2/widget/FakeDrag;->fakeDragBy(F)Z
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public getAccessibilityClassName()Ljava/lang/CharSequence;
|
|
.locals 1
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 292
|
|
invoke-virtual {v0}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->handlesGetAccessibilityClassName()Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 293
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onGetAccessibilityClassName()Ljava/lang/String;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
|
|
.line 295
|
|
:cond_0
|
|
invoke-super {p0}, Landroid/view/ViewGroup;->getAccessibilityClassName()Ljava/lang/CharSequence;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public getAdapter()Landroidx/recyclerview/widget/RecyclerView$Adapter;
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 490
|
|
invoke-virtual {p0}, Landroidx/recyclerview/widget/RecyclerView;->getAdapter()Landroidx/recyclerview/widget/RecyclerView$Adapter;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public getCurrentItem()I
|
|
.locals 0
|
|
|
|
iget p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItem:I
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public getItemDecorationAt(I)Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 1190
|
|
invoke-virtual {p0, p1}, Landroidx/recyclerview/widget/RecyclerView;->getItemDecorationAt(I)Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public getItemDecorationCount()I
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 1199
|
|
invoke-virtual {p0}, Landroidx/recyclerview/widget/RecyclerView;->getItemDecorationCount()I
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public getOffscreenPageLimit()I
|
|
.locals 0
|
|
|
|
iget p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mOffscreenPageLimit:I
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public getOrientation()I
|
|
.locals 1
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mLayoutManager:Landroidx/recyclerview/widget/LinearLayoutManager;
|
|
|
|
.line 581
|
|
invoke-virtual {p0}, Landroidx/recyclerview/widget/LinearLayoutManager;->getOrientation()I
|
|
|
|
move-result p0
|
|
|
|
const/4 v0, 0x1
|
|
|
|
if-ne p0, v0, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v0, 0x0
|
|
|
|
:goto_0
|
|
return v0
|
|
.end method
|
|
|
|
.method getPageSize()I
|
|
.locals 2
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 565
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getOrientation()I
|
|
|
|
move-result p0
|
|
|
|
if-nez p0, :cond_0
|
|
|
|
.line 566
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView;->getWidth()I
|
|
|
|
move-result p0
|
|
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView;->getPaddingLeft()I
|
|
|
|
move-result v1
|
|
|
|
sub-int/2addr p0, v1
|
|
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView;->getPaddingRight()I
|
|
|
|
move-result v0
|
|
|
|
goto :goto_0
|
|
|
|
.line 567
|
|
:cond_0
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView;->getHeight()I
|
|
|
|
move-result p0
|
|
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView;->getPaddingTop()I
|
|
|
|
move-result v1
|
|
|
|
sub-int/2addr p0, v1
|
|
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView;->getPaddingBottom()I
|
|
|
|
move-result v0
|
|
|
|
:goto_0
|
|
sub-int/2addr p0, v0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public getScrollState()I
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
.line 694
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ScrollEventAdapter;->getScrollState()I
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public invalidateItemDecorations()V
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 1207
|
|
invoke-virtual {p0}, Landroidx/recyclerview/widget/RecyclerView;->invalidateItemDecorations()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public isFakeDragging()Z
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mFakeDragger:Landroidx/viewpager2/widget/FakeDrag;
|
|
|
|
.line 768
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/FakeDrag;->isFakeDragging()Z
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method isRtl()Z
|
|
.locals 1
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mLayoutManager:Landroidx/recyclerview/widget/LinearLayoutManager;
|
|
|
|
.line 586
|
|
invoke-virtual {p0}, Landroidx/recyclerview/widget/LinearLayoutManager;->getLayoutDirection()I
|
|
|
|
move-result p0
|
|
|
|
const/4 v0, 0x1
|
|
|
|
if-ne p0, v0, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v0, 0x0
|
|
|
|
:goto_0
|
|
return v0
|
|
.end method
|
|
|
|
.method public isUserInputEnabled()Z
|
|
.locals 0
|
|
|
|
iget-boolean p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mUserInputEnabled:Z
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public onInitializeAccessibilityNodeInfo(Landroid/view/accessibility/AccessibilityNodeInfo;)V
|
|
.locals 0
|
|
|
|
.line 956
|
|
invoke-super {p0, p1}, Landroid/view/ViewGroup;->onInitializeAccessibilityNodeInfo(Landroid/view/accessibility/AccessibilityNodeInfo;)V
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 957
|
|
invoke-virtual {p0, p1}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onInitializeAccessibilityNodeInfo(Landroid/view/accessibility/AccessibilityNodeInfo;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method protected onLayout(ZIIII)V
|
|
.locals 3
|
|
|
|
iget-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 524
|
|
invoke-virtual {p1}, Landroidx/recyclerview/widget/RecyclerView;->getMeasuredWidth()I
|
|
|
|
move-result p1
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 525
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView;->getMeasuredHeight()I
|
|
|
|
move-result v0
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpContainerRect:Landroid/graphics/Rect;
|
|
|
|
.line 529
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getPaddingLeft()I
|
|
|
|
move-result v2
|
|
|
|
iput v2, v1, Landroid/graphics/Rect;->left:I
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpContainerRect:Landroid/graphics/Rect;
|
|
|
|
sub-int/2addr p4, p2
|
|
|
|
.line 530
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getPaddingRight()I
|
|
|
|
move-result p2
|
|
|
|
sub-int/2addr p4, p2
|
|
|
|
iput p4, v1, Landroid/graphics/Rect;->right:I
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpContainerRect:Landroid/graphics/Rect;
|
|
|
|
.line 531
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getPaddingTop()I
|
|
|
|
move-result p4
|
|
|
|
iput p4, p2, Landroid/graphics/Rect;->top:I
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpContainerRect:Landroid/graphics/Rect;
|
|
|
|
sub-int/2addr p5, p3
|
|
|
|
.line 532
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getPaddingBottom()I
|
|
|
|
move-result p3
|
|
|
|
sub-int/2addr p5, p3
|
|
|
|
iput p5, p2, Landroid/graphics/Rect;->bottom:I
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpContainerRect:Landroid/graphics/Rect;
|
|
|
|
iget-object p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpChildRect:Landroid/graphics/Rect;
|
|
|
|
const p4, 0x800033
|
|
|
|
.line 534
|
|
invoke-static {p4, p1, v0, p2, p3}, Landroid/view/Gravity;->apply(IIILandroid/graphics/Rect;Landroid/graphics/Rect;)V
|
|
|
|
iget-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpChildRect:Landroid/graphics/Rect;
|
|
|
|
.line 535
|
|
iget p2, p2, Landroid/graphics/Rect;->left:I
|
|
|
|
iget-object p3, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpChildRect:Landroid/graphics/Rect;
|
|
|
|
iget p3, p3, Landroid/graphics/Rect;->top:I
|
|
|
|
iget-object p4, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpChildRect:Landroid/graphics/Rect;
|
|
|
|
iget p4, p4, Landroid/graphics/Rect;->right:I
|
|
|
|
iget-object p5, p0, Landroidx/viewpager2/widget/ViewPager2;->mTmpChildRect:Landroid/graphics/Rect;
|
|
|
|
iget p5, p5, Landroid/graphics/Rect;->bottom:I
|
|
|
|
invoke-virtual {p1, p2, p3, p4, p5}, Landroidx/recyclerview/widget/RecyclerView;->layout(IIII)V
|
|
|
|
iget-boolean p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDirty:Z
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
.line 539
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->updateCurrentItem()V
|
|
|
|
:cond_0
|
|
return-void
|
|
.end method
|
|
|
|
.method protected onMeasure(II)V
|
|
.locals 5
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 506
|
|
invoke-virtual {p0, v0, p1, p2}, Landroidx/viewpager2/widget/ViewPager2;->measureChild(Landroid/view/View;II)V
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 507
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView;->getMeasuredWidth()I
|
|
|
|
move-result v0
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 508
|
|
invoke-virtual {v1}, Landroidx/recyclerview/widget/RecyclerView;->getMeasuredHeight()I
|
|
|
|
move-result v1
|
|
|
|
iget-object v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 509
|
|
invoke-virtual {v2}, Landroidx/recyclerview/widget/RecyclerView;->getMeasuredState()I
|
|
|
|
move-result v2
|
|
|
|
.line 511
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getPaddingLeft()I
|
|
|
|
move-result v3
|
|
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getPaddingRight()I
|
|
|
|
move-result v4
|
|
|
|
add-int/2addr v3, v4
|
|
|
|
add-int/2addr v0, v3
|
|
|
|
.line 512
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getPaddingTop()I
|
|
|
|
move-result v3
|
|
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getPaddingBottom()I
|
|
|
|
move-result v4
|
|
|
|
add-int/2addr v3, v4
|
|
|
|
add-int/2addr v1, v3
|
|
|
|
.line 514
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getSuggestedMinimumWidth()I
|
|
|
|
move-result v3
|
|
|
|
invoke-static {v0, v3}, Ljava/lang/Math;->max(II)I
|
|
|
|
move-result v0
|
|
|
|
.line 515
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getSuggestedMinimumHeight()I
|
|
|
|
move-result v3
|
|
|
|
invoke-static {v1, v3}, Ljava/lang/Math;->max(II)I
|
|
|
|
move-result v1
|
|
|
|
.line 517
|
|
invoke-static {v0, p1, v2}, Landroidx/viewpager2/widget/ViewPager2;->resolveSizeAndState(III)I
|
|
|
|
move-result p1
|
|
|
|
shl-int/lit8 v0, v2, 0x10
|
|
|
|
.line 518
|
|
invoke-static {v1, p2, v0}, Landroidx/viewpager2/widget/ViewPager2;->resolveSizeAndState(III)I
|
|
|
|
move-result p2
|
|
|
|
.line 517
|
|
invoke-virtual {p0, p1, p2}, Landroidx/viewpager2/widget/ViewPager2;->setMeasuredDimension(II)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method protected onRestoreInstanceState(Landroid/os/Parcelable;)V
|
|
.locals 1
|
|
|
|
.line 334
|
|
instance-of v0, p1, Landroidx/viewpager2/widget/ViewPager2$SavedState;
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
.line 335
|
|
invoke-super {p0, p1}, Landroid/view/ViewGroup;->onRestoreInstanceState(Landroid/os/Parcelable;)V
|
|
|
|
return-void
|
|
|
|
.line 339
|
|
:cond_0
|
|
check-cast p1, Landroidx/viewpager2/widget/ViewPager2$SavedState;
|
|
|
|
.line 340
|
|
invoke-virtual {p1}, Landroidx/viewpager2/widget/ViewPager2$SavedState;->getSuperState()Landroid/os/Parcelable;
|
|
|
|
move-result-object v0
|
|
|
|
invoke-super {p0, v0}, Landroid/view/ViewGroup;->onRestoreInstanceState(Landroid/os/Parcelable;)V
|
|
|
|
.line 341
|
|
iget v0, p1, Landroidx/viewpager2/widget/ViewPager2$SavedState;->mCurrentItem:I
|
|
|
|
iput v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
.line 342
|
|
iget-object p1, p1, Landroidx/viewpager2/widget/ViewPager2$SavedState;->mAdapterState:Landroid/os/Parcelable;
|
|
|
|
iput-object p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingAdapterState:Landroid/os/Parcelable;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method protected onSaveInstanceState()Landroid/os/Parcelable;
|
|
.locals 3
|
|
|
|
.line 314
|
|
invoke-super {p0}, Landroid/view/ViewGroup;->onSaveInstanceState()Landroid/os/Parcelable;
|
|
|
|
move-result-object v0
|
|
|
|
.line 315
|
|
new-instance v1, Landroidx/viewpager2/widget/ViewPager2$SavedState;
|
|
|
|
invoke-direct {v1, v0}, Landroidx/viewpager2/widget/ViewPager2$SavedState;-><init>(Landroid/os/Parcelable;)V
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 317
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView;->getId()I
|
|
|
|
move-result v0
|
|
|
|
iput v0, v1, Landroidx/viewpager2/widget/ViewPager2$SavedState;->mRecyclerViewId:I
|
|
|
|
iget v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
const/4 v2, -0x1
|
|
|
|
if-ne v0, v2, :cond_0
|
|
|
|
iget v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItem:I
|
|
|
|
.line 318
|
|
:cond_0
|
|
iput v0, v1, Landroidx/viewpager2/widget/ViewPager2$SavedState;->mCurrentItem:I
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingAdapterState:Landroid/os/Parcelable;
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
.line 321
|
|
iput-object v0, v1, Landroidx/viewpager2/widget/ViewPager2$SavedState;->mAdapterState:Landroid/os/Parcelable;
|
|
|
|
goto :goto_0
|
|
|
|
:cond_1
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 323
|
|
invoke-virtual {p0}, Landroidx/recyclerview/widget/RecyclerView;->getAdapter()Landroidx/recyclerview/widget/RecyclerView$Adapter;
|
|
|
|
move-result-object p0
|
|
|
|
.line 324
|
|
instance-of v0, p0, Landroidx/viewpager2/adapter/StatefulAdapter;
|
|
|
|
if-eqz v0, :cond_2
|
|
|
|
.line 325
|
|
check-cast p0, Landroidx/viewpager2/adapter/StatefulAdapter;
|
|
|
|
invoke-interface {p0}, Landroidx/viewpager2/adapter/StatefulAdapter;->saveState()Landroid/os/Parcelable;
|
|
|
|
move-result-object p0
|
|
|
|
iput-object p0, v1, Landroidx/viewpager2/widget/ViewPager2$SavedState;->mAdapterState:Landroid/os/Parcelable;
|
|
|
|
:cond_2
|
|
:goto_0
|
|
return-object v1
|
|
.end method
|
|
|
|
.method public onViewAdded(Landroid/view/View;)V
|
|
.locals 1
|
|
|
|
.line 496
|
|
new-instance p1, Ljava/lang/IllegalStateException;
|
|
|
|
new-instance v0, Ljava/lang/StringBuilder;
|
|
|
|
invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
.line 497
|
|
invoke-virtual {p0}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
|
|
|
|
move-result-object p0
|
|
|
|
invoke-virtual {p0}, Ljava/lang/Class;->getSimpleName()Ljava/lang/String;
|
|
|
|
move-result-object p0
|
|
|
|
invoke-virtual {v0, p0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
move-result-object p0
|
|
|
|
const-string v0, " does not support direct child views"
|
|
|
|
invoke-virtual {p0, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
move-result-object p0
|
|
|
|
invoke-virtual {p0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
move-result-object p0
|
|
|
|
invoke-direct {p1, p0}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public performAccessibilityAction(ILandroid/os/Bundle;)Z
|
|
.locals 1
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 963
|
|
invoke-virtual {v0, p1, p2}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->handlesPerformAccessibilityAction(ILandroid/os/Bundle;)Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 964
|
|
invoke-virtual {p0, p1, p2}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onPerformAccessibilityAction(ILandroid/os/Bundle;)Z
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
|
|
.line 966
|
|
:cond_0
|
|
invoke-super {p0, p1, p2}, Landroid/view/ViewGroup;->performAccessibilityAction(ILandroid/os/Bundle;)Z
|
|
|
|
move-result p0
|
|
|
|
return p0
|
|
.end method
|
|
|
|
.method public registerOnPageChangeCallback(Landroidx/viewpager2/widget/ViewPager2$OnPageChangeCallback;)V
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mExternalPageChangeCallbacks:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
.line 879
|
|
invoke-virtual {p0, p1}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;->addOnPageChangeCallback(Landroidx/viewpager2/widget/ViewPager2$OnPageChangeCallback;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public removeItemDecoration(Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;)V
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 1230
|
|
invoke-virtual {p0, p1}, Landroidx/recyclerview/widget/RecyclerView;->removeItemDecoration(Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public removeItemDecorationAt(I)V
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 1217
|
|
invoke-virtual {p0, p1}, Landroidx/recyclerview/widget/RecyclerView;->removeItemDecorationAt(I)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public requestTransform()V
|
|
.locals 5
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageTransformerAdapter:Landroidx/viewpager2/widget/PageTransformerAdapter;
|
|
|
|
.line 937
|
|
invoke-virtual {v0}, Landroidx/viewpager2/widget/PageTransformerAdapter;->getPageTransformer()Landroidx/viewpager2/widget/ViewPager2$PageTransformer;
|
|
|
|
move-result-object v0
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
.line 940
|
|
invoke-virtual {v0}, Landroidx/viewpager2/widget/ScrollEventAdapter;->getRelativeScrollPosition()D
|
|
|
|
move-result-wide v0
|
|
|
|
double-to-int v2, v0
|
|
|
|
int-to-double v3, v2
|
|
|
|
sub-double/2addr v0, v3
|
|
|
|
double-to-float v0, v0
|
|
|
|
.line 943
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getPageSize()I
|
|
|
|
move-result v1
|
|
|
|
int-to-float v1, v1
|
|
|
|
mul-float/2addr v1, v0
|
|
|
|
invoke-static {v1}, Ljava/lang/Math;->round(F)I
|
|
|
|
move-result v1
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageTransformerAdapter:Landroidx/viewpager2/widget/PageTransformerAdapter;
|
|
|
|
.line 944
|
|
invoke-virtual {p0, v2, v0, v1}, Landroidx/viewpager2/widget/PageTransformerAdapter;->onPageScrolled(IFI)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public setAdapter(Landroidx/recyclerview/widget/RecyclerView$Adapter;)V
|
|
.locals 2
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 466
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView;->getAdapter()Landroidx/recyclerview/widget/RecyclerView$Adapter;
|
|
|
|
move-result-object v0
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 467
|
|
invoke-virtual {v1, v0}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onDetachAdapter(Landroidx/recyclerview/widget/RecyclerView$Adapter;)V
|
|
|
|
.line 468
|
|
invoke-direct {p0, v0}, Landroidx/viewpager2/widget/ViewPager2;->unregisterCurrentItemDataSetTracker(Landroidx/recyclerview/widget/RecyclerView$Adapter;)V
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 469
|
|
invoke-virtual {v0, p1}, Landroidx/recyclerview/widget/RecyclerView;->setAdapter(Landroidx/recyclerview/widget/RecyclerView$Adapter;)V
|
|
|
|
const/4 v0, 0x0
|
|
|
|
iput v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItem:I
|
|
|
|
.line 471
|
|
invoke-direct {p0}, Landroidx/viewpager2/widget/ViewPager2;->restorePendingState()V
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 472
|
|
invoke-virtual {v0, p1}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onAttachAdapter(Landroidx/recyclerview/widget/RecyclerView$Adapter;)V
|
|
|
|
.line 473
|
|
invoke-direct {p0, p1}, Landroidx/viewpager2/widget/ViewPager2;->registerCurrentItemDataSetTracker(Landroidx/recyclerview/widget/RecyclerView$Adapter;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public setCurrentItem(I)V
|
|
.locals 1
|
|
|
|
const/4 v0, 0x1
|
|
|
|
.line 598
|
|
invoke-virtual {p0, p1, v0}, Landroidx/viewpager2/widget/ViewPager2;->setCurrentItem(IZ)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public setCurrentItem(IZ)V
|
|
.locals 1
|
|
|
|
.line 610
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->isFakeDragging()Z
|
|
|
|
move-result v0
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
.line 614
|
|
invoke-virtual {p0, p1, p2}, Landroidx/viewpager2/widget/ViewPager2;->setCurrentItemInternal(IZ)V
|
|
|
|
return-void
|
|
|
|
.line 611
|
|
:cond_0
|
|
new-instance p0, Ljava/lang/IllegalStateException;
|
|
|
|
const-string p1, "Cannot change current item when ViewPager2 is fake dragging"
|
|
|
|
invoke-direct {p0, p1}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw p0
|
|
.end method
|
|
|
|
.method setCurrentItemInternal(IZ)V
|
|
.locals 8
|
|
|
|
.line 621
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getAdapter()Landroidx/recyclerview/widget/RecyclerView$Adapter;
|
|
|
|
move-result-object v0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
if-nez v0, :cond_1
|
|
|
|
iget p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
const/4 v0, -0x1
|
|
|
|
if-eq p2, v0, :cond_0
|
|
|
|
.line 625
|
|
invoke-static {p1, v1}, Ljava/lang/Math;->max(II)I
|
|
|
|
move-result p1
|
|
|
|
iput p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPendingCurrentItem:I
|
|
|
|
:cond_0
|
|
return-void
|
|
|
|
.line 629
|
|
:cond_1
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView$Adapter;->getItemCount()I
|
|
|
|
move-result v2
|
|
|
|
if-gtz v2, :cond_2
|
|
|
|
return-void
|
|
|
|
.line 633
|
|
:cond_2
|
|
invoke-static {p1, v1}, Ljava/lang/Math;->max(II)I
|
|
|
|
move-result p1
|
|
|
|
.line 634
|
|
invoke-virtual {v0}, Landroidx/recyclerview/widget/RecyclerView$Adapter;->getItemCount()I
|
|
|
|
move-result v0
|
|
|
|
add-int/lit8 v0, v0, -0x1
|
|
|
|
invoke-static {p1, v0}, Ljava/lang/Math;->min(II)I
|
|
|
|
move-result p1
|
|
|
|
iget v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItem:I
|
|
|
|
if-ne p1, v0, :cond_3
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
.line 636
|
|
invoke-virtual {v0}, Landroidx/viewpager2/widget/ScrollEventAdapter;->isIdle()Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_3
|
|
|
|
return-void
|
|
|
|
:cond_3
|
|
iget v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItem:I
|
|
|
|
if-ne p1, v0, :cond_4
|
|
|
|
if-eqz p2, :cond_4
|
|
|
|
return-void
|
|
|
|
:cond_4
|
|
int-to-double v0, v0
|
|
|
|
iput p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItem:I
|
|
|
|
iget-object v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 650
|
|
invoke-virtual {v2}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onSetNewCurrentItem()V
|
|
|
|
iget-object v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
.line 652
|
|
invoke-virtual {v2}, Landroidx/viewpager2/widget/ScrollEventAdapter;->isIdle()Z
|
|
|
|
move-result v2
|
|
|
|
if-nez v2, :cond_5
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
.line 654
|
|
invoke-virtual {v0}, Landroidx/viewpager2/widget/ScrollEventAdapter;->getRelativeScrollPosition()D
|
|
|
|
move-result-wide v0
|
|
|
|
:cond_5
|
|
iget-object v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mScrollEventAdapter:Landroidx/viewpager2/widget/ScrollEventAdapter;
|
|
|
|
.line 659
|
|
invoke-virtual {v2, p1, p2}, Landroidx/viewpager2/widget/ScrollEventAdapter;->notifyProgrammaticScroll(IZ)V
|
|
|
|
if-nez p2, :cond_6
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 661
|
|
invoke-virtual {p0, p1}, Landroidx/recyclerview/widget/RecyclerView;->scrollToPosition(I)V
|
|
|
|
return-void
|
|
|
|
:cond_6
|
|
int-to-double v2, p1
|
|
|
|
sub-double v4, v2, v0
|
|
|
|
.line 666
|
|
invoke-static {v4, v5}, Ljava/lang/Math;->abs(D)D
|
|
|
|
move-result-wide v4
|
|
|
|
const-wide/high16 v6, 0x4008000000000000L # 3.0
|
|
|
|
cmpl-double p2, v4, v6
|
|
|
|
if-lez p2, :cond_8
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
cmpl-double v0, v2, v0
|
|
|
|
if-lez v0, :cond_7
|
|
|
|
add-int/lit8 v0, p1, -0x3
|
|
|
|
goto :goto_0
|
|
|
|
:cond_7
|
|
add-int/lit8 v0, p1, 0x3
|
|
|
|
.line 667
|
|
:goto_0
|
|
invoke-virtual {p2, v0}, Landroidx/recyclerview/widget/RecyclerView;->scrollToPosition(I)V
|
|
|
|
iget-object p2, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 669
|
|
new-instance v0, Landroidx/viewpager2/widget/ViewPager2$SmoothScrollToPosition;
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
invoke-direct {v0, p1, p0}, Landroidx/viewpager2/widget/ViewPager2$SmoothScrollToPosition;-><init>(ILandroidx/recyclerview/widget/RecyclerView;)V
|
|
|
|
invoke-virtual {p2, v0}, Landroidx/recyclerview/widget/RecyclerView;->post(Ljava/lang/Runnable;)Z
|
|
|
|
goto :goto_1
|
|
|
|
:cond_8
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 671
|
|
invoke-virtual {p0, p1}, Landroidx/recyclerview/widget/RecyclerView;->smoothScrollToPosition(I)V
|
|
|
|
:goto_1
|
|
return-void
|
|
.end method
|
|
|
|
.method public setLayoutDirection(I)V
|
|
.locals 0
|
|
|
|
.line 950
|
|
invoke-super {p0, p1}, Landroid/view/ViewGroup;->setLayoutDirection(I)V
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 951
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onSetLayoutDirection()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public setOffscreenPageLimit(I)V
|
|
.locals 1
|
|
|
|
const/4 v0, 0x1
|
|
|
|
if-ge p1, v0, :cond_1
|
|
|
|
const/4 v0, -0x1
|
|
|
|
if-ne p1, v0, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
.line 840
|
|
:cond_0
|
|
new-instance p0, Ljava/lang/IllegalArgumentException;
|
|
|
|
const-string p1, "Offscreen page limit must be OFFSCREEN_PAGE_LIMIT_DEFAULT or a number > 0"
|
|
|
|
invoke-direct {p0, p1}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw p0
|
|
|
|
:cond_1
|
|
:goto_0
|
|
iput p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mOffscreenPageLimit:I
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 845
|
|
invoke-virtual {p0}, Landroidx/recyclerview/widget/RecyclerView;->requestLayout()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public setOrientation(I)V
|
|
.locals 1
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mLayoutManager:Landroidx/recyclerview/widget/LinearLayoutManager;
|
|
|
|
.line 576
|
|
invoke-virtual {v0, p1}, Landroidx/recyclerview/widget/LinearLayoutManager;->setOrientation(I)V
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 577
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onSetOrientation()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public setPageTransformer(Landroidx/viewpager2/widget/ViewPager2$PageTransformer;)V
|
|
.locals 3
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-eqz p1, :cond_1
|
|
|
|
iget-boolean v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimatorPresent:Z
|
|
|
|
if-nez v1, :cond_0
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 909
|
|
invoke-virtual {v1}, Landroidx/recyclerview/widget/RecyclerView;->getItemAnimator()Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;
|
|
|
|
move-result-object v1
|
|
|
|
iput-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimator:Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;
|
|
|
|
const/4 v1, 0x1
|
|
|
|
iput-boolean v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimatorPresent:Z
|
|
|
|
:cond_0
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 912
|
|
invoke-virtual {v1, v0}, Landroidx/recyclerview/widget/RecyclerView;->setItemAnimator(Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;)V
|
|
|
|
goto :goto_0
|
|
|
|
:cond_1
|
|
iget-boolean v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimatorPresent:Z
|
|
|
|
if-eqz v1, :cond_2
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
iget-object v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimator:Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;
|
|
|
|
.line 915
|
|
invoke-virtual {v1, v2}, Landroidx/recyclerview/widget/RecyclerView;->setItemAnimator(Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;)V
|
|
|
|
iput-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimator:Landroidx/recyclerview/widget/RecyclerView$ItemAnimator;
|
|
|
|
const/4 v0, 0x0
|
|
|
|
iput-boolean v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mSavedItemAnimatorPresent:Z
|
|
|
|
:cond_2
|
|
:goto_0
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageTransformerAdapter:Landroidx/viewpager2/widget/PageTransformerAdapter;
|
|
|
|
.line 923
|
|
invoke-virtual {v0}, Landroidx/viewpager2/widget/PageTransformerAdapter;->getPageTransformer()Landroidx/viewpager2/widget/ViewPager2$PageTransformer;
|
|
|
|
move-result-object v0
|
|
|
|
if-ne p1, v0, :cond_3
|
|
|
|
return-void
|
|
|
|
:cond_3
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageTransformerAdapter:Landroidx/viewpager2/widget/PageTransformerAdapter;
|
|
|
|
.line 926
|
|
invoke-virtual {v0, p1}, Landroidx/viewpager2/widget/PageTransformerAdapter;->setPageTransformer(Landroidx/viewpager2/widget/ViewPager2$PageTransformer;)V
|
|
|
|
.line 927
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->requestTransform()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public setUserInputEnabled(Z)V
|
|
.locals 0
|
|
|
|
iput-boolean p1, p0, Landroidx/viewpager2/widget/ViewPager2;->mUserInputEnabled:Z
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mAccessibilityProvider:Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;
|
|
|
|
.line 800
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2$AccessibilityProvider;->onSetUserInputEnabled()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method snapToPage()V
|
|
.locals 4
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPagerSnapHelper:Landroidx/recyclerview/widget/PagerSnapHelper;
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mLayoutManager:Landroidx/recyclerview/widget/LinearLayoutManager;
|
|
|
|
.line 777
|
|
invoke-virtual {v0, v1}, Landroidx/recyclerview/widget/PagerSnapHelper;->findSnapView(Landroidx/recyclerview/widget/RecyclerView$LayoutManager;)Landroid/view/View;
|
|
|
|
move-result-object v0
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPagerSnapHelper:Landroidx/recyclerview/widget/PagerSnapHelper;
|
|
|
|
iget-object v2, p0, Landroidx/viewpager2/widget/ViewPager2;->mLayoutManager:Landroidx/recyclerview/widget/LinearLayoutManager;
|
|
|
|
.line 781
|
|
invoke-virtual {v1, v2, v0}, Landroidx/recyclerview/widget/PagerSnapHelper;->calculateDistanceToFinalSnap(Landroidx/recyclerview/widget/RecyclerView$LayoutManager;Landroid/view/View;)[I
|
|
|
|
move-result-object v0
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 783
|
|
aget v1, v0, v1
|
|
|
|
const/4 v2, 0x1
|
|
|
|
if-nez v1, :cond_1
|
|
|
|
aget v3, v0, v2
|
|
|
|
if-eqz v3, :cond_2
|
|
|
|
:cond_1
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mRecyclerView:Landroidx/recyclerview/widget/RecyclerView;
|
|
|
|
.line 784
|
|
aget v0, v0, v2
|
|
|
|
invoke-virtual {p0, v1, v0}, Landroidx/recyclerview/widget/RecyclerView;->smoothScrollBy(II)V
|
|
|
|
:cond_2
|
|
return-void
|
|
.end method
|
|
|
|
.method public unregisterOnPageChangeCallback(Landroidx/viewpager2/widget/ViewPager2$OnPageChangeCallback;)V
|
|
.locals 0
|
|
|
|
iget-object p0, p0, Landroidx/viewpager2/widget/ViewPager2;->mExternalPageChangeCallbacks:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
.line 889
|
|
invoke-virtual {p0, p1}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;->removeOnPageChangeCallback(Landroidx/viewpager2/widget/ViewPager2$OnPageChangeCallback;)V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method updateCurrentItem()V
|
|
.locals 2
|
|
|
|
iget-object v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mPagerSnapHelper:Landroidx/recyclerview/widget/PagerSnapHelper;
|
|
|
|
if-eqz v0, :cond_2
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mLayoutManager:Landroidx/recyclerview/widget/LinearLayoutManager;
|
|
|
|
.line 549
|
|
invoke-virtual {v0, v1}, Landroidx/recyclerview/widget/PagerSnapHelper;->findSnapView(Landroidx/recyclerview/widget/RecyclerView$LayoutManager;)Landroid/view/View;
|
|
|
|
move-result-object v0
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
return-void
|
|
|
|
:cond_0
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mLayoutManager:Landroidx/recyclerview/widget/LinearLayoutManager;
|
|
|
|
.line 553
|
|
invoke-virtual {v1, v0}, Landroidx/recyclerview/widget/LinearLayoutManager;->getPosition(Landroid/view/View;)I
|
|
|
|
move-result v0
|
|
|
|
iget v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItem:I
|
|
|
|
if-eq v0, v1, :cond_1
|
|
|
|
.line 555
|
|
invoke-virtual {p0}, Landroidx/viewpager2/widget/ViewPager2;->getScrollState()I
|
|
|
|
move-result v1
|
|
|
|
if-nez v1, :cond_1
|
|
|
|
iget-object v1, p0, Landroidx/viewpager2/widget/ViewPager2;->mPageChangeEventDispatcher:Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;
|
|
|
|
.line 557
|
|
invoke-virtual {v1, v0}, Landroidx/viewpager2/widget/CompositeOnPageChangeCallback;->onPageSelected(I)V
|
|
|
|
:cond_1
|
|
const/4 v0, 0x0
|
|
|
|
iput-boolean v0, p0, Landroidx/viewpager2/widget/ViewPager2;->mCurrentItemDirty:Z
|
|
|
|
return-void
|
|
|
|
.line 546
|
|
:cond_2
|
|
new-instance p0, Ljava/lang/IllegalStateException;
|
|
|
|
const-string v0, "Design assumption violated."
|
|
|
|
invoke-direct {p0, v0}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
|
|
|
|
throw p0
|
|
.end method
|