From 200bb14d08e8162e893eec2ca928491d75eab8e0 Mon Sep 17 00:00:00 2001 From: Andrew Lee Date: Fri, 19 Jun 2015 18:07:08 -0700 Subject: Set FAB to invisible on hide if no animation. ScaleIn animation will not trigger if FAB is already visible, so if we don't scaleOut, set the visibility of the FAB to GONE. Bug: 21903907 Change-Id: I25ef78ca4e042665d62c40b791d7217310515597 --- src/com/android/dialer/dialpad/DialpadFragment.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/com/android/dialer/dialpad/DialpadFragment.java b/src/com/android/dialer/dialpad/DialpadFragment.java index 766175c9b..5b1e21129 100644 --- a/src/com/android/dialer/dialpad/DialpadFragment.java +++ b/src/com/android/dialer/dialpad/DialpadFragment.java @@ -1643,12 +1643,17 @@ public class DialpadFragment extends Fragment if (mAnimate) { dialpadView.animateShow(); } + mFloatingActionButtonController.setVisible(false); mFloatingActionButtonController.scaleIn(mAnimate ? mDialpadSlideInDuration : 0); activity.onDialpadShown(); mDigits.requestFocus(); } - if (hidden && mAnimate) { - mFloatingActionButtonController.scaleOut(); + if (hidden) { + if (mAnimate) { + mFloatingActionButtonController.scaleOut(); + } else { + mFloatingActionButtonController.setVisible(false); + } } } -- cgit v1.2.3