diff options
| author | 2017-05-26 20:54:49 +0000 | |
|---|---|---|
| committer | 2017-05-26 20:54:57 +0000 | |
| commit | bd8fb0e71d02a0b3b85fa7bfed410f8d6df125bb (patch) | |
| tree | e2c6972860a573e7210c95878e058459788f5765 | |
| parent | b25f52c042dc8954812767a3ee99b4dff4a6afef (diff) | |
| parent | a7cec30f983cbb3d90b13449adf43fec5c1ec677 (diff) | |
Merge "Resolve inflate attr against default package" into oc-dev
| -rw-r--r-- | core/java/android/view/LayoutInflater.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/core/java/android/view/LayoutInflater.java b/core/java/android/view/LayoutInflater.java index f987e4ee184a..ad46d07d61c9 100644 --- a/core/java/android/view/LayoutInflater.java +++ b/core/java/android/view/LayoutInflater.java @@ -923,8 +923,11 @@ public abstract class LayoutInflater { + " include tag: <include layout=\"@layout/layoutID\" />"); } - // Attempt to resolve the "?attr/name" string to an identifier. - layout = context.getResources().getIdentifier(value.substring(1), null, null); + // Attempt to resolve the "?attr/name" string to an attribute + // within the default (e.g. application) package. + layout = context.getResources().getIdentifier( + value.substring(1), "attr", context.getPackageName()); + } // The layout might be referencing a theme attribute. |