如何获取Android设备的铃声并将其设置为Activity(当活动启动设备的铃声自动运行时)
答案 0 :(得分:0)
Uri defaultRintoneUri = RingtoneManager.getActualDefaultRingtoneUri(getActivity().getApplicationContext(), RingtoneManager.TYPE_RINGTONE);
Ringtone defaultRingtone = RingtoneManager.getRingtone(getActivity(), defaultRintoneUri);
defaultRingtone.play();