/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/keyboard/ |
D | PointerTracker.java | 325 final int y, final long eventTime, final boolean isKeyRepeat) { in callListenerOnCodeInput() argument 332 Log.d(TAG, String.format("[%d] onCodeInput: %4d %4d %s%s%s", mPointerId, x, y, in callListenerOnCodeInput() 346 sListener.onCodeInput(code, x, y, isKeyRepeat); in callListenerOnCodeInput() 428 public Key getKeyOn(final int x, final int y) { in getKeyOn() argument 429 return mKeyDetector.detectHitKey(x, y); in getKeyOn() 533 private Key onDownKey(final int x, final int y, final long eventTime) { in onDownKey() argument 535 CoordinateUtils.set(mDownCoordinates, x, y); in onDownKey() 537 return onMoveToNewKey(onMoveKeyInternal(x, y), x, y); in onDownKey() 544 private Key onMoveKeyInternal(final int x, final int y) { in onMoveKeyInternal() argument 545 mBogusMoveEventDetector.onMoveKey(getDistance(x, y, mLastX, mLastY)); in onMoveKeyInternal() [all …]
|
D | MoreKeysKeyboardView.java | 130 final int y = pointY - container.getMeasuredHeight() + container.getPaddingBottom() in showMoreKeysPanel() local 137 final int panelY = y + CoordinateUtils.y(mCoordinates); in showMoreKeysPanel() 142 mOriginY = y + container.getPaddingTop(); in showMoreKeysPanel() 159 public void onDownEvent(final int x, final int y, final int pointerId, final long eventTime) { in onDownEvent() argument 161 mCurrentKey = detectKey(x, y); in onDownEvent() 165 public void onMoveEvent(final int x, final int y, final int pointerId, final long eventTime) { in onMoveEvent() argument 170 mCurrentKey = detectKey(x, y); in onMoveEvent() 178 public void onUpEvent(final int x, final int y, final int pointerId, final long eventTime) { in onUpEvent() argument 184 mCurrentKey = detectKey(x, y); in onUpEvent() 187 onKeyInput(mCurrentKey, x, y); in onUpEvent() [all …]
|
/packages/apps/Launcher2/src/com/android/launcher2/ |
D | CellLayout.java | 330 public void setGridSize(int x, int y) { in setGridSize() argument 332 mCountY = y; in setGridSize() 566 public void setFolderLeaveBehindCell(int x, int y) { in setFolderLeaveBehindCell() argument 568 mFolderLeaveBehindCell[1] = y; in setFolderLeaveBehindCell() 715 final int y = touchY + getScrollY(); in setTagToCellInfoForPoint() local 737 if (frame.contains(x, y)) { in setTagToCellInfoForPoint() 753 pointToCellExact(x, y, cellXY); in setTagToCellInfoForPoint() 806 void pointToCellExact(int x, int y, int[] result) { in pointToCellExact() argument 811 result[1] = (y - vStartPadding) / (mCellHeight + mHeightGap); in pointToCellExact() 828 void pointToCellRounded(int x, int y, int[] result) { in pointToCellRounded() argument [all …]
|
/packages/apps/Launcher3/src/com/android/launcher3/ |
D | CellLayout.java | 316 public void setGridSize(int x, int y) { in setGridSize() argument 318 mCountY = y; in setGridSize() 536 public void setFolderLeaveBehindCell(int x, int y) { in setFolderLeaveBehindCell() argument 538 mFolderLeaveBehindCell[1] = y; in setFolderLeaveBehindCell() 696 void pointToCellExact(int x, int y, int[] result) { in pointToCellExact() argument 701 result[1] = (y - vStartPadding) / (mCellHeight + mHeightGap); in pointToCellExact() 718 void pointToCellRounded(int x, int y, int[] result) { in pointToCellRounded() argument 719 pointToCellExact(x + (mCellWidth / 2), y + (mCellHeight / 2), result); in pointToCellRounded() 783 public float getDistanceFromCell(float x, float y, int[] cell) { in getDistanceFromCell() argument 786 Math.pow(y - mTmpPoint[1], 2)); in getDistanceFromCell() [all …]
|
D | DragController.java | 178 int viewExtraPaddingTop = extraPadding != null ? extraPadding.y : 0; in startDrag() 394 private int[] getClampedDragLayerPos(float x, float y) { in getClampedDragLayerPos() argument 397 mTmpPoint[1] = (int) Math.max(mDragLayerRect.top, Math.min(y, mDragLayerRect.bottom - 1)); in getClampedDragLayerPos() 485 private void handleMoveEvent(int x, int y) { in handleMoveEvent() argument 486 mDragObject.dragView.move(x, y); in handleMoveEvent() 490 DropTarget dropTarget = findDropTarget(x, y, coordinates); in handleMoveEvent() 492 mDragObject.y = coordinates[1]; in handleMoveEvent() 497 Math.sqrt(Math.pow(mLastTouch[0] - x, 2) + Math.pow(mLastTouch[1] - y, 2)); in handleMoveEvent() 499 mLastTouch[1] = y; in handleMoveEvent() 500 checkScrollState(x, y); in handleMoveEvent() [all …]
|
/packages/inputmethods/OpenWnn/src/jp/co/omronsoft/openwnn/ |
D | Keyboard.java | 247 public int y; field in Keyboard.Key 323 public Key(Resources res, Row parent, int x, int y, XmlResourceParser parser) { in Key() argument 327 this.y = y; in Key() 442 public boolean isInside(int x, int y) { in isInside() argument 449 && (y >= this.y || (topEdge && y <= this.y + this.height)) in isInside() 450 && (y < this.y + this.height || (bottomEdge && y >= this.y))) { in isInside() 465 public boolean isInside(int x, int y, int w, int h) { in isInside() argument 467 && (this.y <= (y + h)) && (y <= (this.y + this.height))) { in isInside() 480 public int squaredDistanceFrom(int x, int y) { in squaredDistanceFrom() argument 482 int yDist = this.y + height / 2 - y; in squaredDistanceFrom() [all …]
|
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/imageshow/ |
D | Spline.java | 112 public void movePoint(int pick, float x, float y) { in movePoint() argument 118 point.y = y; in movePoint() 126 if (mPoints.elementAt(0).x != 0 || mPoints.elementAt(0).y != 1) { in isOriginal() 129 if (mPoints.elementAt(1).x != 1 || mPoints.elementAt(1).y != 0) { in isOriginal() 153 points[i] = new ControlPoint(p.x, p.y); in getAppliedCurve() 165 curve[i] = 1.0f - points[0].y; in getAppliedCurve() 168 curve[i] = 1.0f - points[points.length - 1].y; in getAppliedCurve() 185 double y1 = cur.y; in getAppliedCurve() 186 double y2 = next.y; in getAppliedCurve() 198 double y = ta + tb + (delta2 / 6) * (tc + td); in getAppliedCurve() local [all …]
|
D | ImageShow.java | 232 m.postTranslate(translate.x, translate.y); in getImageToScreenMatrix() 408 float y = point.y - maskH * maskScale; in drawImageAndAnimate() local 413 mShaderMatrix.preTranslate(-x + mImageBounds.left, -y + mImageBounds.top); in drawImageAndAnimate() 425 canvas.translate(x, y); in drawImageAndAnimate() 524 if (Math.abs(mTouch.y - mTouchDown.y) > Math.abs(mTouch.x - mTouchDown.x)) { in drawCompareImage() 535 py = mTouch.y - mImageBounds.top; in drawCompareImage() 552 if (mTouchDown.y - mTouch.y > 0) { in drawCompareImage() 565 canvas.drawLine(mImageBounds.left, mTouch.y, in drawCompareImage() 566 mImageBounds.right, mTouch.y, paint); in drawCompareImage() 634 mTouchDown.y = ey; in onTouchEvent() [all …]
|
D | EclipseControl.java | 67 public void setRadius(float x, float y) { in setRadius() argument 69 mRadiusY = y; in setRadius() 72 public void setCenter(float x, float y) { in setCenter() argument 74 mCenterY = y; in setCenter() 77 public int getCloseHandle(float x, float y) { in getCloseHandle() argument 82 float dy = handley[i] - y; in getCloseHandle() 95 float dy = handley[i] - y; in getCloseHandle() 111 public void actionDown(float x, float y, Oval oval) { in actionDown() argument 113 x, y}; in actionDown() 124 public void actionMove(int handle, float x, float y, Oval oval) { in actionMove() argument [all …]
|
/packages/apps/Gallery2/jni/filters/ |
D | redEyeMath.c | 36 int y, x; in findPossible() local 38 for (y = 0; y < recH; y++) { in findPossible() 39 int sy = (recY + y) * iw; in findPossible() 46 mask[x + y * recW] = ( in findPossible() 47 mask[x + y * recW] > 0 && (value(r, g, b) > 240) ? 1 : 0); in findPossible() 57 int y, x; in findReds() local 59 for (y = 0; y < recH; y++) { in findReds() 60 int sy = (recY + y) * iw; in findReds() 64 mask[x + y * recW] = ((isRed(src, p)) ? 1 : 0); in findReds() 74 int y, x; in dialateMaskIfRed() local [all …]
|
/packages/apps/Dialer/src/com/android/dialer/widget/ |
D | ViewDragHelper.java | 764 int y = mScroller.getCurrY(); 768 if (y - mCapturedView.getTop() > 0) { 769 y = Math.min(y, mFinalScrollY); 771 y = Math.max(y, mFinalScrollY); 773 final int dy = y - mCapturedView.getTop(); 777 mCallback.onViewPositionChanged(mCapturedView, 0, y, 0, dy); 780 if (keepGoing && y == mFinalScrollY) { 896 private void saveInitialMotion(float x, float y, int pointerId) { 899 mInitialMotionY[pointerId] = mLastMotionY[pointerId] = y; 900 mInitialEdgesTouched[pointerId] = getEdgesTouched((int) x, (int) y); [all …]
|
/packages/apps/ContactsCommon/src/com/android/contacts/common/list/ |
D | PinnedHeaderListView.java | 85 int y; field in PinnedHeaderListView.PinnedHeader 218 windowTop = header.y + header.height; in onItemSelected() 220 windowBottom = header.y; in onItemSelected() 259 public void setHeaderPinnedAtTop(int viewIndex, int y, boolean animate) { in setHeaderPinnedAtTop() argument 263 header.y = y; in setHeaderPinnedAtTop() 277 public void setHeaderPinnedAtBottom(int viewIndex, int y, boolean animate) { in setHeaderPinnedAtBottom() argument 283 header.sourceY = header.y; in setHeaderPinnedAtBottom() 284 header.targetY = y; in setHeaderPinnedAtBottom() 285 } else if (animate && (header.y != y || !header.visible)) { in setHeaderPinnedAtBottom() 287 header.sourceY = header.y; in setHeaderPinnedAtBottom() [all …]
|
/packages/experimental/DreamTheater/src/com/android/dreamtheater/ |
D | BouncyDroid.java | 52 float y; field in BouncyDroid.BouncyView.World.Vec 54 x = y = 0; in Vec() 58 y = _y; in Vec() 61 return new Vec(x + v.x, y + v.y); in add() 64 return new Vec(x * a, y * a); in mul() 67 return new Vec(x - v.x, y - v.y); in sub() 70 return (float) Math.hypot(x, y); in mag() 74 return new Vec(x*k, y*k); in norm() 77 return "(" + x + "," + y + ")"; in toString() 279 if (mBody.p.y - mBody.r < 0) { in reset() [all …]
|
/packages/apps/Gallery2/src/com/android/gallery3d/filtershow/tools/ |
D | MatrixFit.java | 162 for (int y = 0; y < h; y++) { in gaussianElimination() 163 int maxrow = y; in gaussianElimination() 164 for (int y2 = y + 1; y2 < h; y2++) { // Find max pivot in gaussianElimination() 165 if (Math.abs(m[y2][y]) > Math.abs(m[maxrow][y])) { in gaussianElimination() 171 double t = m[y][i]; in gaussianElimination() 172 m[y][i] = m[maxrow][i]; in gaussianElimination() 176 if (Math.abs(m[y][y]) <= sEPS) { // Singular Matrix in gaussianElimination() 179 for (int y2 = y + 1; y2 < h; y2++) { // Eliminate column y in gaussianElimination() 180 double c = m[y2][y] / m[y][y]; in gaussianElimination() 181 for (int x = y; x < w; x++) { in gaussianElimination() [all …]
|
/packages/apps/Camera/src/com/android/camera/ui/ |
D | PieRenderer.java | 127 mListener.onPieOpened(mCenter.x, mCenter.y); 272 public void setCenter(int x, int y) { in setCenter() argument 274 mCenter.y = y; in setCenter() 276 alignFocus(x, y); in setCenter() 314 int y = mCenter.y - (int) (r * Math.sin(angle)) - h / 2; in layoutItems() local 316 item.setBounds(x, y, x + w, y + h); in layoutItems() 329 new RectF(center.x - outer, center.y - outer, center.x + outer, in makeSlice() 330 center.y + outer); in makeSlice() 332 new RectF(center.x - inner, center.y - inner, center.x + inner, in makeSlice() 333 center.y + inner); in makeSlice() [all …]
|
/packages/apps/Music/src/com/android/music/ |
D | TouchInterceptor.java | 120 int y = (int) ev.getY(); in onInterceptTouchEvent() local 121 int itemnum = pointToPosition(x, y); in onInterceptTouchEvent() 127 mDragPointY = y - item.getTop(); in onInterceptTouchEvent() 129 mYOffset = ((int)ev.getRawY()) - y; in onInterceptTouchEvent() 136 startDragging(bitmap, x, y); in onInterceptTouchEvent() 141 mUpperBound = Math.min(y - touchSlop, mHeight / 3); in onInterceptTouchEvent() 142 mLowerBound = Math.max(y + touchSlop, mHeight * 2 /3); in onInterceptTouchEvent() 156 private int myPointToPosition(int x, int y) { in myPointToPosition() argument 158 if (y < 0) { in myPointToPosition() 161 int pos = myPointToPosition(x, y + mItemHeightNormal); in myPointToPosition() [all …]
|
/packages/apps/Browser/src/com/android/browser/view/ |
D | PieMenu.java | 232 private void setCenter(int x, int y) { in setCenter() argument 238 mCenter.y = y; in setCenter() 262 int y = mCenter.y - (int) (r * Math.cos(angle)) - h / 2; in layoutPie() local 268 view.layout(x, y, x + w, y + h); in layoutPie() 300 int top = mCenter.y - h / 2; in onDraw() 339 canvas.rotate(r, mCenter.x, mCenter.y); in drawItem() 353 new RectF(center.x - outer, center.y - outer, center.x + outer, in makeSlice() 354 center.y + outer); in makeSlice() 356 new RectF(center.x - inner, center.y - inner, center.x + inner, in makeSlice() 357 center.y + inner); in makeSlice() [all …]
|
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/keyboard/internal/ |
D | GestureStrokeRecognitionPoints.java | 112 public void addDownEventPoint(final int x, final int y, final int elapsedTimeSinceFirstDown, in addDownEventPoint() argument 124 addEventPoint(x, y, elapsedTimeSinceFirstDown, true /* isMajorEvent */); in addDownEventPoint() 184 final int y = mYCoordinates.get(lastIndex); in duplicateLastPointWith() local 187 x, y, time)); in duplicateLastPointWith() 190 appendPoint(x, y, time); in duplicateLastPointWith() 191 updateIncrementalRecognitionSize(x, y, time); in duplicateLastPointWith() 206 private void appendPoint(final int x, final int y, final int time) { in appendPoint() argument 213 x, y, time, mXCoordinates.get(lastIndex), mYCoordinates.get(lastIndex), in appendPoint() 219 mYCoordinates.add(y); in appendPoint() 222 private void updateMajorEvent(final int x, final int y, final int time) { in updateMajorEvent() argument [all …]
|
/packages/apps/Camera/jni/feature_mos/src/mosaic/ |
D | Blend.cpp | 200 … FindQuadCentroid(x0, y0, x1, y1, x2, y2, x3, y3, csite->getVCenter().x, csite->getVCenter().y); in runBlend() 454 for(int y = 0; y < imgMos.Y.height; y++) in DoMergeAndBlend() local 463 if (imgMos.Y.ptr[y][x] != imgMos.Y.ptr[y][x+1] && in DoMergeAndBlend() 464 imgMos.Y.ptr[y][x] != 255 && in DoMergeAndBlend() 465 imgMos.Y.ptr[y][x+1] != 255) in DoMergeAndBlend() 468 unsigned char idx1 = imgMos.Y.ptr[y][x]; in DoMergeAndBlend() 469 unsigned char idx2 = imgMos.Y.ptr[y][x+1]; in DoMergeAndBlend() 474 imgMos.V.ptr[y][x - o] = idx2; in DoMergeAndBlend() 476 imgMos.U.ptr[y][x - o] = 50 + (99 - 50) * o / tw; in DoMergeAndBlend() 482 imgMos.V.ptr[y][x + o] = idx1; in DoMergeAndBlend() [all …]
|
/packages/apps/LegacyCamera/jni/feature_mos/src/mosaic/ |
D | Blend.cpp | 200 … FindQuadCentroid(x0, y0, x1, y1, x2, y2, x3, y3, csite->getVCenter().x, csite->getVCenter().y); in runBlend() 454 for(int y = 0; y < imgMos.Y.height; y++) in DoMergeAndBlend() local 463 if (imgMos.Y.ptr[y][x] != imgMos.Y.ptr[y][x+1] && in DoMergeAndBlend() 464 imgMos.Y.ptr[y][x] != 255 && in DoMergeAndBlend() 465 imgMos.Y.ptr[y][x+1] != 255) in DoMergeAndBlend() 468 unsigned char idx1 = imgMos.Y.ptr[y][x]; in DoMergeAndBlend() 469 unsigned char idx2 = imgMos.Y.ptr[y][x+1]; in DoMergeAndBlend() 474 imgMos.V.ptr[y][x - o] = idx2; in DoMergeAndBlend() 476 imgMos.U.ptr[y][x - o] = 50 + (99 - 50) * o / tw; in DoMergeAndBlend() 482 imgMos.V.ptr[y][x + o] = idx1; in DoMergeAndBlend() [all …]
|
/packages/inputmethods/LatinIME/java/src/com/android/inputmethod/latin/ |
D | InputView.java | 74 final int y = (int)me.getY(index) + rect.top; in onInterceptTouchEvent() local 78 if (mKeyboardTopPaddingForwarder.onInterceptTouchEvent(x, y, me)) { in onInterceptTouchEvent() 85 if (mMoreSuggestionsViewCanceler.onInterceptTouchEvent(x, y, me)) { in onInterceptTouchEvent() 104 final int y = (int)me.getY(index) + rect.top; in onTouchEvent() local 105 return mActiveForwarder.onTouchEvent(x, y, me); in onTouchEvent() 130 protected abstract boolean needsToForward(final int x, final int y); in needsToForward() argument 138 protected int translateY(final int y) { in translateY() argument 139 return y - mEventReceivingRect.top; in translateY() 147 public boolean onInterceptTouchEvent(final int x, final int y, final MotionEvent me) { in onInterceptTouchEvent() argument 155 if (!mEventSendingRect.contains(x, y)) { in onInterceptTouchEvent() [all …]
|
/packages/apps/Gallery2/src/com/android/gallery3d/glrenderer/ |
D | GLES11Canvas.java | 177 public void drawRect(float x, float y, float width, float height, GLPaint paint) { in drawRect() argument 184 translate(x, y); in drawRect() 213 public void fillRect(float x, float y, float width, float height, int color) { in fillRect() argument 218 translate(x, y); in fillRect() 229 public void translate(float x, float y, float z) { in translate() argument 230 Matrix.translateM(mMatrixValues, 0, x, y, z); in translate() 237 public void translate(float x, float y) { in translate() argument 239 m[12] += m[0] * x + m[4] * y; in translate() 240 m[13] += m[1] * x + m[5] * y; in translate() 241 m[14] += m[2] * x + m[6] * y; in translate() [all …]
|
D | TiledTexture.java | 139 int y = BORDER_SIZE - offsetY; in onGetBitmap() local 141 int b = localBitmapRef.getHeight() + y; in onGetBitmap() 142 sCanvas.drawBitmap(localBitmapRef, x, y, sBitmapPaint); in onGetBitmap() 147 if (y > 0) sCanvas.drawLine(0, y - 1, TILE_SIZE, y - 1, sPaint); in onGetBitmap() 208 for (int y = 0, h = mHeight; y < h; y += CONTENT_SIZE) { in TiledTexture() 211 tile.offsetY = y; in TiledTexture() 215 Math.min(CONTENT_SIZE, mHeight - y)); in TiledTexture() 266 RectF src, float x0, float y0, float x, float y, float scaleX, in mapRect() argument 269 y + (src.top - y0) * scaleY, in mapRect() 271 y + (src.bottom - y0) * scaleY); in mapRect() [all …]
|
/packages/inputmethods/LatinIME/native/jni/src/suggest/core/layout/ |
D | proximity_info_utils.h | 63 const int y = inputYCoordinates[i]; in initializeProximities() local 67 keyCount, x, y, primaryKey, localeStr, codeToKeyMap, proximities); in initializeProximities() 83 static AK_FORCE_INLINE int getStartIndexFromCoordinates(const int x, const int y, in getStartIndexFromCoordinates() argument 85 return ((y / cellHeight) * gridWidth + (x / cellWidth)) * MAX_PROXIMITY_CHARS_SIZE; in getStartIndexFromCoordinates() 93 static inline float pointToLineSegSquaredDistanceFloat(const float x, const float y, in pointToLineSegSquaredDistanceFloat() argument 96 const float ray1y = y - y1; in pointToLineSegSquaredDistanceFloat() 105 return getSquaredDistanceFloat(x, y, x1, y1); in pointToLineSegSquaredDistanceFloat() 121 return getSquaredDistanceFloat(x, y, projectionX, projectionY); in pointToLineSegSquaredDistanceFloat() 133 const int y) { in isOnKey() argument 139 return left < right && top < bottom && x >= left && x < right && y >= top && y < bottom; in isOnKey() [all …]
|
/packages/inputmethods/LatinIME/tests/src/com/android/inputmethod/latin/ |
D | InputPointersTests.java | 59 final int y = i * 2; in testAdd() local 62 src.addPointer(x, y, pointerId, time); in testAdd() 67 final int y = i * 2; in testAdd() local 71 assertEquals("yCoordinates at " + i, y, src.getYCoordinates()[i]); in testAdd() 82 final int y = i * 2; in testAddAt() local 85 src.addPointerAt(i, x, y, pointerId, time); in testAddAt() 90 final int y = i * 2; in testAddAt() local 94 assertEquals("yCoordinates at " + i, y, src.getYCoordinates()[i]); in testAddAt() 105 final int y = i * 2; in testSet() local 108 src.addPointer(x, y, pointerId, time); in testSet() [all …]
|