/aosp14/frameworks/base/graphics/java/android/graphics/ |
H A D | RectF.java | 58 this.top = top; in RectF() 75 top = r.top; in RectF() 86 top = r.top; in RectF() 205 this.top = top; in set() 218 this.top = src.top; in set() 231 this.top = src.top; in set() 356 if (this.top < top) { in intersect() 357 this.top = top; in intersect() 401 top = Math.max(a.top, b.top); in setIntersect() 485 this.top = top; in union() [all …]
|
H A D | Rect.java | 86 this.top = top; in Rect() 103 top = r.top; in Rect() 117 top = r.top; in Rect() 368 this.top = top; in set() 438 top += insets.top; in inset() 450 top += insets.top; in inset() 465 this.top += top; in inset() 543 if (this.top < top) this.top = top; in intersect() 575 top = Math.max(top, other.top); in intersectUnchecked() 596 top = Math.max(a.top, b.top); in setIntersect() [all …]
|
H A D | Insets.java | 36 public final int top; field in Insets 42 this.top = top; in Insets() 83 return new Rect(left, top, right, bottom); in toRect() 94 return Insets.of(a.left + b.left, a.top + b.top, a.right + b.right, a.bottom + b.bottom); in add() 105 return Insets.of(a.left - b.left, a.top - b.top, a.right - b.right, a.bottom - b.bottom); in subtract() 116 return Insets.of(Math.max(a.left, b.left), Math.max(a.top, b.top), in max() 128 return Insets.of(Math.min(a.left, b.left), Math.min(a.top, b.top), in min() 150 if (top != insets.top) return false; in equals() 158 result = 31 * result + top; in hashCode() 168 ", top=" + top + in toString() [all …]
|
H A D | Outline.java | 174 public void setRect(int left, int top, int right, int bottom) { in setRect() argument 175 setRoundRect(left, top, right, bottom, 0.0f); in setRect() 182 setRect(rect.left, rect.top, rect.right, rect.bottom); in setRect() 191 if (left >= right || top >= bottom) { in setRoundRect() 201 mRect.set(left, top, right, bottom); in setRoundRect() 243 public void setOval(int left, int top, int right, int bottom) { in setOval() argument 244 if (left >= right || top >= bottom) { in setOval() 249 if ((bottom - top) == (right - left)) { in setOval() 251 setRoundRect(left, top, right, bottom, (bottom - top) / 2.0f); in setOval() 262 mPath.addOval(left, top, right, bottom, Path.Direction.CW); in setOval() [all …]
|
H A D | Path.java | 546 addRect(rect.left, rect.top, rect.right, rect.bottom, dir); in addRect() 559 nAddRect(mNativePath, left, top, right, bottom, dir.nativeInt); in addRect() 569 addOval(oval.left, oval.top, oval.right, oval.bottom, dir); in addOval() 578 nAddOval(mNativePath, left, top, right, bottom, dir.nativeInt); in addOval() 612 nAddArc(mNativePath, left, top, right, bottom, startAngle, sweepAngle); in addArc() 652 addRoundRect(rect.left, rect.top, rect.right, rect.bottom, radii, dir); in addRoundRect() 663 public void addRoundRect(float left, float top, float right, float bottom, in addRoundRect() argument 857 private static native void nAddRect(long nPath, float left, float top, in nAddRect() argument 859 private static native void nAddOval(long nPath, float left, float top, in nAddOval() argument 864 private static native void nAddRoundRect(long nPath, float left, float top, in nAddRoundRect() argument [all …]
|
/aosp14/frameworks/base/libs/hwui/ |
H A D | Rect.h | 43 float top; variable 56 : left(left), top(top), right(right), bottom(bottom) {} in Rect() 76 a.top == b.top && 96 this->top = top; in set() 126 top = std::max(top, t); in doIntersect() 143 if (top > r.top) top = r.top; in unionWith() 149 top = r.top; in unionWith() 217 top = floorf(top + 0.5f); in snapToPixelBoundaries() 224 top = floorf(top); in roundOut() 235 top = std::min(top, other.top); in expandToCover() [all …]
|
/aosp14/frameworks/base/services/tests/wmtests/src/com/android/server/wm/ |
H A D | TaskPositionerTests.java | 117 final Rect r = new Rect(left, top, left + windowSize, top + windowSize); in testMoveWindow() 210 assertNotEquals(r.top, mPositioner.getWindowDragBounds().top); in testFreeWindowResizingTestAllEdges() 219 assertNotEquals(r.top, mPositioner.getWindowDragBounds().top); in testFreeWindowResizingTestAllEdges() 228 assertNotEquals(r.top, mPositioner.getWindowDragBounds().top); in testFreeWindowResizingTestAllEdges() 237 assertEquals(r.top, mPositioner.getWindowDragBounds().top); in testFreeWindowResizingTestAllEdges() 246 assertEquals(r.top, mPositioner.getWindowDragBounds().top); in testFreeWindowResizingTestAllEdges() 255 assertEquals(r.top, mPositioner.getWindowDragBounds().top); in testFreeWindowResizingTestAllEdges() 264 assertEquals(r.top, mPositioner.getWindowDragBounds().top); in testFreeWindowResizingTestAllEdges() 273 assertEquals(r.top, mPositioner.getWindowDragBounds().top); in testFreeWindowResizingTestAllEdges() 342 assertBoundsEquals(new Rect(r.right - w, r.top, r.right, r.top + h), in testLandscapePreservedWindowResizingDragLeft() [all …]
|
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/ |
H A D | NotificationSection.java | 94 int newEndValue = mBounds.top; in startTopAnimation() 130 mEndAnimationRect.top = -1; in startTopAnimation() 135 mStartAnimationRect.top = mCurrentBounds.top; in startTopAnimation() 189 mCurrentBounds.top = top; in setBackgroundTop() 226 public boolean isTargetTop(int top) { in isTargetTop() argument 227 return (mTopAnimator == null && mCurrentBounds.top == top) in isTargetTop() 228 || (mTopAnimator != null && mEndAnimationRect.top == top); in isTargetTop() 249 int top = minTopPosition; in updateBounds() local 264 top = Math.max(newTop, top); in updateBounds() 296 bottom = Math.max(top, bottom); in updateBounds() [all …]
|
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/util/ |
H A D | FloatingContentCoordinatorTest.kt | 54 assertEquals(rect100px.top, 0) 60 assertEquals(rect200px.top, 0) 61 assertEquals(rect100px.top, 200) 74 assertEquals(rect100px.top, 0) 75 assertEquals(rect200px.top, 0) 95 assertEquals(rect200px.top, 0) 96 assertEquals(rect100px.top, 200) 105 assertEquals(rect200px.top, 275) 106 assertEquals(rect100px.top, 175) 127 assertEquals(rect200px.top, 0) [all …]
|
/aosp14/frameworks/base/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/samples/simplecamera/ |
H A D | FaceSquareFilter.java | 85 int top = (tempRect.top+HEIGHT_OFFSET)*dims[1]/FACE_X_RANGE; in drawBoxes() local 90 if (top < 0) { in drawBoxes() 91 top = 0; in drawBoxes() 92 } else if (top > dims[1]) { in drawBoxes() 93 top = dims[1]; in drawBoxes() 111 for (int j = 0; j < (bottom - top); j++) { in drawBoxes() 113 if (left > 0 && top > 0) { in drawBoxes() 123 if (right > 0 && top > 0) { in drawBoxes() 135 if (top < dims[1]) { in drawBoxes() 136 pixels[ImageConstants.PIX_CHANNELS * (dims[0] * top + left + k) + in drawBoxes() [all …]
|
/aosp14/frameworks/base/core/java/android/view/ |
H A D | Gravity.java | 263 outRect.top = container.top in apply() 268 if (outRect.top < container.top) { in apply() 269 outRect.top = container.top; in apply() 277 outRect.top = container.top + yAdj; in apply() 291 if (outRect.top < container.top) { in apply() 292 outRect.top = container.top; in apply() 297 outRect.top = container.top + yAdj; in apply() 352 if (inoutObj.top < display.top) inoutObj.top = display.top; in applyDisplay() 356 if (inoutObj.top < display.top) off = display.top-inoutObj.top; in applyDisplay() 360 inoutObj.top = display.top; in applyDisplay() [all …]
|
/aosp14/frameworks/base/tests/Camera2Tests/SmartCamera/SimpleCamera/tests/src/androidx/media/filterfw/samples/simplecamera/ |
H A D | FaceSquareFilterTest.java | 87 int top = (faceRect.top+HEIGHT_OFFSET)*bitmap.getHeight()/FACE_X_RANGE; in testFaceSquareFilter() local 92 if (top < 0) { in testFaceSquareFilter() 93 top = 0; in testFaceSquareFilter() 94 } else if (top > bitmap.getHeight()) { in testFaceSquareFilter() 95 top = bitmap.getHeight(); in testFaceSquareFilter() 113 for (int j = 0; j < (bottom - top); j++) { in testFaceSquareFilter() 115 if (left > 0 && top > 0) { in testFaceSquareFilter() 125 if (right > 0 && top > 0) { in testFaceSquareFilter() 137 if (top < bitmap.getHeight()) { in testFaceSquareFilter() 138 pixels[ImageConstants.PIX_CHANNELS * (bitmap.getWidth() * top + left + k) + in testFaceSquareFilter() [all …]
|
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/screenshot/ |
H A D | FakeSessionTest.java | 88 assertEquals("requested top", 0, result.requested.top); in testCaptureAtZero() 90 assertEquals("captured top", 0, result.captured.top); in testCaptureAtZero() 108 assertEquals("requested top", 90, result.requested.top); in testCaptureAtPageBottom() 110 assertEquals("captured top", 90, result.captured.top); in testCaptureAtPageBottom() 130 assertEquals("captured top", -100, result.captured.top); in testCaptureFromPreviousPage() 150 assertEquals("captured top", 150, result.captured.top); in testCaptureFromNextPage() 170 assertEquals("captured top", -100, result.captured.top); in testCaptureTopPartiallyUnavailable() 190 assertEquals("captured top", 75, result.captured.top); in testCaptureBottomPartiallyUnavailable() 236 assertEquals("captured top", 50, result.captured.top); in testCaptureBottomPartiallyInvisible() 284 assertEquals("requested top", 0, result.requested.top); in testEmptyResult_notVisible() [all …]
|
/aosp14/frameworks/base/core/tests/coretests/src/android/text/ |
H A D | LayoutBidiCursorPathTest.java | 67 final int top = 0; in testGetCursorPathSegments() local 73 expectedPath.moveTo(h1, top); in testGetCursorPathSegments() 94 final int top = 0; in testGetCursorPath_whenShiftIsPressed() local 99 final int dist = (bottom - top) / 4; in testGetCursorPath_whenShiftIsPressed() 104 expectedPath.moveTo(h1, top); in testGetCursorPath_whenShiftIsPressed() 134 int top = 0; in testGetCursorPath_whenAltIsPressed() local 138 final int dist = (bottom - top) / 4; in testGetCursorPath_whenAltIsPressed() 139 top += dist; in testGetCursorPath_whenAltIsPressed() 143 expectedPath.moveTo(h1, top); in testGetCursorPath_whenAltIsPressed() 146 expectedPath.moveTo(h1, top); in testGetCursorPath_whenAltIsPressed() [all …]
|
/aosp14/frameworks/base/libs/WindowManager/Shell/src/com/android/wm/shell/common/pip/ |
H A D | PipSnapAlgorithm.java | 63 final float heightFraction = (float) (tmpBounds.top - movementBounds.top) in getSnapFraction() 65 if (tmpBounds.top == movementBounds.top) { in getSnapFraction() 69 } else if (tmpBounds.top == movementBounds.bottom) { in getSnapFraction() 91 stackBounds.offsetTo(offset, movementBounds.top); in applySnapFraction() 94 int offset = movementBounds.top + (int) (snapFraction * movementBounds.height()); in applySnapFraction() 120 stackBounds.top); in applySnapFraction() 139 final int boundedTop = Math.max(movementBounds.top, Math.min(movementBounds.bottom, in snapRectToClosestEdge() 140 stackBounds.top)); in snapRectToClosestEdge() 145 final int fromTop = Math.abs(stackBounds.top - movementBounds.top); in snapRectToClosestEdge() 147 final int fromBottom = Math.abs(movementBounds.bottom - stackBounds.top); in snapRectToClosestEdge() [all …]
|
/aosp14/frameworks/base/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/windowdecor/ |
H A D | FluidResizeTaskPositionerTest.kt | 111 STARTING_BOUNDS.top.toFloat() 132 STARTING_BOUNDS.top.toFloat() 137 STARTING_BOUNDS.top.toFloat() 158 STARTING_BOUNDS.top.toFloat() 163 STARTING_BOUNDS.top.toFloat() 180 rectAfterEnd.top += 10 195 STARTING_BOUNDS.top.toFloat() 487 STARTING_BOUNDS.top, 499 newBounds.top, 501 DISALLOWED_RESIZE_AREA.top [all …]
|
H A D | DragPositioningCallbackUtilityTest.kt | 92 val newY = STARTING_BOUNDS.top.toFloat() + 95 100 assertThat(repositionTaskBounds.top).isEqualTo(STARTING_BOUNDS.top) 112 val newY = STARTING_BOUNDS.top.toFloat() + 5 120 assertThat(repositionTaskBounds.top).isEqualTo(STARTING_BOUNDS.top + 5) 140 assertThat(repositionTaskBounds.top).isEqualTo(STARTING_BOUNDS.top) 152 val newY = STARTING_BOUNDS.top.toFloat() + 80 159 assertThat(repositionTaskBounds.top).isEqualTo(STARTING_BOUNDS.top + 80) 178 assertThat(repositionTaskBounds.top).isEqualTo(STARTING_BOUNDS.top) 199 newY = DISALLOWED_RESIZE_AREA.top.toFloat() 205 assertThat(repositionTaskBounds.top).isEqualTo(STARTING_BOUNDS.top) [all …]
|
H A D | VeiledResizeTaskPositionerTest.kt | 129 STARTING_BOUNDS.top.toFloat() 135 STARTING_BOUNDS.top.toFloat() 151 STARTING_BOUNDS.top.toFloat() 161 rectAfterMove.top += 100 173 rectAfterEnd.top += 20 192 STARTING_BOUNDS.top.toFloat() 203 rectAfterMove.top += 10 218 rectAfterEnd.top += 10 233 STARTING_BOUNDS.top.toFloat() 239 STARTING_BOUNDS.top.toFloat() [all …]
|
/aosp14/frameworks/base/packages/SystemUI/compose/core/src/com/android/compose/modifiers/ |
H A D | Padding.kt | 46 top: Density.() -> Int = PaddingUnspecified, 53 top, 61 properties["top"] = top 76 top = vertical, 94 val top: Density.() -> Int, 105 val top = top() regex 110 val vertical = top + bottom 118 placeable.placeRelative(start, top) 120 placeable.place(start, top) 127 result = 31 * result + top.hashCode() [all …]
|
/aosp14/frameworks/base/tests/UiBench/src/com/android/test/uibench/ |
H A D | SaveLayerInterleaveActivity.java | 63 int top = bounds.top; in onCreate() 70 for (int i = 0; i < regions; i++, top += smallRectHeight) { in onCreate() 71 canvas.saveLayer(bounds.left, top, bounds.right, top + padding, in onCreate() 74 canvas.drawText("offscreen line "+ i, bounds.left, top + padding, in onCreate() 78 Rect partX = new Rect(bounds.left, top + padding, in onCreate() 79 bounds.right,top + smallRectHeight - padding); in onCreate() 82 top + smallRectHeight - padding, mGreenPaint); in onCreate()
|
/aosp14/frameworks/base/core/java/com/android/internal/widget/ |
H A D | BackgroundFallback.java | 71 int top = height; in draw() local 93 top = Math.min(top, rootOffsetY + child.getTop()); in draw() 120 if (v.getTop() <= 0 && v.getBottom() >= top in draw() 122 top = 0; in draw() 130 eachBarCoversTopInY &= v.getTop() <= 0 && v.getBottom() >= top; in draw() 137 top = 0; in draw() 140 if (left >= right || top >= bottom) { in draw() 145 if (top > 0) { in draw() 146 mBackgroundFallback.setBounds(0, 0, width, top); in draw() 150 mBackgroundFallback.setBounds(0, top, left, height); in draw() [all …]
|
H A D | SimpleItemAnimator.java | 93 int oldTop = preLayoutInfo.top; in animateDisappearance() 96 int newTop = postLayoutInfo == null ? disappearingItemView.getTop() : postLayoutInfo.top; in animateDisappearance() 117 || preLayoutInfo.top != postLayoutInfo.top)) { in animateAppearance() 122 return animateMove(viewHolder, preLayoutInfo.left, preLayoutInfo.top, in animateAppearance() 123 postLayoutInfo.left, postLayoutInfo.top); in animateAppearance() 135 if (preInfo.left != postInfo.left || preInfo.top != postInfo.top) { in animatePersistence() 141 preInfo.left, preInfo.top, postInfo.left, postInfo.top); in animatePersistence() 154 final int fromTop = preInfo.top; in animateChange() 158 toTop = preInfo.top; in animateChange() 161 toTop = postInfo.top; in animateChange()
|
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/navigationbar/gestural/ |
H A D | QuickswitchOrientedNavHandle.java | 48 float top; in computeHomeHandleBounds() local 60 top = (getHeight() - mBottom - height); in computeHomeHandleBounds() 62 bottom = top + height; in computeHomeHandleBounds() 67 top = getHeight() / 2f - (mWidth / 2f) - (topStart / 2f); in computeHomeHandleBounds() 68 bottom = top + mWidth; in computeHomeHandleBounds() 73 top = getHeight() / 2f - (mWidth / 2f) - (topStart / 2f); in computeHomeHandleBounds() 74 bottom = top + mWidth; in computeHomeHandleBounds() 77 mTmpBoundsRectF.set(left, top, right, bottom); in computeHomeHandleBounds()
|
/aosp14/frameworks/base/libs/hwui/tests/common/scenes/ |
H A D | SaveLayer2Animation.cpp | 42 int top = bounds.fTop; in createContent() local 50 for (int i = 0; i < regions; i++, top += smallRectHeight) { in createContent() 51 canvas.saveLayer(bounds.fLeft, top, bounds.fRight, top + padding, &mBluePaint); in createContent() 56 top + padding); in createContent() 59 canvas.drawRect(bounds.fLeft, top + padding, bounds.fRight, in createContent() 60 top + smallRectHeight - padding, mBluePaint); in createContent() 63 top + smallRectHeight - padding); in createContent()
|
/aosp14/frameworks/base/packages/SettingsLib/src/com/android/settingslib/graph/ |
H A D | BatteryMeterDrawableBase.java | 244 super.setBounds(left, top, right, bottom); in setBounds() 251 mHeight = (bounds.bottom - mPadding.bottom) - (bounds.top + mPadding.top); in updateSize() 260 && mPadding.top == 0 in getPadding() 272 mPadding.top = top; in setPadding() 326 mFrame.set(left, top, width + left, height + top); in draw() 332 mFrame.top, in draw() 334 mFrame.top + buttonHeight); in draw() 337 mFrame.top += buttonHeight; in draw() 370 if (mBoltFrame.left != bl || mBoltFrame.top != bt in draw() 439 pctY = (mHeight + mTextHeight) * 0.47f + top; in draw() [all …]
|