package androidx.leanback.widget.picker;

import android.text.TextUtils;
import defpackage.fp4;
import defpackage.n41;
import defpackage.q67;

/* JADX INFO: loaded from: classes.dex */
public class c extends q67 {
    public boolean r;
    public int s;
    public int t;
    public int u;
    public String v;

    @Override // defpackage.q67
    public final void a(int i, int i2) {
        if (i == 0) {
            this.s = i2;
        } else if (i == 0) {
            this.t = i2;
        } else {
            if (i != 0) {
                throw new IllegalArgumentException("Invalid column index.");
            }
            this.u = i2;
        }
    }

    public String getBestHourMinutePattern() {
        throw null;
    }

    public int getHour() {
        return this.r ? this.s : this.u == 0 ? this.s % 12 : (this.s % 12) + 12;
    }

    public int getMinute() {
        return this.t;
    }

    public void setHour(@fp4 int i) {
        if (i < 0 || i > 23) {
            throw new IllegalArgumentException(n41.i(i, "hour: ", " is not in [0-23] range in"));
        }
        this.s = i;
        boolean z = this.r;
        if (!z) {
            if (i >= 12) {
                this.u = 1;
                if (i > 12) {
                    this.s = i - 12;
                }
            } else {
                this.u = 0;
                if (i == 0) {
                    this.s = 12;
                }
            }
            if (!z) {
                c(0, this.u);
            }
        }
        c(0, this.s);
    }

    public void setIs24Hour(boolean z) {
        if (this.r == z) {
            return;
        }
        getHour();
        getMinute();
        this.r = z;
        String bestHourMinutePattern = getBestHourMinutePattern();
        if (TextUtils.equals(bestHourMinutePattern, this.v)) {
            throw null;
        }
        this.v = bestHourMinutePattern;
        getBestHourMinutePattern();
        throw null;
    }

    public void setMinute(@fp4 int i) {
        if (i < 0 || i > 59) {
            throw new IllegalArgumentException(n41.i(i, "minute: ", " is not in [0-59] range."));
        }
        this.t = i;
        c(0, i);
    }
}
