问题
I have an application that requests permission to send SMS from the user then sends a formatted SMS in the background. This works on all other 23+ devices except my new OnePlus 5.
Does anyone know what might be going on?
回答1:
May be it is happening because of the third party app permission. One plus uses Oxygen Os and Settings are managed from a custom settings view in Oxygen OS.
You should open the application Settings page instead
Intent intent = new Intent();
intent.setAction(Settings.ACTION_APPLICATION_DETAILS_SETTINGS);
Uri uri = Uri.fromParts("package", getPackageName(), null);
intent.setData(uri);
startActivity(intent);
来源:https://stackoverflow.com/questions/46224844/android-send-sms-permission-working-on-other-23-devices-but-not-with-the-oneplu