plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.js
function() {
        var editor = this;
        $.map(this.toolbar.commandMapping, function(value) {
          return [value];
        }).filter(function(commandObj) {
          return commandObj.dialog;
        }).map(function(commandObj) {
          return commandObj.dialog;
        }).forEach(function(dialog) {
          dialog.on('show', function() {
            $(this.container).modal('show');
          });
          dialog.on('hide', function() {
            $(this.container).modal('hide');
            setTimeout(editor.composer.focus, 0);
          });
          $(dialog.container).on('shown.bs.modal', function () {
            $(this).find('input, select, textarea').first().focus();
          });
        });
        this.on('change_view', function() {
          $(this.toolbar.container.children).find('a.btn').not('[data-wysihtml5-action="change_view"]').toggleClass('disabled');
        });
      }
function() {
        var editor = this;
        $.map(this.toolbar.commandMapping, function(value) {
          return [value];
        }).filter(function(commandObj) {
          return commandObj.dialog;
        }).map(function(commandObj) {
          return commandObj.dialog;
        }).forEach(function(dialog) {
          dialog.on('show', function() {
            $(this.container).modal('show');
          });
          dialog.on('hide', function() {
            $(this.container).modal('hide');
            setTimeout(editor.composer.focus, 0);
          });
          $(dialog.container).on('shown.bs.modal', function () {
            $(this).find('input, select, textarea').first().focus();
          });
        });
        this.on('change_view', function() {
          $(this.toolbar.container.children).find('a.btn').not('[data-wysihtml5-action="change_view"]').toggleClass('disabled');
        });
      }
function ( ) { var editor = this ; $ . map ( this . toolbar . commandMapping , function ( value ) { return [ value ] ; } ) . filter ( function ( commandObj ) { return commandObj . dialog ; } ) . map ( function ( commandObj ) { return commandObj . dialog ; } ) . forEach ( function ( dialog ) { dialog . on ( 'show' , function ( ) { $ ( this . container ) . modal ( 'show' ) ; } ) ; dialog . on ( 'hide' , function ( ) { $ ( this . container ) . modal ( 'hide' ) ; setTimeout ( editor . composer . focus , 0 ) ; } ) ; $ ( dialog . container ) . on ( 'shown.bs.modal' , function ( ) { $ ( this ) . find ( 'input, select, textarea' ) . first ( ) . focus ( ) ; } ) ; } ) ; this . on ( 'change_view' , function ( ) { $ ( this . toolbar . container . children ) . find ( 'a.btn' ) . not ( '[data-wysihtml5-action="change_view"]' ) . toggleClass ( 'disabled' ) ; } ) ; }
sync wysihtml5 events for dialogs with bootstrap events
sync wysihtml5 events for dialogs with bootstrap events