Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 95559b29 authored by James Lemieux's avatar James Lemieux
Browse files

Fix remaining dangerous M permissions

android.permission.WRITE_SETTINGS was required to adjust the Setting
that stored the last selected alarm ringtone as the new default. The
value is now stored in SharedPreferences and no longer written to the
Setting. The permission has been removed.

android.permission.READ_EXTERNAL_STORAGE was required to play custom
ringtones located at /sdcard/Alarms via MediaPlayer. MediaPlayer is
no longer used to play those ringtones so the permission has been
removed. Ringtone, which is designed to play custom ringtones without
requiring the permission to read from external storage is now the
playback method. The caveat to this approach is: Ringtone does not
offer control over the volume at which the ringtone is played. Old
MediaPlayer code used to detect when we were in a phone call and
reduce the volume defensively to avoid playing a loud ringtone
directly into a user's ear. In practice, it appears that lower layers
of the audio stack are already handling this behavior and the app
need not request a lower volume itself.

Bug: 20273223
Change-Id: I328d168ff7677506aeae3fdf78c915f82e6cc1c7
parent ac260c00
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment