igniteui-react-grids
Version:
Ignite UI React grid components.
81 lines (80 loc) • 2.77 kB
JavaScript
/*
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 { Base, markType } from "igniteui-react-core";
import { ICellPresenter_$type } from "./ICellPresenter";
import { CellModel } from "./CellModel";
import { BrushUtil } from "igniteui-react-core";
/**
* @hidden
*/
var CanvasCellPresenterBase = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(CanvasCellPresenterBase, _super);
function CanvasCellPresenterBase(a) {
var _this = _super.call(this) || this;
_this.a = null;
_this.a = a;
return _this;
}
CanvasCellPresenterBase.prototype.modelUpdated = function (a) {
this.b(a);
};
CanvasCellPresenterBase.prototype.b = function (a) {
this.a.cf(a.c);
if (a.a8(CellModel.em) || a.a8(CellModel.eq) || a.a8(CellModel.eo) || a.a8(CellModel.ek)) {
this.a.cn(a.el, a.ep, a.en, a.ej);
}
if (a.a1) {
this.a.ch(a.lv, a.d9, a.ee, a.ec, a.d7);
}
if (a.bo) {
this.a.ck(a.fu);
this.a.cu(a.hd);
}
if (a.a3) {
if (a.bi && !this.a.z) {
this.a.b5();
}
if (a.a8(CellModel.d6)) {
this.a.cg(a.lu.color);
}
if (a.a8(CellModel.ei)) {
this.a.cm(a.ch);
}
}
if (a.bo && a.bi) {
this.a.cx(a);
}
};
CanvasCellPresenterBase.prototype.c = function (a, b, c) {
if (c == 0) {
return a.color;
}
if (c == 1) {
return b.color;
}
var d = BrushUtil.l(a, c, b, 0);
return d.color;
};
Object.defineProperty(CanvasCellPresenterBase.prototype, "nativeCell", {
get: function () {
return this.a;
},
enumerable: false,
configurable: true
});
Object.defineProperty(CanvasCellPresenterBase.prototype, "isCanvasBased", {
get: function () {
return true;
},
enumerable: false,
configurable: true
});
CanvasCellPresenterBase.$t = markType(CanvasCellPresenterBase, 'CanvasCellPresenterBase', Base.$, [ICellPresenter_$type]);
return CanvasCellPresenterBase;
}(Base));
export { CanvasCellPresenterBase };