本文整理汇总了Java中pub.devrel.easypermissions.EasyPermissions.onRequestPermissionsResult方法的典型用法代码示例。如果您正苦于以下问题:Java EasyPermissions.onRequestPermissionsResult方法的具体用法?Java EasyPermissions.onRequestPermissionsResult怎么用?Java EasyPermissions.onRequestPermissionsResult使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类pub.devrel.easypermissions.EasyPermissions
的用法示例。
在下文中一共展示了EasyPermissions.onRequestPermissionsResult方法的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
@Override
public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
switch (requestCode){
case 1:
if (grantResults.length>0 && grantResults[0]==PackageManager.PERMISSION_GRANTED){
openAlbum();
}else {
Toast.makeText(UIUtils.getContext(),"你关闭了权限功能",Toast.LENGTH_SHORT).show();
}
break;
default:
break;
}
super.onRequestPermissionsResult(requestCode, permissions, grantResults);
// Forward results to EasyPermissions
EasyPermissions.onRequestPermissionsResult(requestCode, permissions, grantResults, this);
}
示例2: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
@Override
public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults);
// Forward results to EasyPermissions
EasyPermissions.onRequestPermissionsResult(requestCode, permissions, grantResults, this);
}
示例3: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
/**
* EsayPermissions接管权限处理逻辑
* @param requestCode
* @param permissions
* @param grantResults
*/
@Override
public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults);
// Forward results to EasyPermissions
EasyPermissions.onRequestPermissionsResult(requestCode, permissions, grantResults, this);
}
示例4: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
@Override
public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults);
// EasyPermissions handles the request result.
EasyPermissions.onRequestPermissionsResult(requestCode, permissions, grantResults, this);
}
示例5: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
@Override
public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults);
EasyPermissions.onRequestPermissionsResult(requestCode, permissions, grantResults, this);
}
示例6: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
@Override
public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults) {
EasyPermissions.onRequestPermissionsResult(requestCode, permissions, grantResults, this);
}
示例7: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults) {
EasyPermissions.onRequestPermissionsResult(requestCode, permissions, grantResults, this);
}
示例8: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
@Override
public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults);
EasyPermissions.onRequestPermissionsResult(requestCode, permissions, grantResults, this);
}
示例9: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
@Override
public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
EasyPermissions.onRequestPermissionsResult(requestCode, permissions, grantResults, this);
}
示例10: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
@Override
public void onRequestPermissionsResult(int requestCode, String[] permissions, int[] grantResults) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults);
// Forward results to EasyPermissions
EasyPermissions.onRequestPermissionsResult(requestCode, permissions, grantResults, this);
}
示例11: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
/**
* Respond to requests for permissions at runtime for API 23 and above.
*
* @param requestCode The request code passed in
* requestPermissions(android.app.Activity, String, int, String[])
* @param permissions The requested permissions. Never null.
* @param grantResults The grant results for the corresponding permissions
* which is either PERMISSION_GRANTED or PERMISSION_DENIED. Never null.
*/
@Override
public void onRequestPermissionsResult(int requestCode,
@NonNull String[] permissions,
@NonNull int[] grantResults) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults);
EasyPermissions.onRequestPermissionsResult(
requestCode, permissions, grantResults, this);
}
示例12: onRequestPermissionsResult
import pub.devrel.easypermissions.EasyPermissions; //导入方法依赖的package包/类
/**
* Respond to requests for permissions at runtime for API 23 and above.
*
* @param requestCode The request code passed in
* requestPermissions(android.app.Activity, String, int, String[])
* @param permissions The requested permissions. Never null.
* @param grantResults The grant results for the corresponding permissions
* which is either PERMISSION_GRANTED or PERMISSION_DENIED. Never null.
*/
@Override
public void onRequestPermissionsResult(int requestCode,
@NonNull String[] permissions,
@NonNull int[] grantResults) {
context.onRequestPermissionsResult(requestCode, permissions, grantResults);
EasyPermissions.onRequestPermissionsResult(
requestCode, permissions, grantResults, this);
}