package o;

import android.view.View;
import android.view.ViewGroup;

/* compiled from: r8-map-id-3b7cc9102578c509342fa2f0fabed2bfc72239cd258d579fc679bfcbc198b048 */
/* renamed from: o.d10, reason: case insensitive filesystem */
/* loaded from: classes.dex */
public final class C0966d10 {
    public final /* synthetic */ int a;
    public final /* synthetic */ AbstractC1157f10 b;

    public /* synthetic */ C0966d10(AbstractC1157f10 abstractC1157f10, int i) {
        this.a = i;
        this.b = abstractC1157f10;
    }

    public final int a(View view) {
        int right;
        int i;
        switch (this.a) {
            case 0:
                C1253g10 c1253g10 = (C1253g10) view.getLayoutParams();
                right = view.getRight() + ((C1253g10) view.getLayoutParams()).b.right;
                i = ((ViewGroup.MarginLayoutParams) c1253g10).rightMargin;
                break;
            default:
                C1253g10 c1253g102 = (C1253g10) view.getLayoutParams();
                right = view.getBottom() + ((C1253g10) view.getLayoutParams()).b.bottom;
                i = ((ViewGroup.MarginLayoutParams) c1253g102).bottomMargin;
                break;
        }
        return right + i;
    }

    public final int b(View view) {
        int left;
        int i;
        switch (this.a) {
            case 0:
                C1253g10 c1253g10 = (C1253g10) view.getLayoutParams();
                left = view.getLeft() - ((C1253g10) view.getLayoutParams()).b.left;
                i = ((ViewGroup.MarginLayoutParams) c1253g10).leftMargin;
                break;
            default:
                C1253g10 c1253g102 = (C1253g10) view.getLayoutParams();
                left = view.getTop() - ((C1253g10) view.getLayoutParams()).b.top;
                i = ((ViewGroup.MarginLayoutParams) c1253g102).topMargin;
                break;
        }
        return left - i;
    }

    public final int c() {
        int i;
        int iF;
        switch (this.a) {
            case 0:
                AbstractC1157f10 abstractC1157f10 = this.b;
                i = abstractC1157f10.n;
                iF = abstractC1157f10.F();
                break;
            default:
                AbstractC1157f10 abstractC1157f102 = this.b;
                i = abstractC1157f102.f519o;
                iF = abstractC1157f102.D();
                break;
        }
        return i - iF;
    }

    public final int d() {
        switch (this.a) {
            case 0:
                return this.b.E();
            default:
                return this.b.G();
        }
    }
}
