No regular expressions were active.
|
|
1 |
|
tinyMCEPop
up.require
LangPack()
;
|
|
|
2 |
|
tinyMCEPop
up.onInit.
add(onLoad
Init);
|
|
|
3 |
|
|
|
|
4 |
|
function s
aveContent
() {
|
|
|
5 |
|
tinyMC
EPopup.edi
tor.setCon
tent(docum
ent.getEle
mentById('
htmlSource
').value);
|
|
|
6 |
|
tinyMC
EPopup.clo
se();
|
|
|
7 |
|
}
|
|
|
8 |
|
|
|
|
9 |
|
function o
nLoadInit(
) {
|
|
|
10 |
|
tinyMC
EPopup.res
izeToInner
Size();
|
|
|
11 |
|
|
|
|
12 |
|
// Rem
ove Gecko
spellcheck
ing
|
|
|
13 |
|
if (ti
nymce.isGe
cko)
|
|
|
14 |
|
do
cument.bod
y.spellche
ck = tinyM
CEPopup.ed
itor.getPa
ram("gecko
_spellchec
k");
|
|
|
15 |
|
|
|
|
16 |
|
docume
nt.getElem
entById('h
tmlSource'
).value =
tinyMCEPop
up.editor.
getContent
();
|
|
|
17 |
|
|
|
|
18 |
|
if (ti
nyMCEPopup
.editor.ge
tParam("th
eme_advanc
ed_source_
editor_wra
p", true))
{
|
|
|
19 |
|
se
tWrap('sof
t');
|
|
|
20 |
|
do
cument.get
ElementByI
d('wraped'
).checked
= true;
|
|
|
21 |
|
}
|
|
|
22 |
|
|
|
|
23 |
|
resize
Inputs();
|
|
|
24 |
|
}
|
|
|
25 |
|
|
|
|
26 |
|
function s
etWrap(val
) {
|
|
|
27 |
|
var v,
n, s = do
cument.get
ElementByI
d('htmlSou
rce');
|
|
|
28 |
|
|
|
|
29 |
|
s.wrap
= val;
|
|
|
30 |
|
|
|
|
31 |
|
if (!t
inymce.isI
E) {
|
|
|
32 |
|
v
= s.value;
|
|
|
33 |
|
n
= s.cloneN
ode(false)
;
|
|
|
34 |
|
n.
setAttribu
te("wrap",
val);
|
|
|
35 |
|
s.
parentNode
.replaceCh
ild(n, s);
|
|
|
36 |
|
n.
value = v;
|
|
|
37 |
|
}
|
|
|
38 |
|
}
|
|
|
39 |
|
|
|
|
40 |
|
function t
oggleWordW
rap(elm) {
|
|
|
41 |
|
if (el
m.checked)
|
|
|
42 |
|
se
tWrap('sof
t');
|
|
|
43 |
|
else
|
|
|
44 |
|
se
tWrap('off
');
|
|
|
45 |
|
}
|
|
|
46 |
|
|
|
|
47 |
|
var wHeigh
t=0, wWidt
h=0, owHei
ght=0, owW
idth=0;
|
|
|
48 |
|
|
|
|
49 |
|
function r
esizeInput
s() {
|
|
|
50 |
|
var el
= documen
t.getEleme
ntById('ht
mlSource')
;
|
|
|
51 |
|
|
|
|
52 |
|
if (!t
inymce.isI
E) {
|
|
|
53 |
|
w
Height = s
elf.innerH
eight - 65
;
|
|
|
54 |
|
w
Width = se
lf.innerWi
dth - 16;
|
|
|
55 |
|
} else
{
|
|
|
56 |
|
w
Height = d
ocument.bo
dy.clientH
eight - 70
;
|
|
|
57 |
|
w
Width = do
cument.bod
y.clientWi
dth - 16;
|
|
|
58 |
|
}
|
|
|
59 |
|
|
|
|
60 |
|
el.sty
le.height
= Math.abs
(wHeight)
+ 'px';
|
|
|
61 |
|
el.sty
le.width
= Math.abs
(wWidth) +
'px';
|
|
|
62 |
|
}
|