-
+ 41FF9FD557F5D9B614727EA2341ACA3B9CBE8D3D3E0B941995A8003ABAA5B8BDCA581E288BD71A237E3AE09ECE202590975E8BB762DA02801406A85E4C88700B
mp-wp/wp-includes/js/tinymce/themes/advanced/js/source_editor.js
(0 . 0)(1 . 62)
129111 tinyMCEPopup.requireLangPack();
129112 tinyMCEPopup.onInit.add(onLoadInit);
129113
129114 function saveContent() {
129115 tinyMCEPopup.editor.setContent(document.getElementById('htmlSource').value);
129116 tinyMCEPopup.close();
129117 }
129118
129119 function onLoadInit() {
129120 tinyMCEPopup.resizeToInnerSize();
129121
129122 // Remove Gecko spellchecking
129123 if (tinymce.isGecko)
129124 document.body.spellcheck = tinyMCEPopup.editor.getParam("gecko_spellcheck");
129125
129126 document.getElementById('htmlSource').value = tinyMCEPopup.editor.getContent();
129127
129128 if (tinyMCEPopup.editor.getParam("theme_advanced_source_editor_wrap", true)) {
129129 setWrap('soft');
129130 document.getElementById('wraped').checked = true;
129131 }
129132
129133 resizeInputs();
129134 }
129135
129136 function setWrap(val) {
129137 var v, n, s = document.getElementById('htmlSource');
129138
129139 s.wrap = val;
129140
129141 if (!tinymce.isIE) {
129142 v = s.value;
129143 n = s.cloneNode(false);
129144 n.setAttribute("wrap", val);
129145 s.parentNode.replaceChild(n, s);
129146 n.value = v;
129147 }
129148 }
129149
129150 function toggleWordWrap(elm) {
129151 if (elm.checked)
129152 setWrap('soft');
129153 else
129154 setWrap('off');
129155 }
129156
129157 var wHeight=0, wWidth=0, owHeight=0, owWidth=0;
129158
129159 function resizeInputs() {
129160 var el = document.getElementById('htmlSource');
129161
129162 if (!tinymce.isIE) {
129163 wHeight = self.innerHeight - 65;
129164 wWidth = self.innerWidth - 16;
129165 } else {
129166 wHeight = document.body.clientHeight - 70;
129167 wWidth = document.body.clientWidth - 16;
129168 }
129169
129170 el.style.height = Math.abs(wHeight) + 'px';
129171 el.style.width = Math.abs(wWidth) + 'px';
129172 }