/*
THIS INFRAGISTICS ULTIMATE SOFTWARE LICENSE  AGREEMENT ("AGREEMENT") LOCATED HERE:
https://www.infragistics.com/legal/license/igultimate-la
https://www.infragistics.com/legal/license/igultimate-eula
GOVERNS THE LICENSING, INSTALLATION AND USE OF INFRAGISTICS SOFTWARE. BY DOWNLOADING AND/OR INSTALLING AND USING INFRAGISTICS SOFTWARE:  you are indicating that you have read and understand this Agreement, and agree to be legally bound by it on behalf of the yourself and your company.
*/
import { __extends } from "tslib";
import { DataPieBaseChart } from "./DataPieBaseChart";
import { typeCast, enumGetBox, markType } from "igniteui-react-core";
import { List$1 } from "igniteui-react-core";
import { DataSeriesType_$type } from "igniteui-react-core";
import { IDataSeriesAdapterRule_$type } from "igniteui-react-core";
import { SimplePieSeriesRule } from "igniteui-react-core";
import { SubCollectionsRule } from "igniteui-react-core";
import { DataPieChartType_$type } from "./DataPieChartType";
import { CategoryTransitionInMode_$type } from "./CategoryTransitionInMode";
import { TransitionInSpeedType_$type } from "./TransitionInSpeedType";
import { BrushUtil } from "igniteui-react-core";
import { AxisDefaults } from "./AxisDefaults";
import { Defaults } from "./Defaults";
import { DeviceUtils } from "igniteui-react-core";
import { RadialBase } from "./RadialBase";
import { RadialPieSeries } from "./RadialPieSeries";
/**
 * @hidden
 */
var DataPieChart = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(DataPieChart, _super);
    function DataPieChart() {
        var _this = _super.call(this) || this;
        _this.ajx = 1000;
        _this.ajy = 1000;
        _this.ajr = null;
        _this.ajs = null;
        _this.ajn = 0;
        _this.ajv = true;
        _this.ajl = 0;
        _this.ajp = 3;
        _this.t8();
        return _this;
    }
    DataPieChart.prototype.ur = function () {
        _super.prototype.ur.call(this);
        if (this.dataChart == null) {
            return;
        }
        var a = this.dataChart.c8.j.e();
        if (this.afh == null) {
            this.afh = a.k;
        }
        if (this.afo == null) {
            this.afo = a.k;
        }
        this.abg = 0;
        this.afp = BrushUtil.h(0, 0, 0, 0);
        this.afs = BrushUtil.h(0, 0, 0, 0);
        this.afl = BrushUtil.h(0, 0, 0, 0);
        this.afi = BrushUtil.h(0, 0, 0, 0);
        this.aav = 0;
        this.afm = BrushUtil.h(0, 0, 0, 0);
        this.aaw = AxisDefaults.e;
        this.af3 = 1;
        this.af4 = 1;
        this.bf = 1;
        this.gj = true;
        this.jg = Defaults.j;
        this.xk = Defaults.ae;
        this.xf = Defaults.af;
        this.xg = Defaults.ag;
        this.gc = true;
        this.hf = true;
        this.g0 = false;
        this.g8 = false;
        this.b3 = 1;
        this.bz = 11;
        this.ajw = true;
        this.xe = BrushUtil.h(255, 255, 255, 255);
        this.jf = DeviceUtils.g(2);
        this.gg = true;
        this.ge = true;
        this.ga = true;
        this.di = 4;
        this.dg = 4;
    };
    DataPieChart.prototype.ut = function (a, b) {
        _super.prototype.ut.call(this, a, b);
        a.kc = this.ajz;
        a.kd = this.aj0;
        a.dc = this.ajt;
        a.dd = this.aju;
    };
    DataPieChart.prototype.vi = function (a, b, c) {
        var _this = this;
        _super.prototype.vi.call(this, a, b, c);
        switch (a) {
            case "TransitionInDuration":
                this.ug(function (d) { return d.kc = _this.ajz; });
                break;
            case "TransitionOutDuration":
                this.ug(function (d) { return d.kd = _this.aj0; });
                break;
            case "TransitionInEasingFunction":
                this.ug(function (d) { return d.dc = _this.ajt; });
                break;
            case "TransitionOutEasingFunction":
                this.ug(function (d) { return d.dd = _this.aju; });
                break;
        }
    };
    Object.defineProperty(DataPieChart.prototype, "ajz", {
        get: function () {
            return this.ajx;
        },
        set: function (a) {
            var b = this.ajz;
            if (a != b) {
                this.ajx = a;
                this.vf("TransitionInDuration", b, this.ajz);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(DataPieChart.prototype, "aj0", {
        get: function () {
            return this.ajy;
        },
        set: function (a) {
            var b = this.aj0;
            if (a != b) {
                this.ajy = a;
                this.vf("TransitionOutDuration", b, this.aj0);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(DataPieChart.prototype, "ajt", {
        get: function () {
            return this.ajr;
        },
        set: function (a) {
            var b = this.ajt;
            if (a != b) {
                this.ajr = a;
                this.vf("TransitionInEasingFunction", b, this.ajt);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(DataPieChart.prototype, "aju", {
        get: function () {
            return this.ajs;
        },
        set: function (a) {
            var b = this.aju;
            if (a != b) {
                this.ajs = a;
                this.vf("TransitionOutEasingFunction", b, this.aju);
            }
        },
        enumerable: false,
        configurable: true
    });
    DataPieChart.prototype.aj2 = function () {
        var cvd_ = this.lp();
        cvd_.scaleByViewport();
        return (cvd_.serialize());
    };
    DataPieChart.prototype.get_hs = function () {
        return ((function () {
            var $ret = new List$1(DataSeriesType_$type, 0);
            $ret.add(34);
            return $ret;
        })());
    };
    Object.defineProperty(DataPieChart.prototype, "hs", {
        get: function () {
            return this.get_hs();
        },
        enumerable: false,
        configurable: true
    });
    DataPieChart.prototype.get_hr = function () {
        return ((function () {
            var $ret = new List$1(IDataSeriesAdapterRule_$type, 0);
            $ret.add(new SimplePieSeriesRule());
            $ret.add(new SubCollectionsRule());
            return $ret;
        })());
    };
    Object.defineProperty(DataPieChart.prototype, "hr", {
        get: function () {
            return this.get_hr();
        },
        enumerable: false,
        configurable: true
    });
    DataPieChart.prototype.get_ag1 = function () {
        return false;
    };
    DataPieChart.prototype.bi = function (a) {
        if (this.ajo == 0) {
            return a.suggestedSeries;
        }
        if (this.ajo == 1) {
            return 34;
        }
        return 34;
    };
    DataPieChart.prototype.da = function (a, b) {
        var c = _super.prototype.da.call(this, a, b);
        return c;
    };
    DataPieChart.prototype.um = function (a, b) {
        _super.prototype.um.call(this, a, b);
    };
    DataPieChart.prototype.us = function (a, b) {
        _super.prototype.us.call(this, a, b);
        var c = typeCast(RadialBase.$, a);
        if (c == null) {
            return;
        }
        c.zj = this.ajw;
        c.yt = this.ajm;
        c.c3 = this.ajq;
    };
    DataPieChart.prototype.tx = function (a, b) {
        _super.prototype.tx.call(this, a, b);
        var c = typeCast(RadialPieSeries.$, a);
        if (c != null) {
            c.w1 = this.c0(a, b);
        }
    };
    DataPieChart.prototype.cz = function (a) {
        return 13;
    };
    DataPieChart.prototype.vf = function (a, b, c) {
        _super.prototype.vf.call(this, a, b, c);
        switch (a) {
            case "ChartType":
                this.t7();
                break;
        }
    };
    DataPieChart.prototype.get_b9 = function () {
        return 4;
    };
    Object.defineProperty(DataPieChart.prototype, "b9", {
        get: function () {
            return this.get_b9();
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(DataPieChart.prototype, "ajo", {
        get: function () {
            return this.ajn;
        },
        set: function (a) {
            if (a != this.ajn) {
                var b = this.ajo;
                this.ajn = a;
                this.vf("ChartType", enumGetBox(DataPieChartType_$type, b), enumGetBox(DataPieChartType_$type, this.ajo));
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(DataPieChart.prototype, "ajw", {
        get: function () {
            return this.ajv;
        },
        set: function (a) {
            var b = this.ajw;
            if (a != b) {
                this.ajv = a;
                this.vf("IsTransitionInEnabled", b, this.ajw);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(DataPieChart.prototype, "ajm", {
        get: function () {
            return this.ajl;
        },
        set: function (a) {
            var b = this.ajm;
            if (a != b) {
                this.ajl = a;
                this.vf("TransitionInMode", enumGetBox(CategoryTransitionInMode_$type, b), enumGetBox(CategoryTransitionInMode_$type, this.ajm));
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(DataPieChart.prototype, "ajq", {
        get: function () {
            return this.ajp;
        },
        set: function (a) {
            var b = this.ajq;
            if (a != b) {
                this.ajp = a;
                this.vf("TransitionInSpeedType", enumGetBox(TransitionInSpeedType_$type, b), enumGetBox(TransitionInSpeedType_$type, this.ajq));
            }
        },
        enumerable: false,
        configurable: true
    });
    DataPieChart.$t = markType(DataPieChart, 'DataPieChart', DataPieBaseChart.$);
    return DataPieChart;
}(DataPieBaseChart));
export { DataPieChart };
