v14-preferences is an empty lib and libraries cannot directly
reference other libraries' R classes due to a bug in Make builds
Bug:
73250914
Bug:
74248169
Test: make && make checkbuild
Change-Id: Id156b2a2140cabc98b58b5312ea28da42f4ca63b
android-support-v7-recyclerview \
android-support-v7-preference \
android-support-v7-appcompat \
- android-support-v14-preference \
android-arch-lifecycle-runtime
LOCAL_SHARED_JAVA_LIBRARIES := \
<attr name="footerPreferenceStyle" format="reference" />
+ <!-- Workaround for b/74248169. These are duplicates of attrs in AndroidX preferences. -->
+ <attr name="preferenceStyle" format="reference" />
+ <attr name="switchPreferenceStyle" format="reference" />
+
</resources>
}
public RestrictedPreference(Context context, AttributeSet attrs) {
- this(context, attrs, TypedArrayUtils.getAttr(context,
- android.support.v7.preference.R.attr.preferenceStyle,
+ this(context, attrs, TypedArrayUtils.getAttr(context, R.attr.preferenceStyle,
android.R.attr.preferenceStyle));
}
}
public RestrictedSwitchPreference(Context context, AttributeSet attrs) {
- this(context, attrs, TypedArrayUtils.getAttr(context,
- android.support.v7.preference.R.attr.switchPreferenceStyle,
+ this(context, attrs, TypedArrayUtils.getAttr(context, R.attr.switchPreferenceStyle,
android.R.attr.switchPreferenceStyle));
}