-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
whenPermissions not called on api 23 or 25 #2
Comments
Hi, private PermissionsGrantedListener onPermissionsGranted = new PermissionsGrantedListener() {
@Override
public void onPermissionsGranted(String[] permissions) throws SecurityException {
// given permissions are granted
}
};
private PermissionsRefusedListener onPermissionsRefused = new PermissionsRefusedListener() {
@Override
public void onPermissionsRefused(String[] permissions) {
// given permissions are refused
}
};
// [...]
new Permissive.Request(Manifest.permission.ACCESS_COARSE_LOCATION, Manifest.permission.ACCESS_FINE_LOCATION)
.whenPermissionsGranted(onPermissionsGranted)
.whenPermissionsRefused(onPermissionsRefused)
.execute(this); |
Got it! Thanks |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
// called from activity
new Permissive.Request(Manifest.permission.ACCESS_COARSE_LOCATION, Manifest.permission.ACCESS_FINE_LOCATION)
.whenPermissionsGranted(new PermissionsGrantedListener() {
@OverRide
public void onPermissionsGranted(String[] permissions) throws SecurityException {
// given permissions are granted
}
})
.whenPermissionsRefused(new PermissionsRefusedListener() {
@OverRide
public void onPermissionsRefused(String[] permissions) {
// given permissions are refused
}
})
.execute(this);
The text was updated successfully, but these errors were encountered: