[VER] 4.0.29

This commit is contained in:
viglino 2025-03-24 09:45:15 +01:00
parent 4e09b872a9
commit efd315a937
4 changed files with 16 additions and 12 deletions

12
dist/ol-ext.js vendored
View File

@ -1,7 +1,7 @@
/**
* ol-ext - A set of cool extensions for OpenLayers (ol) in node modules structure
* @description ol3,openlayers,popup,menu,symbol,renderer,filter,canvas,interaction,split,statistic,charts,pie,LayerSwitcher,toolbar,animation
* @version v4.0.27
* @version v4.0.28
* @author Jean-Marc Viglino
* @see https://github.com/Viglino/ol-ext#,
* @license BSD-3-Clause
@ -8126,9 +8126,9 @@ ol.control.Dialog = class olcontrolDialog extends ol.control.Control {
e.preventDefault()
}
}.bind(this))
// Cencel event
// Cancel event
element.addEventListener('cancel', function(e) {
this.dispatchEvent('cancel');
setTimeout(function() { this.dispatchEvent('cancel'); }.bind(this))
}.bind(this));
}
// Constructor
@ -8371,8 +8371,10 @@ ol.control.Dialog = class olcontrolDialog extends ol.control.Control {
e.preventDefault();
if (button !== 'submit' || this.get('closeOnSubmit') !== false) this.hide();
var inputs = this.getInputs();
this.dispatchEvent({ type: 'button', button: button, inputs: inputs });
if (typeof (callback) === 'function') callback(button, inputs);
setTimeout(function() {
this.dispatchEvent({ type: 'button', button: button, inputs: inputs });
if (typeof (callback) === 'function') callback(button, inputs);
}.bind(this))
}.bind(this);
return fn;
}

4
dist/ol-ext.min.js vendored

File diff suppressed because one or more lines are too long

View File

@ -1,6 +1,6 @@
{
"name": "ol-ext",
"version": "4.0.28",
"version": "4.0.29",
"description": "A set of cool extensions for OpenLayers (ol) in node modules structure",
"main": "dist/ol-ext.js",
"style": "dist/ol-ext.css",

View File

@ -48,9 +48,9 @@ var ol_control_Dialog = class olcontrolDialog extends ol_control_Control {
e.preventDefault()
}
}.bind(this))
// Cencel event
// Cancel event
element.addEventListener('cancel', function(e) {
this.dispatchEvent('cancel');
setTimeout(function() { this.dispatchEvent('cancel'); }.bind(this))
}.bind(this));
}
@ -295,8 +295,10 @@ var ol_control_Dialog = class olcontrolDialog extends ol_control_Control {
e.preventDefault();
if (button !== 'submit' || this.get('closeOnSubmit') !== false) this.hide();
var inputs = this.getInputs();
this.dispatchEvent({ type: 'button', button: button, inputs: inputs });
if (typeof (callback) === 'function') callback(button, inputs);
setTimeout(function() {
this.dispatchEvent({ type: 'button', button: button, inputs: inputs });
if (typeof (callback) === 'function') callback(button, inputs);
}.bind(this))
}.bind(this);
return fn;
}