From 24a1e00acf9f6552c006447c4391c35cfa7a7c11 Mon Sep 17 00:00:00 2001 From: gedoor Date: Fri, 14 Aug 2020 08:22:45 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/io/legado/app/help/permission/PermissionsCompat.kt | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/app/src/main/java/io/legado/app/help/permission/PermissionsCompat.kt b/app/src/main/java/io/legado/app/help/permission/PermissionsCompat.kt index 4bbed5991..17104108b 100644 --- a/app/src/main/java/io/legado/app/help/permission/PermissionsCompat.kt +++ b/app/src/main/java/io/legado/app/help/permission/PermissionsCompat.kt @@ -1,11 +1,9 @@ package io.legado.app.help.permission -import android.os.Build import androidx.annotation.StringRes import androidx.appcompat.app.AppCompatActivity import androidx.fragment.app.Fragment -import org.jetbrains.anko.startActivity -import java.util.ArrayList +import java.util.* class PermissionsCompat private constructor() { @@ -18,7 +16,7 @@ class PermissionsCompat private constructor() { companion object { // 检查权限, 如果已经拥有返回 true fun check(activity: AppCompatActivity, vararg permissions: String): Boolean { - var request: Request = Request(activity) + var request = Request(activity) var pers = ArrayList() pers.addAll(listOf(*permissions)) var data = request.getDeniedPermissions(pers.toTypedArray())