OSDN Git Service

Fix bug with translation in ExpandableNotificationRow.
authorAnthony Chen <ajchen@google.com>
Fri, 21 Apr 2017 20:51:32 +0000 (13:51 -0700)
committerAnthony Chen <ajchen@google.com>
Fri, 21 Apr 2017 20:51:32 +0000 (13:51 -0700)
The translation X should only be used if the entire Notification row is
translating (meaning that mShouldTranslateContents is false).

Test: booted up on AAE headunit and Angler device
Change-Id: I5d04f2bd64cb79421ad30f844ba5e6aa8d1f105d

packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java

index 7277ff9..30bb181 100644 (file)
@@ -1271,7 +1271,7 @@ public class ExpandableNotificationRow extends ActivatableNotificationView
 
     @Override
     public float getTranslation() {
-        if (mShouldTranslateContents) {
+        if (!mShouldTranslateContents) {
             return getTranslationX();
         }