maplair
Version:
JavaScript library for mobile-friendly interactive maps
39 lines (38 loc) • 899 B
JavaScript
import { stamp } from "../../core/Util.js";
import { BlanketOverlay } from "../BlanketOverlay.js";
//#region src/layer/vector/Renderer.js
var Renderer = class Renderer extends BlanketOverlay {
constructor(options) {
super({
...options,
continuous: false
});
stamp(this);
this._layers ??= {};
this.callInitHooks(Renderer);
}
onAdd(map) {
super.onAdd(map);
this.on("update", this._updatePaths, this);
}
onRemove() {
super.onRemove();
this.off("update", this._updatePaths, this);
}
_onZoomEnd() {
for (const layer of Object.values(this._layers)) layer._project();
}
_updatePaths() {
for (const layer of Object.values(this._layers)) layer._update();
}
_onViewReset() {
for (const layer of Object.values(this._layers)) layer._reset();
}
_onSettled() {
this._update();
}
_update() {}
};
//#endregion
export { Renderer };
//# sourceMappingURL=Renderer.js.map