I know that I can use the change event to know when the editor loses focus after content changes. I need to be able to know when the editor loses focus, even if the content has not changed.
Is there a way to do this?
3 Answers, 1 is accepted
0
Iliana Dyankova
Telerik team
answered on 03 Jul 2012, 02:22 PM
Hi Joshua,
In order to achieve the desired behavior you could use a jQuery blur event, which occurs when an element loses focus. Hence, you need to hook up to the iframe window. For example:
$(document).ready(function() {
// create Editor from textarea HTML element with default set of tools
$("#editor").kendoEditor({});
var editor = $("#editor").data("kendoEditor");
$(editor.window).blur(function(){
// do sth.
})
});
I hope this helps.
Regards,
Iliana Nikolova
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
This no longer seems to work with version v2015.1.318 , is there a different selector I should use for an inline editor ?
0
Iliana Dyankova
Telerik team
answered on 17 Apr 2015, 01:18 PM
Hi Charlie,
The suggested solution will not work for Kendo UI Inline Editor because it has a different structure. However the following code snippet should help for Inline Editor:
$(document).ready(function() {
// create Inline Editor
$("#editor").kendoEditor({ /* ... */ });
var editor = $("#editor").data("kendoEditor");
$(editor.element).blur(function(){
//....
})
});
Regards,
Iliana Nikolova
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!