﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
16947	Destroy CKEditor on Focus transfer - Error in Chrome	pfassev		"== Steps to reproduce ==

1. Create CKEditor ""editor"" to replace a text area with name=""editor"" and 2. Add additionaly a simple Input Field ""input1"" <input type=""text"" name=""input1"" id=""input1"">
3. register a focus listener to the input1 field. onfocus deaktivate the ckeditor with onfocus=""CKEDITOR.instances['editor'].destroy()"";
4. Klick into the ckeditor to get the focus
5. Then klick into the 'input1' text field

== Expected result ==
The ckeditor will be deaktivated. 

Actually on our real page we want on focus lost to disable the ckeditor and display the value in a separate div. Probably we could atchive this also with an inline editor, but neverthels, there is a problem with the current solution. It occures only in Chrome, but not in Firefox, Edge or IE.

== Actual result ==
JavaScript Error in Chrome:
ckeditor.js:238 Uncaught TypeError: Cannot read property 'isInline' of null
    at CKEDITOR.focusManager.d (ckeditor.js:238)
    at CKEDITOR.focusManager.<anonymous> (ckeditor.js:238)
    at ckeditor.js:28

== Other details (browser, OS, CKEditor version, installed plugins) ==
The error occures wi the newes CKEditor Version 4.6.2 currently in the newes Chrome Version (57.0.2987.98 (64-bit)) under Windows 10:

The problem is due to a check for chrome and isInline in the following line 238 of our ckeditor.js:

this.hasFocus&&(this.hasFocus=!1,CKEDITOR.env.chrome&&a.editable().isInline()&&a.window.$.getSelection().removeAllRanges()"	Bug	new	Normal		General	4.6.2			
