summaryrefslogtreecommitdiffstats
path: root/src/com
diff options
context:
space:
mode:
authorNivedita Sarkar <nsarkar@codeaurora.org>2015-11-04 16:28:23 -0800
committerSteve Kondik <steve@cyngn.com>2016-05-20 23:09:14 -0700
commit99532f287145225dbf2f55bf5d1a659a3004319a (patch)
treec77bb2749f49ede87e0facc6faeee2b858953ee8 /src/com
parent0f021986e42585c05eb259b0d741d9cda5d1f5e5 (diff)
downloadandroid_packages_apps_InCallUI-99532f287145225dbf2f55bf5d1a659a3004319a.tar.gz
android_packages_apps_InCallUI-99532f287145225dbf2f55bf5d1a659a3004319a.tar.bz2
android_packages_apps_InCallUI-99532f287145225dbf2f55bf5d1a659a3004319a.zip
IMS-VT: Update end button position onPreDraw of secondary call info
- Update floating end button position when onPreDraw of secondary call info is called and updated secondary height is passed in Change-Id: I14e66305e907c05c16a3aa13d0db9af16f66eb05 CRs-Fixed: 926532 IMS-VT: Don't animate secondary call info if visibility hasn't changed - Return from setSecondaryInfoVisible if visibility hasn't changed and wasVisibile and isVisibile flags are both true or false - This fixes the issue where secondary call info is animated for the above scenario as well leading to hold call disappearing for a very short time Change-Id: I7416decd83bc161fc5e135bdc8b05e6acf9a2f6a CRs-Fixed: 923927
Diffstat (limited to 'src/com')
-rw-r--r--src/com/android/incallui/CallCardFragment.java10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/com/android/incallui/CallCardFragment.java b/src/com/android/incallui/CallCardFragment.java
index e7de8b35..4e2c522c 100644
--- a/src/com/android/incallui/CallCardFragment.java
+++ b/src/com/android/incallui/CallCardFragment.java
@@ -666,7 +666,11 @@ public class CallCardFragment extends BaseFragment<CallCardPresenter, CallCardPr
mSecondaryCallInfo.setVisibility(View.VISIBLE);
}
- updateFabPositionForSecondaryCallInfo();
+ // If secondary info visibility hasn't changed, don't animate. Return.
+ if (wasVisible == isVisible) {
+ return;
+ }
+
// We need to translate the secondary caller info, but we need to know its position after
// the layout has occurred so use a {@code ViewTreeObserver}.
final ViewTreeObserver observer = getView().getViewTreeObserver();
@@ -680,6 +684,10 @@ public class CallCardFragment extends BaseFragment<CallCardPresenter, CallCardPr
// Get the height of the secondary call info now, and then re-hide the view prior
// to doing the actual animation.
int secondaryHeight = mSecondaryCallInfo.getHeight();
+
+ // Update floating end call button position onPreDraw
+ updateFabPositionForSecondaryCallInfo();
+
if (isVisible) {
mSecondaryCallInfo.setVisibility(View.GONE);
}