Ticket #6654: 6654_3.patch

File 6654_3.patch, 1.4 KB (added by Garry Yao, 13 years ago)
  • _source/plugins/wysiwygarea/plugin.js

     
    381381                        }
    382382                }
    383383
    384                 // When enterMode set to block, we'll establing new paragraph only if we're
    385                 // selecting inline contents right under body. (#3657)
    386                 if ( enterMode != CKEDITOR.ENTER_BR
    387                      && range.collapsed
    388                          && blockLimit.getName() == 'body'
    389                          && !path.block )
     384                // When we're in block enter mode, a new paragraph will be established
     385                // to encapsulate inline contents right under body. (#3657)
     386                if ( editor.config.autoParagraph !== false
     387                                && enterMode != CKEDITOR.ENTER_BR
     388                                && range.collapsed
     389                                && blockLimit.getName() == 'body'
     390                                && !path.block )
    390391                {
    391392                        editor.fire( 'updateSnapshot' );
    392393                        restoreDirty( editor );
     
    13061307 */
    13071308
    13081309/**
     1310 * Whether automatically create wrapping blocks around inline contents inside document body,
     1311 * this helps to ensure the integrality of the block enter mode.
     1312 * <strong>Note:</strong> Changing the default value might introduce unpredictable usability issues.
     1313 * @since 3.6
     1314 * @type Boolean
     1315 * @default true
     1316 * @example
     1317 * config.autoParagraph = false;
     1318 */
     1319
     1320/**
    13091321 * Fired when some elements are added to the document
    13101322 * @name CKEDITOR.editor#ariaWidget
    13111323 * @event
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy