Cleaning out unused lines of code

Change-Id: I558248c9e1ccf8098220b110709d2a0cba9247ea
diff --git a/src/com/android/launcher2/CellLayout.java b/src/com/android/launcher2/CellLayout.java
index b8515fc..22516cc 100644
--- a/src/com/android/launcher2/CellLayout.java
+++ b/src/com/android/launcher2/CellLayout.java
@@ -29,7 +29,6 @@
 import android.content.res.TypedArray;
 import android.graphics.Bitmap;
 import android.graphics.Canvas;
-import android.graphics.Matrix;
 import android.graphics.Paint;
 import android.graphics.Point;
 import android.graphics.PointF;
diff --git a/src/com/android/launcher2/Launcher.java b/src/com/android/launcher2/Launcher.java
index 6f64f9d..76866a7 100644
--- a/src/com/android/launcher2/Launcher.java
+++ b/src/com/android/launcher2/Launcher.java
@@ -1066,7 +1066,6 @@
             if (appWidgetId != -1) {
                 // Deleting an app widget ID is a void call but writes to disk before returning
                 // to the caller...
-                final LauncherAppWidgetHost appWidgetHost = mAppWidgetHost;
                 new Thread("deleteAppWidgetId") {
                     public void run() {
                         mAppWidgetHost.deleteAppWidgetId(appWidgetId);
@@ -2861,7 +2860,6 @@
          * Handle the action clicked in the "Add to home" dialog.
          */
         public void onClick(DialogInterface dialog, int which) {
-            Resources res = getResources();
             cleanup();
 
             AddAdapter.ListItem item = (AddAdapter.ListItem) mAdapter.getItem(which);
diff --git a/src/com/android/launcher2/Workspace.java b/src/com/android/launcher2/Workspace.java
index 611d360..cffc456 100644
--- a/src/com/android/launcher2/Workspace.java
+++ b/src/com/android/launcher2/Workspace.java
@@ -109,16 +109,11 @@
     private float mOverScrollMaxBackgroundAlpha = 0.0f;
     private int mOverScrollPageIndex = -1;
 
-
-
     private final WallpaperManager mWallpaperManager;
     private IBinder mWindowToken;
 
     private int mDefaultPage;
 
-    private boolean mIsDragInProcess = false;
-    private boolean mIsDraggingOverIcon = false;
-
     /**
      * CellInfo for the cell that is currently being dragged
      */
@@ -147,9 +142,7 @@
     private float[] mTempTouchCoordinates = new float[2];
     private float[] mTempCellLayoutCenterCoordinates = new float[2];
     private float[] mTempDragBottomRightCoordinates = new float[2];
-    private float[] mTempFloatTuple = new float[2];
     private Matrix mTempInverseMatrix = new Matrix();
-    private int[] mTempLocation = new int[2];
 
     private SpringLoadedDragController mSpringLoadedDragController;
     private float mSpringLoadedShrinkFactor;
@@ -172,9 +165,6 @@
     /** Is the user is dragging an item near the edge of a page? */
     private boolean mInScrollArea = false;
 
-    /** If mInScrollArea is true, the direction of the scroll. */
-    private int mPendingScrollDirection = DragController.SCROLL_NONE;
-
     private final HolographicOutlineHelper mOutlineHelper = new HolographicOutlineHelper();
     private Bitmap mDragOutline = null;
     private final Rect mTempRect = new Rect();
@@ -196,9 +186,6 @@
     boolean mSyncWallpaperOffsetWithScroll = true;
     private Runnable mDelayedResizeRunnable;
 
-    // info about the last drag
-    private DragView mLastDragView;
-
     // Variables relating to the creation of user folders by hovering shortcuts over shortcuts
     private static final int FOLDER_CREATION_TIMEOUT = 250;
     private final Alarm mFolderCreationAlarm = new Alarm();
@@ -255,10 +242,6 @@
             // TODO: This code currently fails on tablets with an aspect ratio < 1.3.
             // Around that ratio we should make cells the same size in portrait and
             // landscape
-            final DisplayMetrics dm = res.getDisplayMetrics();
-            float widthDp = dm.widthPixels / dm.density;
-            float heightDp = dm.heightPixels / dm.density;
-
             TypedArray actionBarSizeTypedArray =
                 context.obtainStyledAttributes(new int[] { android.R.attr.actionBarSize });
             final float actionBarHeight = actionBarSizeTypedArray.getDimension(0, 0f);
@@ -1586,8 +1569,6 @@
     *
     */
     public void onDragStartedWithItem(View v) {
-        mIsDragInProcess = true;
-
         final Canvas canvas = new Canvas();
 
         // We need to add extra padding to the bitmap to make room for the glow effect
@@ -1598,8 +1579,6 @@
     }
 
     public void onDragStartedWithItemSpans(int spanX, int spanY, Bitmap b) {
-        mIsDragInProcess = true;
-
         final Canvas canvas = new Canvas();
 
         // We need to add extra padding to the bitmap to make room for the glow effect
@@ -1620,7 +1599,6 @@
         if (!success) {
             doDragExit(null);
         }
-        mIsDragInProcess = false;
     }
 
     // We call this when we trigger an unshrink by clicking on the CellLayout cl
@@ -2311,7 +2289,6 @@
         mDragTargetLayout = getCurrentDropLayout();
         mDragTargetLayout.setIsDragOverlapping(true);
         mDragTargetLayout.onDragEnter();
-        mLastDragView = d.dragView;
 
         // Because we don't have space in the Phone UI (the CellLayouts run to the edge) we
         // don't need to show the outlines
@@ -2331,7 +2308,6 @@
             mDragTargetLayout.setIsDragOverlapping(false);
             mDragTargetLayout.onDragExit();
         }
-        mLastDragView = null;
         mLastDragOverView = null;
 
         if (!mIsPageMoving) {
@@ -2578,10 +2554,6 @@
      *
      */
     private CellLayout findMatchingPageForDragOver(
-            DragView dragView, int originX, int originY, int offsetX, int offsetY) {
-        return findMatchingPageForDragOver(dragView, originX, originY, offsetX, offsetY, false);
-    }
-    private CellLayout findMatchingPageForDragOver(
             DragView dragView, int originX, int originY, int offsetX, int offsetY, boolean exact) {
         // We loop through all the screens (ie CellLayouts) and see which ones overlap
         // with the item being dragged and then choose the one that's closest to the touch point
@@ -3032,7 +3004,6 @@
     public void onEnterScrollArea(int direction) {
         if (!mIsSmall && !mIsInUnshrinkAnimation) {
             mInScrollArea = true;
-            mPendingScrollDirection = direction;
 
             final int page = mCurrentPage + (direction == DragController.SCROLL_LEFT ? -1 : 1);
             final CellLayout layout = (CellLayout) getChildAt(page);
@@ -3067,7 +3038,6 @@
                 // so we need to redraw the workspace when this may have changed.
                 invalidate();
             }
-            mPendingScrollDirection = DragController.SCROLL_NONE;
             mInScrollArea = false;
         }
     }
@@ -3081,7 +3051,6 @@
             // so we need to redraw the workspace when this may have changed.
             invalidate();
         }
-        mPendingScrollDirection = DragController.SCROLL_NONE;
         mInScrollArea = false;
     }