apkfuckery/com.discord/smali/androidx/transition/ViewOverlayApi14$OverlayViewGroup.smali
2019-07-24 13:27:29 +02:00

707 lines
18 KiB
Smali

.class Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;
.super Landroid/view/ViewGroup;
.source "ViewOverlayApi14.java"
# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
value = Landroidx/transition/ViewOverlayApi14;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
accessFlags = 0x8
name = "OverlayViewGroup"
.end annotation
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Landroidx/transition/ViewOverlayApi14$OverlayViewGroup$TouchInterceptor;
}
.end annotation
# static fields
.field static sInvalidateChildInParentFastMethod:Ljava/lang/reflect/Method;
# instance fields
.field mDrawables:Ljava/util/ArrayList;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/ArrayList<",
"Landroid/graphics/drawable/Drawable;",
">;"
}
.end annotation
.end field
.field mHostView:Landroid/view/ViewGroup;
.field mRequestingView:Landroid/view/View;
.field mViewOverlay:Landroidx/transition/ViewOverlayApi14;
# direct methods
.method static constructor <clinit>()V
.locals 5
:try_start_0
const-class v0, Landroid/view/ViewGroup;
const-string v1, "invalidateChildInParentFast"
const/4 v2, 0x3
new-array v2, v2, [Ljava/lang/Class;
const/4 v3, 0x0
sget-object v4, Ljava/lang/Integer;->TYPE:Ljava/lang/Class;
aput-object v4, v2, v3
const/4 v3, 0x1
sget-object v4, Ljava/lang/Integer;->TYPE:Ljava/lang/Class;
aput-object v4, v2, v3
const/4 v3, 0x2
const-class v4, Landroid/graphics/Rect;
aput-object v4, v2, v3
invoke-virtual {v0, v1, v2}, Ljava/lang/Class;->getDeclaredMethod(Ljava/lang/String;[Ljava/lang/Class;)Ljava/lang/reflect/Method;
move-result-object v0
sput-object v0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->sInvalidateChildInParentFastMethod:Ljava/lang/reflect/Method;
:try_end_0
.catch Ljava/lang/NoSuchMethodException; {:try_start_0 .. :try_end_0} :catch_0
:catch_0
return-void
.end method
.method constructor <init>(Landroid/content/Context;Landroid/view/ViewGroup;Landroid/view/View;Landroidx/transition/ViewOverlayApi14;)V
.locals 0
invoke-direct {p0, p1}, Landroid/view/ViewGroup;-><init>(Landroid/content/Context;)V
const/4 p1, 0x0
iput-object p1, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
iput-object p2, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
iput-object p3, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mRequestingView:Landroid/view/View;
invoke-virtual {p2}, Landroid/view/ViewGroup;->getWidth()I
move-result p1
invoke-virtual {p0, p1}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->setRight(I)V
invoke-virtual {p2}, Landroid/view/ViewGroup;->getHeight()I
move-result p1
invoke-virtual {p0, p1}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->setBottom(I)V
invoke-virtual {p2, p0}, Landroid/view/ViewGroup;->addView(Landroid/view/View;)V
iput-object p4, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mViewOverlay:Landroidx/transition/ViewOverlayApi14;
return-void
.end method
.method private getOffset([I)V
.locals 5
const/4 v0, 0x2
new-array v1, v0, [I
new-array v0, v0, [I
iget-object v2, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
invoke-virtual {v2, v1}, Landroid/view/ViewGroup;->getLocationOnScreen([I)V
iget-object v2, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mRequestingView:Landroid/view/View;
invoke-virtual {v2, v0}, Landroid/view/View;->getLocationOnScreen([I)V
const/4 v2, 0x0
aget v3, v0, v2
aget v4, v1, v2
sub-int/2addr v3, v4
aput v3, p1, v2
const/4 v2, 0x1
aget v0, v0, v2
aget v1, v1, v2
sub-int/2addr v0, v1
aput v0, p1, v2
return-void
.end method
# virtual methods
.method public add(Landroid/graphics/drawable/Drawable;)V
.locals 1
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
if-nez v0, :cond_0
new-instance v0, Ljava/util/ArrayList;
invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V
iput-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
:cond_0
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
invoke-virtual {v0, p1}, Ljava/util/ArrayList;->contains(Ljava/lang/Object;)Z
move-result v0
if-nez v0, :cond_1
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
invoke-virtual {v0, p1}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
invoke-virtual {p1}, Landroid/graphics/drawable/Drawable;->getBounds()Landroid/graphics/Rect;
move-result-object v0
invoke-virtual {p0, v0}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->invalidate(Landroid/graphics/Rect;)V
invoke-virtual {p1, p0}, Landroid/graphics/drawable/Drawable;->setCallback(Landroid/graphics/drawable/Drawable$Callback;)V
:cond_1
return-void
.end method
.method public add(Landroid/view/View;)V
.locals 6
invoke-virtual {p1}, Landroid/view/View;->getParent()Landroid/view/ViewParent;
move-result-object v0
instance-of v0, v0, Landroid/view/ViewGroup;
const/4 v1, 0x1
if-eqz v0, :cond_1
invoke-virtual {p1}, Landroid/view/View;->getParent()Landroid/view/ViewParent;
move-result-object v0
check-cast v0, Landroid/view/ViewGroup;
iget-object v2, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
if-eq v0, v2, :cond_0
invoke-virtual {v0}, Landroid/view/ViewGroup;->getParent()Landroid/view/ViewParent;
move-result-object v2
if-eqz v2, :cond_0
invoke-static {v0}, Landroidx/core/view/ViewCompat;->isAttachedToWindow(Landroid/view/View;)Z
move-result v2
if-eqz v2, :cond_0
const/4 v2, 0x2
new-array v3, v2, [I
new-array v2, v2, [I
invoke-virtual {v0, v3}, Landroid/view/ViewGroup;->getLocationOnScreen([I)V
iget-object v4, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
invoke-virtual {v4, v2}, Landroid/view/ViewGroup;->getLocationOnScreen([I)V
const/4 v4, 0x0
aget v5, v3, v4
aget v4, v2, v4
sub-int/2addr v5, v4
invoke-static {p1, v5}, Landroidx/core/view/ViewCompat;->offsetLeftAndRight(Landroid/view/View;I)V
aget v3, v3, v1
aget v2, v2, v1
sub-int/2addr v3, v2
invoke-static {p1, v3}, Landroidx/core/view/ViewCompat;->offsetTopAndBottom(Landroid/view/View;I)V
:cond_0
invoke-virtual {v0, p1}, Landroid/view/ViewGroup;->removeView(Landroid/view/View;)V
invoke-virtual {p1}, Landroid/view/View;->getParent()Landroid/view/ViewParent;
move-result-object v2
if-eqz v2, :cond_1
invoke-virtual {v0, p1}, Landroid/view/ViewGroup;->removeView(Landroid/view/View;)V
:cond_1
invoke-virtual {p0}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->getChildCount()I
move-result v0
sub-int/2addr v0, v1
invoke-super {p0, p1, v0}, Landroid/view/ViewGroup;->addView(Landroid/view/View;I)V
return-void
.end method
.method public clear()V
.locals 1
invoke-virtual {p0}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->removeAllViews()V
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
if-eqz v0, :cond_0
invoke-virtual {v0}, Ljava/util/ArrayList;->clear()V
:cond_0
return-void
.end method
.method protected dispatchDraw(Landroid/graphics/Canvas;)V
.locals 5
const/4 v0, 0x2
new-array v1, v0, [I
new-array v0, v0, [I
iget-object v2, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
invoke-virtual {v2, v1}, Landroid/view/ViewGroup;->getLocationOnScreen([I)V
iget-object v2, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mRequestingView:Landroid/view/View;
invoke-virtual {v2, v0}, Landroid/view/View;->getLocationOnScreen([I)V
const/4 v2, 0x0
aget v3, v0, v2
aget v4, v1, v2
sub-int/2addr v3, v4
int-to-float v3, v3
const/4 v4, 0x1
aget v0, v0, v4
aget v1, v1, v4
sub-int/2addr v0, v1
int-to-float v0, v0
invoke-virtual {p1, v3, v0}, Landroid/graphics/Canvas;->translate(FF)V
new-instance v0, Landroid/graphics/Rect;
iget-object v1, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mRequestingView:Landroid/view/View;
invoke-virtual {v1}, Landroid/view/View;->getWidth()I
move-result v1
iget-object v3, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mRequestingView:Landroid/view/View;
invoke-virtual {v3}, Landroid/view/View;->getHeight()I
move-result v3
invoke-direct {v0, v2, v2, v1, v3}, Landroid/graphics/Rect;-><init>(IIII)V
invoke-virtual {p1, v0}, Landroid/graphics/Canvas;->clipRect(Landroid/graphics/Rect;)Z
invoke-super {p0, p1}, Landroid/view/ViewGroup;->dispatchDraw(Landroid/graphics/Canvas;)V
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
if-nez v0, :cond_0
const/4 v0, 0x0
goto :goto_0
:cond_0
invoke-virtual {v0}, Ljava/util/ArrayList;->size()I
move-result v0
:goto_0
if-ge v2, v0, :cond_1
iget-object v1, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
invoke-virtual {v1, v2}, Ljava/util/ArrayList;->get(I)Ljava/lang/Object;
move-result-object v1
check-cast v1, Landroid/graphics/drawable/Drawable;
invoke-virtual {v1, p1}, Landroid/graphics/drawable/Drawable;->draw(Landroid/graphics/Canvas;)V
add-int/lit8 v2, v2, 0x1
goto :goto_0
:cond_1
return-void
.end method
.method public dispatchTouchEvent(Landroid/view/MotionEvent;)Z
.locals 0
const/4 p1, 0x0
return p1
.end method
.method public invalidateChildFast(Landroid/view/View;Landroid/graphics/Rect;)V
.locals 3
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
if-eqz v0, :cond_0
invoke-virtual {p1}, Landroid/view/View;->getLeft()I
move-result v0
invoke-virtual {p1}, Landroid/view/View;->getTop()I
move-result p1
const/4 v1, 0x2
new-array v1, v1, [I
invoke-direct {p0, v1}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->getOffset([I)V
const/4 v2, 0x0
aget v2, v1, v2
add-int/2addr v0, v2
const/4 v2, 0x1
aget v1, v1, v2
add-int/2addr p1, v1
invoke-virtual {p2, v0, p1}, Landroid/graphics/Rect;->offset(II)V
iget-object p1, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
invoke-virtual {p1, p2}, Landroid/view/ViewGroup;->invalidate(Landroid/graphics/Rect;)V
:cond_0
return-void
.end method
.method public invalidateChildInParent([ILandroid/graphics/Rect;)Landroid/view/ViewParent;
.locals 4
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
if-eqz v0, :cond_1
const/4 v0, 0x0
aget v1, p1, v0
const/4 v2, 0x1
aget v3, p1, v2
invoke-virtual {p2, v1, v3}, Landroid/graphics/Rect;->offset(II)V
iget-object v1, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
instance-of v1, v1, Landroid/view/ViewGroup;
if-eqz v1, :cond_0
aput v0, p1, v0
aput v0, p1, v2
const/4 v1, 0x2
new-array v1, v1, [I
invoke-direct {p0, v1}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->getOffset([I)V
aget v0, v1, v0
aget v1, v1, v2
invoke-virtual {p2, v0, v1}, Landroid/graphics/Rect;->offset(II)V
invoke-super {p0, p1, p2}, Landroid/view/ViewGroup;->invalidateChildInParent([ILandroid/graphics/Rect;)Landroid/view/ViewParent;
move-result-object p1
return-object p1
:cond_0
invoke-virtual {p0, p2}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->invalidate(Landroid/graphics/Rect;)V
:cond_1
const/4 p1, 0x0
return-object p1
.end method
.method protected invalidateChildInParentFast(IILandroid/graphics/Rect;)Landroid/view/ViewParent;
.locals 5
.annotation build Landroidx/annotation/RestrictTo;
value = {
.enum Landroidx/annotation/RestrictTo$Scope;->LIBRARY_GROUP:Landroidx/annotation/RestrictTo$Scope;
}
.end annotation
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
instance-of v0, v0, Landroid/view/ViewGroup;
if-eqz v0, :cond_0
sget-object v0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->sInvalidateChildInParentFastMethod:Ljava/lang/reflect/Method;
if-eqz v0, :cond_0
const/4 v0, 0x2
:try_start_0
new-array v1, v0, [I
invoke-direct {p0, v1}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->getOffset([I)V
sget-object v1, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->sInvalidateChildInParentFastMethod:Ljava/lang/reflect/Method;
iget-object v2, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
const/4 v3, 0x3
new-array v3, v3, [Ljava/lang/Object;
const/4 v4, 0x0
invoke-static {p1}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object p1
aput-object p1, v3, v4
const/4 p1, 0x1
invoke-static {p2}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object p2
aput-object p2, v3, p1
aput-object p3, v3, v0
invoke-virtual {v1, v2, v3}, Ljava/lang/reflect/Method;->invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;
:try_end_0
.catch Ljava/lang/IllegalAccessException; {:try_start_0 .. :try_end_0} :catch_1
.catch Ljava/lang/reflect/InvocationTargetException; {:try_start_0 .. :try_end_0} :catch_0
goto :goto_0
:catch_0
move-exception p1
invoke-virtual {p1}, Ljava/lang/reflect/InvocationTargetException;->printStackTrace()V
goto :goto_0
:catch_1
move-exception p1
invoke-virtual {p1}, Ljava/lang/IllegalAccessException;->printStackTrace()V
:cond_0
:goto_0
const/4 p1, 0x0
return-object p1
.end method
.method public invalidateDrawable(Landroid/graphics/drawable/Drawable;)V
.locals 0
.param p1 # Landroid/graphics/drawable/Drawable;
.annotation build Landroidx/annotation/NonNull;
.end annotation
.end param
invoke-virtual {p1}, Landroid/graphics/drawable/Drawable;->getBounds()Landroid/graphics/Rect;
move-result-object p1
invoke-virtual {p0, p1}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->invalidate(Landroid/graphics/Rect;)V
return-void
.end method
.method isEmpty()Z
.locals 1
invoke-virtual {p0}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->getChildCount()I
move-result v0
if-nez v0, :cond_1
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
if-eqz v0, :cond_0
invoke-virtual {v0}, Ljava/util/ArrayList;->size()I
move-result v0
if-nez v0, :cond_1
:cond_0
const/4 v0, 0x1
return v0
:cond_1
const/4 v0, 0x0
return v0
.end method
.method protected onLayout(ZIIII)V
.locals 0
return-void
.end method
.method public remove(Landroid/graphics/drawable/Drawable;)V
.locals 1
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
if-eqz v0, :cond_0
invoke-virtual {v0, p1}, Ljava/util/ArrayList;->remove(Ljava/lang/Object;)Z
invoke-virtual {p1}, Landroid/graphics/drawable/Drawable;->getBounds()Landroid/graphics/Rect;
move-result-object v0
invoke-virtual {p0, v0}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->invalidate(Landroid/graphics/Rect;)V
const/4 v0, 0x0
invoke-virtual {p1, v0}, Landroid/graphics/drawable/Drawable;->setCallback(Landroid/graphics/drawable/Drawable$Callback;)V
:cond_0
return-void
.end method
.method public remove(Landroid/view/View;)V
.locals 0
invoke-super {p0, p1}, Landroid/view/ViewGroup;->removeView(Landroid/view/View;)V
invoke-virtual {p0}, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->isEmpty()Z
move-result p1
if-eqz p1, :cond_0
iget-object p1, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mHostView:Landroid/view/ViewGroup;
invoke-virtual {p1, p0}, Landroid/view/ViewGroup;->removeView(Landroid/view/View;)V
:cond_0
return-void
.end method
.method protected verifyDrawable(Landroid/graphics/drawable/Drawable;)Z
.locals 1
.param p1 # Landroid/graphics/drawable/Drawable;
.annotation build Landroidx/annotation/NonNull;
.end annotation
.end param
invoke-super {p0, p1}, Landroid/view/ViewGroup;->verifyDrawable(Landroid/graphics/drawable/Drawable;)Z
move-result v0
if-nez v0, :cond_1
iget-object v0, p0, Landroidx/transition/ViewOverlayApi14$OverlayViewGroup;->mDrawables:Ljava/util/ArrayList;
if-eqz v0, :cond_0
invoke-virtual {v0, p1}, Ljava/util/ArrayList;->contains(Ljava/lang/Object;)Z
move-result p1
if-eqz p1, :cond_0
goto :goto_0
:cond_0
const/4 p1, 0x0
return p1
:cond_1
:goto_0
const/4 p1, 0x1
return p1
.end method