107 lines
2 KiB
Smali
107 lines
2 KiB
Smali
.class public final Lcom/discord/utilities/device/DeviceUtils;
|
|
.super Ljava/lang/Object;
|
|
.source "DeviceUtils.kt"
|
|
|
|
|
|
# static fields
|
|
.field public static final INSTANCE:Lcom/discord/utilities/device/DeviceUtils;
|
|
|
|
|
|
# direct methods
|
|
.method public static constructor <clinit>()V
|
|
.locals 1
|
|
|
|
new-instance v0, Lcom/discord/utilities/device/DeviceUtils;
|
|
|
|
invoke-direct {v0}, Lcom/discord/utilities/device/DeviceUtils;-><init>()V
|
|
|
|
sput-object v0, Lcom/discord/utilities/device/DeviceUtils;->INSTANCE:Lcom/discord/utilities/device/DeviceUtils;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>()V
|
|
.locals 0
|
|
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
return-void
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final canDrawOverlays(Landroid/content/Context;)Z
|
|
.locals 2
|
|
|
|
if-eqz p1, :cond_2
|
|
|
|
sget v0, Landroid/os/Build$VERSION;->SDK_INT:I
|
|
|
|
const/16 v1, 0x16
|
|
|
|
if-le v0, v1, :cond_1
|
|
|
|
invoke-static {p1}, Landroid/provider/Settings;->canDrawOverlays(Landroid/content/Context;)Z
|
|
|
|
move-result p1
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 p1, 0x0
|
|
|
|
goto :goto_1
|
|
|
|
:cond_1
|
|
:goto_0
|
|
const/4 p1, 0x1
|
|
|
|
:goto_1
|
|
return p1
|
|
|
|
:cond_2
|
|
const-string p1, "context"
|
|
|
|
invoke-static {p1}, Ls/u/b/j;->a(Ljava/lang/String;)V
|
|
|
|
const/4 p1, 0x0
|
|
|
|
throw p1
|
|
.end method
|
|
|
|
.method public final isMeizuAndroid7Device()Z
|
|
.locals 3
|
|
|
|
sget v0, Landroid/os/Build$VERSION;->SDK_INT:I
|
|
|
|
const/4 v1, 0x1
|
|
|
|
const/16 v2, 0x18
|
|
|
|
if-ne v0, v2, :cond_0
|
|
|
|
sget-object v0, Landroid/os/Build;->MANUFACTURER:Ljava/lang/String;
|
|
|
|
const-string v2, "Build.MANUFACTURER"
|
|
|
|
invoke-static {v0, v2}, Ls/u/b/j;->checkExpressionValueIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
const-string v2, "meizu"
|
|
|
|
invoke-static {v0, v2, v1}, Ls/a0/u;->contains(Ljava/lang/CharSequence;Ljava/lang/CharSequence;Z)Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
const/4 v1, 0x0
|
|
|
|
:goto_0
|
|
return v1
|
|
.end method
|