2021-01-18 16:51:03 +01:00
|
|
|
import {Object3D} from "three";
|
|
|
|
|
2021-01-28 02:56:26 +01:00
|
|
|
export class MarkerSet extends Object3D {
|
2021-01-18 16:51:03 +01:00
|
|
|
|
2021-01-28 02:56:26 +01:00
|
|
|
/**
|
|
|
|
* @param markerSetId {string}
|
|
|
|
*/
|
|
|
|
constructor(markerSetId) {
|
|
|
|
super();
|
2021-01-18 16:51:03 +01:00
|
|
|
Object.defineProperty(this, 'isMarkerSet', {value: true});
|
|
|
|
|
2021-01-28 02:56:26 +01:00
|
|
|
this.markerSetId = markerSetId;
|
|
|
|
this.label = markerSetId;
|
2021-01-18 16:51:03 +01:00
|
|
|
|
|
|
|
this.toggleable = true;
|
|
|
|
this.defaultHide = false;
|
|
|
|
}
|
|
|
|
|
|
|
|
dispose() {
|
2021-01-28 02:56:26 +01:00
|
|
|
super.dispose();
|
2021-01-18 16:51:03 +01:00
|
|
|
|
2021-01-28 02:56:26 +01:00
|
|
|
this.children.forEach(child => {
|
|
|
|
if (child.dispose) child.dispose();
|
|
|
|
});
|
2021-01-18 16:51:03 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|