Home
last modified time | relevance | path

Searched refs:getDisplayMetrics (Results 1 – 25 of 181) sorted by relevance

12345678

/frameworks/base/packages/SettingsLib/src/com/android/settingslib/applications/
DInterestingConfigChanges.java41 boolean densityChanged = mLastDensity != res.getDisplayMetrics().densityDpi; in applyNewConfig()
43 mLastDensity = res.getDisplayMetrics().densityDpi; in applyNewConfig()
/frameworks/base/core/tests/coretests/src/android/content/res/
DConfigurationBoundResourceCacheTest.java85 float staticDim = TypedValue.complexToDimension(staticValue.data, res.getDisplayMetrics()); in testVoidConfigChange()
107 res.getDisplayMetrics()); in testEffectiveConfigChange()
130 float staticDim = TypedValue.complexToDimension(staticValue.data, res.getDisplayMetrics()); in testConfigChangeMultipleResources()
132 res.getDisplayMetrics()); in testConfigChangeMultipleResources()
166 .complexToDimension(staticValues[i].data, res.getDisplayMetrics()); in testConfigChangeMultipleThemes()
171 res.getDisplayMetrics()); in testConfigChangeMultipleThemes()
/frameworks/base/tests/WallpaperTest/src/com/example/wallpapertest/
DTestWallpaper.java107 tpaint.density = getResources().getDisplayMetrics().density; in onCreate()
110 tpaint.setTextSize(18 * getResources().getDisplayMetrics().scaledDensity); in onCreate()
111 tpaint.setShadowLayer(4 * getResources().getDisplayMetrics().density, 0, 0, 0xff000000); in onCreate()
115 mPadding = (int)(16 * getResources().getDisplayMetrics().density); in onCreate()
/frameworks/base/rs/java/android/renderscript/
DFont.java164 int dpi = res.getDisplayMetrics().densityDpi; in createFromFile()
188 int dpi = res.getDisplayMetrics().densityDpi; in createFromAsset()
212 int dpi = res.getDisplayMetrics().densityDpi; in createFromResource()
/frameworks/base/tests/UiBench/src/com/android/test/uibench/
DSlowNestedRecyclerViewActivity.java53 innerItemWidth = (int) (resources.getDisplayMetrics().widthPixels / 3.3f); in SizeData()
55 headerHeight = (int) (resources.getDisplayMetrics().heightPixels * 0.5f); in SizeData()
81 final float density = parent.getResources().getDisplayMetrics().density; in onCreateViewHolder()
DResizeHWLayerActivity.java36 DisplayMetrics metrics = getResources().getDisplayMetrics(); in onCreate()
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/
DNotificationUtils.java74 float factor = Math.max(1.0f, context.getResources().getDisplayMetrics().scaledDensity / in getFontScaledHeight()
75 context.getResources().getDisplayMetrics().density); in getFontScaledHeight()
/frameworks/base/packages/SystemUI/src/com/android/systemui/
DCornerHandleView.java120 return dp * ((float) context.getResources().getDisplayMetrics().densityDpi in convertDpToPixel()
126 / ((float) context.getResources().getDisplayMetrics().densityDpi); in convertPixelToDp()
/frameworks/base/packages/SystemUI/src/com/android/systemui/tuner/
DSelectablePreference.java33 context.getResources().getDisplayMetrics()); in SelectablePreference()
/frameworks/opt/bitmap/sample/src/com/example/bitmapsample/
DBitmapView.java38 mDensity = getResources().getDisplayMetrics().density; in BitmapView()
/frameworks/base/tests/HwAccelerationTest/src/com/android/test/hwui/
DRotationActivity.java39 return (int) (c.getResources().getDisplayMetrics().density * dip + 0.5f); in dipToPx()
DDrawIntoHwBitmapActivity.java43 p.setTextSize(20 * getResources().getDisplayMetrics().density); in createBitmap()
DViewLayersActivity3.java57 final DisplayMetrics metrics = r.getDisplayMetrics(); in getView()
DViewLayersActivity4.java64 final DisplayMetrics metrics = r.getDisplayMetrics(); in getView()
DViewLayersActivity2.java60 final DisplayMetrics metrics = r.getDisplayMetrics(); in getView()
DListActivity.java115 final DisplayMetrics metrics = r.getDisplayMetrics(); in getView()
DTransparentListActivity.java113 final DisplayMetrics metrics = r.getDisplayMetrics(); in getView()
/frameworks/base/tests/UiBench/src/com/android/test/uibench/leanback/
DTestHelper.java108 DisplayMetrics dm = mContext.getResources().getDisplayMetrics(); in build()
230 DisplayMetrics metrics = activity.getResources().getDisplayMetrics(); in initBackground()
/frameworks/opt/setupwizard/library/gingerbread/test/robotest/src/com/android/setupwizardlib/util/
DDimensionConsistencyTest.java62 DisplayMetrics displayMetrics = mContext.getResources().getDisplayMetrics(); in dp2Px()
/frameworks/opt/setupwizard/library/test/instrumentation/src/com/android/setupwizardlib/test/
DIllustrationTest.java48 context.getResources().getDisplayMetrics().density = 2.0f; in testAspectRatio()
/frameworks/base/core/java/com/android/internal/widget/
DNotificationExpandButton.java60 int touchTargetSize = (int) (getResources().getDisplayMetrics().density * 48); in extendRectToMinTouchSize()
DWeightedLinearLayout.java58 final DisplayMetrics metrics = getContext().getResources().getDisplayMetrics(); in onMeasure()
/frameworks/base/graphics/java/android/graphics/drawable/
DDrawableWrapper.java144 final int densityDpi = r.getDisplayMetrics().densityDpi; in inflate()
172 final int densityDpi = t.getResources().getDisplayMetrics().densityDpi; in applyTheme()
498 density = res.getDisplayMetrics().densityDpi; in DrawableWrapperState()
/frameworks/base/services/accessibility/java/com/android/server/accessibility/
DAccessibilityGestureDetector.java248 context.getResources().getDisplayMetrics()) * GESTURE_CONFIRM_MM; in AccessibilityGestureDetector()
251 final float pixelsPerInchX = context.getResources().getDisplayMetrics().xdpi; in AccessibilityGestureDetector()
252 final float pixelsPerInchY = context.getResources().getDisplayMetrics().ydpi; in AccessibilityGestureDetector()
/frameworks/base/packages/SystemUI/legacy/recents/src/com/android/systemui/recents/
DRecentsConfiguration.java97 float screenDensity = context.getResources().getDisplayMetrics().density; in RecentsConfiguration()

12345678