X-Git-Url: https://scm.cri.ensmp.fr/git/ckeditor.git/blobdiff_plain/871bad8291b6dbc29d489d95d185458caab25158..35d32f35f43e33f068b39a4c7daf9eb16773cbe7:/skins/ckeditor/plugins/wsc/dialogs/ciframe.html diff --git a/skins/ckeditor/plugins/wsc/dialogs/ciframe.html b/skins/ckeditor/plugins/wsc/dialogs/ciframe.html index e174702..1d6ba5a 100644 --- a/skins/ckeditor/plugins/wsc/dialogs/ciframe.html +++ b/skins/ckeditor/plugins/wsc/dialogs/ciframe.html @@ -1,6 +1,6 @@ @@ -38,9 +38,26 @@ function sendData2Master() catch (e) {} } +function OnMessage (event) { + var message = event.data; + var destination = window.parent.parent; + destination.XDTMaster.read( [ 'end', message, 'fpm' ] ) ; +} + +function listenPostMessage() { + if (window.addEventListener) { // all browsers except IE before version 9 + window.addEventListener ("message", OnMessage, false); + }else { + if (window.attachEvent) { // IE before version 9 + window.attachEvent("onmessage", OnMessage); + } + } +} + function onLoad() { interval = window.setInterval( sendData2Master, 100 ); + listenPostMessage(); }