Searched defs:targetDensity (Results 1 - 10 of 10) sorted by relevance

/frameworks/base/graphics/java/android/graphics/drawable/
H A DInsetDrawable.java344 void onDensityChanged(int sourceDensity, int targetDensity) { argument
345 super.onDensityChanged(sourceDensity, targetDensity);
347 applyDensityScaling(sourceDensity, targetDensity);
355 * @param targetDensity the new constant state density
357 private void applyDensityScaling(int sourceDensity, int targetDensity) { argument
358 mInsetLeft.scaleFromDensity(sourceDensity, targetDensity);
359 mInsetTop.scaleFromDensity(sourceDensity, targetDensity);
360 mInsetRight.scaleFromDensity(sourceDensity, targetDensity);
361 mInsetBottom.scaleFromDensity(sourceDensity, targetDensity);
401 void scaleFromDensity(int sourceDensity, int targetDensity) { argument
[all...]
H A DDrawableWrapper.java132 final int targetDensity = densityDpi == 0 ? DisplayMetrics.DENSITY_DEFAULT : densityDpi;
133 state.setDensity(targetDensity);
494 * @param targetDensity the new constant state density
496 public final void setDensity(int targetDensity) { argument
497 if (mDensity != targetDensity) {
499 mDensity = targetDensity;
501 onDensityChanged(sourceDensity, targetDensity);
512 * @param targetDensity the new constant state density
514 void onDensityChanged(int sourceDensity, int targetDensity) { argument
H A DAdaptiveIconDrawable.java930 public final void setDensity(int targetDensity) { argument
931 if (mDensity != targetDensity) {
932 mDensity = targetDensity;
992 public final void setDensity(int targetDensity) { argument
993 if (mDensity != targetDensity) {
994 mDensity = targetDensity;
H A DDrawable.java1511 * @param targetDensity the target density
1514 static float scaleFromDensity(float pixels, int sourceDensity, int targetDensity) { argument
1515 return pixels * targetDensity / sourceDensity;
1531 * @param targetDensity the target density
1537 int pixels, int sourceDensity, int targetDensity, boolean isSize) {
1538 if (pixels == 0 || sourceDensity == targetDensity) {
1542 final float result = pixels * targetDensity / (float) sourceDensity;
1536 scaleFromDensity( int pixels, int sourceDensity, int targetDensity, boolean isSize) argument
H A DRippleDrawable.java1012 protected void onDensityChanged(int sourceDensity, int targetDensity) { argument
1013 super.onDensityChanged(sourceDensity, targetDensity);
1015 applyDensityScaling(sourceDensity, targetDensity);
1018 private void applyDensityScaling(int sourceDensity, int targetDensity) { argument
1021 mMaxRadius, sourceDensity, targetDensity, true);
H A DGradientDrawable.java1893 * @param targetDensity the new constant state density
1895 public final void setDensity(int targetDensity) { argument
1896 if (mDensity != targetDensity) {
1898 mDensity = targetDensity;
1900 applyDensityScaling(sourceDensity, targetDensity);
1904 private void applyDensityScaling(int sourceDensity, int targetDensity) { argument
1907 mInnerRadius, sourceDensity, targetDensity, true);
1911 mThickness, sourceDensity, targetDensity, true);
1915 mOpticalInsets.left, sourceDensity, targetDensity, true);
1917 mOpticalInsets.top, sourceDensity, targetDensity, tru
[all...]
H A DLayerDrawable.java1892 public final void setDensity(int targetDensity) { argument
1893 if (mDensity != targetDensity) {
1895 mDensity = targetDensity;
1897 applyDensityScaling(sourceDensity, targetDensity);
1901 private void applyDensityScaling(int sourceDensity, int targetDensity) { argument
1902 mInsetL = Drawable.scaleFromDensity(mInsetL, sourceDensity, targetDensity, false);
1903 mInsetT = Drawable.scaleFromDensity(mInsetT, sourceDensity, targetDensity, false);
1904 mInsetR = Drawable.scaleFromDensity(mInsetR, sourceDensity, targetDensity, false);
1905 mInsetB = Drawable.scaleFromDensity(mInsetB, sourceDensity, targetDensity, false);
1907 mInsetS = Drawable.scaleFromDensity(mInsetS, sourceDensity, targetDensity, fals
1994 setDensity(int targetDensity) argument
2003 onDensityChanged(int sourceDensity, int targetDensity) argument
2007 applyDensityScaling(int sourceDensity, int targetDensity) argument
[all...]
H A DVectorDrawable.java485 final int targetDensity = mTargetDensity;
486 if (targetDensity != sourceDensity) {
488 targetDensity, true);
490 targetDensity, true);
492 opticalInsets.left, sourceDensity, targetDensity, false);
494 opticalInsets.right, sourceDensity, targetDensity, false);
496 opticalInsets.top, sourceDensity, targetDensity, false);
498 opticalInsets.bottom, sourceDensity, targetDensity, false);
1003 public final boolean setDensity(int targetDensity) { argument
1004 if (mDensity != targetDensity) {
1013 applyDensityScaling(int sourceDensity, int targetDensity) argument
[all...]
/frameworks/base/core/jni/android/graphics/
H A DBitmapFactory.cpp268 const int targetDensity = env->GetIntField(options, gOptions_targetDensityFieldID); local
270 if (density != 0 && targetDensity != 0 && density != screenDensity) {
271 scale = (float) targetDensity / density;
/frameworks/base/graphics/java/android/graphics/
H A DBitmap.java1372 * @param targetDensity The density of the target canvas of the bitmap.
1375 public int getScaledWidth(int targetDensity) { argument
1376 return scaleFromDensity(getWidth(), mDensity, targetDensity);
1383 * @param targetDensity The density of the target canvas of the bitmap.
1386 public int getScaledHeight(int targetDensity) { argument
1387 return scaleFromDensity(getHeight(), mDensity, targetDensity);

Completed in 235 milliseconds