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

Commit 76c382ed authored by Scott Kennedy's avatar Scott Kennedy
Browse files

Add @Nullable to AttributeSet in a couple constructors

Change-Id: I184113680c5dc867b353df81961e93523b91bbc5
parent cd25e1c6
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -3582,7 +3582,7 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
     * @param attrs The attributes of the XML tag that is inflating the view.
     * @see #View(Context, AttributeSet, int)
     */
    public View(Context context, AttributeSet attrs) {
    public View(Context context, @Nullable AttributeSet attrs) {
        this(context, attrs, 0);
    }
@@ -3603,7 +3603,7 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
     *        the view. Can be 0 to not look for defaults.
     * @see #View(Context, AttributeSet)
     */
    public View(Context context, AttributeSet attrs, int defStyleAttr) {
    public View(Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
        this(context, attrs, defStyleAttr, 0);
    }
@@ -3640,7 +3640,7 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
     *        to not look for defaults.
     * @see #View(Context, AttributeSet, int)
     */
    public View(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
    public View(Context context, @Nullable AttributeSet attrs, int defStyleAttr, int defStyleRes) {
        this(context);
        final TypedArray a = context.obtainStyledAttributes(
+4 −3
Original line number Diff line number Diff line
@@ -127,15 +127,16 @@ public class ImageView extends View {
        initImageView();
    }

    public ImageView(Context context, AttributeSet attrs) {
    public ImageView(Context context, @Nullable AttributeSet attrs) {
        this(context, attrs, 0);
    }

    public ImageView(Context context, AttributeSet attrs, int defStyleAttr) {
    public ImageView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
        this(context, attrs, defStyleAttr, 0);
    }

    public ImageView(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
    public ImageView(Context context, @Nullable AttributeSet attrs, int defStyleAttr,
            int defStyleRes) {
        super(context, attrs, defStyleAttr, defStyleRes);

        initImageView();