Rename undefined inset constant
Bug: 27531289
Change-Id: I31c5cc295c7f36b934eccf46cdbe7a7b293af9e0
diff --git a/api/current.txt b/api/current.txt
index 6b10a17..1689dae 100644
--- a/api/current.txt
+++ b/api/current.txt
@@ -13035,9 +13035,9 @@
method public void setPaddingMode(int);
method public void setPaddingRelative(int, int, int, int);
method public void unscheduleDrawable(android.graphics.drawable.Drawable, java.lang.Runnable);
+ field public static final int INSET_UNDEFINED = -2147483648; // 0x80000000
field public static final int PADDING_MODE_NEST = 0; // 0x0
field public static final int PADDING_MODE_STACK = 1; // 0x1
- field public static final int UNDEFINED_INSET = -2147483648; // 0x80000000
}
public class LevelListDrawable extends android.graphics.drawable.DrawableContainer {
diff --git a/api/system-current.txt b/api/system-current.txt
index 0461368..707f6d3 100644
--- a/api/system-current.txt
+++ b/api/system-current.txt
@@ -13430,9 +13430,9 @@
method public void setPaddingMode(int);
method public void setPaddingRelative(int, int, int, int);
method public void unscheduleDrawable(android.graphics.drawable.Drawable, java.lang.Runnable);
+ field public static final int INSET_UNDEFINED = -2147483648; // 0x80000000
field public static final int PADDING_MODE_NEST = 0; // 0x0
field public static final int PADDING_MODE_STACK = 1; // 0x1
- field public static final int UNDEFINED_INSET = -2147483648; // 0x80000000
}
public class LevelListDrawable extends android.graphics.drawable.DrawableContainer {
diff --git a/api/test-current.txt b/api/test-current.txt
index f94bb2e..96b2033 100644
--- a/api/test-current.txt
+++ b/api/test-current.txt
@@ -13045,9 +13045,9 @@
method public void setPaddingMode(int);
method public void setPaddingRelative(int, int, int, int);
method public void unscheduleDrawable(android.graphics.drawable.Drawable, java.lang.Runnable);
+ field public static final int INSET_UNDEFINED = -2147483648; // 0x80000000
field public static final int PADDING_MODE_NEST = 0; // 0x0
field public static final int PADDING_MODE_STACK = 1; // 0x1
- field public static final int UNDEFINED_INSET = -2147483648; // 0x80000000
}
public class LevelListDrawable extends android.graphics.drawable.DrawableContainer {
diff --git a/graphics/java/android/graphics/drawable/LayerDrawable.java b/graphics/java/android/graphics/drawable/LayerDrawable.java
index 8417a40..d9c3a02 100644
--- a/graphics/java/android/graphics/drawable/LayerDrawable.java
+++ b/graphics/java/android/graphics/drawable/LayerDrawable.java
@@ -89,7 +89,7 @@
* @see #getLayerInsetStart(int)
* @see #getLayerInsetEnd(int)
*/
- public static final int UNDEFINED_INSET = Integer.MIN_VALUE;
+ public static final int INSET_UNDEFINED = Integer.MIN_VALUE;
LayerState mLayerState;
@@ -759,7 +759,7 @@
* @attr ref android.R.styleable#LayerDrawableItem_bottom
*/
public void setLayerInset(int index, int l, int t, int r, int b) {
- setLayerInsetInternal(index, l, t, r, b, UNDEFINED_INSET, UNDEFINED_INSET);
+ setLayerInsetInternal(index, l, t, r, b, INSET_UNDEFINED, INSET_UNDEFINED);
}
/**
@@ -874,7 +874,7 @@
/**
* @param index the index of the layer
* @return the number of pixels to inset from the start bound, or
- * {@link #UNDEFINED_INSET} if not specified
+ * {@link #INSET_UNDEFINED} if not specified
* @attr ref android.R.styleable#LayerDrawableItem_start
*/
public int getLayerInsetStart(int index) {
@@ -885,7 +885,7 @@
/**
* @param index the index of the layer to adjust
* @param e number of pixels to inset from the end bound, or
- * {@link #UNDEFINED_INSET} if not specified
+ * {@link #INSET_UNDEFINED} if not specified
* @attr ref android.R.styleable#LayerDrawableItem_end
*/
public void setLayerInsetEnd(int index, int e) {
@@ -1503,8 +1503,8 @@
// insets.
final int insetRtlL = isLayoutRtl ? r.mInsetE : r.mInsetS;
final int insetRtlR = isLayoutRtl ? r.mInsetS : r.mInsetE;
- final int insetL = insetRtlL == UNDEFINED_INSET ? r.mInsetL : insetRtlL;
- final int insetR = insetRtlR == UNDEFINED_INSET ? r.mInsetR : insetRtlR;
+ final int insetL = insetRtlL == INSET_UNDEFINED ? r.mInsetL : insetRtlL;
+ final int insetR = insetRtlR == INSET_UNDEFINED ? r.mInsetR : insetRtlR;
// Establish containing region based on aggregate padding and
// requested insets for the current layer.
@@ -1602,8 +1602,8 @@
// left / right ones.
final int insetRtlL = isLayoutRtl ? r.mInsetE : r.mInsetS;
final int insetRtlR = isLayoutRtl ? r.mInsetS : r.mInsetE;
- final int insetL = insetRtlL == UNDEFINED_INSET ? r.mInsetL : insetRtlL;
- final int insetR = insetRtlR == UNDEFINED_INSET ? r.mInsetR : insetRtlR;
+ final int insetL = insetRtlL == INSET_UNDEFINED ? r.mInsetL : insetRtlL;
+ final int insetR = insetRtlR == INSET_UNDEFINED ? r.mInsetR : insetRtlR;
// Don't apply padding and insets for children that don't have
// an intrinsic dimension.
@@ -1763,8 +1763,8 @@
public int[] mThemeAttrs;
public int mDensity = DisplayMetrics.DENSITY_DEFAULT;
public int mInsetL, mInsetT, mInsetR, mInsetB;
- public int mInsetS = UNDEFINED_INSET;
- public int mInsetE = UNDEFINED_INSET;
+ public int mInsetS = INSET_UNDEFINED;
+ public int mInsetE = INSET_UNDEFINED;
public int mWidth = -1;
public int mHeight = -1;
public int mGravity = Gravity.NO_GRAVITY;
@@ -1833,10 +1833,10 @@
mInsetT = Drawable.scaleFromDensity(mInsetT, sourceDensity, targetDensity, false);
mInsetR = Drawable.scaleFromDensity(mInsetR, sourceDensity, targetDensity, false);
mInsetB = Drawable.scaleFromDensity(mInsetB, sourceDensity, targetDensity, false);
- if (mInsetS != UNDEFINED_INSET) {
+ if (mInsetS != INSET_UNDEFINED) {
mInsetS = Drawable.scaleFromDensity(mInsetS, sourceDensity, targetDensity, false);
}
- if (mInsetE != UNDEFINED_INSET) {
+ if (mInsetE != INSET_UNDEFINED) {
mInsetE = Drawable.scaleFromDensity(mInsetE, sourceDensity, targetDensity, false);
}
if (mWidth > 0) {