summaryrefslogtreecommitdiffstats
path: root/core/java/android/preference/GenericInflater.java
diff options
context:
space:
mode:
Diffstat (limited to 'core/java/android/preference/GenericInflater.java')
-rw-r--r--core/java/android/preference/GenericInflater.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/core/java/android/preference/GenericInflater.java b/core/java/android/preference/GenericInflater.java
index 7de7d1c..c84dbf1 100644
--- a/core/java/android/preference/GenericInflater.java
+++ b/core/java/android/preference/GenericInflater.java
@@ -23,6 +23,8 @@ import java.util.HashMap;
import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;
+import android.annotation.AnyRes;
+import android.annotation.XmlRes;
import android.content.Context;
import android.content.res.XmlResourceParser;
import android.util.AttributeSet;
@@ -216,7 +218,7 @@ abstract class GenericInflater<T, P extends GenericInflater.Parent> {
* this is the root item; otherwise it is the root of the inflated
* XML file.
*/
- public T inflate(int resource, P root) {
+ public T inflate(@XmlRes int resource, P root) {
return inflate(resource, root, root != null);
}
@@ -256,7 +258,7 @@ abstract class GenericInflater<T, P extends GenericInflater.Parent> {
* attachToRoot is true, this is root; otherwise it is the root of
* the inflated XML file.
*/
- public T inflate(int resource, P root, boolean attachToRoot) {
+ public T inflate(@XmlRes int resource, P root, boolean attachToRoot) {
if (DEBUG) System.out.println("INFLATING from resource: " + resource);
XmlResourceParser parser = getContext().getResources().getXml(resource);
try {