Move color extraction utils to extractor class so each instance can
have its own set of temp variables.

- Pass in float[] param to not create new obj in each frame
  for dragging widget case.

Bug: 175329686
Bug: 187019711
Test: manual, verify
Change-Id: I4350fb7e66a80c73def5659fb41abc14d357e667
diff --git a/src/com/android/launcher3/CellLayout.java b/src/com/android/launcher3/CellLayout.java
index af625a5..1df9df6 100644
--- a/src/com/android/launcher3/CellLayout.java
+++ b/src/com/android/launcher3/CellLayout.java
@@ -195,6 +195,7 @@
 
     private final Rect mTempRect = new Rect();
     private final RectF mTempRectF = new RectF();
+    private final float[] mTmpFloatArray = new float[4];
 
     private static final Paint sPaint = new Paint();
 
@@ -1080,7 +1081,7 @@
 
             // Now get the rect in drag layer coordinates.
             getBoundsForViewInDragLayer(launcher.getDragLayer(), workspace, mTempRect, false,
-                    mTempRectF);
+                    mTmpFloatArray, mTempRectF);
             Utilities.setRect(mTempRectF, mTempRect);
             ((LauncherAppWidgetHostView) view).handleDrag(mTempRect, pageId);
         }