summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJim Miller <jaggies@google.com>2010-01-29 17:25:26 -0800
committerJim Miller <jaggies@google.com>2010-01-29 17:59:33 -0800
commitd8a3a8957b9d71ab75584b0cc98324fd70cc527c (patch)
treea1203b42453a88316b74e2e152b8807aa8bfd3e1
parent9800adf2a4d78d1e3e44dbef6aecf2b2b738c9c8 (diff)
downloadframeworks_base-d8a3a8957b9d71ab75584b0cc98324fd70cc527c.zip
frameworks_base-d8a3a8957b9d71ab75584b0cc98324fd70cc527c.tar.gz
frameworks_base-d8a3a8957b9d71ab75584b0cc98324fd70cc527c.tar.bz2
Fix 2404771: Expose reset() in SlidingTab widget so we can reset it when we get an incoming call.
Updated javadoc.
-rw-r--r--core/java/com/android/internal/widget/SlidingTab.java14
1 files changed, 12 insertions, 2 deletions
diff --git a/core/java/com/android/internal/widget/SlidingTab.java b/core/java/com/android/internal/widget/SlidingTab.java
index 940a2e5..07955c4 100644
--- a/core/java/com/android/internal/widget/SlidingTab.java
+++ b/core/java/com/android/internal/widget/SlidingTab.java
@@ -548,12 +548,22 @@ public class SlidingTab extends ViewGroup {
return true;
}
+ /**
+ * Reset the tabs to their original state and stop any existing animation.
+ * Animate them back into place if animate is true.
+ *
+ * @param animate
+ */
+ public void reset(boolean animate) {
+ mLeftSlider.reset(animate);
+ mRightSlider.reset(animate);
+ }
+
@Override
public void setVisibility(int visibility) {
// Clear animations so sliders don't continue to animate when we show the widget again.
if (visibility != getVisibility() && visibility == View.INVISIBLE) {
- mLeftSlider.reset(false);
- mRightSlider.reset(false);
+ reset(false);
}
super.setVisibility(visibility);
}