Cancel events on buttons
This commit is contained in:
parent
743b5c6e8d
commit
46091aa7db
@ -81,9 +81,11 @@
|
|||||||
this.$refs.upload.check()
|
this.$refs.upload.check()
|
||||||
},
|
},
|
||||||
zoomout() {
|
zoomout() {
|
||||||
|
this.$parent.$parent.$refs.editLayer.stopDrawing()
|
||||||
this.$parent.$parent.zoomUpdated(9)
|
this.$parent.$parent.zoomUpdated(9)
|
||||||
},
|
},
|
||||||
zoomin() {
|
zoomin() {
|
||||||
|
this.$parent.$parent.$refs.editLayer.stopDrawing()
|
||||||
this.$parent.$parent.zoomUpdated(14)
|
this.$parent.$parent.zoomUpdated(14)
|
||||||
},
|
},
|
||||||
edit () {
|
edit () {
|
||||||
@ -106,6 +108,7 @@
|
|||||||
this.$parent.$parent.$refs.editLayer.reload(false)
|
this.$parent.$parent.$refs.editLayer.reload(false)
|
||||||
},
|
},
|
||||||
save () {
|
save () {
|
||||||
|
this.$parent.$parent.$refs.editLayer.stopDrawing()
|
||||||
this.editing = false
|
this.editing = false
|
||||||
this.$parent.$parent.$refs.map.mapObject.options.minZoom = 1;
|
this.$parent.$parent.$refs.map.mapObject.options.minZoom = 1;
|
||||||
Vue.set(this, 'saveDialogVisible', true)
|
Vue.set(this, 'saveDialogVisible', true)
|
||||||
@ -191,21 +194,27 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
drawPolyline () {
|
drawPolyline () {
|
||||||
|
this.$parent.$parent.$refs.editLayer.stopDrawing()
|
||||||
this.$parent.$parent.$refs.editLayer.drawPolyline()
|
this.$parent.$parent.$refs.editLayer.drawPolyline()
|
||||||
},
|
},
|
||||||
drawForwardPolyline () {
|
drawForwardPolyline () {
|
||||||
|
this.$parent.$parent.$refs.editLayer.stopDrawing()
|
||||||
this.$parent.$parent.$refs.editLayer.drawForwardPolyline()
|
this.$parent.$parent.$refs.editLayer.drawForwardPolyline()
|
||||||
},
|
},
|
||||||
drawPushbackPolyline () {
|
drawPushbackPolyline () {
|
||||||
|
this.$parent.$parent.$refs.editLayer.stopDrawing()
|
||||||
this.$parent.$parent.$refs.editLayer.drawPushbackPolyline()
|
this.$parent.$parent.$refs.editLayer.drawPushbackPolyline()
|
||||||
},
|
},
|
||||||
drawParking () {
|
drawParking () {
|
||||||
|
this.$parent.$parent.$refs.editLayer.stopDrawing()
|
||||||
this.$parent.$parent.$refs.editLayer.drawParking()
|
this.$parent.$parent.$refs.editLayer.drawParking()
|
||||||
},
|
},
|
||||||
deleteFeature () {
|
deleteFeature () {
|
||||||
|
this.$parent.$parent.$refs.editLayer.stopDrawing()
|
||||||
this.$parent.$parent.$refs.editLayer.deleteFeature()
|
this.$parent.$parent.$refs.editLayer.deleteFeature()
|
||||||
},
|
},
|
||||||
showCheck() {
|
showCheck() {
|
||||||
|
this.$parent.$parent.$refs.editLayer.stopDrawing()
|
||||||
Vue.set(this, 'checkDialogVisible', true)
|
Vue.set(this, 'checkDialogVisible', true)
|
||||||
this.check()
|
this.check()
|
||||||
},
|
},
|
||||||
|
@ -766,6 +766,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
drawParking () {
|
drawParking () {
|
||||||
|
this.$parent.mapObject._container.style.cursor = 'crosshair'
|
||||||
this.$parent.mapObject.on('click', this.addParking)
|
this.$parent.mapObject.on('click', this.addParking)
|
||||||
},
|
},
|
||||||
removeLayerClick (event) {
|
removeLayerClick (event) {
|
||||||
@ -789,6 +790,7 @@
|
|||||||
addFeature(circle)
|
addFeature(circle)
|
||||||
// console.log(this.groundnetLayerGroup)
|
// console.log(this.groundnetLayerGroup)
|
||||||
this.$parent.mapObject.off('click', this.addParking)
|
this.$parent.mapObject.off('click', this.addParking)
|
||||||
|
this.$parent.mapObject._container.style.cursor = ''
|
||||||
},
|
},
|
||||||
reload (force) {
|
reload (force) {
|
||||||
this.load(this.icao, force)
|
this.load(this.icao, force)
|
||||||
|
@ -17,6 +17,11 @@ L.EditControl = L.Control.extend({
|
|||||||
link.title = this.options.tooltip;
|
link.title = this.options.tooltip;
|
||||||
link.innerHTML = this.options.html;
|
link.innerHTML = this.options.html;
|
||||||
link.callback = this.options.callback;
|
link.callback = this.options.callback;
|
||||||
|
link.addEventListener('click',function (event) {
|
||||||
|
event.stopPropagation();
|
||||||
|
event.preventDefault();
|
||||||
|
event.stopImmediatePropagation();
|
||||||
|
}, false);
|
||||||
link.addEventListener('mousedown',function (event) {
|
link.addEventListener('mousedown',function (event) {
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
|
Loading…
Reference in New Issue
Block a user