Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ab324cfb authored by Aurimas Liutikas's avatar Aurimas Liutikas
Browse files

Update core widgets to save attribute source info.

Bug: 111439551
Test: make -j
Change-Id: I72997a87122f38b32e38e42a690385acc7d0e521
parent f6f2e32b
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -703,7 +703,9 @@ public abstract class ViewGroup extends View implements ViewParent, ViewManager

    private void initFromAttributes(
            Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
        final TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.ViewGroup, defStyleAttr,
        final TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.ViewGroup,
                defStyleAttr, defStyleRes);
        saveAttributeDataForStyleable(context, R.styleable.ViewGroup, attrs, a, defStyleAttr,
                defStyleRes);

        final int N = a.getIndexCount();
+3 −0
Original line number Diff line number Diff line
@@ -108,6 +108,9 @@ public final class ViewStub extends View {

        final TypedArray a = context.obtainStyledAttributes(attrs,
                R.styleable.ViewStub, defStyleAttr, defStyleRes);
        saveAttributeDataForStyleable(context, R.styleable.ViewStub, attrs, a, defStyleAttr,
                defStyleRes);

        mInflatedId = a.getResourceId(R.styleable.ViewStub_inflatedId, NO_ID);
        mLayoutResource = a.getResourceId(R.styleable.ViewStub_layout, 0);
        mID = a.getResourceId(R.styleable.ViewStub_id, NO_ID);
+2 −0
Original line number Diff line number Diff line
@@ -875,6 +875,8 @@ public abstract class AbsListView extends AdapterView<ListAdapter> implements Te

        final TypedArray a = context.obtainStyledAttributes(
                attrs, R.styleable.AbsListView, defStyleAttr, defStyleRes);
        saveAttributeDataForStyleable(context, R.styleable.AbsListView, attrs, a, defStyleAttr,
                defStyleRes);

        final Drawable selector = a.getDrawable(R.styleable.AbsListView_listSelector);
        if (selector != null) {
+2 −0
Original line number Diff line number Diff line
@@ -107,6 +107,8 @@ public abstract class AbsSeekBar extends ProgressBar {

        final TypedArray a = context.obtainStyledAttributes(
                attrs, R.styleable.SeekBar, defStyleAttr, defStyleRes);
        saveAttributeDataForStyleable(context, R.styleable.SeekBar, attrs, a, defStyleAttr,
                defStyleRes);

        final Drawable thumb = a.getDrawable(R.styleable.SeekBar_thumb);
        setThumb(thumb);
+2 −0
Original line number Diff line number Diff line
@@ -82,6 +82,8 @@ public abstract class AbsSpinner extends AdapterView<SpinnerAdapter> {

        final TypedArray a = context.obtainStyledAttributes(
                attrs, R.styleable.AbsSpinner, defStyleAttr, defStyleRes);
        saveAttributeDataForStyleable(context, R.styleable.AbsSpinner, attrs, a, defStyleAttr,
                defStyleRes);

        final CharSequence[] entries = a.getTextArray(R.styleable.AbsSpinner_entries);
        if (entries != null) {
Loading