Searched refs:center (Results 1 - 13 of 13) sorted by relevance

/packages/apps/Gallery2/src/com/android/gallery3d/data/
H A DLocationClustering.java209 Point[] center = new Point[maxK]; // center of each group.
215 center[i] = new Point();
220 // (sum of distance from each point to its group center) * sqrt(k).
235 center[i].latRad = p.latRad;
236 center[i].lngRad = p.lngRad;
240 // step 2: assign each point to the nearest center.
254 p.latRad, p.lngRad, center[j].latRad, center[j].lngRad);
276 center[
[all...]
/packages/apps/Launcher2/src/com/android/launcher2/
H A DFolderIcon.java365 int[] center = new int[2];
366 float scale = getLocalCenterForIndex(index, center);
367 center[0] = (int) Math.round(scaleRelativeToDragLayer * center[0]);
368 center[1] = (int) Math.round(scaleRelativeToDragLayer * center[1]);
370 to.offset(center[0] - animateView.getMeasuredWidth() / 2,
371 center[1] - animateView.getMeasuredHeight() / 2);
447 private float getLocalCenterForIndex(int index, int[] center) { argument
455 center[
[all...]
/packages/apps/Browser/src/com/android/browser/view/
H A DPieMenu.java191 * guaranteed has center set
351 private Path makeSlice(float start, float end, int outer, int inner, Point center) { argument
353 new RectF(center.x - outer, center.y - outer, center.x + outer,
354 center.y + outer);
356 new RectF(center.x - inner, center.y - inner, center.x + inner,
357 center
[all...]
/packages/apps/VideoEditor/src/com/android/videoeditor/widgets/
H A DImageViewTouchBase.java228 center(true, true);
356 * @param centerX The horizontal center
357 * @param centerY The vertical center
367 center(true, true);
383 * Zoom to the specified scale factor and center point
466 center(true, true);
473 * view's dimensions then center it (literally). If the image
477 private void center(boolean horizontal, boolean vertical) { method in class:ImageViewTouchBase
/packages/apps/Gallery2/src/com/android/gallery3d/app/
H A DAlbumSetPage.java103 // The eyes' position of the user, the origin is at the center of the
172 private void getSlotCenter(int slotIndex, int center[]) { argument
178 center[0] = offset.left + (r.left + r.right) / 2 - scrollX;
179 center[1] = offset.top + (r.top + r.bottom) / 2 - scrollY;
207 int[] center = new int[2];
208 getSlotCenter(slotIndex, center);
209 data.putIntArray(AlbumPage.KEY_SET_CENTER, center);
H A DAlbumPage.java71 public static final String KEY_SET_CENTER = "set-center";
354 int[] center = data.getIntArray(KEY_SET_CENTER);
355 if (center != null) {
356 mOpenCenter.setAbsolutePosition(center[0], center[1]);
/packages/apps/Gallery/src/com/android/camera/
H A DImageViewTouchBase.java183 // view's dimensions then center it (literally). If the image
186 protected void center(boolean horizontal, boolean vertical) { method in class:ImageViewTouchBase
317 center(true, true);
396 center(true, true);
H A DViewImage.java1104 center(true, true);
1146 center(true, false);
1157 center(true, false);
1163 center(false, true);
1168 center(false, true);
1184 center(true, true);
H A DCropImage.java197 mImageView.center(true, true);
226 // with the cropped image in the center and the extra space filled.
240 // If the srcRect is too big, use the center part of it.
243 // If the dstRect is too big, use the center part of it.
246 // Draw the cropped bitmap in the center
295 mImageView.center(true, true);
720 center(true, true);
724 // the user to move the image around. This call to center puts
728 center(true, true);
755 // view's center an
[all...]
/packages/apps/Calendar/src/com/android/calendar/
H A DDayView.java485 /** The hour at the center two touch points */
3204 // Figure out where we came from and compute the center of that area.
3319 int center = (left + right) / 2;
3323 if (currentRight <= center) {
3324 currentDistance = center - currentRight;
3325 } else if (currentLeft >= center) {
3326 currentDistance = currentLeft - center;
3330 if (neighborRight <= center) {
3331 neighborDistance = center - neighborRight;
3332 } else if (neighborLeft >= center) {
3551 drawEventText(StaticLayout eventLayout, Rect rect, Canvas canvas, int top, int bottom, boolean center) argument
[all...]
/packages/apps/Gallery2/src/com/android/gallery3d/ui/
H A DPhotoView.java679 // the center of the view.
717 // Find out the bitmap coordinates of the center of the view
887 // Draw the video play icon at the center
1360 // Determine how many photos we need to draw in addition to the center
1421 int center = getWidth() / 2;
1423 if (curr.left > center && mPrevBound < 0) {
1425 int currDist = curr.left - center;
1426 int prevDist = center - prev.right;
1430 } else if (curr.right < center && mNextBound > 0) {
1432 int currDist = center
[all...]
H A DSlotView.java159 // is changed (like orientation change). We choose to keep the center
361 public ScatteringAnimation(RelativePosition center) { argument
362 mCenter = center;
464 // to put the slots towards to the center of the display.
H A DTileImageView.java288 // center of the ImageViewer.
318 // Calculate where the center of the image is, in the view coordinates.
319 public void getImageCenter(Point center) { argument
324 // The distance between the center of the view to the center of the
326 // coordinates correspond to the center of view)
338 center.x = Math.round(viewW / 2f + distW * mScale);
339 center.y = Math.round(viewH / 2f + distH * mScale);

Completed in 126 milliseconds