diff --git a/mindplot/src/main/javascript/libraries/bootstrap/BootstrapDialog.js b/mindplot/src/main/javascript/libraries/bootstrap/BootstrapDialog.js index d1962f25..691091d4 100644 --- a/mindplot/src/main/javascript/libraries/bootstrap/BootstrapDialog.js +++ b/mindplot/src/main/javascript/libraries/bootstrap/BootstrapDialog.js @@ -5,11 +5,13 @@ var BootstrapDialog = new Class({ cancelButton: false, closeButton: false, acceptButton: true, - removeButton:false + removeButton:false, + onRemoveClickData:{} }, initialize: function (title, options) { this.setOptions(options); + this.options.onRemoveClickData.dialog = this; this._native = $('
').append(''); var content = $(''); var header = this._buildHeader(title); @@ -38,7 +40,7 @@ var BootstrapDialog = new Class({ if (this.options.removeButton) { this.removeButton = $(''); footer.append(this.removeButton); - this.removeButton.on('click', {data:'hola'}, this.onRemoveClick); + this.removeButton.on('click', this.options.onRemoveClickData, this.onRemoveClick); this.removeButton.hide(); } if (this.options.cancelButton) { @@ -58,7 +60,7 @@ var BootstrapDialog = new Class({ ); } if (title) { - header.append('