2019-07-24 11:27:29 +00:00
|
|
|
.class public Landroidx/appcompat/widget/MenuPopupWindow;
|
|
|
|
.super Landroidx/appcompat/widget/ListPopupWindow;
|
|
|
|
.source "MenuPopupWindow.java"
|
|
|
|
|
|
|
|
# interfaces
|
|
|
|
.implements Landroidx/appcompat/widget/MenuItemHoverListener;
|
|
|
|
|
|
|
|
|
|
|
|
# annotations
|
|
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
|
|
value = {
|
|
|
|
Landroidx/appcompat/widget/MenuPopupWindow$MenuDropDownListView;
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
|
|
|
|
# static fields
|
|
|
|
.field private static final TAG:Ljava/lang/String; = "MenuPopupWindow"
|
|
|
|
|
|
|
|
.field private static sSetTouchModalMethod:Ljava/lang/reflect/Method;
|
|
|
|
|
|
|
|
|
|
|
|
# instance fields
|
|
|
|
.field private mHoverListener:Landroidx/appcompat/widget/MenuItemHoverListener;
|
|
|
|
|
|
|
|
|
|
|
|
# direct methods
|
|
|
|
.method static constructor <clinit>()V
|
|
|
|
.locals 5
|
|
|
|
|
|
|
|
:try_start_0
|
2019-11-15 02:21:15 +00:00
|
|
|
sget v0, Landroid/os/Build$VERSION;->SDK_INT:I
|
|
|
|
|
|
|
|
const/16 v1, 0x1c
|
|
|
|
|
|
|
|
if-gt v0, v1, :cond_0
|
|
|
|
|
2019-07-24 11:27:29 +00:00
|
|
|
const-class v0, Landroid/widget/PopupWindow;
|
|
|
|
|
|
|
|
const-string v1, "setTouchModal"
|
|
|
|
|
|
|
|
const/4 v2, 0x1
|
|
|
|
|
|
|
|
new-array v2, v2, [Ljava/lang/Class;
|
|
|
|
|
|
|
|
const/4 v3, 0x0
|
|
|
|
|
|
|
|
sget-object v4, Ljava/lang/Boolean;->TYPE:Ljava/lang/Class;
|
|
|
|
|
|
|
|
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/appcompat/widget/MenuPopupWindow;->sSetTouchModalMethod:Ljava/lang/reflect/Method;
|
|
|
|
:try_end_0
|
|
|
|
.catch Ljava/lang/NoSuchMethodException; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
|
2019-11-15 02:21:15 +00:00
|
|
|
:cond_0
|
2019-07-24 11:27:29 +00:00
|
|
|
return-void
|
|
|
|
|
|
|
|
:catch_0
|
|
|
|
const-string v0, "MenuPopupWindow"
|
|
|
|
|
|
|
|
const-string v1, "Could not find method setTouchModal() on PopupWindow. Oh well."
|
|
|
|
|
|
|
|
invoke-static {v0, v1}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;)I
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;II)V
|
|
|
|
.locals 0
|
|
|
|
|
|
|
|
invoke-direct {p0, p1, p2, p3, p4}, Landroidx/appcompat/widget/ListPopupWindow;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;II)V
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
|
|
|
|
# virtual methods
|
|
|
|
.method createDropDownListView(Landroid/content/Context;Z)Landroidx/appcompat/widget/DropDownListView;
|
|
|
|
.locals 1
|
|
|
|
|
|
|
|
new-instance v0, Landroidx/appcompat/widget/MenuPopupWindow$MenuDropDownListView;
|
|
|
|
|
|
|
|
invoke-direct {v0, p1, p2}, Landroidx/appcompat/widget/MenuPopupWindow$MenuDropDownListView;-><init>(Landroid/content/Context;Z)V
|
|
|
|
|
|
|
|
invoke-virtual {v0, p0}, Landroidx/appcompat/widget/MenuPopupWindow$MenuDropDownListView;->setHoverListener(Landroidx/appcompat/widget/MenuItemHoverListener;)V
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public onItemHoverEnter(Landroidx/appcompat/view/menu/MenuBuilder;Landroid/view/MenuItem;)V
|
|
|
|
.locals 1
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/appcompat/widget/MenuPopupWindow;->mHoverListener:Landroidx/appcompat/widget/MenuItemHoverListener;
|
|
|
|
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
|
|
|
|
invoke-interface {v0, p1, p2}, Landroidx/appcompat/widget/MenuItemHoverListener;->onItemHoverEnter(Landroidx/appcompat/view/menu/MenuBuilder;Landroid/view/MenuItem;)V
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public onItemHoverExit(Landroidx/appcompat/view/menu/MenuBuilder;Landroid/view/MenuItem;)V
|
|
|
|
.locals 1
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/appcompat/widget/MenuPopupWindow;->mHoverListener:Landroidx/appcompat/widget/MenuItemHoverListener;
|
|
|
|
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
|
|
|
|
invoke-interface {v0, p1, p2}, Landroidx/appcompat/widget/MenuItemHoverListener;->onItemHoverExit(Landroidx/appcompat/view/menu/MenuBuilder;Landroid/view/MenuItem;)V
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public setEnterTransition(Ljava/lang/Object;)V
|
|
|
|
.locals 2
|
|
|
|
|
|
|
|
sget v0, Landroid/os/Build$VERSION;->SDK_INT:I
|
|
|
|
|
|
|
|
const/16 v1, 0x17
|
|
|
|
|
|
|
|
if-lt v0, v1, :cond_0
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/appcompat/widget/MenuPopupWindow;->mPopup:Landroid/widget/PopupWindow;
|
|
|
|
|
|
|
|
check-cast p1, Landroid/transition/Transition;
|
|
|
|
|
|
|
|
invoke-virtual {v0, p1}, Landroid/widget/PopupWindow;->setEnterTransition(Landroid/transition/Transition;)V
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public setExitTransition(Ljava/lang/Object;)V
|
|
|
|
.locals 2
|
|
|
|
|
|
|
|
sget v0, Landroid/os/Build$VERSION;->SDK_INT:I
|
|
|
|
|
|
|
|
const/16 v1, 0x17
|
|
|
|
|
|
|
|
if-lt v0, v1, :cond_0
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/appcompat/widget/MenuPopupWindow;->mPopup:Landroid/widget/PopupWindow;
|
|
|
|
|
|
|
|
check-cast p1, Landroid/transition/Transition;
|
|
|
|
|
|
|
|
invoke-virtual {v0, p1}, Landroid/widget/PopupWindow;->setExitTransition(Landroid/transition/Transition;)V
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public setHoverListener(Landroidx/appcompat/widget/MenuItemHoverListener;)V
|
|
|
|
.locals 0
|
|
|
|
|
|
|
|
iput-object p1, p0, Landroidx/appcompat/widget/MenuPopupWindow;->mHoverListener:Landroidx/appcompat/widget/MenuItemHoverListener;
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public setTouchModal(Z)V
|
|
|
|
.locals 4
|
|
|
|
|
2019-11-15 02:21:15 +00:00
|
|
|
sget v0, Landroid/os/Build$VERSION;->SDK_INT:I
|
|
|
|
|
|
|
|
const/16 v1, 0x1c
|
|
|
|
|
|
|
|
if-gt v0, v1, :cond_0
|
|
|
|
|
2019-07-24 11:27:29 +00:00
|
|
|
sget-object v0, Landroidx/appcompat/widget/MenuPopupWindow;->sSetTouchModalMethod:Ljava/lang/reflect/Method;
|
|
|
|
|
2019-11-15 02:21:15 +00:00
|
|
|
if-eqz v0, :cond_1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
:try_start_0
|
|
|
|
iget-object v1, p0, Landroidx/appcompat/widget/MenuPopupWindow;->mPopup:Landroid/widget/PopupWindow;
|
|
|
|
|
|
|
|
const/4 v2, 0x1
|
|
|
|
|
|
|
|
new-array v2, v2, [Ljava/lang/Object;
|
|
|
|
|
|
|
|
const/4 v3, 0x0
|
|
|
|
|
|
|
|
invoke-static {p1}, Ljava/lang/Boolean;->valueOf(Z)Ljava/lang/Boolean;
|
|
|
|
|
|
|
|
move-result-object p1
|
|
|
|
|
|
|
|
aput-object p1, v2, v3
|
|
|
|
|
|
|
|
invoke-virtual {v0, v1, v2}, Ljava/lang/reflect/Method;->invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
:try_end_0
|
|
|
|
.catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
|
|
|
|
return-void
|
|
|
|
|
|
|
|
:catch_0
|
|
|
|
const-string p1, "MenuPopupWindow"
|
|
|
|
|
|
|
|
const-string v0, "Could not invoke setTouchModal() on PopupWindow. Oh well."
|
|
|
|
|
|
|
|
invoke-static {p1, v0}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;)I
|
|
|
|
|
2019-11-15 02:21:15 +00:00
|
|
|
return-void
|
|
|
|
|
2019-07-24 11:27:29 +00:00
|
|
|
:cond_0
|
2019-11-15 02:21:15 +00:00
|
|
|
iget-object v0, p0, Landroidx/appcompat/widget/MenuPopupWindow;->mPopup:Landroid/widget/PopupWindow;
|
|
|
|
|
|
|
|
invoke-virtual {v0, p1}, Landroid/widget/PopupWindow;->setTouchModal(Z)V
|
|
|
|
|
|
|
|
:cond_1
|
2019-07-24 11:27:29 +00:00
|
|
|
return-void
|
|
|
|
.end method
|