/*
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 { PolarLineSeriesBase } from "./PolarLineSeriesBase";
import { UnknownValuePlotting_$type } from "igniteui-angular-core";
import { DependencyProperty } from "igniteui-angular-core";
import { runOn, enumGetBox, markType, markDep, Point_$type } from "igniteui-angular-core";
import { Path } from "igniteui-angular-core";
import { List$1 } from "igniteui-angular-core";
import { PropertyMetadata } from "igniteui-angular-core";
import { PolarLineSeriesBaseView } from "./PolarLineSeriesBaseView";
import { Defaults } from "./Defaults";
import { Color } from "igniteui-angular-core";
/**
 * @hidden
 */
var PolarAreaSeries = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(PolarAreaSeries, _super);
    function PolarAreaSeries() {
        var _this = _super.call(this) || this;
        _this.ab = PolarAreaSeries.$;
        return _this;
    }
    PolarAreaSeries.prototype.bk = function () {
        return new PolarAreaSeries();
    };
    PolarAreaSeries.prototype.get_ew = function () {
        return true;
    };
    PolarAreaSeries.prototype.ct = function () {
        return new PolarAreaSeriesView(this);
    };
    PolarAreaSeries.prototype.z8 = function () {
        return false;
    };
    PolarAreaSeries.prototype.q7 = function (a) {
        _super.prototype.q7.call(this, a);
        this.ac4 = a;
    };
    PolarAreaSeries.prototype.ac2 = function (a) {
        var b = a;
        b.dn();
    };
    PolarAreaSeries.prototype.ac3 = function (a, b) {
        if (a.n.count > 0) {
            var c = a.n._inner[0];
            var d = a.n._inner[a.n.count - 1];
            var e = c.x == d.x && c.y == d.y;
            if (!e) {
                a.n.add(a.n._inner[0]);
            }
        }
        var f = b;
        f.dp(a.n, this.ie);
        this.zf.az(this, this.z7(), runOn(this, this.yx));
        var g = false;
        var h = this.zf.b;
        if (h != null) {
            g = true;
        }
        if (g) {
            this.abm(-1, this.zt.count, b.t);
        }
        var i = f.dv;
        var j = f.du;
        this.zf.ad(i, true, false, true, true);
        this.zf.ad(j, false, true, false, false);
        j._opacity = this.zf.j * this.ia;
    };
    PolarAreaSeries.prototype.get_acz = function () {
        return true;
    };
    PolarAreaSeries.prototype.acu = function () {
        return this.ac5;
    };
    PolarAreaSeries.$t = markType(PolarAreaSeries, 'PolarAreaSeries', PolarLineSeriesBase.$);
    PolarAreaSeries.$$p = markDep(DependencyProperty, PropertyMetadata, PolarAreaSeries, 'raisePropertyChanged', ['UnknownValuePlotting:ac5:ac7', [UnknownValuePlotting_$type, enumGetBox(UnknownValuePlotting_$type, 1)]]);
    return PolarAreaSeries;
}(PolarLineSeriesBase));
export { PolarAreaSeries };
/**
 * @hidden
 */
var PolarAreaSeriesView = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(PolarAreaSeriesView, _super);
    function PolarAreaSeriesView(a) {
        var _this = _super.call(this, a) || this;
        _this.dm = null;
        _this.dt = new Path();
        _this.ds = new Path();
        _this.dr = new Path();
        _this.dq = new Path();
        _this.dm = a;
        return _this;
    }
    PolarAreaSeriesView.prototype.a4 = function () {
        _super.prototype.a4.call(this);
        if (!this.t) {
            this.dm.xk = Defaults.e;
        }
    };
    Object.defineProperty(PolarAreaSeriesView.prototype, "du", {
        get: function () {
            return this.ds;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(PolarAreaSeriesView.prototype, "dv", {
        get: function () {
            return this.dt;
        },
        enumerable: false,
        configurable: true
    });
    PolarAreaSeriesView.prototype.dn = function () {
        this.ds.an = null;
        this.dt.an = null;
        this.dq.an = null;
        this.dr.an = null;
        this.a2();
    };
    PolarAreaSeriesView.prototype.dp = function (a, b) {
        var c = new List$1(Point_$type, 1, a);
        this.dm.acr.d(this.dt, c, b);
        this.dm.acr.d(this.ds, c, b);
        this.a2();
    };
    PolarAreaSeriesView.prototype.bp = function () {
        _super.prototype.bp.call(this);
    };
    PolarAreaSeriesView.prototype.bq = function () {
        _super.prototype.bq.call(this);
        var a = this.b3();
        this.dr.an = this.dt.an;
        this.dq.an = this.ds.an;
        this.dr._stroke = a;
        this.dr.ad = this.f.ig + 3;
        this.dq._fill = a;
        this.dq._opacity = 1;
    };
    PolarAreaSeriesView.prototype.bj = function (a, b) {
        _super.prototype.bj.call(this, a, b);
        if (a.d) {
            if (b) {
                a.t(this.dq);
                a.t(this.dr);
            }
            else {
                a.t(this.ds);
                a.t(this.dt);
            }
        }
    };
    PolarAreaSeriesView.prototype.ax = function (a) {
        _super.prototype.ax.call(this, a);
        this.f.bc.exportPathData(a, this.dt, "polarShape", ["Main"]);
        this.f.bc.exportPathData(a, this.ds, "fillShape", ["Fill"]);
    };
    PolarAreaSeriesView.prototype.an = function () {
        var a = new Color();
        a.colorString = "rgba(95,95,95,0.5)";
        this.f.wb = a;
        this.f.jq = 5;
        this.f.jr = 5;
        this.f.js = 5;
    };
    PolarAreaSeriesView.$t = markType(PolarAreaSeriesView, 'PolarAreaSeriesView', PolarLineSeriesBaseView.$);
    return PolarAreaSeriesView;
}(PolarLineSeriesBaseView));
export { PolarAreaSeriesView };
