igniteui-angular-core
Version:
Ignite UI Angular Core logic used in multiple UI components.
62 lines (61 loc) • 2.33 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 { CollisionGeometry } from "./CollisionGeometry";
import { CollisionRect } from "./CollisionRect";
import { markType } from "./type";
/**
* @hidden
*/
var BoxesCollisionGeometry = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(BoxesCollisionGeometry, _super);
function BoxesCollisionGeometry(a) {
var _this = _super.call(this) || this;
_this.g = null;
_this.h = CollisionRect.empty;
_this.g = a;
return _this;
}
BoxesCollisionGeometry.prototype.get_type = function () {
return 0;
};
Object.defineProperty(BoxesCollisionGeometry.prototype, "type", {
get: function () {
return this.get_type();
},
enumerable: false,
configurable: true
});
BoxesCollisionGeometry.prototype.get_boundingBox = function () {
if (this.h.isEmpty) {
var a = CollisionRect.empty;
for (var b = 0; b < this.g.length; b++) {
a.union(this.g[b]);
}
this.h = a;
}
return this.h;
};
Object.defineProperty(BoxesCollisionGeometry.prototype, "boundingBox", {
get: function () {
return this.get_boundingBox();
},
enumerable: false,
configurable: true
});
BoxesCollisionGeometry.prototype.d = function (a) {
for (var b = 0; b < this.g.length; b++) {
if (a.intersectsWith(this.g[b])) {
return true;
}
}
return false;
};
BoxesCollisionGeometry.$t = markType(BoxesCollisionGeometry, 'BoxesCollisionGeometry', CollisionGeometry.$);
return BoxesCollisionGeometry;
}(CollisionGeometry));
export { BoxesCollisionGeometry };