@@ -14,7+14,7 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
var nonExitableElementNames = { table:1,pre:1 };\r
\r
// Matching an empty paragraph at the end of document.\r
var nonExitableElementNames = { table:1,pre:1 };\r
\r
// Matching an empty paragraph at the end of document.\r
- var emptyParagraphRegexp = /\s*<(p|div|address|h\d|center)[^>]*>\s*(?:<br[^>]*>| |\u00A0| )?\s*(:?<\/\1>)?(?=\s*$|<\/body>)/gi;\r
+ var emptyParagraphRegexp = /(^|<body\b[^>]*>)\s*<(p|div|address|h\d|center)[^>]*>\s*(?:<br[^>]*>| |\u00A0| )?\s*(:?<\/\2>)?\s*(?=$|<\/body>)/gi;\r
\r
var notWhitespaceEval = CKEDITOR.dom.walker.whitespaces( true );\r
\r
\r
var notWhitespaceEval = CKEDITOR.dom.walker.whitespaces( true );\r
\r
@@ -92,6+92,7 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
var marker = this.document.getById( 'cke_paste_marker' );\r
marker.scrollIntoView();\r
marker.remove();\r
var marker = this.document.getById( 'cke_paste_marker' );\r
marker.scrollIntoView();\r
marker.remove();\r
+ marker = null;\r
}\r
\r
CKEDITOR.tools.setTimeout( function()\r
}\r
\r
CKEDITOR.tools.setTimeout( function()\r
@@ -132,14+133,14 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
// Remove the original contents.\r
range.deleteContents();\r
\r
// Remove the original contents.\r
range.deleteContents();\r
\r
- clone = !i && element || element.clone( true );\r
+ clone = !i && element || element.clone( 1 );\r
\r
// If we're inserting a block at dtd-violated position, split\r
// the parent blocks until we reach blockLimit.\r
var current, dtd;\r
if ( isBlock )\r
{\r
\r
// If we're inserting a block at dtd-violated position, split\r
// the parent blocks until we reach blockLimit.\r
var current, dtd;\r
if ( isBlock )\r
{\r
- while ( ( current = range.getCommonAncestor( false, true ) )\r
+ while ( ( current = range.getCommonAncestor( 0, 1 ) )\r
&& ( dtd = CKEDITOR.dtd[ current.getName() ] )\r
&& !( dtd && dtd [ elementName ] ) )\r
{\r
&& ( dtd = CKEDITOR.dtd[ current.getName() ] )\r
&& !( dtd && dtd [ elementName ] ) )\r
{\r
@@ -530,7+531,7 @@ For licensing, see LICENSE.html or http://ckeditor.com/license