Fix a couple small bugs (issue 6539339)

-> Adjusting the character of the 'shake' animation to keep
   a single phase, and instead stagger the animations slightly
-> Fixing issue where widget is not given the size change callback
   if the widget is resized on drop

Change-Id: I9cd9e6cd39009d9e5c70e745812b6ece71b845ee
diff --git a/src/com/android/launcher2/CellLayout.java b/src/com/android/launcher2/CellLayout.java
index e4b5af3..5591c9a 100644
--- a/src/com/android/launcher2/CellLayout.java
+++ b/src/com/android/launcher2/CellLayout.java
@@ -80,7 +80,6 @@
     // return an (x, y) value from helper functions. Do NOT use them to maintain other state.
     private final int[] mTmpXY = new int[2];
     private final int[] mTmpPoint = new int[2];
-    private final PointF mTmpPointF = new PointF();
     int[] mTempLocation = new int[2];
 
     boolean[][] mOccupied;
@@ -149,7 +148,7 @@
     static final int LANDSCAPE = 0;
     static final int PORTRAIT = 1;
 
-    private static final float REORDER_HINT_MAGNITUDE = 0.10f;
+    private static final float REORDER_HINT_MAGNITUDE = 0.12f;
     private static final int REORDER_ANIMATION_DURATION = 150;
     private float mReorderHintAnimationMagnitude;
 
@@ -1969,7 +1968,9 @@
             va = ValueAnimator.ofFloat(0f, 1f);
             va.setRepeatMode(ValueAnimator.REVERSE);
             va.setRepeatCount(ValueAnimator.INFINITE);
-            va.setDuration((int) (DURATION * (1.0f + Math.random()*.08f)));
+            va.setDuration(DURATION);
+            va.setStartDelay((int) ((Math.max(REORDER_ANIMATION_DURATION, delay)
+                    + Math.random() * 60)));
             va.addUpdateListener(new AnimatorUpdateListener() {
                 @Override
                 public void onAnimationUpdate(ValueAnimator animation) {
@@ -1993,7 +1994,6 @@
                     }
                 }
             });
-            va.setStartDelay(Math.max(REORDER_ANIMATION_DURATION, delay));
             mShakeAnimators.put(child, this);
             va.start();
         }