Plugin Directory

Changeset 731757


Ignore:
Timestamp:
06/25/2013 10:24:46 PM (13 years ago)
Author:
bjorsq
Message:

added a fix to the javascript metabox-dragging code and updated trac ticket

Location:
rich-text-excerpts/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • rich-text-excerpts/trunk/readme.txt

    r731052 r731757  
    6666
    6767= 1.0 =
    68 * Wordpress submission after [initial development on bitbucket](https://bitbucket.org/bjorsq/rich-text-excerpts).
     68* Wordpress submission after initial development on bitbucket.
    6969
    7070== Screenshots ==
  • rich-text-excerpts/trunk/rich-text-excerpts.js

    r731159 r731757  
    103103
    104104        textarea.each(function(index, element) {
    105             var editor;
     105            var editor, is_active;
     106
    106107            editor = tinyMCE.EditorManager.get(element.id);
     108            is_active = $(this).parents('.tmce-active').length;
     109
    107110            if (creatingEditor) {
    108                 if (!editor) {
     111                if (!editor && is_active) {
    109112                    tinyMCE.execCommand('mceAddControl', true, element.id);
    110113                }
    111114            }
    112115            else {
    113                 if (editor) {
    114                     editor.save();                                         
     116                if (editor && is_active) {
     117                    editor.save();
    115118                    tinyMCE.execCommand('mceRemoveControl', true, element.id);
    116119                }       
  • rich-text-excerpts/trunk/rich-text-excerpts.php

    r731159 r731757  
    66Author: Peter Edwards
    77Author URI: http://bjorsq.net
    8 Version: 1.3beta
     8Version: 1.3
    99Text Domain: rich-text-excerpts
    1010License: GPLv3
     
    311311        );
    312312
    313         add_settings_field(
    314             'metabox',
    315             __('Embed the excerpt editor in a draggable meta box', 'rich-text-excerpts'),
    316             array( __CLASS__, 'options_setting_metabox' ),
    317             'rte',
    318             'post-type-options'
    319         );
    320313
    321314        /* editor options */
     
    326319            'rte'
    327320        );
     321
     322        add_settings_field(
     323            'metabox',
     324            __('Use a meta box', 'rich-text-excerpts'),
     325            array( __CLASS__, 'options_setting_metabox' ),
     326            'rte',
     327            'editor-options'
     328        );
     329
    328330        add_settings_field(
    329331            'editor_type',
     
    408410        $options = self::get_plugin_options();
    409411        $chckd = $options["metabox"]["use"]? ' checked="checked"': '';
    410 
     412        printf('<p class="rte-use-metabox-input"><input class="rte-metabox" type="checkbox" name="rich_text_excerpts_options[metabox][use]" id="rte-use-metabox" value="1"%s /> <label for="rte-use-metabox">%s</label></p>', $chckd, __('Check this box to put the excerpt in a draggable meta box (experimental!)', 'rich-text-excerpts'));
    411413    }
    412414
Note: See TracChangeset for help on using the changeset viewer.