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

Commit cd50a568 authored by Anton Potapov's avatar Anton Potapov Committed by Android (Google) Code Review
Browse files

Merge "Handle AudioManager#STREAM_ASSISTANT in the Volume Dialog" into main

parents 4b700924 47a14467
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1914,6 +1914,7 @@
    <string name="stream_dtmf">Dual multi tone frequency</string> <!-- STREAM_DTMF -->
    <string name="stream_tts" translatable="false">Transmitted Through Speaker</string> <!-- STREAM_TTS -->
    <string name="stream_accessibility">Accessibility</string> <!-- STREAM_ACCESSIBILITY -->
    <string name="stream_assistant">Assistant</string> <!-- STREAM_ASSISTANT -->

    <string name="volume_ringer_status_normal">Ring</string>
    <string name="volume_ringer_status_vibrate">Vibrate</string>
+1 −0
Original line number Diff line number Diff line
@@ -127,6 +127,7 @@ public class VolumeDialogControllerImpl implements VolumeDialogController, Dumpa
        STREAMS.put(AudioSystem.STREAM_SYSTEM_ENFORCED, R.string.stream_system_enforced);
        STREAMS.put(AudioSystem.STREAM_TTS, R.string.stream_tts);
        STREAMS.put(AudioSystem.STREAM_VOICE_CALL, R.string.stream_voice_call);
        STREAMS.put(AudioSystem.STREAM_ASSISTANT, R.string.stream_assistant);
    }

    private final W mWorker;
+2 −0
Original line number Diff line number Diff line
@@ -145,6 +145,7 @@ constructor(
                AudioManager.STREAM_RING -> ringerOfflineIcon ?: R.drawable.ic_volume_ringer_vibrate
                AudioManager.STREAM_ALARM -> R.drawable.ic_volume_alarm_mute
                AudioManager.STREAM_SYSTEM -> R.drawable.ic_volume_system_mute
                AudioManager.STREAM_ASSISTANT -> R.drawable.ic_volume_system_mute
                else -> null
            }
        } else {
@@ -168,6 +169,7 @@ constructor(
            AudioManager.STREAM_ALARM -> R.drawable.ic_alarm
            AudioManager.STREAM_VOICE_CALL -> com.android.internal.R.drawable.ic_phone
            AudioManager.STREAM_SYSTEM -> R.drawable.ic_volume_system
            AudioManager.STREAM_ASSISTANT -> R.drawable.ic_volume_system
            else -> error("Unsupported stream: $stream")
        }
    }