fix esc key not working if not focus in modal

This commit is contained in:
Ezequiel Bergamaschi 2014-09-11 14:38:22 -03:00
parent 9fd5c2c8d4
commit c946742767

View File

@ -13,7 +13,7 @@ var BootstrapDialog = new Class({
initialize: function (title, options) {
this.setOptions(options);
this.options.onRemoveClickData.dialog = this;
this._native = $('<div class="modal fade"></div>').append('<div class="modal-dialog"></div>');
this._native = $('<div class="modal fade" tabindex="-1"></div>').append('<div class="modal-dialog"></div>');
var content = $('<div class="modal-content"></div>');
content.on('keydown', function(event) {
event.stopPropagation();