summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoboErik <epastern@google.com>2014-09-24 21:35:55 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2014-09-24 21:35:56 +0000
commit143dc769ef9709f0e65cda85f2ff6375c69560c8 (patch)
tree2c53359b978de08fd7b48f72c0af24311a249b62
parentd9cb5a7344c1a04a52445a410a875b79d4c38a62 (diff)
parent23b113592a5f461ec66026cbf8bce253cb8d3a46 (diff)
downloadframeworks_base-143dc769ef9709f0e65cda85f2ff6375c69560c8.zip
frameworks_base-143dc769ef9709f0e65cda85f2ff6375c69560c8.tar.gz
frameworks_base-143dc769ef9709f0e65cda85f2ff6375c69560c8.tar.bz2
Merge "Clear the volume cache for all inactive state transitions" into lmp-dev
-rw-r--r--services/core/java/com/android/server/media/MediaSessionStack.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/services/core/java/com/android/server/media/MediaSessionStack.java b/services/core/java/com/android/server/media/MediaSessionStack.java
index a9bc818..e464be7 100644
--- a/services/core/java/com/android/server/media/MediaSessionStack.java
+++ b/services/core/java/com/android/server/media/MediaSessionStack.java
@@ -94,8 +94,8 @@ public class MediaSessionStack {
mSessions.add(0, record);
clearCache();
return true;
- } else if (newState == PlaybackState.STATE_PAUSED) {
- // Just clear the volume cache in this case
+ } else if (!MediaSession.isActiveState(newState)) {
+ // Just clear the volume cache when a state goes inactive
mCachedVolumeDefault = null;
}
return false;