[Safer intents] Settings misc

To avoid implicit intents, make intents launch explicitly.

Test: build
Bug: 323061508
Change-Id: Ie19cbceb89842a75a180898abcce81b63c18d46c
This commit is contained in:
Jason Chiu
2024-03-25 12:15:56 +08:00
parent 9507bdb3ac
commit 0bd014c497
23 changed files with 54 additions and 44 deletions

View File

@@ -74,7 +74,8 @@ public class RingtonePreference extends Preference {
true);
mShowSilent = a.getBoolean(com.android.internal.R.styleable.RingtonePreference_showSilent,
true);
setIntent(new Intent(RingtoneManager.ACTION_RINGTONE_PICKER));
setIntent(new Intent(RingtoneManager.ACTION_RINGTONE_PICKER)
.setPackage(context.getString(R.string.config_sound_picker_package_name)));
setUserId(UserHandle.myUserId());
a.recycle();
}