mirror of
https://bitbucket.org/wisemapping/wisemapping-open-source.git
synced 2024-11-22 14:17:57 +01:00
update remove button for editors
This commit is contained in:
parent
c78ae247f4
commit
ac425c6f0d
@ -54,7 +54,6 @@ var BootstrapDialog = new Class({
|
|||||||
this.removeButton = $('<button type="button" class="btn btn-secondary" id="removeBtn" data-dismiss="modal">'+ $msg('REMOVE') +'</button>');
|
this.removeButton = $('<button type="button" class="btn btn-secondary" id="removeBtn" data-dismiss="modal">'+ $msg('REMOVE') +'</button>');
|
||||||
footer.append(this.removeButton);
|
footer.append(this.removeButton);
|
||||||
this.removeButton.on('click', this.options.onRemoveClickData, this.onRemoveClick);
|
this.removeButton.on('click', this.options.onRemoveClickData, this.onRemoveClick);
|
||||||
this.removeButton.hide();
|
|
||||||
}
|
}
|
||||||
if (this.options.cancelButton) {
|
if (this.options.cancelButton) {
|
||||||
footer.append('<button type="button" class="btn btn-secondary" data-dismiss="modal">'+ $msg('CANCEL') +'</button>');
|
footer.append('<button type="button" class="btn btn-secondary" data-dismiss="modal">'+ $msg('CANCEL') +'</button>');
|
||||||
|
@ -116,6 +116,11 @@ mindplot.widget.LinkEditor = new Class({
|
|||||||
|
|
||||||
onDialogShown: function() {
|
onDialogShown: function() {
|
||||||
$(this).find('#inputUrl').focus();
|
$(this).find('#inputUrl').focus();
|
||||||
|
},
|
||||||
|
|
||||||
|
onRemoveClick: function(event) {
|
||||||
|
event.data.model.setValue(null);
|
||||||
|
event.data.dialog.close();
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
@ -82,6 +82,11 @@ mindplot.widget.NoteEditor = new Class({
|
|||||||
|
|
||||||
onDialogShown: function() {
|
onDialogShown: function() {
|
||||||
$(this).find('textarea').focus();
|
$(this).find('textarea').focus();
|
||||||
|
},
|
||||||
|
|
||||||
|
onRemoveClick: function(event) {
|
||||||
|
event.data.model.setValue(null);
|
||||||
|
event.data.dialog.close();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user