88 lines
2.4 KiB
Smali
88 lines
2.4 KiB
Smali
.class public final Lcom/discord/utilities/recycler/GridColumnSpaceItemDecoration;
|
|
.super Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;
|
|
.source "GridColumnSpaceItemDecoration.kt"
|
|
|
|
|
|
# instance fields
|
|
.field public final columnCount:I
|
|
|
|
.field public final columnSpacePx:I
|
|
|
|
|
|
# direct methods
|
|
.method public constructor <init>(II)V
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;-><init>()V
|
|
|
|
iput p1, p0, Lcom/discord/utilities/recycler/GridColumnSpaceItemDecoration;->columnSpacePx:I
|
|
|
|
iput p2, p0, Lcom/discord/utilities/recycler/GridColumnSpaceItemDecoration;->columnCount:I
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public getItemOffsets(Landroid/graphics/Rect;Landroid/view/View;Landroidx/recyclerview/widget/RecyclerView;Landroidx/recyclerview/widget/RecyclerView$State;)V
|
|
.locals 1
|
|
|
|
const-string v0, "outRect"
|
|
|
|
invoke-static {p1, v0}, Ly/n/c/j;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string/jumbo v0, "view"
|
|
|
|
invoke-static {p2, v0}, Ly/n/c/j;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string v0, "parent"
|
|
|
|
invoke-static {p3, v0}, Ly/n/c/j;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string v0, "state"
|
|
|
|
invoke-static {p4, v0}, Ly/n/c/j;->checkNotNullParameter(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
invoke-super {p0, p1, p2, p3, p4}, Landroidx/recyclerview/widget/RecyclerView$ItemDecoration;->getItemOffsets(Landroid/graphics/Rect;Landroid/view/View;Landroidx/recyclerview/widget/RecyclerView;Landroidx/recyclerview/widget/RecyclerView$State;)V
|
|
|
|
invoke-virtual {p3, p2}, Landroidx/recyclerview/widget/RecyclerView;->getChildAdapterPosition(Landroid/view/View;)I
|
|
|
|
move-result p2
|
|
|
|
iget p3, p0, Lcom/discord/utilities/recycler/GridColumnSpaceItemDecoration;->columnCount:I
|
|
|
|
rem-int/2addr p2, p3
|
|
|
|
const/4 p4, 0x1
|
|
|
|
sub-int/2addr p3, p4
|
|
|
|
const/4 v0, 0x0
|
|
|
|
if-ne p2, p3, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 p4, 0x0
|
|
|
|
:goto_0
|
|
if-eqz p4, :cond_1
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
iget v0, p0, Lcom/discord/utilities/recycler/GridColumnSpaceItemDecoration;->columnSpacePx:I
|
|
|
|
:goto_1
|
|
iget p2, p1, Landroid/graphics/Rect;->left:I
|
|
|
|
iget p3, p1, Landroid/graphics/Rect;->top:I
|
|
|
|
iget p4, p1, Landroid/graphics/Rect;->bottom:I
|
|
|
|
invoke-virtual {p1, p2, p3, v0, p4}, Landroid/graphics/Rect;->set(IIII)V
|
|
|
|
return-void
|
|
.end method
|