igniteui-react-core
Version:
Ignite UI React Core.
38 lines (37 loc) • 1.55 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 "./type";
import { CollisionRect } from "./CollisionRect";
/**
* @hidden
*/
var CollisionGeometry = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(CollisionGeometry, _super);
function CollisionGeometry() {
return _super !== null && _super.apply(this, arguments) || this;
}
CollisionGeometry.prototype.e = function (a) {
return this.collidesWith(new CollisionRect(0, a));
};
CollisionGeometry.prototype.collidesWith = function (a) {
if (!this.boundingBox.intersectsWith(a)) {
return false;
}
return this.d(a);
};
CollisionGeometry.prototype.collidesWithPoint = function (a, b) {
var c = new CollisionRect(1, a, b, 0, 0);
if (!this.boundingBox.intersectsWith(c)) {
return false;
}
return this.d(c);
};
CollisionGeometry.$t = markType(CollisionGeometry, 'CollisionGeometry');
return CollisionGeometry;
}(Base));
export { CollisionGeometry };