@robotlegsjs/createjs
Version:
CreateJS View Integration with RobotlegsJS
74 lines • 3.01 kB
JavaScript
;
// ------------------------------------------------------------------------------
// Copyright (c) 2017-present, RobotlegsJS. All Rights Reserved.
//
// NOTICE: You are permitted to use, modify, and distribute this file
// in accordance with the terms of the license agreement accompanying it.
// ------------------------------------------------------------------------------
Object.defineProperty(exports, "__esModule", { value: true });
exports.ViewManagerEvent = void 0;
var tslib_1 = require("tslib");
var core_1 = require("@robotlegsjs/core");
/**
* Container existence event
*
* @private
*/
var ViewManagerEvent = /** @class */ (function (_super) {
tslib_1.__extends(ViewManagerEvent, _super);
/*============================================================================*/
/* Constructor */
/*============================================================================*/
/**
* Creates a view manager event
*
* @param type The event type
* @param container The container associated with this event
* @param handler The view handler associated with this event
*/
function ViewManagerEvent(type, container, handler) {
var _this = _super.call(this, type) || this;
_this._container = container;
_this._handler = handler;
return _this;
}
Object.defineProperty(ViewManagerEvent.prototype, "container", {
/**
* The container associated with this event
*/
get: function () {
return this._container;
},
enumerable: false,
configurable: true
});
Object.defineProperty(ViewManagerEvent.prototype, "handler", {
/**
* The view handler associated with this event
*/
get: function () {
return this._handler;
},
enumerable: false,
configurable: true
});
/*============================================================================*/
/* Public Functions */
/*============================================================================*/
/**
* @inheritDoc
*/
ViewManagerEvent.prototype.clone = function () {
return new ViewManagerEvent(this.type, this._container, this._handler);
};
/*============================================================================*/
/* Public Static Properties */
/*============================================================================*/
ViewManagerEvent.CONTAINER_ADD = "containerAdd";
ViewManagerEvent.CONTAINER_REMOVE = "containerRemove";
ViewManagerEvent.HANDLER_ADD = "handlerAdd";
ViewManagerEvent.HANDLER_REMOVE = "handlerRemove";
return ViewManagerEvent;
}(core_1.Event));
exports.ViewManagerEvent = ViewManagerEvent;
//# sourceMappingURL=ViewManagerEvent.js.map