/**
   * Starts a drag.
   *
   * @param v The view that is being dragged
   * @param source An object representing where the drag originated
   * @param dragInfo The data associated with the object that is being dragged
   * @param dragAction The drag action: either {@link #DRAG_ACTION_MOVE} or {@link
   *     #DRAG_ACTION_COPY}
   */
  public void startDrag(View v, DragSource source, Object dragInfo, int dragAction) {
    mOriginator = v;
    mView = source;
    Bitmap b = getViewBitmap(v);

    if (b == null) {
      // out of memory?
      return;
    }

    int[] loc = mCoordinatesTemp;
    v.getLocationOnScreen(loc);
    int screenX = loc[0];
    int screenY = loc[1];

    startDrag(b, screenX, screenY, 0, 0, b.getWidth(), b.getHeight(), source, dragInfo, dragAction);

    b.recycle();

    if (dragAction == DRAG_ACTION_MOVE) {
      v.setVisibility(View.GONE);
    }
  }