|
@@ -458,8 +458,7 @@ class MyMap extends Component {
|
|
boxZoom={false}
|
|
boxZoom={false}
|
|
>
|
|
>
|
|
<AttributionControl
|
|
<AttributionControl
|
|
- // prefix={window.EDITOR_NAME + " v" + PACKAGE.version}
|
|
|
|
- prefix={PACKAGE.name + " v" + PACKAGE.version}
|
|
|
|
|
|
+ prefix={window.MAP_NAME + " v" + PACKAGE.version}
|
|
/>
|
|
/>
|
|
|
|
|
|
<ScaleControl
|
|
<ScaleControl
|
|
@@ -651,7 +650,7 @@ class MyMap extends Component {
|
|
});
|
|
});
|
|
|
|
|
|
PubSub.subscribe("map.event.bind", (msg, data) => {
|
|
PubSub.subscribe("map.event.bind", (msg, data) => {
|
|
- if(data.eventName === 'contextmenu'){
|
|
|
|
|
|
+ if (data.eventName === 'contextmenu') {
|
|
this.elem.leafletElement.addEventListener(data.eventName, data.callback);
|
|
this.elem.leafletElement.addEventListener(data.eventName, data.callback);
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
@@ -659,11 +658,11 @@ class MyMap extends Component {
|
|
});
|
|
});
|
|
|
|
|
|
PubSub.subscribe("map.event.unbind", (msg, data) => {
|
|
PubSub.subscribe("map.event.unbind", (msg, data) => {
|
|
- if(data.eventName === 'contextmenu'){
|
|
|
|
|
|
+ if (data.eventName === 'contextmenu') {
|
|
this.elem.leafletElement.removeEventListener(data.eventName, data.callback);
|
|
this.elem.leafletElement.removeEventListener(data.eventName, data.callback);
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
- if(!data.callback){
|
|
|
|
|
|
+ if (!data.callback) {
|
|
this.elem.leafletElement.off(data.eventName);
|
|
this.elem.leafletElement.off(data.eventName);
|
|
return;
|
|
return;
|
|
}
|
|
}
|