/packages/apps/Camera/tests/src/com/android/camera/unittest/ |
D | CameraUnitTest.java | 19 import com.android.camera.Util; 29 int h = Util.ORIENTATION_HYSTERESIS; in testRoundOrientation() 30 assertEquals(0, Util.roundOrientation(0, 0)); in testRoundOrientation() 31 assertEquals(0, Util.roundOrientation(359, 0)); in testRoundOrientation() 32 assertEquals(0, Util.roundOrientation(0 + 44 + h, 0)); in testRoundOrientation() 33 assertEquals(90, Util.roundOrientation(0 + 45 + h, 0)); in testRoundOrientation() 34 assertEquals(0, Util.roundOrientation(360 - 44 - h, 0)); in testRoundOrientation() 35 assertEquals(270, Util.roundOrientation(360 - 45 - h, 0)); in testRoundOrientation() 37 assertEquals(90, Util.roundOrientation(90, 90)); in testRoundOrientation() 38 assertEquals(90, Util.roundOrientation(90 + 44 + h, 90)); in testRoundOrientation() [all …]
|
/packages/apps/LegacyCamera/tests/src/com/android/camera/unittest/ |
D | CameraTest.java | 21 import com.android.camera.Util; 33 int h = Util.ORIENTATION_HYSTERESIS; in testRoundOrientation() 34 assertEquals(0, Util.roundOrientation(0, 0)); in testRoundOrientation() 35 assertEquals(0, Util.roundOrientation(359, 0)); in testRoundOrientation() 36 assertEquals(0, Util.roundOrientation(0 + 44 + h, 0)); in testRoundOrientation() 37 assertEquals(90, Util.roundOrientation(0 + 45 + h, 0)); in testRoundOrientation() 38 assertEquals(0, Util.roundOrientation(360 - 44 - h, 0)); in testRoundOrientation() 39 assertEquals(270, Util.roundOrientation(360 - 45 - h, 0)); in testRoundOrientation() 41 assertEquals(90, Util.roundOrientation(90, 90)); in testRoundOrientation() 42 assertEquals(90, Util.roundOrientation(90 + 44 + h, 90)); in testRoundOrientation() [all …]
|
/packages/apps/Gallery/src/com/android/camera/gallery/ |
D | BaseImage.java | 20 import com.android.camera.Util; 97 Bitmap b = Util.makeBitmap(minSideLength, maxNumberOfPixels, in fullSizeBitmap() 101 b = Util.rotate(b, getDegreesRotated()); in fullSizeBitmap() 154 Util.closeSilently(input); in setupDimension() 179 b = Util.rotate(b, getDegreesRotated()); in miniThumbBitmap()
|
D | BaseImageList.java | 20 import com.android.camera.Util; 180 return Util.equals(base.getScheme(), uri.getScheme()) in isChildImageUri() 181 && Util.equals(base.getHost(), uri.getHost()) in isChildImageUri() 182 && Util.equals(base.getAuthority(), uri.getAuthority()) in isChildImageUri() 183 && Util.equals(base.getPath(), getPathWithoutId(uri)); in isChildImageUri()
|
D | UriImage.java | 20 import com.android.camera.Util; 94 Bitmap b = Util.makeBitmap(minSideLength, maxNumberOfPixels, in fullSizeBitmap() 134 Util.closeSilently(input); in snifBitmapOptions()
|
/packages/apps/Camera/src/com/android/camera/ |
D | Thumbnail.java | 118 Util.closeSilently(f); in saveLastThumbnailToFile() 119 Util.closeSilently(b); in saveLastThumbnailToFile() 120 Util.closeSilently(d); in saveLastThumbnailToFile() 140 if (!Util.isUriValid(uri, resolver)) { in getLastThumbnailFromFile() 150 Util.closeSilently(f); in getLastThumbnailFromFile() 151 Util.closeSilently(b); in getLastThumbnailFromFile() 152 Util.closeSilently(d); in getLastThumbnailFromFile() 185 if (Util.isUriValid(lastMedia.uri, resolver)) { in getLastThumbnailFromContentResolver()
|
D | Camera.java | 280 mCameraDevice = Util.openCamera(Camera.this, mCameraId); in run() 334 if (Util.getDisplayRotation(Camera.this) != mDisplayRotation) { in handleMessage() 378 Util.showErrorAndFinish(Camera.this, in handleMessage() 386 Util.showErrorAndFinish(Camera.this, in handleMessage() 570 if ((mModePicker != null) && !Util.pointInView(x, y, mModePicker)) { in dispatchTouchEvent() 581 if (!Util.pointInView(x, y, popup) in dispatchTouchEvent() 582 && !Util.pointInView(x, y, mIndicatorControlContainer) in dispatchTouchEvent() 583 && !Util.pointInView(x, y, mPreviewFrameLayout)) { in dispatchTouchEvent() 1040 Util.broadcastNewPicture(Camera.this, uri); in storeImage() 1126 mTitle = Util.createJpegName(mDateTaken); in generateUri() [all …]
|
D | VideoCamera.java | 250 if ((Util.getDisplayRotation(VideoCamera.this) != mDisplayRotation) in handleMessage() 318 int intentCameraId = Util.getCameraFacingIntentExtras(this); in getPreferredCameraId() 361 Util.showErrorAndFinish(this, R.string.cannot_connect_camera); in onCreate() 364 Util.showErrorAndFinish(this, R.string.camera_disabled); in onCreate() 392 Util.showErrorAndFinish(this, R.string.cannot_connect_camera); in onCreate() 395 Util.showErrorAndFinish(this, R.string.camera_disabled); in onCreate() 475 int newOrientation = Util.roundOrientation(orientation, mOrientation); in onOrientationChanged() 492 (mOrientation + Util.getDisplayRotation(VideoCamera.this)) % 360; in onOrientationChanged() 731 Size optimalSize = Util.getOptimalPreviewSize(this, sizes, in getDesiredPreviewSize() 768 Util.showErrorAndFinish(this, R.string.cannot_connect_camera); in onResume() [all …]
|
D | FocusManager.java | 187 Util.prepareMatrix(matrix, mMirror, mDisplayOrientation, in setMatrix() 342 int left = Util.clamp(x - focusWidth / 2, 0, previewWidth - focusWidth); in onSingleTapUp() 343 int top = Util.clamp(y - focusHeight / 2, 0, previewHeight - focusHeight); in onSingleTapUp() 505 int left = Util.clamp(x - areaWidth / 2, 0, previewWidth - areaWidth); in calculateTapArea() 506 int top = Util.clamp(y - areaHeight / 2, 0, previewHeight - areaHeight); in calculateTapArea() 510 Util.rectFToRect(rectF, rect); in calculateTapArea()
|
/packages/apps/LegacyCamera/src/com/android/camera/ |
D | Camera.java | 305 if (Util.getDisplayRotation(Camera.this) != mDisplayRotation) { in handleMessage() 390 Util.initializeScreenBrightness(getWindow(), getContentResolver()); in initializeFirstTime() 424 if ((mThumbnail == null || !Util.isUriValid(mThumbnail.getUri(), mContentResolver)) in updateThumbnailButton() 563 if (!Util.pointInView(e.getX(), e.getY(), popup) in onDown() 564 && !Util.pointInView(e.getX(), e.getY(), mIndicatorControlContainer) in onDown() 565 && !Util.pointInView(e.getX(), e.getY(), mPreviewFrame)) { in onDown() 993 String title = Util.createJpegName(dateTaken); in storeImage() 1020 Util.broadcastNewPicture(Camera.this, uri); in storeImage() 1050 Util.setRotationParameter(mParameters, mCameraId, mOrientation); in capture() 1052 Util.setGpsParameters(mParameters, loc); in capture() [all …]
|
D | Thumbnail.java | 118 Util.closeSilently(f); in saveTo() 119 Util.closeSilently(b); in saveTo() 120 Util.closeSilently(d); in saveTo() 145 Util.closeSilently(f); in loadFrom() 146 Util.closeSilently(b); in loadFrom() 147 Util.closeSilently(d); in loadFrom() 175 if (Util.isUriValid(lastMedia.uri, resolver)) { in getLastThumbnail()
|
D | VideoCamera.java | 298 if ((Util.getDisplayRotation(VideoCamera.this) != mDisplayRotation) in handleMessage() 356 Util.initializeScreenBrightness(getWindow(), getContentResolver()); in onCreate() 363 int intentCameraId = Util.getCameraFacingIntentExtras(this); in onCreate() 388 mCameraDevice = Util.openCamera(VideoCamera.this, mCameraId); in onCreate() 400 Util.enterLightsOutMode(getWindow()); in onCreate() 467 Util.showErrorAndFinish(this, R.string.cannot_connect_camera); in onCreate() 470 Util.showErrorAndFinish(this, R.string.camera_disabled); in onCreate() 552 mOrientation = Util.roundOrientation(orientation, mOrientation); in onOrientationChanged() 556 + Util.getDisplayRotation(VideoCamera.this); in onOrientationChanged() 808 Size optimalSize = Util.getOptimalPreviewSize(this, sizes, in getDesiredPreviewSize() [all …]
|
D | FocusManager.java | 127 Util.prepareMatrix(matrix, mirror, displayOrientation, in initialize() 278 int left = Util.clamp(x - focusWidth / 2, 0, previewWidth - focusWidth); in onTouch() 279 int top = Util.clamp(y - focusHeight / 2, 0, previewHeight - focusHeight); in onTouch() 451 int left = Util.clamp(x - areaWidth / 2, 0, previewWidth - areaWidth); in calculateTapArea() 452 int top = Util.clamp(y - areaHeight / 2, 0, previewHeight - areaHeight); in calculateTapArea() 456 Util.rectFToRect(rectF, rect); in calculateTapArea()
|
/packages/apps/LegacyCamera/src/com/android/camera/ui/ |
D | FaceView.java | 20 import com.android.camera.Util; 124 Util.prepareMatrix(mMatrix, mMirror, mDisplayOrientation, getWidth(), getHeight()); in onDraw() 134 if (LOGV) Util.dumpRect(mRect, "Original rect"); in onDraw() 136 if (LOGV) Util.dumpRect(mRect, "Transformed rect"); in onDraw()
|
D | ZoomControlBar.java | 20 import com.android.camera.Util; 32 private static final int THRESHOLD_FIRST_MOVE = Util.dpToPixel(10); // pixels 34 private static final int ICON_SPACING = Util.dpToPixel(12);
|
D | RotateTextToast.java | 20 import com.android.camera.Util; 48 Util.fadeOut(mToast);
|
D | IndicatorControlWheelContainer.java | 22 import com.android.camera.Util; 53 mShutterButtonRadius = Util.dpToPixel(SHUTTER_BUTTON_RADIUS); in onFinishInflate() 106 mCenterX = right - left - Util.dpToPixel(FULL_WHEEL_RADIUS); in onLayout()
|
D | ZoomControlWheel.java | 20 import com.android.camera.Util; 82 mStrokeWidth = Util.dpToPixel(IndicatorControlWheelContainer.STROKE_WIDTH); in ZoomControlWheel() 146 mCenterX = right - left - Util.dpToPixel( in onLayout()
|
/packages/apps/Camera/src/com/android/camera/ui/ |
D | FaceView.java | 30 import com.android.camera.Util; 127 Util.prepareMatrix(mMatrix, mMirror, mDisplayOrientation, getWidth(), getHeight()); in onDraw() 137 if (LOGV) Util.dumpRect(mRect, "Original rect"); in onDraw() 139 if (LOGV) Util.dumpRect(mRect, "Transformed rect"); in onDraw()
|
D | ZoomControlWheel.java | 30 import com.android.camera.Util; 80 mShutterButtonRadius = Util.dpToPixel(IndicatorControlWheelContainer.SHUTTER_BUTTON_RADIUS); in ZoomControlWheel() 81 mStrokeWidth = Util.dpToPixel(IndicatorControlWheelContainer.STROKE_WIDTH); in ZoomControlWheel() 163 mCenterX = right - left - Util.dpToPixel( in onLayout() 168 mCenterY = bottom - top - Util.dpToPixel( in onLayout()
|
D | IndicatorControlWheelContainer.java | 28 import com.android.camera.Util; 67 mShutterButtonRadius = Util.dpToPixel(SHUTTER_BUTTON_RADIUS); in onFinishInflate() 124 mCenterX = right - left - Util.dpToPixel(WHEEL_CENTER_TO_SECANT); in onLayout() 132 mCenterY = bottom - top - Util.dpToPixel(WHEEL_CENTER_TO_SECANT); in onLayout()
|
D | RotateTextToast.java | 27 import com.android.camera.Util; 49 Util.fadeOut(mToast);
|
D | ZoomControlBar.java | 26 import com.android.camera.Util; 34 private static final int THRESHOLD_FIRST_MOVE = Util.dpToPixel(10); // pixels 36 private static final int ICON_SPACING = Util.dpToPixel(12);
|
/packages/apps/CertInstaller/src/com/android/certinstaller/ |
D | Util.java | 30 class Util { class 100 private Util() { in Util() method in Util
|
/packages/apps/LegacyCamera/src/com/android/camera/panorama/ |
D | PanoramaActivity.java | 32 import com.android.camera.Util; 217 mDeviceOrientation = Util.roundOrientation(orientation, mDeviceOrientation); in onOrientationChanged() 221 + Util.getDisplayRotation(PanoramaActivity.this); in onOrientationChanged() 273 Util.enterLightsOutMode(window); in onCreate() 274 Util.initializeScreenBrightness(window, getContentResolver()); in onCreate() 367 mCameraDevice = Util.openCamera(this, backCameraId); in openCamera() 368 mCameraOrientation = Util.getCameraOrientation(backCameraId); in openCamera() 819 if ((mThumbnail == null || !Util.isUriValid(mThumbnail.getUri(), contentResolver))) { in updateThumbnailButton() 871 Util.broadcastNewPicture(PanoramaActivity.this, uri); in saveHighResMosaic() 1040 Util.showErrorAndFinish(this, R.string.cannot_connect_camera); in doOnResume() [all …]
|