commited for presentation.
This commit is contained in:
@@ -9,6 +9,9 @@ import { ScatterContainer } from '../scatter.js'
|
||||
* The GeoLayer is a special PIXILayer, that recognizes other GeoLayers and
|
||||
* GeoGraphics. The layer can be adapted to a map and notifies all Geo-Children
|
||||
* of the Adaption.
|
||||
*
|
||||
* @export
|
||||
* @class GeoLayer
|
||||
*/
|
||||
export class GeoLayer {
|
||||
constructor(displayObject, opts = {}) {
|
||||
@@ -264,7 +267,7 @@ export class MapLayer extends GeoLayer {
|
||||
listeners: onChange
|
||||
})
|
||||
|
||||
this.mapview = new MapViewport({
|
||||
this._mapview = new MapViewport({
|
||||
zoom,
|
||||
focus,
|
||||
viewport
|
||||
@@ -284,6 +287,18 @@ export class MapLayer extends GeoLayer {
|
||||
this.changeMap(mapList.active)
|
||||
}
|
||||
|
||||
//Todo: rename to mapviewport.
|
||||
/**
|
||||
* Returns the MapViewport of this map layer.
|
||||
*
|
||||
* @readonly
|
||||
* @member {MapViewport}
|
||||
* @memberof MapLayer
|
||||
*/
|
||||
get mapview() {
|
||||
return this._mapview
|
||||
}
|
||||
|
||||
get mapChangeLocked() {
|
||||
return this._mapChangeLocked
|
||||
}
|
||||
@@ -311,7 +326,7 @@ export class MapLayer extends GeoLayer {
|
||||
}
|
||||
|
||||
transformed(e) {
|
||||
this.mapview.transformed(this.map)
|
||||
this.mapview.update(this.map)
|
||||
this.layers.forEach(layer => layer.parentMapLayerTransformed(this))
|
||||
this.transformHandler.call(this)
|
||||
}
|
||||
@@ -321,7 +336,7 @@ export class MapLayer extends GeoLayer {
|
||||
*
|
||||
* @param {ScatterContainer} scatterContainer - ScatterContainer of the app.
|
||||
* @param {PIXI.DisplayObject} [container=null] - Container of the newly created MapLayer. If null, an empty PIXI.Container will be created.
|
||||
* @returns
|
||||
* @returns {MapLayer} - Returns the cloned MapLayer.
|
||||
* @memberof MapLayer
|
||||
*/
|
||||
clone(scatterContainer, container = null) {
|
||||
|
||||
Reference in New Issue
Block a user