Home
last modified time | relevance | path

Searched refs:rotation (Results 1 – 25 of 282) sorted by relevance

12345678910>>...12

/aosp14/frameworks/base/core/java/android/util/
H A DRotationUtils.java49 switch (rotation) { in rotateInsets()
100 @Rotation int rotation) { in rotateBounds() argument
103 switch (rotation) { in rotateBounds()
152 @Rotation int rotation) { in rotateSurface() argument
156 switch (rotation) { in rotateSurface()
180 switch (rotation) { in rotatePoint()
203 switch (rotation) { in rotatePointF()
229 switch (rotation) { in transformPhysicalToLogicalCoordinates()
262 rotation = Surface.ROTATION_270; in reverseRotationDirectionAroundZAxis()
264 rotation = Surface.ROTATION_90; in reverseRotationDirectionAroundZAxis()
[all …]
/aosp14/frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/udfps/
H A DUdfpsUtilsTest.java56 int rotation = Surface.ROTATION_0; in testTouchOutsideAreaNoRotation() local
61 new UdfpsOverlayParams(new Rect(), new Rect(), 0, 0, 1f, rotation) in testTouchOutsideAreaNoRotation()
68 new UdfpsOverlayParams(new Rect(), new Rect(), 0, 0, 1f, rotation) in testTouchOutsideAreaNoRotation()
75 new UdfpsOverlayParams(new Rect(), new Rect(), 0, 0, 1f, rotation) in testTouchOutsideAreaNoRotation()
82 new UdfpsOverlayParams(new Rect(), new Rect(), 0, 0, 1f, rotation) in testTouchOutsideAreaNoRotation()
90 int rotation = Surface.ROTATION_90; in testTouchOutsideAreaNoRotation90Degrees() local
95 new UdfpsOverlayParams(new Rect(), new Rect(), 0, 0, 1f, rotation) in testTouchOutsideAreaNoRotation90Degrees()
102 new UdfpsOverlayParams(new Rect(), new Rect(), 0, 0, 1f, rotation) in testTouchOutsideAreaNoRotation90Degrees()
109 new UdfpsOverlayParams(new Rect(), new Rect(), 0, 0, 1f, rotation) in testTouchOutsideAreaNoRotation90Degrees()
116 new UdfpsOverlayParams(new Rect(), new Rect(), 0, 0, 1f, rotation) in testTouchOutsideAreaNoRotation90Degrees()
[all …]
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/navigationbar/gestural/
H A DFloatingRotationButtonPositionCalculatorTest.kt23 testCase.rotation,
32 val rotation: Int,
45 append(", rotation = $rotation")
71 rotation = Surface.ROTATION_0,
82 rotation = Surface.ROTATION_90,
115 rotation = Surface.ROTATION_0,
126 rotation = Surface.ROTATION_0,
137 rotation = Surface.ROTATION_90,
150 rotation = Surface.ROTATION_0,
194 rotation = Surface.ROTATION_0,
[all …]
/aosp14/frameworks/base/libs/WindowManager/Jetpack/tests/unittest/src/androidx/window/util/
H A DExtensionHelperTest.java65 for (int rotation : ROTATIONS) { in testRotateRectToDisplayRotation()
66 final Rect expectedResult = getExpectedFeatureRectAfterRotation(rotation); in testRotateRectToDisplayRotation()
72 ExtensionHelper.rotateRectToDisplayRotation(displayInfo, rotation, rect); in testRotateRectToDisplayRotation()
74 "Result Rect should equal to expected for rotation: " + rotation in testRotateRectToDisplayRotation()
82 private static DisplayInfo getMockDisplayInfo(@Surface.Rotation int rotation) { in getMockDisplayInfo() argument
84 displayInfo.rotation = rotation; in getMockDisplayInfo()
85 if (rotation == Surface.ROTATION_0 || rotation == Surface.ROTATION_180) { in getMockDisplayInfo()
101 private static Rect getExpectedFeatureRectAfterRotation(@Surface.Rotation int rotation) { in getExpectedFeatureRectAfterRotation() argument
102 switch (rotation) { in getExpectedFeatureRectAfterRotation()
116 throw new IllegalArgumentException("Unknown rotation value: " + rotation); in getExpectedFeatureRectAfterRotation()
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/decor/
H A DRoundedCornerDecorProviderImpl.kt42 @Surface.Rotation rotation: Int,
48 initView(view, rotation, tintColor)
59 alignedBound1.toLayoutGravity(rotation) or alignedBound2.toLayoutGravity(rotation)
69 @Surface.Rotation rotation: Int,
73 view.adjustRotation(alignedBounds, rotation)
80 @Surface.Rotation rotation: Int,
86 initView((view as ImageView), rotation, tintColor)
97 alignedBound2.toLayoutGravity(rotation)
104 private fun Int.toLayoutGravity(@Surface.Rotation rotation: Int): Int = when (rotation) {
167 when (rotation) {
[all …]
H A DOverlayWindow.kt37 @Surface.Rotation rotation: Int,
40 val view = decorProvider.inflateView(context, rootView, rotation, tintColor)
85 @Surface.Rotation rotation: Int,
94 rotation = rotation,
104 rotation = rotation,
/aosp14/frameworks/base/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/utils/
H A DCommonAssertions.kt250 rotation: Rotation
261 rotation: Rotation
263 val displayBounds = WindowUtils.getDisplayBounds(rotation)
372 rotation: Rotation,
384 rotation: Rotation,
396 rotation: Rotation,
408 rotation: Rotation,
420 val displayBounds = WindowUtils.getDisplayBounds(rotation)
421 return if (rotation.isRotated()) {
439 val displayBounds = WindowUtils.getDisplayBounds(rotation)
[all …]
/aosp14/frameworks/base/core/java/android/view/
H A DPrivacyIndicatorBounds.java50 public PrivacyIndicatorBounds(@NonNull Rect[] staticBounds, @Surface.Rotation int rotation) { in PrivacyIndicatorBounds() argument
52 mRotation = rotation; in PrivacyIndicatorBounds()
67 @Surface.Rotation int rotation) { in updateBoundsForRotation() argument
68 if (rotation >= mStaticBounds.length || rotation < 0) { in updateBoundsForRotation()
72 newBounds[rotation] = bounds; in updateBoundsForRotation()
107 public PrivacyIndicatorBounds rotate(@Surface.Rotation int rotation) { in rotate() argument
108 if (rotation == ROTATION_0) { in rotate()
111 return new PrivacyIndicatorBounds(mStaticBounds, rotation); in rotate()
215 int rotation = in.readInt(); in PrivacyIndicatorBounds() local
220 this.mRotation = rotation; in PrivacyIndicatorBounds()
/aosp14/frameworks/base/services/tests/wmtests/src/com/android/server/wm/
H A DDisplayPolicyTestsBase.java78 DisplayInfo displayInfoAndCutoutForRotation(int rotation, boolean withDisplayCutout, in displayInfoAndCutoutForRotation() argument
81 final boolean flippedDimensions = rotation == ROTATION_90 || rotation == ROTATION_270; in displayInfoAndCutoutForRotation()
84 info.rotation = rotation; in displayInfoAndCutoutForRotation()
88 info.displayCutout = mDisplayContent.calculateDisplayCutoutForRotation(rotation); in displayInfoAndCutoutForRotation()
94 private static DisplayCutout displayCutoutForRotation(int rotation, boolean isLongEdgeCutout) { in displayCutoutForRotation() argument
103 transformPhysicalToLogicalCoordinates(rotation, DISPLAY_WIDTH, DISPLAY_HEIGHT, m); in displayCutoutForRotation()
107 switch (rotation) { in displayCutoutForRotation()
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/phone/
H A DStatusBarContentInsetsProvider.kt139 val key = getCacheKey(rotation, displayCutout)
165 val key = getCacheKey(rotation, displayCutout)
172 val width = point.logicalWidth(rotation)
175 rotation, displayCutout, getResourcesForRotation(rotation, context), key)
199 @Rotation rotation: Int
202 val key = getCacheKey(rotation, displayCutout)
204 rotation, displayCutout, getResourcesForRotation(rotation, context), key)
211 val rotation = getExactRotation(context) regex
278 @Rotation rotation: Int,
281 rotation = rotation,
[all …]
/aosp14/frameworks/base/services/core/java/com/android/server/wm/utils/
H A DCoordinateTransforms.java42 public static void transformPhysicalToLogicalCoordinates(@Rotation int rotation, in transformPhysicalToLogicalCoordinates() argument
44 switch (rotation) { in transformPhysicalToLogicalCoordinates()
61 throw new IllegalArgumentException("Unknown rotation: " + rotation); in transformPhysicalToLogicalCoordinates()
72 public static void transformLogicalToPhysicalCoordinates(@Rotation int rotation, in transformLogicalToPhysicalCoordinates() argument
74 switch (rotation) { in transformLogicalToPhysicalCoordinates()
91 throw new IllegalArgumentException("Unknown rotation: " + rotation); in transformLogicalToPhysicalCoordinates()
106 final boolean flipped = info.rotation == ROTATION_90 || info.rotation == ROTATION_270; in transformToRotation()
H A DRotationCache.java48 public R getOrCompute(T t, int rotation) { in getOrCompute() argument
53 final int idx = mCache.indexOfKey(rotation); in getOrCompute()
57 final R result = mComputation.compute(t, rotation); in getOrCompute()
58 mCache.put(rotation, result); in getOrCompute()
68 R compute(T t, int rotation); in compute() argument
/aosp14/frameworks/base/packages/SettingsLib/src/com/android/settingslib/udfps/
H A DUdfpsOverlayParams.kt33 @Rotation val rotation: Int = Surface.ROTATION_0
44 if (rotation == Surface.ROTATION_90 || rotation == Surface.ROTATION_270) {
52 if (rotation == Surface.ROTATION_90 || rotation == Surface.ROTATION_270) {
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/biometrics/data/repository/
H A DDisplayStateRepository.kt106 var rotation = cachedDisplayInfo.rotation regex
108 rotation = (rotation + 1) % 4
110 return rotation.toDisplayRotation()
122 val rotation = getDisplayRotation() regex
124 rotation,
126 "Error sending display rotation to $rotation"
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/decor/
H A DCutoutDecorProviderFactoryTest.kt64 @Surface.Rotation rotation: Int = Surface.ROTATION_0,
70 info.rotation = rotation
80 @Surface.Rotation rotation: Int = Surface.ROTATION_0,
83 val insets = RotationUtils.rotateInsets(safeInsets, rotation)
86 val rotatedPos = (pos - rotation + BOUNDS_POSITION_LENGTH) % BOUNDS_POSITION_LENGTH
92 rotation
139 rotation = Surface.ROTATION_90
159 rotation = Surface.ROTATION_270
184 rotation = Surface.ROTATION_180
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/assist/ui/
H A DDisplayUtils.java54 int rotation = d.getRotation(); in getWidth() local
55 if (rotation == Surface.ROTATION_0 || rotation == Surface.ROTATION_180) { in getWidth()
74 int rotation = d.getRotation(); in getHeight() local
75 if (rotation == Surface.ROTATION_0 || rotation == Surface.ROTATION_180) { in getHeight()
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/biometrics/
H A DSideFpsControllerTest.kt370 { rotation = Surface.ROTATION_0 }
380 { rotation = Surface.ROTATION_90 }
390 { rotation = Surface.ROTATION_180 }
432 { rotation = Surface.ROTATION_0 }
442 { rotation = Surface.ROTATION_90 }
494 { rotation = Surface.ROTATION_0 }
504 { rotation = Surface.ROTATION_90 }
556 { rotation = Surface.ROTATION_0 }
618 { rotation = Surface.ROTATION_0 },
697 { rotation = Surface.ROTATION_0 }
[all …]
/aosp14/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/shared/animation/
H A DUnfoldMoveFromCenterAnimatorTest.kt58 givenScreen(width = 100, height = 100, rotation = ROTATION_0)
74 givenScreen(width = 100, height = 100, rotation = ROTATION_0)
90 givenScreen(width = 100, height = 100, rotation = ROTATION_0)
106 givenScreen(width = 100, height = 100, rotation = ROTATION_0)
122 givenScreen(width = 100, height = 100, rotation = ROTATION_0)
135 givenScreen(width = 100, height = 100, rotation = ROTATION_0)
149 givenScreen(width = 100, height = 100, rotation = ROTATION_90)
162 givenScreen(width = 100, height = 100, rotation = ROTATION_0)
226 rotation: Int = ROTATION_0
234 whenever(display.rotation).thenReturn(rotation)
/aosp14/frameworks/base/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/decoder/
H A DVideoTrackDecoder.java43 public void grabFrame(FrameImage2D outputVideoFrame, int rotation) { in grabFrame() argument
51 copyFrameDataTo(outputVideoFrame, rotation); in grabFrame()
87 protected static boolean needSwapDimension(int rotation) { in needSwapDimension() argument
88 switch(rotation) { in needSwapDimension()
106 protected abstract void copyFrameDataTo(FrameImage2D outputVideoFrame, int rotation); in copyFrameDataTo() argument
/aosp14/frameworks/base/packages/SystemUI/src/com/android/systemui/biometrics/
H A DAuthBiometricFingerprintIconController.kt74 if (isSideFps && getRotationFromDefault(displayInfo.rotation) == Surface.ROTATION_180) {
75 iconView.rotation = 180f
82 val rotation = getRotationFromDefault(displayInfo.rotation) regex
229 private fun getRotationFromDefault(rotation: Int): Int =
230 if (isReverseDefaultRotation) (rotation + 1) % 4 else rotation
236 rotation: Int
240 when (rotation) {
254 when (rotation) {
266 when (rotation) {
280 when (rotation) {
[all …]
/aosp14/frameworks/base/packages/SystemUI/shared/src/com/android/systemui/shared/rotation/
H A DFloatingRotationButtonPositionCalculator.kt1 package com.android.systemui.shared.rotation
57 private fun resolveGravity(rotation: Int): Int =
59 when (rotation) {
64 else -> throw IllegalArgumentException("Invalid rotation $rotation")
67 when (rotation) {
72 else -> throw IllegalArgumentException("Invalid rotation $rotation")
/aosp14/frameworks/base/libs/WindowManager/Jetpack/src/androidx/window/util/
H A DExtensionHelper.java54 int displayId, @Surface.Rotation int rotation, @NonNull Rect inOutRect) { in rotateRectToDisplayRotation() argument
58 rotateRectToDisplayRotation(displayInfo, rotation, inOutRect); in rotateRectToDisplayRotation()
67 @Surface.Rotation int rotation, @NonNull Rect inOutRect) { in rotateRectToDisplayRotation() argument
72 displayInfo.rotation == ROTATION_90 || displayInfo.rotation == ROTATION_270; in rotateRectToDisplayRotation()
80 RotationUtils.rotateBounds(inOutRect, baseDisplayWidth, baseDisplayHeight, rotation); in rotateRectToDisplayRotation()
/aosp14/frameworks/base/core/java/com/android/internal/view/
H A DRotationPolicy.java79 final int rotation = in getRotationLockOrientation() local
81 final boolean rotated = rotation % 2 != 0; in getRotationLockOrientation()
109 final int rotation = areAllRotationsAllowed(context) in setRotationLock() local
112 setRotationLockAtAngle(context, enabled, rotation); in setRotationLock()
119 final int rotation) { in setRotationLockAtAngle() argument
124 setRotationLock(enabled, rotation); in setRotationLockAtAngle()
149 private static void setRotationLock(final boolean enabled, final int rotation) { in setRotationLock() argument
156 wm.freezeRotation(rotation); in setRotationLock()
/aosp14/frameworks/base/services/core/java/com/android/server/wm/
H A DDisplayRotation.java358 switch (rotation) { in readRotation()
454 mRotation = rotation; in setRotation()
582 Surface.rotationToString(rotation), rotation, in updateRotationUnchecked()
590 Surface.rotationToString(rotation), rotation); in updateRotationUnchecked()
592 if (oldRotation == rotation) { in updateRotationUnchecked()
615 mRotation = rotation; in updateRotationUnchecked()
956 void freezeRotation(int rotation) { in freezeRotation() argument
958 rotation = RotationUtils.reverseRotationDirectionAroundZAxis(rotation); in freezeRotation()
961 rotation = (rotation == -1) ? mRotation : rotation; in freezeRotation()
1417 return rotation == mLandscapeRotation || rotation == mSeascapeRotation; in isLandscapeOrSeascape()
[all …]
H A DWindowOrientationListener.java248 public void setCurrentRotation(int rotation) { in setCurrentRotation() argument
250 mCurrentRotation = rotation; in setCurrentRotation()
935 if (rotation == currentRotation in isOrientationAngleAcceptableLocked()
937 int lowerBound = rotation * 90 - 45 in isOrientationAngleAcceptableLocked()
939 if (rotation == 0) { in isOrientationAngleAcceptableLocked()
954 if (rotation == currentRotation in isOrientationAngleAcceptableLocked()
958 if (rotation == 0) { in isOrientationAngleAcceptableLocked()
1015 if (mPredictedRotation != rotation) { in updatePredictedRotationLocked()
1016 mPredictedRotation = rotation; in updatePredictedRotationLocked()
1357 private int rotationToLogEnum(int rotation) { in rotationToLogEnum() argument
[all …]

12345678910>>...12