Modified scatter to get access to the Resize event.
This commit is contained in:
@@ -264,12 +264,10 @@ export class MapLayer extends GeoLayer {
|
||||
})
|
||||
}
|
||||
|
||||
// placeLayer(layer) {
|
||||
// super.placeLayer(layer)
|
||||
// if (layer instanceof GeoLayer && this.map) {
|
||||
// layer.adapt(this.map)
|
||||
// }
|
||||
// }
|
||||
|
||||
focus(coordinates, zoom) {
|
||||
this.mapview.updateFocusPoint(this.map)
|
||||
}
|
||||
|
||||
transformed(e) {
|
||||
this.mapview.transformed(this.map)
|
||||
@@ -401,6 +399,10 @@ export class MapLayer extends GeoLayer {
|
||||
}*/
|
||||
}
|
||||
|
||||
refocus() {
|
||||
this.mapview.apply(this.map)
|
||||
}
|
||||
|
||||
get map() {
|
||||
return this.mapList.map
|
||||
}
|
||||
|
||||
@@ -267,10 +267,20 @@ export class SubmapScatter extends DisplayObjectScatter {
|
||||
maxScale: 1,
|
||||
startScale: 1,
|
||||
overdoScaling: 1,
|
||||
scalable: false
|
||||
scalable: false,
|
||||
resizable: true
|
||||
})
|
||||
|
||||
super(displayObject, renderer, opts)
|
||||
|
||||
console.log('onResize', opts.onResize)
|
||||
this.onResize = opts.onResize
|
||||
}
|
||||
|
||||
gesture(interaction) {
|
||||
super.gesture(interaction)
|
||||
|
||||
if (this.onResize) this.onResize(interaction)
|
||||
}
|
||||
|
||||
get width() {
|
||||
|
||||
Reference in New Issue
Block a user