Conversation
fix android 14
@dotnet-policy-service agree |
|
Nice work! I think this is a useful workaround but it might be best to keep the PR open and eventually work in the updated Silk.NET binaries as they contain fixes for this and other Android bugs, |
|
I suspect this might only require a
I think AudioManager does not fall under 'highly privileged apps', but will definitely test to see if this is the case. |
| RegisterReceiver(ringerModeIntentReceiver, new IntentFilter(AudioManager.RingerModeChangedAction)); | ||
| if (OperatingSystem.IsAndroidVersionAtLeast(34)) | ||
| { | ||
| RegisterReceiver(ringerModeIntentReceiver, new IntentFilter(AudioManager.RingerModeChangedAction), ReceiverFlags.Exported); |
There was a problem hiding this comment.
Have tested this and it looks like it only needs to be ReceiverFlags.NotExported
I suggest you also this whole if-else logic in a single method (eg. something like RegisterRingerReceiver()) so this logic only needs to be modified in one place.
PR Details
🐞 Bug Fixes
Related Issue
#2349
Types of changes
Checklist