在targetSdkVersion小于23(Android M)的时候,ContextCompat.CheckSelfPermission 和Context.checkSelfPermission方法都不能正常工作并且始终返0(PERMISSION_GRANTED),即使你的应用运行在Android6.0(API 23)的设备上
使用
PermissionChecker.checkSelfPermission()
去检查权限是否被授予。
ContextCompat.checkSelfPermission, NoSuchMethodError错误
猜你喜欢
转载自blog.csdn.net/u011976443/article/details/80810596
今日推荐
周排行