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

Commit d3038c30 authored by Eric Laurent's avatar Eric Laurent Committed by Android Git Automerger
Browse files

am c15c2656: audio policy: remove redundant fixed volume management

* commit 'c15c2656':
  audio policy: remove redundant fixed volume management
parents c41eb95c c15c2656
Loading
Loading
Loading
Loading
+0 −8
Original line number Diff line number Diff line
@@ -4264,14 +4264,6 @@ float AudioPolicyManager::computeVolume(audio_stream_type_t stream,
        device = outputDesc->device();
    }

    // if volume is not 0 (not muted), force media volume to max on digital output
    if (stream == AUDIO_STREAM_MUSIC &&
        index != mStreams[stream].mIndexMin &&
        (device == AUDIO_DEVICE_OUT_AUX_DIGITAL ||
         device == AUDIO_DEVICE_OUT_DGTL_DOCK_HEADSET)) {
        return 1.0;
    }

    volume = volIndexToAmpl(device, streamDesc, index);

    // if a headset is connected, apply the following rules to ring tones and notifications