X-Git-Url: https://jasonwoof.com/gitweb/?p=ckeditor.git;a=blobdiff_plain;f=plugins%2Fpreview%2Fplugin.js;h=42e800a5b6f1804081ccd0eadd5b82f7aa220a7a;hp=85c74cae405520d19e27ce2f2b5b8f5889925eac;hb=8761695d9b70afe75905deaac88f78c1f8aeb32d;hpb=ea7e3453c7b0f023b050aca6d9f83ab372860d91 diff --git a/plugins/preview/plugin.js b/plugins/preview/plugin.js index 85c74ca..42e800a 100644 --- a/plugins/preview/plugin.js +++ b/plugins/preview/plugin.js @@ -3,4 +3,4 @@ Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.html or http://ckeditor.com/license */ -(function(){var a={modes:{wysiwyg:1,source:1},canUndo:false,exec:function(c){var d,e=CKEDITOR.env.ie&&document.domain!=window.location.hostname;if(c.config.fullPage)d=c.getData();else{var f='0?'':'';if(g.getAttribute('id'))f+='id="'+g.getAttribute('id')+'" ';if(g.getAttribute('class'))f+='class="'+g.getAttribute('class')+'" ';f+='>';d=c.config.docType+''+''+h+''+c.lang.preview+''+''+''+f+c.getData()+'';}var i=640,j=420,k=80;try{var l=window.screen;i=Math.round(l.width*0.8);j=Math.round(l.height*0.7);k=Math.round(l.width*0.1);}catch(o){}var m='';if(e){window._cke_htmlToLoad=d;m='javascript:void( (function(){document.open();document.domain="'+document.domain+'";'+'document.write( window.opener._cke_htmlToLoad );'+'document.close();'+'window.opener._cke_htmlToLoad = null;'+'})() )';}var n=window.open(m,null,'toolbar=yes,location=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width='+i+',height='+j+',left='+k);if(!e){n.document.write(d);n.document.close();}}},b='preview';CKEDITOR.plugins.add(b,{init:function(c){c.addCommand(b,a);c.ui.addButton('Preview',{label:c.lang.preview,command:b});}});})(); +(function(){var a={modes:{wysiwyg:1,source:1},canUndo:false,exec:function(c){var d,e=CKEDITOR.env.isCustomDomain();if(c.config.fullPage)d=c.getData();else{var f='0?'':'';if(g.getAttribute('id'))f+='id="'+g.getAttribute('id')+'" ';if(g.getAttribute('class'))f+='class="'+g.getAttribute('class')+'" ';f+='>';d=c.config.docType+''+''+h+''+c.lang.preview+''+''+''+f+c.getData()+'';}var i=640,j=420,k=80;try{var l=window.screen;i=Math.round(l.width*0.8);j=Math.round(l.height*0.7);k=Math.round(l.width*0.1);}catch(o){}var m='';if(e){window._cke_htmlToLoad=d;m='javascript:void( (function(){document.open();document.domain="'+document.domain+'";'+'document.write( window.opener._cke_htmlToLoad );'+'document.close();'+'window.opener._cke_htmlToLoad = null;'+'})() )';}var n=window.open(m,null,'toolbar=yes,location=no,status=yes,menubar=yes,scrollbars=yes,resizable=yes,width='+i+',height='+j+',left='+k);if(!e){n.document.write(d);n.document.close();}}},b='preview';CKEDITOR.plugins.add(b,{init:function(c){c.addCommand(b,a);c.ui.addButton('Preview',{label:c.lang.preview,command:b});}});})();