summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Dianne Hackborn <hackbod@android.com> 2011-07-21 22:23:46 -0700
committer Android Git Automerger <android-git-automerger@android.com> 2011-07-21 22:23:46 -0700
commit1a2fcea1a28074f15126471daa5a8650cb5e2ecc (patch)
tree84c2290fff7572ea4548580ee983b58ac0f18bd2
parente70b2b8fe0c265171f3a367a66c99b36c62567c7 (diff)
parent2f4698fda46a3d2a6e78019588d77bae1cfa7193 (diff)
am 2f4698fd: Merge "frameworks/base: unlink death notifications of Vibrate requests"
* commit '2f4698fda46a3d2a6e78019588d77bae1cfa7193': frameworks/base: unlink death notifications of Vibrate requests
-rwxr-xr-xservices/java/com/android/server/VibratorService.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/services/java/com/android/server/VibratorService.java b/services/java/com/android/server/VibratorService.java
index 86c30f88a23e..71353911ea6c 100755
--- a/services/java/com/android/server/VibratorService.java
+++ b/services/java/com/android/server/VibratorService.java
@@ -379,6 +379,12 @@ public class VibratorService extends IVibratorService.Stub {
if (intent.getAction().equals(Intent.ACTION_SCREEN_OFF)) {
synchronized (mVibrations) {
doCancelVibrateLocked();
+
+ int size = mVibrations.size();
+ for(int i = 0; i < size; i++) {
+ unlinkVibration(mVibrations.get(i));
+ }
+
mVibrations.clear();
}
}