@wcardinal/wcardinal-geditor
Version:
WebGL-based graphic editor, tester and viewer for supervisory systems
27 lines • 1.27 kB
JavaScript
import { __extends } from "tslib";
import { EShapeCapabilities, EShapeCapability } from "@wcardinal/wcardinal-ui";
import { ECommandShapePropertySimple } from "./e-command-shape-property-simple";
var ECommandShapePropertyRotation = /** @class */ (function (_super) {
__extends(ECommandShapePropertyRotation, _super);
function ECommandShapePropertyRotation() {
return _super !== null && _super.apply(this, arguments) || this;
}
ECommandShapePropertyRotation.prototype.toCapability = function (shape) {
if (EShapeCapabilities.contains(shape, EShapeCapability.ROTATION)) {
return EShapeCapability.ROTATION;
}
return EShapeCapability.NONE;
};
ECommandShapePropertyRotation.prototype.getProperty = function (shape, capability) {
return shape.transform.rotation;
};
ECommandShapePropertyRotation.prototype.setProperty = function (shape, capability, property) {
shape.transform.rotation = property;
};
ECommandShapePropertyRotation.prototype.isMergeable = function () {
return true;
};
return ECommandShapePropertyRotation;
}(ECommandShapePropertySimple));
export { ECommandShapePropertyRotation };
//# sourceMappingURL=e-command-shape-property-rotation.js.map