Bug 1100904 - Track transitions in tab strip (r=mcomella)
☠☠ backed out by 53473d17f515 ☠ ☠
authorLucas Rocha <lucasr@lucasr.org>
Mon, 24 Nov 2014 15:13:22 +0000
changeset 241514 37c61cbcb9704f9fb85c172a79ef2d7e64bc4692
parent 241513 33c8749d384b316ce7bd6ba6794630222c007c9a
child 241515 daf6d7046496244fed9f6e5f117fe942a1e61488
push id4311
push userraliiev@mozilla.com
push dateMon, 12 Jan 2015 19:37:41 +0000
treeherdermozilla-beta@150c9fed433b [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmcomella
bugs1100904
milestone36.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1100904 - Track transitions in tab strip (r=mcomella)
mobile/android/base/tabs/TabStripView.java
--- a/mobile/android/base/tabs/TabStripView.java
+++ b/mobile/android/base/tabs/TabStripView.java
@@ -20,16 +20,17 @@ import android.view.ViewTreeObserver.OnP
 import com.nineoldandroids.animation.Animator;
 import com.nineoldandroids.animation.Animator.AnimatorListener;
 import com.nineoldandroids.animation.AnimatorSet;
 import com.nineoldandroids.animation.ObjectAnimator;
 
 import java.util.ArrayList;
 import java.util.List;
 
+import org.mozilla.gecko.animation.TransitionsTracker;
 import org.mozilla.gecko.R;
 import org.mozilla.gecko.Tab;
 import org.mozilla.gecko.Tabs;
 import org.mozilla.gecko.widget.TwoWayView;
 
 public class TabStripView extends TwoWayView {
     private static final String LOGTAG = "GeckoTabStrip";
 
@@ -129,16 +130,19 @@ public class TabStripView extends TwoWay
                     childAnimators.add(animator);
                 }
 
                 final AnimatorSet animatorSet = new AnimatorSet();
                 animatorSet.playTogether(childAnimators);
                 animatorSet.setDuration(ANIM_TIME_MS);
                 animatorSet.setInterpolator(ANIM_INTERPOLATOR);
                 animatorSet.addListener(animatorListener);
+
+                TransitionsTracker.track(animatorSet);
+
                 animatorSet.start();
 
                 return true;
             }
         });
     }
 
     private void animateNewTab(Tab newTab) {
@@ -178,16 +182,19 @@ public class TabStripView extends TwoWay
                         ObjectAnimator.ofFloat(child, "translationX", -tabSize, 0));
                 }
 
                 final AnimatorSet animatorSet = new AnimatorSet();
                 animatorSet.playTogether(childAnimators);
                 animatorSet.setDuration(ANIM_TIME_MS);
                 animatorSet.setInterpolator(ANIM_INTERPOLATOR);
                 animatorSet.addListener(animatorListener);
+
+                TransitionsTracker.track(animatorSet);
+
                 animatorSet.start();
 
                 return true;
             }
         });
     }
 
     private void ensurePositionIsVisible(final int position) {