From df6e980e3f63eb0f6f9eb437fa925d5009cd9c44 Mon Sep 17 00:00:00 2001 From: Dianne Hackborn Date: Thu, 26 May 2011 14:20:23 -0700 Subject: Add new supports-screens attributes for declaring the compatible screens. Change-Id: I40d57e4354e48accc1027c9f90916ea73eb5190d android:requiresSmallestWidthDp provides the smallest supported width. android:compatibleWidthLimitDp provides the largest compatible width. --- tests/DpiTest/src/com/google/android/test/dpi/DpiTestActivity.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/DpiTest/src/com/google/android/test/dpi/DpiTestActivity.java b/tests/DpiTest/src/com/google/android/test/dpi/DpiTestActivity.java index 2a40c57..01c1c70 100644 --- a/tests/DpiTest/src/com/google/android/test/dpi/DpiTestActivity.java +++ b/tests/DpiTest/src/com/google/android/test/dpi/DpiTestActivity.java @@ -63,7 +63,8 @@ public class DpiTestActivity extends Activity { | ApplicationInfo.FLAG_RESIZEABLE_FOR_SCREENS | ApplicationInfo.FLAG_SUPPORTS_SCREEN_DENSITIES; app.getResources().setCompatibilityInfo(new CompatibilityInfo(ai, - getResources().getConfiguration().screenLayout, false)); + getResources().getConfiguration().screenLayout, + getResources().getConfiguration().smallestScreenWidthDp, false)); } } catch (PackageManager.NameNotFoundException e) { throw new RuntimeException("ouch", e); -- cgit v1.1