Sha256: a35bbfdef25b8781968c1db92ecd0e83bf8ab2cc977a7bc7c1989c5312972b77

Contents?: true

Size: 851 Bytes

Versions: 11

Compression:

Stored size: 851 Bytes

Contents

CKEDITOR.plugins.add('edit_content', {
    icons:'editcontent',
    init:function (editor) {
        editor.ui.addButton('EditContent', {
            label:'Edit this content in the full editor.',
            command:'editContent',
            toolbar:'tools'
        });

        // When the user clicks the 'Edit Content' button, save any changes they made already, then take them to
        editor.addCommand('editContent', {
            exec:function (editor) {
                var goto_edit = function(){
                    window.parent.location = $.cms_editor.selectedConnector().data('edit-path');
                };
                if (editor.checkDirty()) {
                    $.cms_editor.saveChanges(editor, goto_edit);
                } else {
                    goto_edit.apply();
                }
            }
        });
    }
});

Version data entries

11 entries across 11 versions & 2 rubygems

Version Path
browsercms-artirix-4.0.4 app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js
browsercms-artirix-4.0.3.3 app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js
browsercms-artirix-4.0.3.2 app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js
browsercms-artirix-4.0.3.1 app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js
browsercms-artirix-4.0.3 app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js
browsercms-artirix-4.0.2 app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js
browsercms-artirix-4.0.1.1 app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js
browsercms-artirix-4.0.0.rc1.art4 app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js
browsercms-4.0.0.rc1 app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js
browsercms-4.0.0.beta app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js
browsercms-4.0.0.alpha app/assets/javascripts/ckeditor/plugins/edit_content/plugin.js