本文整理匯總了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);
}