Fix themed attributes resolution

If an attribute is not an actual theme reference, the call to
Resources.Theme.resolveAttribute will fail in layoutlib. This would
happen for example for color values.
The call in the Android framework simply returns the value.

Bug: 31553972
Change-Id: Idda768a659d94a6c3f848dc960303cf4241325c3
This commit is contained in:
Diego Perez
2016-09-20 20:04:26 +01:00
parent d4babda3aa
commit 58658eaa64

View File

@@ -373,7 +373,9 @@ public final class BridgeContext extends Context {
return true;
}
return false;
// If the value is not a valid reference, fallback to pass the value as a string.
outValue.string = value.getValue();
return true;
}