Skip to content

Commit 400376f

Browse files
committed
Merge branch 't/13919'
2 parents 6d95813 + 0592035 commit 400376f

File tree

3 files changed

+23
-2
lines changed

3 files changed

+23
-2
lines changed

CHANGES.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ Fixed Issues:
2424
* [#13798](http://dev.ckeditor.com/ticket/13798): [Firefox] Fixed: Changing paragraph format causes the cursor to move.
2525
* [#13771](http://dev.ckeditor.com/ticket/13771): Fixed: The `contents.css` style is not used if the [IFrame Editing Area](http://ckeditor.com/addon/wysiwygarea) plugin is missing.
2626
* [#13782](http://dev.ckeditor.com/ticket/13782): Fixed: Unclear log messages.
27+
* [#13919](http://dev.ckeditor.com/ticket/13919): [Edge] Fixed: Browser window crashes while accessing `isContentEditable` property of an `<input>` DOM element.
2728

2829
Other Changes:
2930

core/dom/node.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -869,8 +869,8 @@ CKEDITOR.tools.extend( CKEDITOR.dom.node.prototype, {
869869
if ( this.type != CKEDITOR.NODE_ELEMENT )
870870
element = this.getParent();
871871

872-
// Prevent Edge crash. #13609.
873-
if ( CKEDITOR.env.edge && element && element.is( 'textarea' ) ) {
872+
// Prevent Edge crash (#13609, #13919).
873+
if ( CKEDITOR.env.edge && element && element.is( 'textarea', 'input' ) ) {
874874
checkOnlyAttributes = true;
875875
}
876876

tests/core/dom/node.js

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,26 @@
254254
assert.isFalse( el.getChild( [ 0, 0 ] ).isReadOnly( 1 ) );
255255
},
256256

257+
// #13609, #13919
258+
'test isReadOnly - isContentEditable property access': function() {
259+
// Edge tends to break when accessing isContentEditable property in certain elements.
260+
// If this test causes refreshes/crashes the web page, then some new element is causing this issue.
261+
var blacklistedElems = {
262+
applet: 1 // applet displays a popup about Java at IE11.
263+
},
264+
elemName;
265+
266+
// Test every element in DTD.
267+
for ( elemName in CKEDITOR.dtd ) {
268+
if ( elemName[ 0 ] !== '$' && !( elemName in blacklistedElems ) ) {
269+
new CKEDITOR.dom.element( elemName ).isReadOnly();
270+
}
271+
}
272+
273+
// If it didn't crash, it's OK.
274+
assert.isTrue( true );
275+
},
276+
257277
test_appendTo: function() {
258278
var p = newElement( 'p' ),
259279
t = newTextNode( 'text' ),

0 commit comments

Comments
 (0)