/*\r
-Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.\r
+Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved.\r
For licensing, see LICENSE.html or http://ckeditor.com/license\r
*/\r
\r
blockLimit = path.blockLimit,\r
div = blockLimit.is( 'div' ) && blockLimit;\r
\r
- if ( div && !div.getAttribute( '_cke_div_added' ) )\r
+ if ( div && !div.data( 'cke-div-added' ) )\r
{\r
toRemove.push( div );\r
- div.setAttribute( '_cke_div_added' );\r
+ div.data( 'cke-div-added' );\r
}\r
}\r
\r
{\r
editor.contextMenu.addListener( function( element, selection )\r
{\r
- if ( !element )\r
+ if ( !element || element.isReadOnly() )\r
return null;\r
\r
var elementPath = new CKEDITOR.dom.elementPath( element ),\r