Loading api/current.txt +1 −0 Original line number Diff line number Diff line Loading @@ -39881,6 +39881,7 @@ package android.util { field public static final int DENSITY_420 = 420; // 0x1a4 field public static final int DENSITY_560 = 560; // 0x230 field public static final int DENSITY_DEFAULT = 160; // 0xa0 field public static final int DENSITY_DEVICE_STABLE; field public static final int DENSITY_HIGH = 240; // 0xf0 field public static final int DENSITY_LOW = 120; // 0x78 field public static final int DENSITY_MEDIUM = 160; // 0xa0 api/system-current.txt +1 −0 Original line number Diff line number Diff line Loading @@ -42298,6 +42298,7 @@ package android.util { field public static final int DENSITY_420 = 420; // 0x1a4 field public static final int DENSITY_560 = 560; // 0x230 field public static final int DENSITY_DEFAULT = 160; // 0xa0 field public static final int DENSITY_DEVICE_STABLE; field public static final int DENSITY_HIGH = 240; // 0xf0 field public static final int DENSITY_LOW = 120; // 0x78 field public static final int DENSITY_MEDIUM = 160; // 0xa0 api/test-current.txt +1 −0 Original line number Diff line number Diff line Loading @@ -39898,6 +39898,7 @@ package android.util { field public static final int DENSITY_420 = 420; // 0x1a4 field public static final int DENSITY_560 = 560; // 0x230 field public static final int DENSITY_DEFAULT = 160; // 0xa0 field public static final int DENSITY_DEVICE_STABLE; field public static final int DENSITY_HIGH = 240; // 0xf0 field public static final int DENSITY_LOW = 120; // 0x78 field public static final int DENSITY_MEDIUM = 160; // 0xa0 core/java/android/util/DisplayMetrics.java +18 −5 Original line number Diff line number Diff line Loading @@ -131,15 +131,28 @@ public class DisplayMetrics { public static final float DENSITY_DEFAULT_SCALE = 1.0f / DENSITY_DEFAULT; /** * The device's density. * @hide because eventually this should be able to change while * running, so shouldn't be a constant. * @deprecated There is no longer a static density; you can find the * density for a display in {@link #densityDpi}. * The device's current density. * <p> * This value reflects any changes made to the device density. To obtain * the device's stable density, use {@link #DENSITY_DEVICE_STABLE}. * * @hide This value should not be used. * @deprecated Use {@link #DENSITY_DEVICE_STABLE} to obtain the stable * device density or {@link #densityDpi} to obtain the current * density for a specific display. */ @Deprecated public static int DENSITY_DEVICE = getDeviceDensity(); /** * The device's stable density. * <p> * This value is constant at run time and may not reflect the current * display density. To obtain the current density for a specific display, * use {@link #densityDpi}. */ public static final int DENSITY_DEVICE_STABLE = getDeviceDensity(); /** * The absolute width of the display in pixels. */ Loading Loading
api/current.txt +1 −0 Original line number Diff line number Diff line Loading @@ -39881,6 +39881,7 @@ package android.util { field public static final int DENSITY_420 = 420; // 0x1a4 field public static final int DENSITY_560 = 560; // 0x230 field public static final int DENSITY_DEFAULT = 160; // 0xa0 field public static final int DENSITY_DEVICE_STABLE; field public static final int DENSITY_HIGH = 240; // 0xf0 field public static final int DENSITY_LOW = 120; // 0x78 field public static final int DENSITY_MEDIUM = 160; // 0xa0
api/system-current.txt +1 −0 Original line number Diff line number Diff line Loading @@ -42298,6 +42298,7 @@ package android.util { field public static final int DENSITY_420 = 420; // 0x1a4 field public static final int DENSITY_560 = 560; // 0x230 field public static final int DENSITY_DEFAULT = 160; // 0xa0 field public static final int DENSITY_DEVICE_STABLE; field public static final int DENSITY_HIGH = 240; // 0xf0 field public static final int DENSITY_LOW = 120; // 0x78 field public static final int DENSITY_MEDIUM = 160; // 0xa0
api/test-current.txt +1 −0 Original line number Diff line number Diff line Loading @@ -39898,6 +39898,7 @@ package android.util { field public static final int DENSITY_420 = 420; // 0x1a4 field public static final int DENSITY_560 = 560; // 0x230 field public static final int DENSITY_DEFAULT = 160; // 0xa0 field public static final int DENSITY_DEVICE_STABLE; field public static final int DENSITY_HIGH = 240; // 0xf0 field public static final int DENSITY_LOW = 120; // 0x78 field public static final int DENSITY_MEDIUM = 160; // 0xa0
core/java/android/util/DisplayMetrics.java +18 −5 Original line number Diff line number Diff line Loading @@ -131,15 +131,28 @@ public class DisplayMetrics { public static final float DENSITY_DEFAULT_SCALE = 1.0f / DENSITY_DEFAULT; /** * The device's density. * @hide because eventually this should be able to change while * running, so shouldn't be a constant. * @deprecated There is no longer a static density; you can find the * density for a display in {@link #densityDpi}. * The device's current density. * <p> * This value reflects any changes made to the device density. To obtain * the device's stable density, use {@link #DENSITY_DEVICE_STABLE}. * * @hide This value should not be used. * @deprecated Use {@link #DENSITY_DEVICE_STABLE} to obtain the stable * device density or {@link #densityDpi} to obtain the current * density for a specific display. */ @Deprecated public static int DENSITY_DEVICE = getDeviceDensity(); /** * The device's stable density. * <p> * This value is constant at run time and may not reflect the current * display density. To obtain the current density for a specific display, * use {@link #densityDpi}. */ public static final int DENSITY_DEVICE_STABLE = getDeviceDensity(); /** * The absolute width of the display in pixels. */ Loading