132 | | var range = retval.getNative().createRange(); |
133 | | if ( !range ) |
134 | | return null; |
135 | | else if ( range.item ) |
136 | | return range.item(0).ownerDocument == this.document.$ ? retval : null; |
137 | | else |
138 | | return range.parentElement().ownerDocument == this.document.$ ? retval : null; |
| 128 | /** |
| 129 | * IE BUG: The selection's document may be a different document than the |
| 130 | * editor document. Return null if that's the case. |
| 131 | */ |
| 132 | if ( CKEDITOR.env.ie ) |
| 133 | { |
| 134 | var range = retval.getNative().createRange(); |
| 135 | if ( !range ) |
| 136 | return null; |
| 137 | else if ( range.item ) |
| 138 | return range.item(0).ownerDocument == this.document.$ ? retval : null; |
| 139 | else |
| 140 | return range.parentElement().ownerDocument == this.document.$ ? retval : null; |
| 141 | } |
| 142 | |
| 143 | retval.onSelectionSet = CKEDITOR.tools.bind( checkSelectionChangeTimeout, this ); |