Home
last modified time | relevance | path

Searched refs:targetDensity (Results 1 – 4 of 4) sorted by relevance

/cts/tests/framework/base/windowmanager/src/android/server/wm/
DDisplaySizeTest.java177 final int targetDensity = (int) (stableDensity * 0.85); in setUnsupportedDensity() local
178 setDensity(targetDensity); in setUnsupportedDensity()
197 private void setDensity(int targetDensity) { in setDensity() argument
198 executeShellCommand("wm density " + targetDensity); in setDensity()
202 final boolean success = output.contains("Override density: " + targetDensity); in setDensity()
204 assertTrue("Failed to set density to " + targetDensity, success); in setDensity()
/cts/tests/tests/graphics/src/android/graphics/drawable/cts/
DBitmapDrawableTest.java404 int sourceDensity, targetDensity; in testSetTargetDensity() local
414 targetDensity = canvas.getDensity(); in testSetTargetDensity()
417 sourceWidth, sourceDensity, targetDensity); in testSetTargetDensity()
419 sourceHeight, sourceDensity, targetDensity); in testSetTargetDensity()
428 targetDensity = mContext.getResources().getDisplayMetrics().densityDpi; in testSetTargetDensity()
431 sourceWidth, sourceDensity, targetDensity); in testSetTargetDensity()
433 sourceHeight, sourceDensity, targetDensity); in testSetTargetDensity()
443 targetDensity = sourceDensity * 2; in testSetTargetDensity()
444 bitmapDrawable.setTargetDensity(targetDensity); in testSetTargetDensity()
446 sourceWidth, sourceDensity, targetDensity); in testSetTargetDensity()
[all …]
DNinePatchDrawableTest.java383 int targetDensity = mResources.getDisplayMetrics().densityDpi; in testInflate() local
385 sourceWidth, sourceDensity, targetDensity); in testInflate()
387 sourceHeight, sourceDensity, targetDensity); in testInflate()
/cts/tests/tests/content/src/android/content/res/cts/
DResourcesTest.java331 int targetDensity = mResources.getDisplayMetrics().densityDpi; in testGetDrawable() local
334 assertEquals(212 * targetDensity / defaultDensity, draw.getIntrinsicWidth(), 1); in testGetDrawable()
335 assertEquals(142 * targetDensity / defaultDensity, draw.getIntrinsicHeight(), 1); in testGetDrawable()