Home
last modified time | relevance | path

Searched refs:Point (Results 1 – 25 of 337) sorted by relevance

12345678910>>...14

/packages/apps/Launcher3/tests/multivalentTests/src/com/android/launcher3/widget/picker/util/
DWidgetPreviewContainerSizesTest.kt21 import android.graphics.Point
82 private val HANDHELD_TEST_SIZES: Map<Point, WidgetPreviewContainerSize> =
85 Point(1, 1) to WidgetPreviewContainerSize(1, 1),
87 Point(2, 1) to WidgetPreviewContainerSize(2, 1),
88 Point(3, 1) to WidgetPreviewContainerSize(2, 1),
90 Point(4, 1) to WidgetPreviewContainerSize(4, 1),
92 Point(2, 2) to WidgetPreviewContainerSize(2, 2),
93 Point(3, 3) to WidgetPreviewContainerSize(2, 2),
94 Point(3, 2) to WidgetPreviewContainerSize(2, 2),
96 Point(2, 3) to WidgetPreviewContainerSize(2, 3),
[all …]
/packages/modules/Bluetooth/tools/rootcanal/rust/src/lmp/
Dec.rs80 fn to_point<Curve: EllipticCurve>(&self) -> Point<Curve> { in to_point()
81 Point::from_affine(self.get_x(), self.get_y()) in to_point()
157 Point::<P192r1>::generate_public_key(&self.to_bigint()).to_bytes() in derive()
160 Point::<P256r1>::generate_public_key(&self.to_bigint()).to_bytes() in derive()
256 enum Point<Curve> { enum
261 impl<Curve> Point<Curve> impl
266 Point::Infinite(PhantomData) in o()
274 Point::Finite { x, y, z, _curve: PhantomData } in new()
290 Point::Infinite(_) => None, in to_affine()
291 Point::Finite { x, y, z, _curve } => { in to_affine()
[all …]
/packages/apps/WallpaperPicker2/src/com/android/wallpaper/util/
DWallpaperCropUtils.java20 import android.graphics.Point;
72 public static Point getDefaultCropSurfaceSize(Resources resources, Display display) { in getDefaultCropSurfaceSize()
73 Point minDims = new Point(); in getDefaultCropSurfaceSize()
74 Point maxDims = new Point(); in getDefaultCropSurfaceSize()
81 Point realSize = new Point(); in getDefaultCropSurfaceSize()
95 public static Point calculateCropSurfaceSize(Resources resources, int maxDim, int minDim, in calculateCropSurfaceSize()
105 return new Point(defaultWidth, defaultHeight); in calculateCropSurfaceSize()
124 public static Point calculateCenterPosition(Point outer, Point inner, boolean alignStart,
131 Point relativePosition = new Point();
150 public static float calculateMinZoom(Point outer, Point inner) { in calculateMinZoom()
[all …]
DScreenSizeCalculator.java21 import android.graphics.Point;
37 private Point mPortraitScreenSize;
38 private Point mLandscapeScreenSize;
62 public Point getScreenSize(Display display) { in getScreenSize()
81 final Point screenSize = getScreenSize(windowManager.getDefaultDisplay()); in getScreenAspectRatio()
91 final Point screenSize = getScreenSize(windowManager.getDefaultDisplay()); in getScreenHeight()
95 private Point getPortraitScreenSize(Display display) { in getPortraitScreenSize()
97 mPortraitScreenSize = new Point(); in getPortraitScreenSize()
100 return new Point(mPortraitScreenSize); in getPortraitScreenSize()
103 private Point getLandscapeScreenSize(Display display) { in getLandscapeScreenSize()
[all …]
DSizeCalculator.java21 import android.graphics.Point;
173 public static Point getCategoryTileSize(@NonNull Activity activity) { in getCategoryTileSize()
186 public static Point getCategoryTileSize(Context context, int windowWidthPx) { in getCategoryTileSize()
198 public static Point getFeaturedCategoryTileSize(@NonNull Activity activity) { in getFeaturedCategoryTileSize()
211 public static Point getFeaturedCategoryTileSize(Context context, int windowWidthPx) { in getFeaturedCategoryTileSize()
223 public static Point getIndividualTileSize(@NonNull Activity activity) { in getIndividualTileSize()
236 public static Point getFeaturedIndividualTileSize(@NonNull Activity activity) { in getFeaturedIndividualTileSize()
251 public static Point getSuggestedThumbnailSize(@NonNull Context appContext) { in getSuggestedThumbnailSize()
266 Point screenSize = ScreenSizeCalculator.getInstance().getScreenSize( in getPreviewCornerRadius()
278 private static Point getTileSize(Context context, int columnCount, int windowWidthPx) { in getTileSize()
[all …]
/packages/apps/WallpaperPicker2/tests/robotests/src/com/android/wallpaper/util/
DDisplayUtilsTest.kt20 import android.graphics.Point
146 val displayConfig1 = FakeDisplaysProvider.FakeDisplayConfig(Point(250, 500)) in getMaxDisplaysDimension_oneDisplay_returnsDisplayDimensions()
150 assertThat(displayUtils.getMaxDisplaysDimension()).isEqualTo(Point(250, 500)) in getMaxDisplaysDimension_oneDisplay_returnsDisplayDimensions()
155 val displayConfig1 = FakeDisplaysProvider.FakeDisplayConfig(Point(250, 500)) in getMaxDisplaysDimension_noRotation_returnsMaxOfEachDimension()
156 val displayConfig2 = FakeDisplaysProvider.FakeDisplayConfig(Point(300, 400)) in getMaxDisplaysDimension_noRotation_returnsMaxOfEachDimension()
160 assertThat(displayUtils.getMaxDisplaysDimension()).isEqualTo(Point(300, 500)) in getMaxDisplaysDimension_noRotation_returnsMaxOfEachDimension()
165 val displayConfig1 = FakeDisplaysProvider.FakeDisplayConfig(Point(250, 500)) in getMaxDisplaysDimension_withRotation_returnsMaxPostRotation()
169 displaySize = Point(300, 400), in getMaxDisplaysDimension_withRotation_returnsMaxPostRotation()
175 assertThat(displayUtils.getMaxDisplaysDimension()).isEqualTo(Point(400, 500)) in getMaxDisplaysDimension_withRotation_returnsMaxPostRotation()
180 val displayConfig1 = FakeDisplaysProvider.FakeDisplayConfig(Point(250, 500)) in getMaxDisplaysDimension_foldable_returnsMaxOfEachDimension()
[all …]
/packages/apps/Launcher3/tests/tapl/com/android/launcher3/tapl/
DLaunchedAppState.java29 import android.graphics.Point;
153 final Point displaySize = launcher.getRealDisplaySize();
156 final Point endPoint = new Point(displaySize.x / 4, displaySize.y / 4);
160 Point itemVisibleCenter = launchable.mObject.getVisibleCenter();
164 Point dragStart = launchable.startDrag(
224 Point taskbarUnstashArea = new Point(leftEdge, mLauncher.getRealDisplaySize().y - 1);
226 new Point(taskbarUnstashArea.x, taskbarUnstashArea.y), null,
232 new Point(taskbarUnstashArea.x, taskbarUnstashArea.y), null,
247 Point stashedTaskbarHintArea = new Point(mLauncher.getRealDisplaySize().x / 2,
250 new Point(stashedTaskbarHintArea.x, stashedTaskbarHintArea.y), null,
[all …]
DWorkspace.java34 import android.graphics.Point;
308 () -> new Point(targetX, targetY), in dragIcon()
335 final Point center = getHotseatCellCenter(mLauncher, cellInd); in getHotseatAppIcon()
348 public Map<String, Point> getWorkspaceIconsPositions() { in getWorkspaceIconsPositions()
373 private static Point getDropPointFromDropTargetBar(
394 () -> new Point(0, 0),
485 public Point getIconGridDimensions() {
489 return new Point(countXY[0], countXY[1]);
492 static Point getCellCenter(LauncherInstrumentation launcher, int cellX, int cellY) {
497 static Point getCellCenter(LauncherInstrumentation launcher, int cellX, int cellY, int spanX,
[all …]
/packages/apps/Dialer/java/com/android/incallui/answer/impl/classifier/
DPoint.java19 class Point { class
24 public Point(float x, float y) { in Point() method in Point
30 public Point(float x, float y, long timeOffsetNano) { in Point() method in Point
38 if (!(other instanceof Point)) { in equals()
41 Point otherPoint = ((Point) other); in equals()
52 public float dist(Point a) { in dist()
60 public float crossProduct(Point a, Point b) { in crossProduct()
68 public float dotProduct(Point a, Point b) { in dotProduct()
78 public float getAngle(Point a, Point b) { in getAngle()
/packages/apps/WallpaperPicker2/tests/robotests/src/com/android/wallpaper/picker/preview/ui/util/
DFullResImageViewUtilTest.kt3 import android.graphics.Point
19 val wallpaperSize = Point(1080, 1920) in getScaleAndCenter_wallpaperSizeSameAsScreen()
22 viewSize = Point(screenWidth, screenHeight), in getScaleAndCenter_wallpaperSizeSameAsScreen()
24 displaySize = Point(screenWidth, screenHeight), in getScaleAndCenter_wallpaperSizeSameAsScreen()
44 val wallpaperSize = Point(3840, 3840) in getScaleAndCenter_wallpaperSizeLargerThanScreen()
47 viewSize = Point(screenWidth, screenHeight), in getScaleAndCenter_wallpaperSizeLargerThanScreen()
49 displaySize = Point(screenWidth, screenHeight), in getScaleAndCenter_wallpaperSizeLargerThanScreen()
69 val wallpaperSize = Point(960, 960) in getScaleAndCenter_wallpaperSizeSmallerThanScreen()
72 viewSize = Point(screenWidth, screenHeight), in getScaleAndCenter_wallpaperSizeSmallerThanScreen()
74 displaySize = Point(screenWidth, screenHeight), in getScaleAndCenter_wallpaperSizeSmallerThanScreen()
[all …]
/packages/modules/CellBroadcastService/src/com/android/cellbroadcastservice/
DCbGeoUtils.java251 Point sa = convertToDistanceFromOrigin(a); in distance()
252 Point sb = convertToDistanceFromOrigin(b); in distance()
253 Point sp = convertToDistanceFromOrigin(latLng); in distance()
271 private Point convertToDistanceFromOrigin(LatLng latLng) { in convertToDistanceFromOrigin()
294 public static Point convertToDistanceFromOrigin(@NonNull final LatLng origin, in convertToDistanceFromOrigin()
301 return new Point(x, y); in convertToDistanceFromOrigin()
308 public static class Point { class in CbGeoUtils
324 public Point(double x, double y) { in Point() method in CbGeoUtils.Point
334 public Point subtract(Point p) { in subtract()
335 return new Point(x - p.x, y - p.y); in subtract()
[all …]
/packages/apps/Car/Cluster/DirectRenderingCluster/tests/robotests/src/android/car/cluster/
DImageResolverTest.java21 import android.graphics.Point;
52 assertEquals(new Point(20, 10), mImageResolver.getAdjustedSize(2, 20, 20)); in adjustedSize_widerImageInSquareBox()
57 assertEquals(new Point(10, 20), mImageResolver.getAdjustedSize(0.5, 20, 20)); in adjustedSize_tallerImageInSquareBox()
62 assertEquals(new Point(10, 20), mImageResolver.getAdjustedSize(0.5, 20, 20)); in adjustedSize_narrowerImageInSquareBox()
67 assertEquals(new Point(20, 8), mImageResolver.getAdjustedSize(2.5, 20, 20)); in adjustedSize_shorterImageInSquareBox()
72 assertEquals(new Point(20, 10), mImageResolver.getAdjustedSize(2, 20, 40)); in adjustedSize_widerImageInTallRectangle()
77 assertEquals(new Point(20, 40), mImageResolver.getAdjustedSize(0.5, 20, 40)); in adjustedSize_tallerImageInTallRectangle()
82 assertEquals(new Point(40, 20), mImageResolver.getAdjustedSize(2, 40, 20)); in adjustedSize_widerImageInWideRectangle()
87 assertEquals(new Point(10, 20), mImageResolver.getAdjustedSize(0.5, 40, 20)); in adjustedSize_tallerImageInWideRectangle()
97 assertEquals(new Point(20, 30), mImageResolver.getAdjustedSize(0.66667, 0, 30)); in adjustedSize_flexibleWidth()
[all …]
/packages/modules/IntentResolver/tests/unit/src/com/android/intentresolver/ext/
DCreationExtrasExtTest.kt19 import android.graphics.Point
32 val updated = creationExtras.addDefaultArgs("POINT" to Point(1, 1)) in addDefaultArgs_addsWhenAbsent()
36 assertThat(defaultArgs).parcelable<Point>("POINT").marshallsEquallyTo(Point(1, 1)) in addDefaultArgs_addsWhenAbsent()
43 set(DEFAULT_ARGS_KEY, bundleOf("POINT1" to Point(1, 1))) in addDefaultArgs_addsToExisting()
46 val updated = creationExtras.addDefaultArgs("POINT2" to Point(2, 2)) in addDefaultArgs_addsToExisting()
51 assertThat(defaultArgs).parcelable<Point>("POINT1").marshallsEquallyTo(Point(1, 1)) in addDefaultArgs_addsToExisting()
52 assertThat(defaultArgs).parcelable<Point>("POINT2").marshallsEquallyTo(Point(2, 2)) in addDefaultArgs_addsToExisting()
/packages/apps/DocumentsUI/src/com/android/documentsui/
DThumbnailCache.java23 import android.graphics.Point;
53 private final HashMap<SizeIndexKey, TreeMap<Point, CacheKey>> mSizeIndex;
73 public Result getThumbnail(Uri uri, UserId userId, Point size) { in getThumbnail()
74 TreeMap<Point, CacheKey> sizeMap; in getThumbnail()
91 Point otherSize = sizeMap.higherKey(size); in getThumbnail()
127 public void putThumbnail(Uri uri, UserId userId, Point size, Bitmap thumbnail, in putThumbnail()
131 TreeMap<Point, CacheKey> sizeMap; in putThumbnail()
152 TreeMap<Point, CacheKey> sizeMap; in removeUri()
168 TreeMap<Point, CacheKey> sizeMap; in removeKey()
218 private @Nullable Point mSize;
[all …]
/packages/apps/DocumentsUI/tests/functional/com/android/documentsui/
DBandSelectionUiTest.java19 import android.graphics.Point;
44 Point start = new Point(dirListBounds.right - 1, startDir.centerY()); in testBandSelection_allFiles()
45 Point end = new Point(dirListBounds.left + 1, dirListBounds.bottom - 1); in testBandSelection_allFiles()
57 Point start = new Point(dirListBounds.right - 1, startDoc.bottom - 1); in testBandSelection_someFiles()
59 Point end = new Point(endDoc.centerX(), endDoc.centerY()); in testBandSelection_someFiles()
/packages/services/Car/car_product/car_ui_portrait/apps/CarUiPortraitLauncher/src/com/android/car/portraitlauncher/panel/
DOnPanelDragListener.java21 import android.graphics.Point;
37 private final Point mDragBeginPoint = new Point();
38 private final Point mDragCurrentPoint = new Point();
39 private final Point mDragDeltaPoint = new Point();
40 private final Point mLastDragDeltaPoint = new Point();
/packages/modules/Bluetooth/system/stack/smp/
Dp_256_ecc_pp.cc35 static void p_256_init_point(Point* q) { memset(q, 0, sizeof(Point)); } in p_256_init_point()
37 static void p_256_copy_point(Point* q, Point* p) { in p_256_copy_point()
38 memcpy(q, p, sizeof(Point)); in p_256_copy_point()
42 static void ECC_Double(Point* q, Point* p) { in ECC_Double()
91 static void ECC_Add(Point* r, Point* p, Point* q) { in ECC_Add()
195 void ECC_PointMult_Bin_NAF(Point* q, Point* p, uint32_t* n) { in ECC_PointMult_Bin_NAF()
199 Point minus_p; in ECC_PointMult_Bin_NAF()
200 Point r; in ECC_PointMult_Bin_NAF()
244 bool ECC_ValidatePoint(const Point& pt) { in ECC_ValidatePoint()
/packages/apps/Gallery2/src/com/android/gallery3d/data/
DLocationClustering.java46 private static class Point { class in LocationClustering
47 public Point(double lat, double lng) { in Point() method in LocationClustering.Point
51 public Point() {} in Point() method in LocationClustering.Point
87 final ArrayList<Point> points = new ArrayList<Point>(); in run()
93 points.add(new Point(s.lat, s.lng)); in run()
104 Point[] pointsArray = new Point[m]; in run()
204 private static int[] kMeans(Point points[], int[] bestK) { in kMeans()
211 Point[] center = new Point[maxK]; // center of each group. in kMeans()
212 Point[] groupSum = new Point[maxK]; // sum of points in each group. in kMeans()
217 center[i] = new Point(); in kMeans()
[all …]
/packages/apps/Launcher3/tests/multivalentTests/src/com/android/launcher3/celllayout/board/
DCellLayoutBoard.java18 import android.graphics.Point;
85 public WidgetRect getWidgetAt(Point p) {
159 private void removeOverlappingItems(Point p) { in removeOverlappingItems()
231 new Point(widgetRect.getCellX(), widgetRect.getCellY()))); in removeItem()
234 public void removeItem(Point p) { in removeItem()
243 Point iconCoord = new Point(x, y); in addIcon()
249 public static WidgetRect getWidgetRect(int x, int y, Set<Point> used, char[][] board) { in getWidgetRect()
251 Queue<Point> search = new ArrayDeque<Point>(); in getWidgetRect()
252 Point current = new Point(x, y); in getWidgetRect()
255 List<Point> neighbors = new ArrayList<>(List.of( in getWidgetRect()
[all …]
/packages/modules/Bluetooth/system/gd/security/ecc/
Dp_256_ecc_pp.cc38 static void p_256_init_point(Point* q) { in p_256_init_point()
39 memset(q, 0, sizeof(Point)); in p_256_init_point()
42 static void p_256_copy_point(Point* q, const Point* p) { in p_256_copy_point()
43 memcpy(q, p, sizeof(Point)); in p_256_copy_point()
47 static void ECC_Double(Point* q, const Point* p) { in ECC_Double()
96 static void ECC_Add(Point* r, Point* p, const Point* q) { in ECC_Add()
200 void ECC_PointMult_Bin_NAF(Point* q, const Point* p, uint32_t* n) { in ECC_PointMult_Bin_NAF()
204 Point minus_p; in ECC_PointMult_Bin_NAF()
205 Point r; in ECC_PointMult_Bin_NAF()
244 bool ECC_ValidatePoint(const Point& pt) { in ECC_ValidatePoint()
/packages/apps/DocumentsUI/tests/common/com/android/documentsui/bots/
DGestureBot.java21 import android.graphics.Point;
66 Point[] points = new Point[LONGPRESS_STEPS + TRAVELING_STEPS]; in gestureSelectFiles()
70 points[i] = new Point(startCoord.centerX(), startCoord.centerY()); in gestureSelectFiles()
77 points[i + LONGPRESS_STEPS] = new Point(newX, newY); in gestureSelectFiles()
83 public void bandSelection(Point start, Point end) throws Exception { in bandSelection()
87 public void fingerSelection(Point start, Point end) throws Exception { in fingerSelection()
91 public void bandSelection(Point start, Point end, int steps) throws Exception { in bandSelection()
98 private void fingerSelection(Point start, Point end, int steps) throws Exception { in fingerSelection()
/packages/apps/WallpaperPicker2/tests/robotests/common/src/com/android/wallpaper/testing/
DFakeDisplaysProvider.kt22 import android.graphics.Point in <lambda>()
87 val displaySize: Point, in <lambda>()
104 val HANDHELD = FakeDisplayConfig(Point(1440, 3120), true, ORIENTATION_PORTRAIT, 560) in <lambda>()
105 val FOLDABLE_FOLDED = FakeDisplayConfig(Point(1080, 2092), true, ORIENTATION_PORTRAIT, 408) in <lambda>()
107 FakeDisplayConfig(Point(2208, 1840), false, ORIENTATION_LANDSCAPE, 380) in <lambda>()
109 FakeDisplayConfig(Point(2208, 1840), false, ORIENTATION_PORTRAIT, 380) in <lambda>()
110 val TABLET_LAND = FakeDisplayConfig(Point(2560, 1600), false, ORIENTATION_LANDSCAPE, 276) in <lambda>()
111 val TABLET_PORT = FakeDisplayConfig(Point(2560, 1600), false, ORIENTATION_PORTRAIT, 276) in <lambda>()
/packages/apps/DocumentsUI/tests/unit/com/android/documentsui/
DViewAutoScrollerTest.java22 import android.graphics.Point;
50 private Point mPoint;
59 mPoint = new Point(); in setUp()
73 public Point getCurrentPosition() { in setUp()
98 mPoint = new Point(0, VIEW_HEIGHT/2); in testCursorNotInScrollZone()
110 mPoint = new Point(0, TOP_Y_POINT); in testCursorInScrollZone_notActive()
122 mPoint = new Point(0, TOP_Y_POINT); in testCursorInScrollZone_top()
133 mPoint = new Point(0, BOTTOM_Y_POINT); in testCursorInScrollZone_bottom()
/packages/modules/CellBroadcastService/tests/src/com/android/cellbroadcastservice/tests/
DCbGeoUtilsTest.java106 CbGeoUtils.Point ptCenter = convert(origin, circle.getCenter()); in testExistingLatLngConversionToPoint()
107 CbGeoUtils.Point pt622 = convert(origin, ll622); in testExistingLatLngConversionToPoint()
160 CbGeoUtils.Point ptWestNorth = convert(origin, llWestNorth); in testDistanceFromSegmentToAngledPoint()
161 CbGeoUtils.Point ptWestSouth = convert(origin, llWestSouth); in testDistanceFromSegmentToAngledPoint()
177 CbGeoUtils.Point pt1 = new CbGeoUtils.Point(1.0, 1.0); in testPointEquals()
178 CbGeoUtils.Point pt2 = new CbGeoUtils.Point(1.0, 1.0); in testPointEquals()
185 CbGeoUtils.Point pt = new CbGeoUtils.Point(1.0, 1.0); in testPointToString()
238 private CbGeoUtils.Point newPoint(double x, double y) { in newPoint()
239 return new CbGeoUtils.Point(x, y); in newPoint()
251 private CbGeoUtils.Point convert(LatLng origin, LatLng latLng) { in convert()
/packages/apps/WallpaperPicker2/tests/robotests/src/com/android/wallpaper/picker/preview/ui/viewmodel/
DStaticWallpaperPreviewViewModelTest.kt28 import android.graphics.Point
241 displaySize = Point(1000, 1000), in fullResWallpaperViewModel_withStaticWallpaperAndCropHints_shouldEmitNonNullValue()
271 displaySize = Point(1000, 1000), in subsamplingScaleImageViewModel_withStaticWallpaperAndCropHints_shouldEmitNonNullValue()
383 displaySize = Point(1000, 1000), in wallpaperColors_withStoredColorsAndNonNullCropHints_returnsClientWallpaperColors()
425 displaySize = Point(1000, 1000), in wallpaperColors_withNoStoredColorsAndNonNullCropHints_returnsClientWallpaperColors()
452 displaySize = Point(1000, 1000), in updateCropHintsInfo_updateDefaultCropTrue_onlyAddsNewCropHints()
457 displaySize = Point(500, 1500), in updateCropHintsInfo_updateDefaultCropTrue_onlyAddsNewCropHints()
462 displaySize = Point(500, 1500), in updateCropHintsInfo_updateDefaultCropTrue_onlyAddsNewCropHints()
467 displaySize = Point(400, 600), in updateCropHintsInfo_updateDefaultCropTrue_onlyAddsNewCropHints()
484 displaySize = Point(1000, 1000), in updateCropHintsInfo_updateDefaultCropFalse_addsAndReplacesPreviousCropHints()
[all …]

12345678910>>...14