diff options
author | Tyler Gunn <tgunn@google.com> | 2014-08-12 12:16:28 -0700 |
---|---|---|
committer | Tyler Gunn <tgunn@google.com> | 2014-08-12 12:16:28 -0700 |
commit | bf7a95e47facece917e99f19848c014c1438cd77 (patch) | |
tree | d6a8f9c7bd280a3cad92b506d0f82503ad58ea9c /src | |
parent | a9c226358d83cbfe6b31ac2750fd641fd561a2d7 (diff) |
Correcting dialpad animations in landscape (3/3).
1. Fixed slide in/out animations for RTL locales.
Bug: 16463723
Change-Id: Ifb32e8daed58949d53acc23828d083f1adac3944
Diffstat (limited to 'src')
-rw-r--r-- | src/com/android/dialer/DialtactsActivity.java | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src/com/android/dialer/DialtactsActivity.java b/src/com/android/dialer/DialtactsActivity.java index cb01e8ef0..5a76ffa74 100644 --- a/src/com/android/dialer/DialtactsActivity.java +++ b/src/com/android/dialer/DialtactsActivity.java @@ -414,10 +414,16 @@ public class DialtactsActivity extends TransactionSafeActivity implements View.O mActionBarController.restoreInstanceState(savedInstanceState); } - mSlideIn = AnimationUtils.loadAnimation(this, - mIsLandscape ? R.anim.dialpad_slide_in_right : R.anim.dialpad_slide_in_bottom); - mSlideOut = AnimationUtils.loadAnimation(this, - mIsLandscape ? R.anim.dialpad_slide_out_right : R.anim.dialpad_slide_out_bottom); + final boolean isLayoutRtl = DialerUtils.isRtl(); + if (mIsLandscape) { + mSlideIn = AnimationUtils.loadAnimation(this, + isLayoutRtl ? R.anim.dialpad_slide_in_left : R.anim.dialpad_slide_in_right); + mSlideOut = AnimationUtils.loadAnimation(this, + isLayoutRtl ? R.anim.dialpad_slide_out_left : R.anim.dialpad_slide_out_right); + } else { + mSlideIn = AnimationUtils.loadAnimation(this, R.anim.dialpad_slide_in_bottom); + mSlideOut = AnimationUtils.loadAnimation(this, R.anim.dialpad_slide_out_bottom); + } mSlideIn.setInterpolator(AnimUtils.EASE_IN); mSlideOut.setInterpolator(AnimUtils.EASE_OUT); |