Got questions, comments, patches, etc.?
Contact Jason Woofenden
gitweb
/
ckeditor.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
vanilla ckeditor-3.6.6
[ckeditor.git]
/
_samples
/
divreplace.html
diff --git
a/_samples/divreplace.html
b/_samples/divreplace.html
index
35699e2
..
6f4ff41
100644
(file)
--- a/
_samples/divreplace.html
+++ b/
_samples/divreplace.html
@@
-1,6
+1,6
@@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
\r
<!--
\r
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
\r
<!--
\r
-Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved.
\r
+Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
\r
For licensing, see LICENSE.html or http://ckeditor.com/license
\r
-->
\r
<html xmlns="http://www.w3.org/1999/xhtml">
\r
For licensing, see LICENSE.html or http://ckeditor.com/license
\r
-->
\r
<html xmlns="http://www.w3.org/1999/xhtml">
\r
@@
-48,10
+48,15
@@
function onDoubleClick( ev )
var element = ev.target || ev.srcElement;
\r
\r
// Find out the div that holds this element.
\r
var element = ev.target || ev.srcElement;
\r
\r
// Find out the div that holds this element.
\r
- element = element.parentNode;
\r
+ var name;
\r
+ do
\r
+ {
\r
+ element = element.parentNode;
\r
+ }
\r
+ while ( element && ( name = element.nodeName.toLowerCase() ) && ( name != 'div' || element.className.indexOf( 'editable' ) == -1 ) && name != 'body' )
\r
\r
\r
- if ( element.nodeName.toLowerCase() == 'div'
\r
- && ( element.className.indexOf( 'editable' ) != -1 ) )
\r
+
\r
+ if ( name == 'div' && element.className.indexOf( 'editable' ) != -1 )
\r
replaceDiv( element );
\r
}
\r
\r
replaceDiv( element );
\r
}
\r
\r
@@
-141,7
+146,7
@@
function replaceDiv( div )
CKEditor - The text editor for the Internet - <a class="samples" href="http://ckeditor.com/">http://ckeditor.com</a>
\r
</p>
\r
<p id="copy">
\r
CKEditor - The text editor for the Internet - <a class="samples" href="http://ckeditor.com/">http://ckeditor.com</a>
\r
</p>
\r
<p id="copy">
\r
- Copyright © 2003-2011, <a class="samples" href="http://cksource.com/">CKSource</a> - Frederico
\r
+ Copyright © 2003-2013, <a class="samples" href="http://cksource.com/">CKSource</a> - Frederico
\r
Knabben. All rights reserved.
\r
</p>
\r
</div>
\r
Knabben. All rights reserved.
\r
</p>
\r
</div>
\r