am 8ed784e2: am edc8b857: Merge "Fix "@null" resource values in LayoutLib. [DO NOT MERGE]" into jb-mr1.1-dev

* commit '8ed784e2893c79d943b6184d25167ecf72a9a9ed':
  Fix "@null" resource values in LayoutLib. [DO NOT MERGE]
This commit is contained in:
Deepanshu Gupta
2014-09-04 02:15:02 +00:00
committed by Android Git Automerger

View File

@@ -91,7 +91,7 @@ public final class BridgeTypedArray extends TypedArray {
// first count the array size // first count the array size
int count = 0; int count = 0;
for (ResourceValue data : mResourceData) { for (ResourceValue data : mResourceData) {
if (data != null) { if (data != null && !RenderResources.REFERENCE_NULL.equals(data.getValue())) {
count++; count++;
} }
} }
@@ -103,7 +103,8 @@ public final class BridgeTypedArray extends TypedArray {
// fill the array with the indices. // fill the array with the indices.
int index = 1; int index = 1;
for (int i = 0 ; i < mResourceData.length ; i++) { for (int i = 0 ; i < mResourceData.length ; i++) {
if (mResourceData[i] != null) { if (mResourceData[i] != null
&& !RenderResources.REFERENCE_NULL.equals(mResourceData[i].getValue())) {
mIndices[index++] = i; mIndices[index++] = i;
} }
} }