Fix MediaSessionManager.Callback to be called with the media button session
MediaSessionManager.Callback have been called with the previous media
button session instead of latest media button session.
Bug: 37998705
Test: Manual test (Avrcp leaves log fo the addressed player changes)
Change-Id: I57b0b88f68c70047474d0f0e3d10eac527eb57bd
diff --git a/services/core/java/com/android/server/media/MediaSessionService.java b/services/core/java/com/android/server/media/MediaSessionService.java
index 0db1b5d..a9db7e9 100644
--- a/services/core/java/com/android/server/media/MediaSessionService.java
+++ b/services/core/java/com/android/server/media/MediaSessionService.java
@@ -673,7 +673,7 @@
public void onMediaButtonSessionChanged(MediaSessionRecord oldMediaButtonSession,
MediaSessionRecord newMediaButtonSession) {
if (DEBUG_KEY_EVENT) {
- Log.d(TAG, "Media button session will be changed to " + newMediaButtonSession);
+ Log.d(TAG, "Media button session is changed to " + newMediaButtonSession);
}
synchronized (mLock) {
if (oldMediaButtonSession != null) {