private void setTextAttributes()

in rides-android/src/main/java/com/uber/sdk/android/rides/RideRequestButton.java [239:263]


    private void setTextAttributes(
            @NonNull Context context,
            @Nullable AttributeSet attrs,
            int defStyleAttr,
            int defStyleRes) {
        int attrsResources[] = {
                android.R.attr.textColor,
                android.R.attr.gravity,
                android.R.attr.textSize,
                android.R.attr.textStyle,
                android.R.attr.text
        };
        TypedArray textAttributes = context.getTheme().obtainStyledAttributes(
                attrs,
                attrsResources,
                defStyleAttr,
                defStyleRes);
        try {
            applyTextAttributes(priceEstimateView, textAttributes);
            applyTextAttributes(timeEstimateView, textAttributes);
            applyTextAttributes(requestButton, textAttributes);
        } finally {
            textAttributes.recycle();
        }
    }