Merge "AudioService: fix cancelMuteAwaitConnection" into tm-dev am: e651a60db4
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18523605 Change-Id: Ie439e3509a64dc3532fe5940d7718216898f21fb Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -494,7 +494,7 @@ public final class PlaybackActivityMonitor
|
|||||||
}
|
}
|
||||||
pw.println("\n");
|
pw.println("\n");
|
||||||
// muted players:
|
// muted players:
|
||||||
pw.print("\n muted players (piids) awaiting device connection: BL3 ####");
|
pw.print("\n muted players (piids) awaiting device connection:");
|
||||||
for (int piid : mMutedPlayersAwaitingConnection) {
|
for (int piid : mMutedPlayersAwaitingConnection) {
|
||||||
pw.print(" " + piid);
|
pw.print(" " + piid);
|
||||||
}
|
}
|
||||||
@@ -1235,9 +1235,7 @@ public final class PlaybackActivityMonitor
|
|||||||
|
|
||||||
@GuardedBy("mPlayerLock")
|
@GuardedBy("mPlayerLock")
|
||||||
private void unmutePlayersExpectingDevice() {
|
private void unmutePlayersExpectingDevice() {
|
||||||
if (mMutedPlayersAwaitingConnection.isEmpty()) {
|
mMutedUsagesAwaitingConnection = null;
|
||||||
return;
|
|
||||||
}
|
|
||||||
for (int piid : mMutedPlayersAwaitingConnection) {
|
for (int piid : mMutedPlayersAwaitingConnection) {
|
||||||
final AudioPlaybackConfiguration apc = mPlayers.get(piid);
|
final AudioPlaybackConfiguration apc = mPlayers.get(piid);
|
||||||
if (apc == null) {
|
if (apc == null) {
|
||||||
@@ -1254,7 +1252,6 @@ public final class PlaybackActivityMonitor
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
mMutedPlayersAwaitingConnection.clear();
|
mMutedPlayersAwaitingConnection.clear();
|
||||||
mMutedUsagesAwaitingConnection = null;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================
|
//=================================================================
|
||||||
@@ -1278,8 +1275,8 @@ public final class PlaybackActivityMonitor
|
|||||||
public void handleMessage(Message msg) {
|
public void handleMessage(Message msg) {
|
||||||
switch (msg.what) {
|
switch (msg.what) {
|
||||||
case MSG_L_TIMEOUT_MUTE_AWAIT_CONNECTION:
|
case MSG_L_TIMEOUT_MUTE_AWAIT_CONNECTION:
|
||||||
Log.i(TAG, "Timeout for muting waiting for "
|
sEventLogger.loglogi("Timeout for muting waiting for "
|
||||||
+ (AudioDeviceAttributes) msg.obj + ", unmuting");
|
+ (AudioDeviceAttributes) msg.obj + ", unmuting", TAG);
|
||||||
synchronized (mPlayerLock) {
|
synchronized (mPlayerLock) {
|
||||||
unmutePlayersExpectingDevice();
|
unmutePlayersExpectingDevice();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user