Version Description
Updated for WordPress 3.7 and TinyMCE 3.5.9.
Download this release
Release Info
Developer | azaozz |
Plugin | TinyMCE Advanced |
Version | 3.5.9 |
Comparing to | |
See all releases |
Code changes from version 3.5.8 to 3.5.9
- css/tadv-styles.css +34 -54
- images/fade-butt.png +0 -0
- images/fontselect.gif +0 -0
- images/fontselect.png +0 -0
- images/fontsizeselect.gif +0 -0
- images/fontsizeselect.png +0 -0
- images/formatselect.gif +0 -0
- images/formatselect.png +0 -0
- images/styleselect.gif +0 -0
- images/styleselect.png +0 -0
- mce/advhr/css/advhr.css +5 -5
- mce/advhr/js/rule.js +43 -43
- mce/advhr/langs/langs.php +12 -9
- mce/advhr/langs/zh_dlg.js +1 -1
- mce/advhr/rule.htm +5 -5
- mce/advimage/css/advimage.css +13 -13
- mce/advimage/image.htm +235 -235
- mce/advimage/js/image.js +464 -464
- mce/advimage/langs/de_dlg.js +1 -1
- mce/advimage/langs/langs.php +12 -9
- mce/advimage/langs/zh_dlg.js +1 -1
- mce/advlink/css/advlink.css +8 -8
- mce/advlink/js/advlink.js +543 -543
- mce/advlink/langs/de_dlg.js +1 -1
- mce/advlink/langs/langs.php +12 -9
- mce/advlink/langs/ru_dlg.js +1 -1
- mce/advlink/langs/zh_dlg.js +1 -1
- mce/advlink/link.htm +338 -338
- mce/emotions/editor_plugin.js +39 -39
- mce/searchreplace/css/searchreplace.css +6 -6
- mce/searchreplace/js/searchreplace.js +148 -142
- mce/searchreplace/langs/langs.php +12 -9
- mce/searchreplace/langs/zh_dlg.js +1 -1
- mce/searchreplace/searchreplace.htm +100 -100
- mce/style/css/props.css +15 -14
- mce/style/js/props.js +709 -709
- mce/style/langs/de_dlg.js +1 -1
- mce/style/langs/en_dlg.js +1 -1
- mce/style/langs/es_dlg.js +1 -1
- mce/style/langs/fr_dlg.js +1 -1
- mce/style/langs/it_dlg.js +1 -1
- mce/style/langs/ja_dlg.js +1 -1
- mce/style/langs/langs.php +12 -9
- mce/style/langs/pt_dlg.js +1 -1
- mce/style/langs/ru_dlg.js +1 -1
- mce/style/langs/zh_dlg.js +1 -1
- mce/style/props.htm +6 -6
- mce/table/cell.htm +180 -180
- mce/table/css/cell.css +18 -17
- mce/table/css/row.css +26 -25
- mce/table/css/table.css +14 -13
- mce/table/editor_plugin.js +1 -1
- mce/table/js/cell.js +319 -319
- mce/table/js/merge_cells.js +27 -27
- mce/table/js/row.js +254 -254
- mce/table/js/table.js +499 -499
- mce/table/langs/de_dlg.js +1 -1
- mce/table/langs/langs.php +12 -9
- mce/table/langs/zh_dlg.js +1 -1
- mce/table/merge_cells.htm +32 -32
- mce/table/row.htm +158 -158
- mce/table/table.htm +188 -188
- mce/xhtmlxtras/abbr.htm +142 -142
- mce/xhtmlxtras/acronym.htm +142 -142
- mce/xhtmlxtras/attributes.htm +149 -149
- mce/xhtmlxtras/cite.htm +142 -142
- mce/xhtmlxtras/css/attributes.css +13 -11
- mce/xhtmlxtras/css/popup.css +9 -9
- mce/xhtmlxtras/css/xhtmlxtras.css +24 -24
- mce/xhtmlxtras/del.htm +162 -162
- mce/xhtmlxtras/ins.htm +162 -162
- mce/xhtmlxtras/js/abbr.js +28 -28
- mce/xhtmlxtras/js/acronym.js +28 -28
- mce/xhtmlxtras/js/attributes.js +111 -111
- mce/xhtmlxtras/js/cite.js +28 -28
- mce/xhtmlxtras/js/del.js +53 -53
- mce/xhtmlxtras/js/element_common.js +229 -229
- mce/xhtmlxtras/js/ins.js +53 -53
- mce/xhtmlxtras/langs/langs.php +12 -9
- mce/xhtmlxtras/langs/zh_dlg.js +1 -1
- readme.txt +26 -17
- screenshot-1.jpg +0 -0
- screenshot-1.png +0 -0
- tadv_admin.php +189 -130
- tiny_mce_popup.js +1 -1
- tinymce-advanced.php +5 -19
css/tadv-styles.css
CHANGED
@@ -15,17 +15,17 @@ body {
|
|
15 |
}
|
16 |
|
17 |
#fontsizeselect {
|
18 |
-
background: url(../images/fontsizeselect.
|
19 |
width: 94px;
|
20 |
}
|
21 |
|
22 |
#fontselect {
|
23 |
-
background: url(../images/fontselect.
|
24 |
width: 94px;
|
25 |
}
|
26 |
|
27 |
#formatselect {
|
28 |
-
background: url(../images/formatselect.
|
29 |
width: 94px;
|
30 |
}
|
31 |
|
@@ -35,7 +35,7 @@ body {
|
|
35 |
}
|
36 |
|
37 |
#styleselect {
|
38 |
-
background: url(../images/styleselect.
|
39 |
width: 94px;
|
40 |
}
|
41 |
|
@@ -146,27 +146,14 @@ body {
|
|
146 |
#restoredraft {background-position:-20px -40px}
|
147 |
#spellchecker {background-position:-540px -20px}
|
148 |
|
149 |
-
input.tadv-chk {
|
150 |
-
border: none;
|
151 |
-
padding: 0;
|
152 |
-
vertical-align: middle;
|
153 |
-
}
|
154 |
-
|
155 |
-
* html input.tadv-chk {
|
156 |
-
margin: 0;
|
157 |
-
background-color:#eaeaea;
|
158 |
-
}
|
159 |
-
|
160 |
label.tadv-box {
|
161 |
-
margin: 0
|
162 |
-
padding:
|
163 |
-
background-color: #
|
164 |
-
cursor: default;
|
165 |
line-height: 28px;
|
166 |
-
|
167 |
-
|
168 |
-
|
169 |
-
padding: 0 3px 1px 8px;
|
170 |
}
|
171 |
|
172 |
form#tadvadmin {
|
@@ -182,7 +169,6 @@ form#tadvadmin {
|
|
182 |
top: 0px;
|
183 |
left: 0px;
|
184 |
z-index: 0;
|
185 |
-
opacity: 0.999999;
|
186 |
}
|
187 |
|
188 |
#tadvadmin, #tadvzones, #tadvpalette {
|
@@ -191,10 +177,6 @@ form#tadvadmin {
|
|
191 |
user-select: none;
|
192 |
}
|
193 |
|
194 |
-
* ul, * ul li {
|
195 |
-
list-style-type: none;
|
196 |
-
}
|
197 |
-
|
198 |
#tadvadmin p.submit {
|
199 |
padding-right: 10px;
|
200 |
}
|
@@ -203,10 +185,6 @@ form#tadvadmin {
|
|
203 |
float: right;
|
204 |
}
|
205 |
|
206 |
-
.tadv_btn {
|
207 |
-
margin-left: 8px;
|
208 |
-
}
|
209 |
-
|
210 |
#tadvzones {
|
211 |
margin-right: 280px;
|
212 |
}
|
@@ -223,34 +201,35 @@ form#tadvadmin {
|
|
223 |
display: none;
|
224 |
}
|
225 |
|
226 |
-
.tadvitem {
|
227 |
-
background:
|
228 |
}
|
229 |
|
230 |
.tadvdropzone .tadvmodule .tadvitem {
|
231 |
-
border: 1px solid #999999;
|
232 |
display: block;
|
233 |
height: 20px;
|
234 |
margin: 1px;
|
235 |
padding: 1px 2px;
|
236 |
width: 20px;
|
237 |
-
-moz-border-radius: 3px;
|
238 |
-
-khtml-border-radius: 3px;
|
239 |
-
-webkit-border-radius: 3px;
|
240 |
-
border-radius: 3px;
|
241 |
}
|
242 |
|
243 |
.tadvdropzone ul {
|
244 |
height: 30px;
|
245 |
-
|
246 |
-
width: 99.99%;
|
247 |
float: left;
|
248 |
margin: 0;
|
249 |
padding: 2px 4px;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
250 |
}
|
251 |
|
252 |
#tadvadmin .tadvmodule {
|
253 |
-
cursor:
|
254 |
position: relative;
|
255 |
}
|
256 |
|
@@ -262,7 +241,8 @@ form#tadvadmin {
|
|
262 |
float: left;
|
263 |
}
|
264 |
|
265 |
-
#tadvpalette li,
|
|
|
266 |
float: left;
|
267 |
margin: 0;
|
268 |
padding: 0;
|
@@ -271,8 +251,8 @@ form#tadvadmin {
|
|
271 |
}
|
272 |
|
273 |
#tadvpalette {
|
274 |
-
border: 1px solid #
|
275 |
-
background-color:
|
276 |
height: 64px;
|
277 |
padding: 4px;
|
278 |
margin: 8px 0;
|
@@ -282,11 +262,9 @@ form#tadvadmin {
|
|
282 |
display: block;
|
283 |
height: 22px;
|
284 |
width: 134px;
|
285 |
-
border: 1px solid #
|
286 |
background-color: #fff;
|
287 |
margin: 4px;
|
288 |
-
-moz-border-radius: 3px;
|
289 |
-
-khtml-border-radius: 3px;
|
290 |
-webkit-border-radius: 3px;
|
291 |
border-radius: 3px;
|
292 |
}
|
@@ -346,7 +324,8 @@ form#tadvadmin {
|
|
346 |
width: 88px;
|
347 |
}
|
348 |
|
349 |
-
#tadvpalette .separator,
|
|
|
350 |
float: left;
|
351 |
cursor: crosshair;
|
352 |
}
|
@@ -368,10 +347,6 @@ form#tadvadmin {
|
|
368 |
padding: 1px 3px;
|
369 |
}
|
370 |
|
371 |
-
* html #tadvpalette .separator .tadvitem img {
|
372 |
-
margin: 1px 0 -2px 1px;
|
373 |
-
}
|
374 |
-
|
375 |
.tadvdropzone .separator {
|
376 |
background: transparent;
|
377 |
display: block;
|
@@ -379,7 +354,8 @@ form#tadvadmin {
|
|
379 |
margin: 2px 1px 0pt 0pt;
|
380 |
}
|
381 |
|
382 |
-
#tadvWarnmsg,
|
|
|
383 |
color: #ff0000;
|
384 |
font-weight: bold;
|
385 |
height: 26px;
|
@@ -393,3 +369,7 @@ form#tadvadmin {
|
|
393 |
padding: 8px;
|
394 |
margin-left: 20px;
|
395 |
}
|
|
|
|
|
|
|
|
15 |
}
|
16 |
|
17 |
#fontsizeselect {
|
18 |
+
background: url(../images/fontsizeselect.png) no-repeat 0 0;
|
19 |
width: 94px;
|
20 |
}
|
21 |
|
22 |
#fontselect {
|
23 |
+
background: url(../images/fontselect.png) no-repeat 0 0;
|
24 |
width: 94px;
|
25 |
}
|
26 |
|
27 |
#formatselect {
|
28 |
+
background: url(../images/formatselect.png) no-repeat 0 0;
|
29 |
width: 94px;
|
30 |
}
|
31 |
|
35 |
}
|
36 |
|
37 |
#styleselect {
|
38 |
+
background: url(../images/styleselect.png) no-repeat 0 0;
|
39 |
width: 94px;
|
40 |
}
|
41 |
|
146 |
#restoredraft {background-position:-20px -40px}
|
147 |
#spellchecker {background-position:-540px -20px}
|
148 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
149 |
label.tadv-box {
|
150 |
+
margin: 0 5px;
|
151 |
+
padding: 2px 4px;
|
152 |
+
background-color: #eee;
|
|
|
153 |
line-height: 28px;
|
154 |
+
border: 1px solid #ccc;
|
155 |
+
vertical-align: baseline;
|
156 |
+
background-color: rgba(50, 50, 50, 0.05);
|
|
|
157 |
}
|
158 |
|
159 |
form#tadvadmin {
|
169 |
top: 0px;
|
170 |
left: 0px;
|
171 |
z-index: 0;
|
|
|
172 |
}
|
173 |
|
174 |
#tadvadmin, #tadvzones, #tadvpalette {
|
177 |
user-select: none;
|
178 |
}
|
179 |
|
|
|
|
|
|
|
|
|
180 |
#tadvadmin p.submit {
|
181 |
padding-right: 10px;
|
182 |
}
|
185 |
float: right;
|
186 |
}
|
187 |
|
|
|
|
|
|
|
|
|
188 |
#tadvzones {
|
189 |
margin-right: 280px;
|
190 |
}
|
201 |
display: none;
|
202 |
}
|
203 |
|
204 |
+
#tadvpalettediv .tadvitem {
|
205 |
+
background-color: #eee;
|
206 |
}
|
207 |
|
208 |
.tadvdropzone .tadvmodule .tadvitem {
|
|
|
209 |
display: block;
|
210 |
height: 20px;
|
211 |
margin: 1px;
|
212 |
padding: 1px 2px;
|
213 |
width: 20px;
|
|
|
|
|
|
|
|
|
214 |
}
|
215 |
|
216 |
.tadvdropzone ul {
|
217 |
height: 30px;
|
218 |
+
width: 99%;
|
|
|
219 |
float: left;
|
220 |
margin: 0;
|
221 |
padding: 2px 4px;
|
222 |
+
border: 1px solid #ccc;
|
223 |
+
background: #eee;
|
224 |
+
background-image: -webkit-gradient(linear, left bottom, left top, from(#e5e5e5), to(#f4f4f4));
|
225 |
+
background-image: -webkit-linear-gradient(bottom, #e5e5e5, #f4f4f4);
|
226 |
+
background-image: -moz-linear-gradient(bottom, #e5e5e5, #f4f4f4);
|
227 |
+
background-image: -o-linear-gradient(bottom, #e5e5e5, #f4f4f4);
|
228 |
+
background-image: linear-gradient(to top, #e5e5e5, #f4f4f4);
|
229 |
}
|
230 |
|
231 |
#tadvadmin .tadvmodule {
|
232 |
+
cursor: move;
|
233 |
position: relative;
|
234 |
}
|
235 |
|
241 |
float: left;
|
242 |
}
|
243 |
|
244 |
+
#tadvpalette li,
|
245 |
+
.tadvdropzone li {
|
246 |
float: left;
|
247 |
margin: 0;
|
248 |
padding: 0;
|
251 |
}
|
252 |
|
253 |
#tadvpalette {
|
254 |
+
border: 1px solid #ccc;
|
255 |
+
background-color: #f3f3f3;
|
256 |
height: 64px;
|
257 |
padding: 4px;
|
258 |
margin: 8px 0;
|
262 |
display: block;
|
263 |
height: 22px;
|
264 |
width: 134px;
|
265 |
+
border: 1px solid #ccc;
|
266 |
background-color: #fff;
|
267 |
margin: 4px;
|
|
|
|
|
268 |
-webkit-border-radius: 3px;
|
269 |
border-radius: 3px;
|
270 |
}
|
324 |
width: 88px;
|
325 |
}
|
326 |
|
327 |
+
#tadvpalette .separator,
|
328 |
+
.tadvdropzone .separator {
|
329 |
float: left;
|
330 |
cursor: crosshair;
|
331 |
}
|
347 |
padding: 1px 3px;
|
348 |
}
|
349 |
|
|
|
|
|
|
|
|
|
350 |
.tadvdropzone .separator {
|
351 |
background: transparent;
|
352 |
display: block;
|
354 |
margin: 2px 1px 0pt 0pt;
|
355 |
}
|
356 |
|
357 |
+
#tadvWarnmsg,
|
358 |
+
#tadvWarnmsg2 {
|
359 |
color: #ff0000;
|
360 |
font-weight: bold;
|
361 |
height: 26px;
|
369 |
padding: 8px;
|
370 |
margin-left: 20px;
|
371 |
}
|
372 |
+
|
373 |
+
.tadv_btn.button-primary {
|
374 |
+
margin: 0 10px;
|
375 |
+
}
|
images/fade-butt.png
DELETED
Binary file
|
images/fontselect.gif
DELETED
Binary file
|
images/fontselect.png
ADDED
Binary file
|
images/fontsizeselect.gif
DELETED
Binary file
|
images/fontsizeselect.png
ADDED
Binary file
|
images/formatselect.gif
DELETED
Binary file
|
images/formatselect.png
ADDED
Binary file
|
images/styleselect.gif
DELETED
Binary file
|
images/styleselect.png
ADDED
Binary file
|
mce/advhr/css/advhr.css
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
-
input.radio {border:1px none #000; background:transparent; vertical-align:middle;}
|
2 |
-
.panel_wrapper div.current {height:80px;}
|
3 |
-
#width {width:50px; vertical-align:middle;}
|
4 |
-
#width2 {width:50px; vertical-align:middle;}
|
5 |
-
#size {width:100px;}
|
1 |
+
input.radio {border:1px none #000; background:transparent; vertical-align:middle;}
|
2 |
+
.panel_wrapper div.current {min-height:80px;height:auto;}
|
3 |
+
#width {width:50px; vertical-align:middle;}
|
4 |
+
#width2 {width:50px; vertical-align:middle;}
|
5 |
+
#size {width:100px;}
|
mce/advhr/js/rule.js
CHANGED
@@ -1,43 +1,43 @@
|
|
1 |
-
var AdvHRDialog = {
|
2 |
-
init : function(ed) {
|
3 |
-
var dom = ed.dom, f = document.forms[0], n = ed.selection.getNode(), w;
|
4 |
-
|
5 |
-
w = dom.getAttrib(n, 'width');
|
6 |
-
f.width.value = w ? parseInt(w) : (dom.getStyle('width') || '');
|
7 |
-
f.size.value = dom.getAttrib(n, 'size') || parseInt(dom.getStyle('height')) || '';
|
8 |
-
f.noshade.checked = !!dom.getAttrib(n, 'noshade') || !!dom.getStyle('border-width');
|
9 |
-
selectByValue(f, 'width2', w.indexOf('%') != -1 ? '%' : 'px');
|
10 |
-
},
|
11 |
-
|
12 |
-
update : function() {
|
13 |
-
var ed = tinyMCEPopup.editor, h, f = document.forms[0], st = '';
|
14 |
-
|
15 |
-
h = '<hr';
|
16 |
-
|
17 |
-
if (f.size.value) {
|
18 |
-
h += ' size="' + f.size.value + '"';
|
19 |
-
st += ' height:' + f.size.value + 'px;';
|
20 |
-
}
|
21 |
-
|
22 |
-
if (f.width.value) {
|
23 |
-
h += ' width="' + f.width.value + (f.width2.value == '%' ? '%' : '') + '"';
|
24 |
-
st += ' width:' + f.width.value + (f.width2.value == '%' ? '%' : 'px') + ';';
|
25 |
-
}
|
26 |
-
|
27 |
-
if (f.noshade.checked) {
|
28 |
-
h += ' noshade="noshade"';
|
29 |
-
st += ' border-width: 1px; border-style: solid; border-color: #CCCCCC; color: #ffffff;';
|
30 |
-
}
|
31 |
-
|
32 |
-
if (ed.settings.inline_styles)
|
33 |
-
h += ' style="' + tinymce.trim(st) + '"';
|
34 |
-
|
35 |
-
h += ' />';
|
36 |
-
|
37 |
-
ed.execCommand("mceInsertContent", false, h);
|
38 |
-
tinyMCEPopup.close();
|
39 |
-
}
|
40 |
-
};
|
41 |
-
|
42 |
-
tinyMCEPopup.requireLangPack();
|
43 |
-
tinyMCEPopup.onInit.add(AdvHRDialog.init, AdvHRDialog);
|
1 |
+
var AdvHRDialog = {
|
2 |
+
init : function(ed) {
|
3 |
+
var dom = ed.dom, f = document.forms[0], n = ed.selection.getNode(), w;
|
4 |
+
|
5 |
+
w = dom.getAttrib(n, 'width');
|
6 |
+
f.width.value = w ? parseInt(w) : (dom.getStyle('width') || '');
|
7 |
+
f.size.value = dom.getAttrib(n, 'size') || parseInt(dom.getStyle('height')) || '';
|
8 |
+
f.noshade.checked = !!dom.getAttrib(n, 'noshade') || !!dom.getStyle('border-width');
|
9 |
+
selectByValue(f, 'width2', w.indexOf('%') != -1 ? '%' : 'px');
|
10 |
+
},
|
11 |
+
|
12 |
+
update : function() {
|
13 |
+
var ed = tinyMCEPopup.editor, h, f = document.forms[0], st = '';
|
14 |
+
|
15 |
+
h = '<hr';
|
16 |
+
|
17 |
+
if (f.size.value) {
|
18 |
+
h += ' size="' + f.size.value + '"';
|
19 |
+
st += ' height:' + f.size.value + 'px;';
|
20 |
+
}
|
21 |
+
|
22 |
+
if (f.width.value) {
|
23 |
+
h += ' width="' + f.width.value + (f.width2.value == '%' ? '%' : '') + '"';
|
24 |
+
st += ' width:' + f.width.value + (f.width2.value == '%' ? '%' : 'px') + ';';
|
25 |
+
}
|
26 |
+
|
27 |
+
if (f.noshade.checked) {
|
28 |
+
h += ' noshade="noshade"';
|
29 |
+
st += ' border-width: 1px; border-style: solid; border-color: #CCCCCC; color: #ffffff;';
|
30 |
+
}
|
31 |
+
|
32 |
+
if (ed.settings.inline_styles)
|
33 |
+
h += ' style="' + tinymce.trim(st) + '"';
|
34 |
+
|
35 |
+
h += ' />';
|
36 |
+
|
37 |
+
ed.execCommand("mceInsertContent", false, h);
|
38 |
+
tinyMCEPopup.close();
|
39 |
+
}
|
40 |
+
};
|
41 |
+
|
42 |
+
tinyMCEPopup.requireLangPack();
|
43 |
+
tinyMCEPopup.onInit.add(AdvHRDialog.init, AdvHRDialog);
|
mce/advhr/langs/langs.php
CHANGED
@@ -1,9 +1,12 @@
|
|
1 |
-
<?php
|
2 |
-
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
-
|
4 |
-
if ( is_file($lang_file) &&
|
5 |
-
$
|
6 |
-
|
7 |
-
|
8 |
-
$strings =
|
9 |
-
}
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
+
|
4 |
+
if ( ! is_file( $lang_file ) && defined( 'TINYMCE_ADVANCED_LANGUAGES_PATH' ) )
|
5 |
+
$lang_file = TINYMCE_ADVANCED_LANGUAGES_PATH . 'advhr/langs/' . $mce_locale . '_dlg.js';
|
6 |
+
|
7 |
+
if ( is_file( $lang_file ) && is_readable( $lang_file ) ) {
|
8 |
+
$strings = tdav_get_file( $lang_file );
|
9 |
+
} else {
|
10 |
+
$strings = tdav_get_file( dirname(__FILE__) . '/en_dlg.js' );
|
11 |
+
$strings = preg_replace( '/([\'"])en\./', '$1' . $mce_locale . '.', $strings, 1 );
|
12 |
+
}
|
mce/advhr/langs/zh_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('zh.advhr_dlg',{size:"\u9ad8
|
1 |
+
tinyMCE.addI18n('zh.advhr_dlg',{size:"\u9ad8",noshade:"\u65e0\u9634\u5f71",width:"\u5bbd",normal:"\u6807\u51c6",widthunits:"\u5355\u4f4d"});
|
mce/advhr/rule.htm
CHANGED
@@ -2,11 +2,11 @@
|
|
2 |
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
<head>
|
4 |
<title>{#advhr.advhr_desc}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="js/rule.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
9 |
-
<link href="css/advhr.css?ver=
|
10 |
</head>
|
11 |
<body role="application">
|
12 |
<form onsubmit="AdvHRDialog.update();return false;" action="#">
|
2 |
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
<head>
|
4 |
<title>{#advhr.advhr_desc}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="js/rule.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
9 |
+
<link href="css/advhr.css?ver=359" rel="stylesheet" type="text/css" />
|
10 |
</head>
|
11 |
<body role="application">
|
12 |
<form onsubmit="AdvHRDialog.update();return false;" action="#">
|
mce/advimage/css/advimage.css
CHANGED
@@ -1,13 +1,13 @@
|
|
1 |
-
#src_list, #over_list, #out_list {width:280px;}
|
2 |
-
.mceActionPanel {margin-top:7px;}
|
3 |
-
.alignPreview {border:1px solid #000; width:140px; height:140px; overflow:hidden; padding:5px;}
|
4 |
-
.checkbox {border:0;}
|
5 |
-
.panel_wrapper div.current {height:305px;}
|
6 |
-
#prev {margin:0; border:1px solid #000; width:428px; height:150px; overflow:auto;}
|
7 |
-
#align, #classlist {width:150px;}
|
8 |
-
#width, #height {vertical-align:middle; width:50px; text-align:center;}
|
9 |
-
#vspace, #hspace, #border {vertical-align:middle; width:30px; text-align:center;}
|
10 |
-
#class_list {width:180px;}
|
11 |
-
input {width: 280px;}
|
12 |
-
#constrain, #onmousemovecheck {width:auto;}
|
13 |
-
#id, #dir, #lang, #usemap, #longdesc {width:200px;}
|
1 |
+
#src_list, #over_list, #out_list {width:280px;}
|
2 |
+
.mceActionPanel {margin-top:7px;}
|
3 |
+
.alignPreview {border:1px solid #000; width:140px; height:140px; overflow:hidden; padding:5px;}
|
4 |
+
.checkbox {border:0;}
|
5 |
+
.panel_wrapper div.current {min-height:305px;height:auto;}
|
6 |
+
#prev {margin:0; border:1px solid #000; width:428px; height:150px; overflow:auto;}
|
7 |
+
#align, #classlist {width:150px;}
|
8 |
+
#width, #height {vertical-align:middle; width:50px; text-align:center;}
|
9 |
+
#vspace, #hspace, #border {vertical-align:middle; width:30px; text-align:center;}
|
10 |
+
#class_list {width:180px;}
|
11 |
+
input[type="text"] {width: 280px;}
|
12 |
+
#constrain, #onmousemovecheck {width:auto;}
|
13 |
+
#id, #dir, #lang, #usemap, #longdesc {width:200px;}
|
mce/advimage/image.htm
CHANGED
@@ -1,235 +1,235 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#advimage_dlg.dialog_title}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/validate.js?ver=
|
9 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
10 |
-
<script type="text/javascript" src="js/image.js?ver=
|
11 |
-
<link href="css/advimage.css?ver=
|
12 |
-
</head>
|
13 |
-
<body id="advimage" style="display: none" role="application" aria-labelledby="app_title">
|
14 |
-
<span id="app_title" style="display:none">{#advimage_dlg.dialog_title}</span>
|
15 |
-
<form onsubmit="ImageDialog.insert();return false;" action="#">
|
16 |
-
<div class="tabs">
|
17 |
-
<ul>
|
18 |
-
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#advimage_dlg.tab_general}</a></span></li>
|
19 |
-
<li id="appearance_tab" aria-controls="appearance_panel"><span><a href="javascript:mcTabs.displayTab('appearance_tab','appearance_panel');" onmousedown="return false;">{#advimage_dlg.tab_appearance}</a></span></li>
|
20 |
-
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#advimage_dlg.tab_advanced}</a></span></li>
|
21 |
-
</ul>
|
22 |
-
</div>
|
23 |
-
|
24 |
-
<div class="panel_wrapper">
|
25 |
-
<div id="general_panel" class="panel current">
|
26 |
-
<fieldset>
|
27 |
-
<legend>{#advimage_dlg.general}</legend>
|
28 |
-
|
29 |
-
<table role="presentation" class="properties">
|
30 |
-
<tr>
|
31 |
-
<td class="column1"><label id="srclabel" for="src">{#advimage_dlg.src}</label></td>
|
32 |
-
<td colspan="2"><table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
33 |
-
<tr>
|
34 |
-
<td><input name="src" type="text" id="src" value="" class="mceFocus" onchange="ImageDialog.showPreviewImage(this.value);" aria-required="true" /></td>
|
35 |
-
<td id="srcbrowsercontainer"> </td>
|
36 |
-
</tr>
|
37 |
-
</table></td>
|
38 |
-
</tr>
|
39 |
-
<tr>
|
40 |
-
<td><label for="src_list">{#advimage_dlg.image_list}</label></td>
|
41 |
-
<td><select id="src_list" name="src_list" onchange="document.getElementById('src').value=this.options[this.selectedIndex].value;document.getElementById('alt').value=this.options[this.selectedIndex].text;document.getElementById('title').value=this.options[this.selectedIndex].text;ImageDialog.showPreviewImage(this.options[this.selectedIndex].value);"><option value=""></option></select></td>
|
42 |
-
</tr>
|
43 |
-
<tr>
|
44 |
-
<td class="column1"><label id="altlabel" for="alt">{#advimage_dlg.alt}</label></td>
|
45 |
-
<td colspan="2"><input id="alt" name="alt" type="text" value="" /></td>
|
46 |
-
</tr>
|
47 |
-
<tr>
|
48 |
-
<td class="column1"><label id="titlelabel" for="title">{#advimage_dlg.title}</label></td>
|
49 |
-
<td colspan="2"><input id="title" name="title" type="text" value="" /></td>
|
50 |
-
</tr>
|
51 |
-
</table>
|
52 |
-
</fieldset>
|
53 |
-
|
54 |
-
<fieldset>
|
55 |
-
<legend>{#advimage_dlg.preview}</legend>
|
56 |
-
<div id="prev"></div>
|
57 |
-
</fieldset>
|
58 |
-
</div>
|
59 |
-
|
60 |
-
<div id="appearance_panel" class="panel">
|
61 |
-
<fieldset>
|
62 |
-
<legend>{#advimage_dlg.tab_appearance}</legend>
|
63 |
-
|
64 |
-
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
|
65 |
-
<tr>
|
66 |
-
<td class="column1"><label id="alignlabel" for="align">{#advimage_dlg.align}</label></td>
|
67 |
-
<td><select id="align" name="align" onchange="ImageDialog.updateStyle('align');ImageDialog.changeAppearance();">
|
68 |
-
<option value="">{#not_set}</option>
|
69 |
-
<option value="baseline">{#advimage_dlg.align_baseline}</option>
|
70 |
-
<option value="top">{#advimage_dlg.align_top}</option>
|
71 |
-
<option value="middle">{#advimage_dlg.align_middle}</option>
|
72 |
-
<option value="bottom">{#advimage_dlg.align_bottom}</option>
|
73 |
-
<option value="text-top">{#advimage_dlg.align_texttop}</option>
|
74 |
-
<option value="text-bottom">{#advimage_dlg.align_textbottom}</option>
|
75 |
-
<option value="left">{#advimage_dlg.align_left}</option>
|
76 |
-
<option value="right">{#advimage_dlg.align_right}</option>
|
77 |
-
</select>
|
78 |
-
</td>
|
79 |
-
<td rowspan="6" valign="top">
|
80 |
-
<div class="alignPreview">
|
81 |
-
<img id="alignSampleImg" src="img/sample.gif" alt="{#advimage_dlg.example_img}" />
|
82 |
-
Lorem ipsum, Dolor sit amet, consectetuer adipiscing loreum ipsum edipiscing elit, sed diam
|
83 |
-
nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.Loreum ipsum
|
84 |
-
edipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam
|
85 |
-
erat volutpat.
|
86 |
-
</div>
|
87 |
-
</td>
|
88 |
-
</tr>
|
89 |
-
|
90 |
-
<tr role="group" aria-labelledby="widthlabel">
|
91 |
-
<td class="column1"><label id="widthlabel" for="width">{#advimage_dlg.dimensions}</label></td>
|
92 |
-
<td class="nowrap">
|
93 |
-
<span style="display:none" id="width_voiceLabel">{#advimage_dlg.width}</span>
|
94 |
-
<input name="width" type="text" id="width" value="" size="5" maxlength="5" class="size" onchange="ImageDialog.changeHeight();" aria-labelledby="width_voiceLabel" /> x
|
95 |
-
<span style="display:none" id="height_voiceLabel">{#advimage_dlg.height}</span>
|
96 |
-
<input name="height" type="text" id="height" value="" size="5" maxlength="5" class="size" onchange="ImageDialog.changeWidth();" aria-labelledby="height_voiceLabel" /> px
|
97 |
-
</td>
|
98 |
-
</tr>
|
99 |
-
|
100 |
-
<tr>
|
101 |
-
<td> </td>
|
102 |
-
<td><table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
103 |
-
<tr>
|
104 |
-
<td><input id="constrain" type="checkbox" name="constrain" class="checkbox" /></td>
|
105 |
-
<td><label id="constrainlabel" for="constrain">{#advimage_dlg.constrain_proportions}</label></td>
|
106 |
-
</tr>
|
107 |
-
</table></td>
|
108 |
-
</tr>
|
109 |
-
|
110 |
-
<tr>
|
111 |
-
<td class="column1"><label id="vspacelabel" for="vspace">{#advimage_dlg.vspace}</label></td>
|
112 |
-
<td><input name="vspace" type="text" id="vspace" value="" size="3" maxlength="3" class="number" onchange="ImageDialog.updateStyle('vspace');ImageDialog.changeAppearance();" onblur="ImageDialog.updateStyle('vspace');ImageDialog.changeAppearance();" />
|
113 |
-
</td>
|
114 |
-
</tr>
|
115 |
-
|
116 |
-
<tr>
|
117 |
-
<td class="column1"><label id="hspacelabel" for="hspace">{#advimage_dlg.hspace}</label></td>
|
118 |
-
<td><input name="hspace" type="text" id="hspace" value="" size="3" maxlength="3" class="number" onchange="ImageDialog.updateStyle('hspace');ImageDialog.changeAppearance();" onblur="ImageDialog.updateStyle('hspace');ImageDialog.changeAppearance();" /></td>
|
119 |
-
</tr>
|
120 |
-
|
121 |
-
<tr>
|
122 |
-
<td class="column1"><label id="borderlabel" for="border">{#advimage_dlg.border}</label></td>
|
123 |
-
<td><input id="border" name="border" type="text" value="" size="3" maxlength="3" class="number" onchange="ImageDialog.updateStyle('border');ImageDialog.changeAppearance();" onblur="ImageDialog.updateStyle('border');ImageDialog.changeAppearance();" /></td>
|
124 |
-
</tr>
|
125 |
-
|
126 |
-
<tr>
|
127 |
-
<td><label for="class_list">{#class_name}</label></td>
|
128 |
-
<td colspan="2"><select id="class_list" name="class_list" class="mceEditableSelect"><option value=""></option></select></td>
|
129 |
-
</tr>
|
130 |
-
|
131 |
-
<tr>
|
132 |
-
<td class="column1"><label id="stylelabel" for="style">{#advimage_dlg.style}</label></td>
|
133 |
-
<td colspan="2"><input id="style" name="style" type="text" value="" onchange="ImageDialog.changeAppearance();" /></td>
|
134 |
-
</tr>
|
135 |
-
|
136 |
-
<!-- <tr>
|
137 |
-
<td class="column1"><label id="classeslabel" for="classes">{#advimage_dlg.classes}</label></td>
|
138 |
-
<td colspan="2"><input id="classes" name="classes" type="text" value="" onchange="selectByValue(this.form,'classlist',this.value,true);" /></td>
|
139 |
-
</tr> -->
|
140 |
-
</table>
|
141 |
-
</fieldset>
|
142 |
-
</div>
|
143 |
-
|
144 |
-
<div id="advanced_panel" class="panel">
|
145 |
-
<fieldset>
|
146 |
-
<legend>{#advimage_dlg.swap_image}</legend>
|
147 |
-
|
148 |
-
<input type="checkbox" id="onmousemovecheck" name="onmousemovecheck" class="checkbox" onclick="ImageDialog.setSwapImage(this.checked);" aria-controls="onmouseoversrc onmouseoutsrc" />
|
149 |
-
<label id="onmousemovechecklabel" for="onmousemovecheck">{#advimage_dlg.alt_image}</label>
|
150 |
-
|
151 |
-
<table role="presentation" border="0" cellpadding="4" cellspacing="0" width="100%">
|
152 |
-
<tr>
|
153 |
-
<td class="column1"><label id="onmouseoversrclabel" for="onmouseoversrc">{#advimage_dlg.mouseover}</label></td>
|
154 |
-
<td><table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
155 |
-
<tr>
|
156 |
-
<td><input id="onmouseoversrc" name="onmouseoversrc" type="text" value="" /></td>
|
157 |
-
<td id="onmouseoversrccontainer"> </td>
|
158 |
-
</tr>
|
159 |
-
</table></td>
|
160 |
-
</tr>
|
161 |
-
<tr>
|
162 |
-
<td><label for="over_list">{#advimage_dlg.image_list}</label></td>
|
163 |
-
<td><select id="over_list" name="over_list" onchange="document.getElementById('onmouseoversrc').value=this.options[this.selectedIndex].value;"><option value=""></option></select></td>
|
164 |
-
</tr>
|
165 |
-
<tr>
|
166 |
-
<td class="column1"><label id="onmouseoutsrclabel" for="onmouseoutsrc">{#advimage_dlg.mouseout}</label></td>
|
167 |
-
<td class="column2"><table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
168 |
-
<tr>
|
169 |
-
<td><input id="onmouseoutsrc" name="onmouseoutsrc" type="text" value="" /></td>
|
170 |
-
<td id="onmouseoutsrccontainer"> </td>
|
171 |
-
</tr>
|
172 |
-
</table></td>
|
173 |
-
</tr>
|
174 |
-
<tr>
|
175 |
-
<td><label for="out_list">{#advimage_dlg.image_list}</label></td>
|
176 |
-
<td><select id="out_list" name="out_list" onchange="document.getElementById('onmouseoutsrc').value=this.options[this.selectedIndex].value;"><option value=""></option></select></td>
|
177 |
-
</tr>
|
178 |
-
</table>
|
179 |
-
</fieldset>
|
180 |
-
|
181 |
-
<fieldset>
|
182 |
-
<legend>{#advimage_dlg.misc}</legend>
|
183 |
-
|
184 |
-
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
|
185 |
-
<tr>
|
186 |
-
<td class="column1"><label id="idlabel" for="id">{#advimage_dlg.id}</label></td>
|
187 |
-
<td><input id="id" name="id" type="text" value="" /></td>
|
188 |
-
</tr>
|
189 |
-
|
190 |
-
<tr>
|
191 |
-
<td class="column1"><label id="dirlabel" for="dir">{#advimage_dlg.langdir}</label></td>
|
192 |
-
<td>
|
193 |
-
<select id="dir" name="dir" onchange="ImageDialog.changeAppearance();">
|
194 |
-
<option value="">{#not_set}</option>
|
195 |
-
<option value="ltr">{#advimage_dlg.ltr}</option>
|
196 |
-
<option value="rtl">{#advimage_dlg.rtl}</option>
|
197 |
-
</select>
|
198 |
-
</td>
|
199 |
-
</tr>
|
200 |
-
|
201 |
-
<tr>
|
202 |
-
<td class="column1"><label id="langlabel" for="lang">{#advimage_dlg.langcode}</label></td>
|
203 |
-
<td>
|
204 |
-
<input id="lang" name="lang" type="text" value="" />
|
205 |
-
</td>
|
206 |
-
</tr>
|
207 |
-
|
208 |
-
<tr>
|
209 |
-
<td class="column1"><label id="usemaplabel" for="usemap">{#advimage_dlg.map}</label></td>
|
210 |
-
<td>
|
211 |
-
<input id="usemap" name="usemap" type="text" value="" />
|
212 |
-
</td>
|
213 |
-
</tr>
|
214 |
-
|
215 |
-
<tr>
|
216 |
-
<td class="column1"><label id="longdesclabel" for="longdesc">{#advimage_dlg.long_desc}</label></td>
|
217 |
-
<td><table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
218 |
-
<tr>
|
219 |
-
<td><input id="longdesc" name="longdesc" type="text" value="" /></td>
|
220 |
-
<td id="longdesccontainer"> </td>
|
221 |
-
</tr>
|
222 |
-
</table></td>
|
223 |
-
</tr>
|
224 |
-
</table>
|
225 |
-
</fieldset>
|
226 |
-
</div>
|
227 |
-
</div>
|
228 |
-
|
229 |
-
<div class="mceActionPanel">
|
230 |
-
<input type="submit" id="insert" name="insert" value="{#insert}" />
|
231 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
232 |
-
</div>
|
233 |
-
</form>
|
234 |
-
</body>
|
235 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#advimage_dlg.dialog_title}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/validate.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
10 |
+
<script type="text/javascript" src="js/image.js?ver=359"></script>
|
11 |
+
<link href="css/advimage.css?ver=359" rel="stylesheet" type="text/css" />
|
12 |
+
</head>
|
13 |
+
<body id="advimage" style="display: none" role="application" aria-labelledby="app_title">
|
14 |
+
<span id="app_title" style="display:none">{#advimage_dlg.dialog_title}</span>
|
15 |
+
<form onsubmit="ImageDialog.insert();return false;" action="#">
|
16 |
+
<div class="tabs">
|
17 |
+
<ul>
|
18 |
+
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#advimage_dlg.tab_general}</a></span></li>
|
19 |
+
<li id="appearance_tab" aria-controls="appearance_panel"><span><a href="javascript:mcTabs.displayTab('appearance_tab','appearance_panel');" onmousedown="return false;">{#advimage_dlg.tab_appearance}</a></span></li>
|
20 |
+
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#advimage_dlg.tab_advanced}</a></span></li>
|
21 |
+
</ul>
|
22 |
+
</div>
|
23 |
+
|
24 |
+
<div class="panel_wrapper">
|
25 |
+
<div id="general_panel" class="panel current">
|
26 |
+
<fieldset>
|
27 |
+
<legend>{#advimage_dlg.general}</legend>
|
28 |
+
|
29 |
+
<table role="presentation" class="properties">
|
30 |
+
<tr>
|
31 |
+
<td class="column1"><label id="srclabel" for="src">{#advimage_dlg.src}</label></td>
|
32 |
+
<td colspan="2"><table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
33 |
+
<tr>
|
34 |
+
<td><input name="src" type="text" id="src" value="" class="mceFocus" onchange="ImageDialog.showPreviewImage(this.value);" aria-required="true" /></td>
|
35 |
+
<td id="srcbrowsercontainer"> </td>
|
36 |
+
</tr>
|
37 |
+
</table></td>
|
38 |
+
</tr>
|
39 |
+
<tr>
|
40 |
+
<td><label for="src_list">{#advimage_dlg.image_list}</label></td>
|
41 |
+
<td><select id="src_list" name="src_list" onchange="document.getElementById('src').value=this.options[this.selectedIndex].value;document.getElementById('alt').value=this.options[this.selectedIndex].text;document.getElementById('title').value=this.options[this.selectedIndex].text;ImageDialog.showPreviewImage(this.options[this.selectedIndex].value);"><option value=""></option></select></td>
|
42 |
+
</tr>
|
43 |
+
<tr>
|
44 |
+
<td class="column1"><label id="altlabel" for="alt">{#advimage_dlg.alt}</label></td>
|
45 |
+
<td colspan="2"><input id="alt" name="alt" type="text" value="" /></td>
|
46 |
+
</tr>
|
47 |
+
<tr>
|
48 |
+
<td class="column1"><label id="titlelabel" for="title">{#advimage_dlg.title}</label></td>
|
49 |
+
<td colspan="2"><input id="title" name="title" type="text" value="" /></td>
|
50 |
+
</tr>
|
51 |
+
</table>
|
52 |
+
</fieldset>
|
53 |
+
|
54 |
+
<fieldset>
|
55 |
+
<legend>{#advimage_dlg.preview}</legend>
|
56 |
+
<div id="prev"></div>
|
57 |
+
</fieldset>
|
58 |
+
</div>
|
59 |
+
|
60 |
+
<div id="appearance_panel" class="panel">
|
61 |
+
<fieldset>
|
62 |
+
<legend>{#advimage_dlg.tab_appearance}</legend>
|
63 |
+
|
64 |
+
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
|
65 |
+
<tr>
|
66 |
+
<td class="column1"><label id="alignlabel" for="align">{#advimage_dlg.align}</label></td>
|
67 |
+
<td><select id="align" name="align" onchange="ImageDialog.updateStyle('align');ImageDialog.changeAppearance();">
|
68 |
+
<option value="">{#not_set}</option>
|
69 |
+
<option value="baseline">{#advimage_dlg.align_baseline}</option>
|
70 |
+
<option value="top">{#advimage_dlg.align_top}</option>
|
71 |
+
<option value="middle">{#advimage_dlg.align_middle}</option>
|
72 |
+
<option value="bottom">{#advimage_dlg.align_bottom}</option>
|
73 |
+
<option value="text-top">{#advimage_dlg.align_texttop}</option>
|
74 |
+
<option value="text-bottom">{#advimage_dlg.align_textbottom}</option>
|
75 |
+
<option value="left">{#advimage_dlg.align_left}</option>
|
76 |
+
<option value="right">{#advimage_dlg.align_right}</option>
|
77 |
+
</select>
|
78 |
+
</td>
|
79 |
+
<td rowspan="6" valign="top">
|
80 |
+
<div class="alignPreview">
|
81 |
+
<img id="alignSampleImg" src="img/sample.gif" alt="{#advimage_dlg.example_img}" />
|
82 |
+
Lorem ipsum, Dolor sit amet, consectetuer adipiscing loreum ipsum edipiscing elit, sed diam
|
83 |
+
nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.Loreum ipsum
|
84 |
+
edipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam
|
85 |
+
erat volutpat.
|
86 |
+
</div>
|
87 |
+
</td>
|
88 |
+
</tr>
|
89 |
+
|
90 |
+
<tr role="group" aria-labelledby="widthlabel">
|
91 |
+
<td class="column1"><label id="widthlabel" for="width">{#advimage_dlg.dimensions}</label></td>
|
92 |
+
<td class="nowrap">
|
93 |
+
<span style="display:none" id="width_voiceLabel">{#advimage_dlg.width}</span>
|
94 |
+
<input name="width" type="text" id="width" value="" size="5" maxlength="5" class="size" onchange="ImageDialog.changeHeight();" aria-labelledby="width_voiceLabel" /> x
|
95 |
+
<span style="display:none" id="height_voiceLabel">{#advimage_dlg.height}</span>
|
96 |
+
<input name="height" type="text" id="height" value="" size="5" maxlength="5" class="size" onchange="ImageDialog.changeWidth();" aria-labelledby="height_voiceLabel" /> px
|
97 |
+
</td>
|
98 |
+
</tr>
|
99 |
+
|
100 |
+
<tr>
|
101 |
+
<td> </td>
|
102 |
+
<td><table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
103 |
+
<tr>
|
104 |
+
<td><input id="constrain" type="checkbox" name="constrain" class="checkbox" /></td>
|
105 |
+
<td><label id="constrainlabel" for="constrain">{#advimage_dlg.constrain_proportions}</label></td>
|
106 |
+
</tr>
|
107 |
+
</table></td>
|
108 |
+
</tr>
|
109 |
+
|
110 |
+
<tr>
|
111 |
+
<td class="column1"><label id="vspacelabel" for="vspace">{#advimage_dlg.vspace}</label></td>
|
112 |
+
<td><input name="vspace" type="text" id="vspace" value="" size="3" maxlength="3" class="number" onchange="ImageDialog.updateStyle('vspace');ImageDialog.changeAppearance();" onblur="ImageDialog.updateStyle('vspace');ImageDialog.changeAppearance();" />
|
113 |
+
</td>
|
114 |
+
</tr>
|
115 |
+
|
116 |
+
<tr>
|
117 |
+
<td class="column1"><label id="hspacelabel" for="hspace">{#advimage_dlg.hspace}</label></td>
|
118 |
+
<td><input name="hspace" type="text" id="hspace" value="" size="3" maxlength="3" class="number" onchange="ImageDialog.updateStyle('hspace');ImageDialog.changeAppearance();" onblur="ImageDialog.updateStyle('hspace');ImageDialog.changeAppearance();" /></td>
|
119 |
+
</tr>
|
120 |
+
|
121 |
+
<tr>
|
122 |
+
<td class="column1"><label id="borderlabel" for="border">{#advimage_dlg.border}</label></td>
|
123 |
+
<td><input id="border" name="border" type="text" value="" size="3" maxlength="3" class="number" onchange="ImageDialog.updateStyle('border');ImageDialog.changeAppearance();" onblur="ImageDialog.updateStyle('border');ImageDialog.changeAppearance();" /></td>
|
124 |
+
</tr>
|
125 |
+
|
126 |
+
<tr>
|
127 |
+
<td><label for="class_list">{#class_name}</label></td>
|
128 |
+
<td colspan="2"><select id="class_list" name="class_list" class="mceEditableSelect"><option value=""></option></select></td>
|
129 |
+
</tr>
|
130 |
+
|
131 |
+
<tr>
|
132 |
+
<td class="column1"><label id="stylelabel" for="style">{#advimage_dlg.style}</label></td>
|
133 |
+
<td colspan="2"><input id="style" name="style" type="text" value="" onchange="ImageDialog.changeAppearance();" /></td>
|
134 |
+
</tr>
|
135 |
+
|
136 |
+
<!-- <tr>
|
137 |
+
<td class="column1"><label id="classeslabel" for="classes">{#advimage_dlg.classes}</label></td>
|
138 |
+
<td colspan="2"><input id="classes" name="classes" type="text" value="" onchange="selectByValue(this.form,'classlist',this.value,true);" /></td>
|
139 |
+
</tr> -->
|
140 |
+
</table>
|
141 |
+
</fieldset>
|
142 |
+
</div>
|
143 |
+
|
144 |
+
<div id="advanced_panel" class="panel">
|
145 |
+
<fieldset>
|
146 |
+
<legend>{#advimage_dlg.swap_image}</legend>
|
147 |
+
|
148 |
+
<input type="checkbox" id="onmousemovecheck" name="onmousemovecheck" class="checkbox" onclick="ImageDialog.setSwapImage(this.checked);" aria-controls="onmouseoversrc onmouseoutsrc" />
|
149 |
+
<label id="onmousemovechecklabel" for="onmousemovecheck">{#advimage_dlg.alt_image}</label>
|
150 |
+
|
151 |
+
<table role="presentation" border="0" cellpadding="4" cellspacing="0" width="100%">
|
152 |
+
<tr>
|
153 |
+
<td class="column1"><label id="onmouseoversrclabel" for="onmouseoversrc">{#advimage_dlg.mouseover}</label></td>
|
154 |
+
<td><table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
155 |
+
<tr>
|
156 |
+
<td><input id="onmouseoversrc" name="onmouseoversrc" type="text" value="" /></td>
|
157 |
+
<td id="onmouseoversrccontainer"> </td>
|
158 |
+
</tr>
|
159 |
+
</table></td>
|
160 |
+
</tr>
|
161 |
+
<tr>
|
162 |
+
<td><label for="over_list">{#advimage_dlg.image_list}</label></td>
|
163 |
+
<td><select id="over_list" name="over_list" onchange="document.getElementById('onmouseoversrc').value=this.options[this.selectedIndex].value;"><option value=""></option></select></td>
|
164 |
+
</tr>
|
165 |
+
<tr>
|
166 |
+
<td class="column1"><label id="onmouseoutsrclabel" for="onmouseoutsrc">{#advimage_dlg.mouseout}</label></td>
|
167 |
+
<td class="column2"><table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
168 |
+
<tr>
|
169 |
+
<td><input id="onmouseoutsrc" name="onmouseoutsrc" type="text" value="" /></td>
|
170 |
+
<td id="onmouseoutsrccontainer"> </td>
|
171 |
+
</tr>
|
172 |
+
</table></td>
|
173 |
+
</tr>
|
174 |
+
<tr>
|
175 |
+
<td><label for="out_list">{#advimage_dlg.image_list}</label></td>
|
176 |
+
<td><select id="out_list" name="out_list" onchange="document.getElementById('onmouseoutsrc').value=this.options[this.selectedIndex].value;"><option value=""></option></select></td>
|
177 |
+
</tr>
|
178 |
+
</table>
|
179 |
+
</fieldset>
|
180 |
+
|
181 |
+
<fieldset>
|
182 |
+
<legend>{#advimage_dlg.misc}</legend>
|
183 |
+
|
184 |
+
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
|
185 |
+
<tr>
|
186 |
+
<td class="column1"><label id="idlabel" for="id">{#advimage_dlg.id}</label></td>
|
187 |
+
<td><input id="id" name="id" type="text" value="" /></td>
|
188 |
+
</tr>
|
189 |
+
|
190 |
+
<tr>
|
191 |
+
<td class="column1"><label id="dirlabel" for="dir">{#advimage_dlg.langdir}</label></td>
|
192 |
+
<td>
|
193 |
+
<select id="dir" name="dir" onchange="ImageDialog.changeAppearance();">
|
194 |
+
<option value="">{#not_set}</option>
|
195 |
+
<option value="ltr">{#advimage_dlg.ltr}</option>
|
196 |
+
<option value="rtl">{#advimage_dlg.rtl}</option>
|
197 |
+
</select>
|
198 |
+
</td>
|
199 |
+
</tr>
|
200 |
+
|
201 |
+
<tr>
|
202 |
+
<td class="column1"><label id="langlabel" for="lang">{#advimage_dlg.langcode}</label></td>
|
203 |
+
<td>
|
204 |
+
<input id="lang" name="lang" type="text" value="" />
|
205 |
+
</td>
|
206 |
+
</tr>
|
207 |
+
|
208 |
+
<tr>
|
209 |
+
<td class="column1"><label id="usemaplabel" for="usemap">{#advimage_dlg.map}</label></td>
|
210 |
+
<td>
|
211 |
+
<input id="usemap" name="usemap" type="text" value="" />
|
212 |
+
</td>
|
213 |
+
</tr>
|
214 |
+
|
215 |
+
<tr>
|
216 |
+
<td class="column1"><label id="longdesclabel" for="longdesc">{#advimage_dlg.long_desc}</label></td>
|
217 |
+
<td><table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
218 |
+
<tr>
|
219 |
+
<td><input id="longdesc" name="longdesc" type="text" value="" /></td>
|
220 |
+
<td id="longdesccontainer"> </td>
|
221 |
+
</tr>
|
222 |
+
</table></td>
|
223 |
+
</tr>
|
224 |
+
</table>
|
225 |
+
</fieldset>
|
226 |
+
</div>
|
227 |
+
</div>
|
228 |
+
|
229 |
+
<div class="mceActionPanel">
|
230 |
+
<input type="submit" id="insert" name="insert" value="{#insert}" />
|
231 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
232 |
+
</div>
|
233 |
+
</form>
|
234 |
+
</body>
|
235 |
+
</html>
|
mce/advimage/js/image.js
CHANGED
@@ -1,464 +1,464 @@
|
|
1 |
-
var ImageDialog = {
|
2 |
-
preInit : function() {
|
3 |
-
var url;
|
4 |
-
|
5 |
-
tinyMCEPopup.requireLangPack();
|
6 |
-
|
7 |
-
if (url = tinyMCEPopup.getParam("external_image_list_url"))
|
8 |
-
document.write('<script language="javascript" type="text/javascript" src="' + tinyMCEPopup.editor.documentBaseURI.toAbsolute(url) + '"></script>');
|
9 |
-
},
|
10 |
-
|
11 |
-
init : function(ed) {
|
12 |
-
var f = document.forms[0], nl = f.elements, ed = tinyMCEPopup.editor, dom = ed.dom, n = ed.selection.getNode(), fl = tinyMCEPopup.getParam('external_image_list', 'tinyMCEImageList');
|
13 |
-
|
14 |
-
tinyMCEPopup.resizeToInnerSize();
|
15 |
-
this.fillClassList('class_list');
|
16 |
-
this.fillFileList('src_list', fl);
|
17 |
-
this.fillFileList('over_list', fl);
|
18 |
-
this.fillFileList('out_list', fl);
|
19 |
-
TinyMCE_EditableSelects.init();
|
20 |
-
|
21 |
-
if (n.nodeName == 'IMG') {
|
22 |
-
nl.src.value = dom.getAttrib(n, 'src');
|
23 |
-
nl.width.value = dom.getAttrib(n, 'width');
|
24 |
-
nl.height.value = dom.getAttrib(n, 'height');
|
25 |
-
nl.alt.value = dom.getAttrib(n, 'alt');
|
26 |
-
nl.title.value = dom.getAttrib(n, 'title');
|
27 |
-
nl.vspace.value = this.getAttrib(n, 'vspace');
|
28 |
-
nl.hspace.value = this.getAttrib(n, 'hspace');
|
29 |
-
nl.border.value = this.getAttrib(n, 'border');
|
30 |
-
selectByValue(f, 'align', this.getAttrib(n, 'align'));
|
31 |
-
selectByValue(f, 'class_list', dom.getAttrib(n, 'class'), true, true);
|
32 |
-
nl.style.value = dom.getAttrib(n, 'style');
|
33 |
-
nl.id.value = dom.getAttrib(n, 'id');
|
34 |
-
nl.dir.value = dom.getAttrib(n, 'dir');
|
35 |
-
nl.lang.value = dom.getAttrib(n, 'lang');
|
36 |
-
nl.usemap.value = dom.getAttrib(n, 'usemap');
|
37 |
-
nl.longdesc.value = dom.getAttrib(n, 'longdesc');
|
38 |
-
nl.insert.value = ed.getLang('update');
|
39 |
-
|
40 |
-
if (/^\s*this.src\s*=\s*\'([^\']+)\';?\s*$/.test(dom.getAttrib(n, 'onmouseover')))
|
41 |
-
nl.onmouseoversrc.value = dom.getAttrib(n, 'onmouseover').replace(/^\s*this.src\s*=\s*\'([^\']+)\';?\s*$/, '$1');
|
42 |
-
|
43 |
-
if (/^\s*this.src\s*=\s*\'([^\']+)\';?\s*$/.test(dom.getAttrib(n, 'onmouseout')))
|
44 |
-
nl.onmouseoutsrc.value = dom.getAttrib(n, 'onmouseout').replace(/^\s*this.src\s*=\s*\'([^\']+)\';?\s*$/, '$1');
|
45 |
-
|
46 |
-
if (ed.settings.inline_styles) {
|
47 |
-
// Move attribs to styles
|
48 |
-
if (dom.getAttrib(n, 'align'))
|
49 |
-
this.updateStyle('align');
|
50 |
-
|
51 |
-
if (dom.getAttrib(n, 'hspace'))
|
52 |
-
this.updateStyle('hspace');
|
53 |
-
|
54 |
-
if (dom.getAttrib(n, 'border'))
|
55 |
-
this.updateStyle('border');
|
56 |
-
|
57 |
-
if (dom.getAttrib(n, 'vspace'))
|
58 |
-
this.updateStyle('vspace');
|
59 |
-
}
|
60 |
-
}
|
61 |
-
|
62 |
-
// Setup browse button
|
63 |
-
document.getElementById('srcbrowsercontainer').innerHTML = getBrowserHTML('srcbrowser','src','image','theme_advanced_image');
|
64 |
-
if (isVisible('srcbrowser'))
|
65 |
-
document.getElementById('src').style.width = '260px';
|
66 |
-
|
67 |
-
// Setup browse button
|
68 |
-
document.getElementById('onmouseoversrccontainer').innerHTML = getBrowserHTML('overbrowser','onmouseoversrc','image','theme_advanced_image');
|
69 |
-
if (isVisible('overbrowser'))
|
70 |
-
document.getElementById('onmouseoversrc').style.width = '260px';
|
71 |
-
|
72 |
-
// Setup browse button
|
73 |
-
document.getElementById('onmouseoutsrccontainer').innerHTML = getBrowserHTML('outbrowser','onmouseoutsrc','image','theme_advanced_image');
|
74 |
-
if (isVisible('outbrowser'))
|
75 |
-
document.getElementById('onmouseoutsrc').style.width = '260px';
|
76 |
-
|
77 |
-
// If option enabled default contrain proportions to checked
|
78 |
-
if (ed.getParam("advimage_constrain_proportions", true))
|
79 |
-
f.constrain.checked = true;
|
80 |
-
|
81 |
-
// Check swap image if valid data
|
82 |
-
if (nl.onmouseoversrc.value || nl.onmouseoutsrc.value)
|
83 |
-
this.setSwapImage(true);
|
84 |
-
else
|
85 |
-
this.setSwapImage(false);
|
86 |
-
|
87 |
-
this.changeAppearance();
|
88 |
-
this.showPreviewImage(nl.src.value, 1);
|
89 |
-
},
|
90 |
-
|
91 |
-
insert : function(file, title) {
|
92 |
-
var ed = tinyMCEPopup.editor, t = this, f = document.forms[0];
|
93 |
-
|
94 |
-
if (f.src.value === '') {
|
95 |
-
if (ed.selection.getNode().nodeName == 'IMG') {
|
96 |
-
ed.dom.remove(ed.selection.getNode());
|
97 |
-
ed.execCommand('mceRepaint');
|
98 |
-
}
|
99 |
-
|
100 |
-
tinyMCEPopup.close();
|
101 |
-
return;
|
102 |
-
}
|
103 |
-
|
104 |
-
if (tinyMCEPopup.getParam("accessibility_warnings", 1)) {
|
105 |
-
if (!f.alt.value) {
|
106 |
-
tinyMCEPopup.confirm(tinyMCEPopup.getLang('advimage_dlg.missing_alt'), function(s) {
|
107 |
-
if (s)
|
108 |
-
t.insertAndClose();
|
109 |
-
});
|
110 |
-
|
111 |
-
return;
|
112 |
-
}
|
113 |
-
}
|
114 |
-
|
115 |
-
t.insertAndClose();
|
116 |
-
},
|
117 |
-
|
118 |
-
insertAndClose : function() {
|
119 |
-
var ed = tinyMCEPopup.editor, f = document.forms[0], nl = f.elements, v, args = {}, el;
|
120 |
-
|
121 |
-
tinyMCEPopup.restoreSelection();
|
122 |
-
|
123 |
-
// Fixes crash in Safari
|
124 |
-
if (tinymce.isWebKit)
|
125 |
-
ed.getWin().focus();
|
126 |
-
|
127 |
-
if (!ed.settings.inline_styles) {
|
128 |
-
args = {
|
129 |
-
vspace : nl.vspace.value,
|
130 |
-
hspace : nl.hspace.value,
|
131 |
-
border : nl.border.value,
|
132 |
-
align : getSelectValue(f, 'align')
|
133 |
-
};
|
134 |
-
} else {
|
135 |
-
// Remove deprecated values
|
136 |
-
args = {
|
137 |
-
vspace : '',
|
138 |
-
hspace : '',
|
139 |
-
border : '',
|
140 |
-
align : ''
|
141 |
-
};
|
142 |
-
}
|
143 |
-
|
144 |
-
tinymce.extend(args, {
|
145 |
-
src : nl.src.value.replace(/ /g, '%20'),
|
146 |
-
width : nl.width.value,
|
147 |
-
height : nl.height.value,
|
148 |
-
alt : nl.alt.value,
|
149 |
-
title : nl.title.value,
|
150 |
-
'class' : getSelectValue(f, 'class_list'),
|
151 |
-
style : nl.style.value,
|
152 |
-
id : nl.id.value,
|
153 |
-
dir : nl.dir.value,
|
154 |
-
lang : nl.lang.value,
|
155 |
-
usemap : nl.usemap.value,
|
156 |
-
longdesc : nl.longdesc.value
|
157 |
-
});
|
158 |
-
|
159 |
-
args.onmouseover = args.onmouseout = '';
|
160 |
-
|
161 |
-
if (f.onmousemovecheck.checked) {
|
162 |
-
if (nl.onmouseoversrc.value)
|
163 |
-
args.onmouseover = "this.src='" + nl.onmouseoversrc.value + "';";
|
164 |
-
|
165 |
-
if (nl.onmouseoutsrc.value)
|
166 |
-
args.onmouseout = "this.src='" + nl.onmouseoutsrc.value + "';";
|
167 |
-
}
|
168 |
-
|
169 |
-
el = ed.selection.getNode();
|
170 |
-
|
171 |
-
if (el && el.nodeName == 'IMG') {
|
172 |
-
ed.dom.setAttribs(el, args);
|
173 |
-
} else {
|
174 |
-
tinymce.each(args, function(value, name) {
|
175 |
-
if (value === "") {
|
176 |
-
delete args[name];
|
177 |
-
}
|
178 |
-
});
|
179 |
-
|
180 |
-
ed.execCommand('mceInsertContent', false, tinyMCEPopup.editor.dom.createHTML('img', args), {skip_undo : 1});
|
181 |
-
ed.undoManager.add();
|
182 |
-
}
|
183 |
-
|
184 |
-
tinyMCEPopup.editor.execCommand('mceRepaint');
|
185 |
-
tinyMCEPopup.editor.focus();
|
186 |
-
tinyMCEPopup.close();
|
187 |
-
},
|
188 |
-
|
189 |
-
getAttrib : function(e, at) {
|
190 |
-
var ed = tinyMCEPopup.editor, dom = ed.dom, v, v2;
|
191 |
-
|
192 |
-
if (ed.settings.inline_styles) {
|
193 |
-
switch (at) {
|
194 |
-
case 'align':
|
195 |
-
if (v = dom.getStyle(e, 'float'))
|
196 |
-
return v;
|
197 |
-
|
198 |
-
if (v = dom.getStyle(e, 'vertical-align'))
|
199 |
-
return v;
|
200 |
-
|
201 |
-
break;
|
202 |
-
|
203 |
-
case 'hspace':
|
204 |
-
v = dom.getStyle(e, 'margin-left')
|
205 |
-
v2 = dom.getStyle(e, 'margin-right');
|
206 |
-
|
207 |
-
if (v && v == v2)
|
208 |
-
return parseInt(v.replace(/[^0-9]/g, ''));
|
209 |
-
|
210 |
-
break;
|
211 |
-
|
212 |
-
case 'vspace':
|
213 |
-
v = dom.getStyle(e, 'margin-top')
|
214 |
-
v2 = dom.getStyle(e, 'margin-bottom');
|
215 |
-
if (v && v == v2)
|
216 |
-
return parseInt(v.replace(/[^0-9]/g, ''));
|
217 |
-
|
218 |
-
break;
|
219 |
-
|
220 |
-
case 'border':
|
221 |
-
v = 0;
|
222 |
-
|
223 |
-
tinymce.each(['top', 'right', 'bottom', 'left'], function(sv) {
|
224 |
-
sv = dom.getStyle(e, 'border-' + sv + '-width');
|
225 |
-
|
226 |
-
// False or not the same as prev
|
227 |
-
if (!sv || (sv != v && v !== 0)) {
|
228 |
-
v = 0;
|
229 |
-
return false;
|
230 |
-
}
|
231 |
-
|
232 |
-
if (sv)
|
233 |
-
v = sv;
|
234 |
-
});
|
235 |
-
|
236 |
-
if (v)
|
237 |
-
return parseInt(v.replace(/[^0-9]/g, ''));
|
238 |
-
|
239 |
-
break;
|
240 |
-
}
|
241 |
-
}
|
242 |
-
|
243 |
-
if (v = dom.getAttrib(e, at))
|
244 |
-
return v;
|
245 |
-
|
246 |
-
return '';
|
247 |
-
},
|
248 |
-
|
249 |
-
setSwapImage : function(st) {
|
250 |
-
var f = document.forms[0];
|
251 |
-
|
252 |
-
f.onmousemovecheck.checked = st;
|
253 |
-
setBrowserDisabled('overbrowser', !st);
|
254 |
-
setBrowserDisabled('outbrowser', !st);
|
255 |
-
|
256 |
-
if (f.over_list)
|
257 |
-
f.over_list.disabled = !st;
|
258 |
-
|
259 |
-
if (f.out_list)
|
260 |
-
f.out_list.disabled = !st;
|
261 |
-
|
262 |
-
f.onmouseoversrc.disabled = !st;
|
263 |
-
f.onmouseoutsrc.disabled = !st;
|
264 |
-
},
|
265 |
-
|
266 |
-
fillClassList : function(id) {
|
267 |
-
var dom = tinyMCEPopup.dom, lst = dom.get(id), v, cl;
|
268 |
-
|
269 |
-
if (v = tinyMCEPopup.getParam('theme_advanced_styles')) {
|
270 |
-
cl = [];
|
271 |
-
|
272 |
-
tinymce.each(v.split(';'), function(v) {
|
273 |
-
var p = v.split('=');
|
274 |
-
|
275 |
-
cl.push({'title' : p[0], 'class' : p[1]});
|
276 |
-
});
|
277 |
-
} else
|
278 |
-
cl = tinyMCEPopup.editor.dom.getClasses();
|
279 |
-
|
280 |
-
if (cl.length > 0) {
|
281 |
-
lst.options.length = 0;
|
282 |
-
lst.options[lst.options.length] = new Option(tinyMCEPopup.getLang('not_set'), '');
|
283 |
-
|
284 |
-
tinymce.each(cl, function(o) {
|
285 |
-
lst.options[lst.options.length] = new Option(o.title || o['class'], o['class']);
|
286 |
-
});
|
287 |
-
} else
|
288 |
-
dom.remove(dom.getParent(id, 'tr'));
|
289 |
-
},
|
290 |
-
|
291 |
-
fillFileList : function(id, l) {
|
292 |
-
var dom = tinyMCEPopup.dom, lst = dom.get(id), v, cl;
|
293 |
-
|
294 |
-
l = typeof(l) === 'function' ? l() : window[l];
|
295 |
-
lst.options.length = 0;
|
296 |
-
|
297 |
-
if (l && l.length > 0) {
|
298 |
-
lst.options[lst.options.length] = new Option('', '');
|
299 |
-
|
300 |
-
tinymce.each(l, function(o) {
|
301 |
-
lst.options[lst.options.length] = new Option(o[0], o[1]);
|
302 |
-
});
|
303 |
-
} else
|
304 |
-
dom.remove(dom.getParent(id, 'tr'));
|
305 |
-
},
|
306 |
-
|
307 |
-
resetImageData : function() {
|
308 |
-
var f = document.forms[0];
|
309 |
-
|
310 |
-
f.elements.width.value = f.elements.height.value = '';
|
311 |
-
},
|
312 |
-
|
313 |
-
updateImageData : function(img, st) {
|
314 |
-
var f = document.forms[0];
|
315 |
-
|
316 |
-
if (!st) {
|
317 |
-
f.elements.width.value = img.width;
|
318 |
-
f.elements.height.value = img.height;
|
319 |
-
}
|
320 |
-
|
321 |
-
this.preloadImg = img;
|
322 |
-
},
|
323 |
-
|
324 |
-
changeAppearance : function() {
|
325 |
-
var ed = tinyMCEPopup.editor, f = document.forms[0], img = document.getElementById('alignSampleImg');
|
326 |
-
|
327 |
-
if (img) {
|
328 |
-
if (ed.getParam('inline_styles')) {
|
329 |
-
ed.dom.setAttrib(img, 'style', f.style.value);
|
330 |
-
} else {
|
331 |
-
img.align = f.align.value;
|
332 |
-
img.border = f.border.value;
|
333 |
-
img.hspace = f.hspace.value;
|
334 |
-
img.vspace = f.vspace.value;
|
335 |
-
}
|
336 |
-
}
|
337 |
-
},
|
338 |
-
|
339 |
-
changeHeight : function() {
|
340 |
-
var f = document.forms[0], tp, t = this;
|
341 |
-
|
342 |
-
if (!f.constrain.checked || !t.preloadImg) {
|
343 |
-
return;
|
344 |
-
}
|
345 |
-
|
346 |
-
if (f.width.value == "" || f.height.value == "")
|
347 |
-
return;
|
348 |
-
|
349 |
-
tp = (parseInt(f.width.value) / parseInt(t.preloadImg.width)) * t.preloadImg.height;
|
350 |
-
f.height.value = tp.toFixed(0);
|
351 |
-
},
|
352 |
-
|
353 |
-
changeWidth : function() {
|
354 |
-
var f = document.forms[0], tp, t = this;
|
355 |
-
|
356 |
-
if (!f.constrain.checked || !t.preloadImg) {
|
357 |
-
return;
|
358 |
-
}
|
359 |
-
|
360 |
-
if (f.width.value == "" || f.height.value == "")
|
361 |
-
return;
|
362 |
-
|
363 |
-
tp = (parseInt(f.height.value) / parseInt(t.preloadImg.height)) * t.preloadImg.width;
|
364 |
-
f.width.value = tp.toFixed(0);
|
365 |
-
},
|
366 |
-
|
367 |
-
updateStyle : function(ty) {
|
368 |
-
var dom = tinyMCEPopup.dom, b, bStyle, bColor, v, isIE = tinymce.isIE, f = document.forms[0], img = dom.create('img', {style : dom.get('style').value});
|
369 |
-
|
370 |
-
if (tinyMCEPopup.editor.settings.inline_styles) {
|
371 |
-
// Handle align
|
372 |
-
if (ty == 'align') {
|
373 |
-
dom.setStyle(img, 'float', '');
|
374 |
-
dom.setStyle(img, 'vertical-align', '');
|
375 |
-
|
376 |
-
v = getSelectValue(f, 'align');
|
377 |
-
if (v) {
|
378 |
-
if (v == 'left' || v == 'right')
|
379 |
-
dom.setStyle(img, 'float', v);
|
380 |
-
else
|
381 |
-
img.style.verticalAlign = v;
|
382 |
-
}
|
383 |
-
}
|
384 |
-
|
385 |
-
// Handle border
|
386 |
-
if (ty == 'border') {
|
387 |
-
b = img.style.border ? img.style.border.split(' ') : [];
|
388 |
-
bStyle = dom.getStyle(img, 'border-style');
|
389 |
-
bColor = dom.getStyle(img, 'border-color');
|
390 |
-
|
391 |
-
dom.setStyle(img, 'border', '');
|
392 |
-
|
393 |
-
v = f.border.value;
|
394 |
-
if (v || v == '0') {
|
395 |
-
if (v == '0')
|
396 |
-
img.style.border = isIE ? '0' : '0 none none';
|
397 |
-
else {
|
398 |
-
var isOldIE = tinymce.isIE && (!document.documentMode || document.documentMode < 9);
|
399 |
-
|
400 |
-
if (b.length == 3 && b[isOldIE ? 2 : 1])
|
401 |
-
bStyle = b[isOldIE ? 2 : 1];
|
402 |
-
else if (!bStyle || bStyle == 'none')
|
403 |
-
bStyle = 'solid';
|
404 |
-
if (b.length == 3 && b[isIE ? 0 : 2])
|
405 |
-
bColor = b[isOldIE ? 0 : 2];
|
406 |
-
else if (!bColor || bColor == 'none')
|
407 |
-
bColor = 'black';
|
408 |
-
img.style.border = v + 'px ' + bStyle + ' ' + bColor;
|
409 |
-
}
|
410 |
-
}
|
411 |
-
}
|
412 |
-
|
413 |
-
// Handle hspace
|
414 |
-
if (ty == 'hspace') {
|
415 |
-
dom.setStyle(img, 'marginLeft', '');
|
416 |
-
dom.setStyle(img, 'marginRight', '');
|
417 |
-
|
418 |
-
v = f.hspace.value;
|
419 |
-
if (v) {
|
420 |
-
img.style.marginLeft = v + 'px';
|
421 |
-
img.style.marginRight = v + 'px';
|
422 |
-
}
|
423 |
-
}
|
424 |
-
|
425 |
-
// Handle vspace
|
426 |
-
if (ty == 'vspace') {
|
427 |
-
dom.setStyle(img, 'marginTop', '');
|
428 |
-
dom.setStyle(img, 'marginBottom', '');
|
429 |
-
|
430 |
-
v = f.vspace.value;
|
431 |
-
if (v) {
|
432 |
-
img.style.marginTop = v + 'px';
|
433 |
-
img.style.marginBottom = v + 'px';
|
434 |
-
}
|
435 |
-
}
|
436 |
-
|
437 |
-
// Merge
|
438 |
-
dom.get('style').value = dom.serializeStyle(dom.parseStyle(img.style.cssText), 'img');
|
439 |
-
}
|
440 |
-
},
|
441 |
-
|
442 |
-
changeMouseMove : function() {
|
443 |
-
},
|
444 |
-
|
445 |
-
showPreviewImage : function(u, st) {
|
446 |
-
if (!u) {
|
447 |
-
tinyMCEPopup.dom.setHTML('prev', '');
|
448 |
-
return;
|
449 |
-
}
|
450 |
-
|
451 |
-
if (!st && tinyMCEPopup.getParam("advimage_update_dimensions_onchange", true))
|
452 |
-
this.resetImageData();
|
453 |
-
|
454 |
-
u = tinyMCEPopup.editor.documentBaseURI.toAbsolute(u);
|
455 |
-
|
456 |
-
if (!st)
|
457 |
-
tinyMCEPopup.dom.setHTML('prev', '<img id="previewImg" src="' + u + '" border="0" onload="ImageDialog.updateImageData(this);" onerror="ImageDialog.resetImageData();" />');
|
458 |
-
else
|
459 |
-
tinyMCEPopup.dom.setHTML('prev', '<img id="previewImg" src="' + u + '" border="0" onload="ImageDialog.updateImageData(this, 1);" />');
|
460 |
-
}
|
461 |
-
};
|
462 |
-
|
463 |
-
ImageDialog.preInit();
|
464 |
-
tinyMCEPopup.onInit.add(ImageDialog.init, ImageDialog);
|
1 |
+
var ImageDialog = {
|
2 |
+
preInit : function() {
|
3 |
+
var url;
|
4 |
+
|
5 |
+
tinyMCEPopup.requireLangPack();
|
6 |
+
|
7 |
+
if (url = tinyMCEPopup.getParam("external_image_list_url"))
|
8 |
+
document.write('<script language="javascript" type="text/javascript" src="' + tinyMCEPopup.editor.documentBaseURI.toAbsolute(url) + '"></script>');
|
9 |
+
},
|
10 |
+
|
11 |
+
init : function(ed) {
|
12 |
+
var f = document.forms[0], nl = f.elements, ed = tinyMCEPopup.editor, dom = ed.dom, n = ed.selection.getNode(), fl = tinyMCEPopup.getParam('external_image_list', 'tinyMCEImageList');
|
13 |
+
|
14 |
+
tinyMCEPopup.resizeToInnerSize();
|
15 |
+
this.fillClassList('class_list');
|
16 |
+
this.fillFileList('src_list', fl);
|
17 |
+
this.fillFileList('over_list', fl);
|
18 |
+
this.fillFileList('out_list', fl);
|
19 |
+
TinyMCE_EditableSelects.init();
|
20 |
+
|
21 |
+
if (n.nodeName == 'IMG') {
|
22 |
+
nl.src.value = dom.getAttrib(n, 'src');
|
23 |
+
nl.width.value = dom.getAttrib(n, 'width');
|
24 |
+
nl.height.value = dom.getAttrib(n, 'height');
|
25 |
+
nl.alt.value = dom.getAttrib(n, 'alt');
|
26 |
+
nl.title.value = dom.getAttrib(n, 'title');
|
27 |
+
nl.vspace.value = this.getAttrib(n, 'vspace');
|
28 |
+
nl.hspace.value = this.getAttrib(n, 'hspace');
|
29 |
+
nl.border.value = this.getAttrib(n, 'border');
|
30 |
+
selectByValue(f, 'align', this.getAttrib(n, 'align'));
|
31 |
+
selectByValue(f, 'class_list', dom.getAttrib(n, 'class'), true, true);
|
32 |
+
nl.style.value = dom.getAttrib(n, 'style');
|
33 |
+
nl.id.value = dom.getAttrib(n, 'id');
|
34 |
+
nl.dir.value = dom.getAttrib(n, 'dir');
|
35 |
+
nl.lang.value = dom.getAttrib(n, 'lang');
|
36 |
+
nl.usemap.value = dom.getAttrib(n, 'usemap');
|
37 |
+
nl.longdesc.value = dom.getAttrib(n, 'longdesc');
|
38 |
+
nl.insert.value = ed.getLang('update');
|
39 |
+
|
40 |
+
if (/^\s*this.src\s*=\s*\'([^\']+)\';?\s*$/.test(dom.getAttrib(n, 'onmouseover')))
|
41 |
+
nl.onmouseoversrc.value = dom.getAttrib(n, 'onmouseover').replace(/^\s*this.src\s*=\s*\'([^\']+)\';?\s*$/, '$1');
|
42 |
+
|
43 |
+
if (/^\s*this.src\s*=\s*\'([^\']+)\';?\s*$/.test(dom.getAttrib(n, 'onmouseout')))
|
44 |
+
nl.onmouseoutsrc.value = dom.getAttrib(n, 'onmouseout').replace(/^\s*this.src\s*=\s*\'([^\']+)\';?\s*$/, '$1');
|
45 |
+
|
46 |
+
if (ed.settings.inline_styles) {
|
47 |
+
// Move attribs to styles
|
48 |
+
if (dom.getAttrib(n, 'align'))
|
49 |
+
this.updateStyle('align');
|
50 |
+
|
51 |
+
if (dom.getAttrib(n, 'hspace'))
|
52 |
+
this.updateStyle('hspace');
|
53 |
+
|
54 |
+
if (dom.getAttrib(n, 'border'))
|
55 |
+
this.updateStyle('border');
|
56 |
+
|
57 |
+
if (dom.getAttrib(n, 'vspace'))
|
58 |
+
this.updateStyle('vspace');
|
59 |
+
}
|
60 |
+
}
|
61 |
+
|
62 |
+
// Setup browse button
|
63 |
+
document.getElementById('srcbrowsercontainer').innerHTML = getBrowserHTML('srcbrowser','src','image','theme_advanced_image');
|
64 |
+
if (isVisible('srcbrowser'))
|
65 |
+
document.getElementById('src').style.width = '260px';
|
66 |
+
|
67 |
+
// Setup browse button
|
68 |
+
document.getElementById('onmouseoversrccontainer').innerHTML = getBrowserHTML('overbrowser','onmouseoversrc','image','theme_advanced_image');
|
69 |
+
if (isVisible('overbrowser'))
|
70 |
+
document.getElementById('onmouseoversrc').style.width = '260px';
|
71 |
+
|
72 |
+
// Setup browse button
|
73 |
+
document.getElementById('onmouseoutsrccontainer').innerHTML = getBrowserHTML('outbrowser','onmouseoutsrc','image','theme_advanced_image');
|
74 |
+
if (isVisible('outbrowser'))
|
75 |
+
document.getElementById('onmouseoutsrc').style.width = '260px';
|
76 |
+
|
77 |
+
// If option enabled default contrain proportions to checked
|
78 |
+
if (ed.getParam("advimage_constrain_proportions", true))
|
79 |
+
f.constrain.checked = true;
|
80 |
+
|
81 |
+
// Check swap image if valid data
|
82 |
+
if (nl.onmouseoversrc.value || nl.onmouseoutsrc.value)
|
83 |
+
this.setSwapImage(true);
|
84 |
+
else
|
85 |
+
this.setSwapImage(false);
|
86 |
+
|
87 |
+
this.changeAppearance();
|
88 |
+
this.showPreviewImage(nl.src.value, 1);
|
89 |
+
},
|
90 |
+
|
91 |
+
insert : function(file, title) {
|
92 |
+
var ed = tinyMCEPopup.editor, t = this, f = document.forms[0];
|
93 |
+
|
94 |
+
if (f.src.value === '') {
|
95 |
+
if (ed.selection.getNode().nodeName == 'IMG') {
|
96 |
+
ed.dom.remove(ed.selection.getNode());
|
97 |
+
ed.execCommand('mceRepaint');
|
98 |
+
}
|
99 |
+
|
100 |
+
tinyMCEPopup.close();
|
101 |
+
return;
|
102 |
+
}
|
103 |
+
|
104 |
+
if (tinyMCEPopup.getParam("accessibility_warnings", 1)) {
|
105 |
+
if (!f.alt.value) {
|
106 |
+
tinyMCEPopup.confirm(tinyMCEPopup.getLang('advimage_dlg.missing_alt'), function(s) {
|
107 |
+
if (s)
|
108 |
+
t.insertAndClose();
|
109 |
+
});
|
110 |
+
|
111 |
+
return;
|
112 |
+
}
|
113 |
+
}
|
114 |
+
|
115 |
+
t.insertAndClose();
|
116 |
+
},
|
117 |
+
|
118 |
+
insertAndClose : function() {
|
119 |
+
var ed = tinyMCEPopup.editor, f = document.forms[0], nl = f.elements, v, args = {}, el;
|
120 |
+
|
121 |
+
tinyMCEPopup.restoreSelection();
|
122 |
+
|
123 |
+
// Fixes crash in Safari
|
124 |
+
if (tinymce.isWebKit)
|
125 |
+
ed.getWin().focus();
|
126 |
+
|
127 |
+
if (!ed.settings.inline_styles) {
|
128 |
+
args = {
|
129 |
+
vspace : nl.vspace.value,
|
130 |
+
hspace : nl.hspace.value,
|
131 |
+
border : nl.border.value,
|
132 |
+
align : getSelectValue(f, 'align')
|
133 |
+
};
|
134 |
+
} else {
|
135 |
+
// Remove deprecated values
|
136 |
+
args = {
|
137 |
+
vspace : '',
|
138 |
+
hspace : '',
|
139 |
+
border : '',
|
140 |
+
align : ''
|
141 |
+
};
|
142 |
+
}
|
143 |
+
|
144 |
+
tinymce.extend(args, {
|
145 |
+
src : nl.src.value.replace(/ /g, '%20'),
|
146 |
+
width : nl.width.value,
|
147 |
+
height : nl.height.value,
|
148 |
+
alt : nl.alt.value,
|
149 |
+
title : nl.title.value,
|
150 |
+
'class' : getSelectValue(f, 'class_list'),
|
151 |
+
style : nl.style.value,
|
152 |
+
id : nl.id.value,
|
153 |
+
dir : nl.dir.value,
|
154 |
+
lang : nl.lang.value,
|
155 |
+
usemap : nl.usemap.value,
|
156 |
+
longdesc : nl.longdesc.value
|
157 |
+
});
|
158 |
+
|
159 |
+
args.onmouseover = args.onmouseout = '';
|
160 |
+
|
161 |
+
if (f.onmousemovecheck.checked) {
|
162 |
+
if (nl.onmouseoversrc.value)
|
163 |
+
args.onmouseover = "this.src='" + nl.onmouseoversrc.value + "';";
|
164 |
+
|
165 |
+
if (nl.onmouseoutsrc.value)
|
166 |
+
args.onmouseout = "this.src='" + nl.onmouseoutsrc.value + "';";
|
167 |
+
}
|
168 |
+
|
169 |
+
el = ed.selection.getNode();
|
170 |
+
|
171 |
+
if (el && el.nodeName == 'IMG') {
|
172 |
+
ed.dom.setAttribs(el, args);
|
173 |
+
} else {
|
174 |
+
tinymce.each(args, function(value, name) {
|
175 |
+
if (value === "") {
|
176 |
+
delete args[name];
|
177 |
+
}
|
178 |
+
});
|
179 |
+
|
180 |
+
ed.execCommand('mceInsertContent', false, tinyMCEPopup.editor.dom.createHTML('img', args), {skip_undo : 1});
|
181 |
+
ed.undoManager.add();
|
182 |
+
}
|
183 |
+
|
184 |
+
tinyMCEPopup.editor.execCommand('mceRepaint');
|
185 |
+
tinyMCEPopup.editor.focus();
|
186 |
+
tinyMCEPopup.close();
|
187 |
+
},
|
188 |
+
|
189 |
+
getAttrib : function(e, at) {
|
190 |
+
var ed = tinyMCEPopup.editor, dom = ed.dom, v, v2;
|
191 |
+
|
192 |
+
if (ed.settings.inline_styles) {
|
193 |
+
switch (at) {
|
194 |
+
case 'align':
|
195 |
+
if (v = dom.getStyle(e, 'float'))
|
196 |
+
return v;
|
197 |
+
|
198 |
+
if (v = dom.getStyle(e, 'vertical-align'))
|
199 |
+
return v;
|
200 |
+
|
201 |
+
break;
|
202 |
+
|
203 |
+
case 'hspace':
|
204 |
+
v = dom.getStyle(e, 'margin-left')
|
205 |
+
v2 = dom.getStyle(e, 'margin-right');
|
206 |
+
|
207 |
+
if (v && v == v2)
|
208 |
+
return parseInt(v.replace(/[^0-9]/g, ''));
|
209 |
+
|
210 |
+
break;
|
211 |
+
|
212 |
+
case 'vspace':
|
213 |
+
v = dom.getStyle(e, 'margin-top')
|
214 |
+
v2 = dom.getStyle(e, 'margin-bottom');
|
215 |
+
if (v && v == v2)
|
216 |
+
return parseInt(v.replace(/[^0-9]/g, ''));
|
217 |
+
|
218 |
+
break;
|
219 |
+
|
220 |
+
case 'border':
|
221 |
+
v = 0;
|
222 |
+
|
223 |
+
tinymce.each(['top', 'right', 'bottom', 'left'], function(sv) {
|
224 |
+
sv = dom.getStyle(e, 'border-' + sv + '-width');
|
225 |
+
|
226 |
+
// False or not the same as prev
|
227 |
+
if (!sv || (sv != v && v !== 0)) {
|
228 |
+
v = 0;
|
229 |
+
return false;
|
230 |
+
}
|
231 |
+
|
232 |
+
if (sv)
|
233 |
+
v = sv;
|
234 |
+
});
|
235 |
+
|
236 |
+
if (v)
|
237 |
+
return parseInt(v.replace(/[^0-9]/g, ''));
|
238 |
+
|
239 |
+
break;
|
240 |
+
}
|
241 |
+
}
|
242 |
+
|
243 |
+
if (v = dom.getAttrib(e, at))
|
244 |
+
return v;
|
245 |
+
|
246 |
+
return '';
|
247 |
+
},
|
248 |
+
|
249 |
+
setSwapImage : function(st) {
|
250 |
+
var f = document.forms[0];
|
251 |
+
|
252 |
+
f.onmousemovecheck.checked = st;
|
253 |
+
setBrowserDisabled('overbrowser', !st);
|
254 |
+
setBrowserDisabled('outbrowser', !st);
|
255 |
+
|
256 |
+
if (f.over_list)
|
257 |
+
f.over_list.disabled = !st;
|
258 |
+
|
259 |
+
if (f.out_list)
|
260 |
+
f.out_list.disabled = !st;
|
261 |
+
|
262 |
+
f.onmouseoversrc.disabled = !st;
|
263 |
+
f.onmouseoutsrc.disabled = !st;
|
264 |
+
},
|
265 |
+
|
266 |
+
fillClassList : function(id) {
|
267 |
+
var dom = tinyMCEPopup.dom, lst = dom.get(id), v, cl;
|
268 |
+
|
269 |
+
if (v = tinyMCEPopup.getParam('theme_advanced_styles')) {
|
270 |
+
cl = [];
|
271 |
+
|
272 |
+
tinymce.each(v.split(';'), function(v) {
|
273 |
+
var p = v.split('=');
|
274 |
+
|
275 |
+
cl.push({'title' : p[0], 'class' : p[1]});
|
276 |
+
});
|
277 |
+
} else
|
278 |
+
cl = tinyMCEPopup.editor.dom.getClasses();
|
279 |
+
|
280 |
+
if (cl.length > 0) {
|
281 |
+
lst.options.length = 0;
|
282 |
+
lst.options[lst.options.length] = new Option(tinyMCEPopup.getLang('not_set'), '');
|
283 |
+
|
284 |
+
tinymce.each(cl, function(o) {
|
285 |
+
lst.options[lst.options.length] = new Option(o.title || o['class'], o['class']);
|
286 |
+
});
|
287 |
+
} else
|
288 |
+
dom.remove(dom.getParent(id, 'tr'));
|
289 |
+
},
|
290 |
+
|
291 |
+
fillFileList : function(id, l) {
|
292 |
+
var dom = tinyMCEPopup.dom, lst = dom.get(id), v, cl;
|
293 |
+
|
294 |
+
l = typeof(l) === 'function' ? l() : window[l];
|
295 |
+
lst.options.length = 0;
|
296 |
+
|
297 |
+
if (l && l.length > 0) {
|
298 |
+
lst.options[lst.options.length] = new Option('', '');
|
299 |
+
|
300 |
+
tinymce.each(l, function(o) {
|
301 |
+
lst.options[lst.options.length] = new Option(o[0], o[1]);
|
302 |
+
});
|
303 |
+
} else
|
304 |
+
dom.remove(dom.getParent(id, 'tr'));
|
305 |
+
},
|
306 |
+
|
307 |
+
resetImageData : function() {
|
308 |
+
var f = document.forms[0];
|
309 |
+
|
310 |
+
f.elements.width.value = f.elements.height.value = '';
|
311 |
+
},
|
312 |
+
|
313 |
+
updateImageData : function(img, st) {
|
314 |
+
var f = document.forms[0];
|
315 |
+
|
316 |
+
if (!st) {
|
317 |
+
f.elements.width.value = img.width;
|
318 |
+
f.elements.height.value = img.height;
|
319 |
+
}
|
320 |
+
|
321 |
+
this.preloadImg = img;
|
322 |
+
},
|
323 |
+
|
324 |
+
changeAppearance : function() {
|
325 |
+
var ed = tinyMCEPopup.editor, f = document.forms[0], img = document.getElementById('alignSampleImg');
|
326 |
+
|
327 |
+
if (img) {
|
328 |
+
if (ed.getParam('inline_styles')) {
|
329 |
+
ed.dom.setAttrib(img, 'style', f.style.value);
|
330 |
+
} else {
|
331 |
+
img.align = f.align.value;
|
332 |
+
img.border = f.border.value;
|
333 |
+
img.hspace = f.hspace.value;
|
334 |
+
img.vspace = f.vspace.value;
|
335 |
+
}
|
336 |
+
}
|
337 |
+
},
|
338 |
+
|
339 |
+
changeHeight : function() {
|
340 |
+
var f = document.forms[0], tp, t = this;
|
341 |
+
|
342 |
+
if (!f.constrain.checked || !t.preloadImg) {
|
343 |
+
return;
|
344 |
+
}
|
345 |
+
|
346 |
+
if (f.width.value == "" || f.height.value == "")
|
347 |
+
return;
|
348 |
+
|
349 |
+
tp = (parseInt(f.width.value) / parseInt(t.preloadImg.width)) * t.preloadImg.height;
|
350 |
+
f.height.value = tp.toFixed(0);
|
351 |
+
},
|
352 |
+
|
353 |
+
changeWidth : function() {
|
354 |
+
var f = document.forms[0], tp, t = this;
|
355 |
+
|
356 |
+
if (!f.constrain.checked || !t.preloadImg) {
|
357 |
+
return;
|
358 |
+
}
|
359 |
+
|
360 |
+
if (f.width.value == "" || f.height.value == "")
|
361 |
+
return;
|
362 |
+
|
363 |
+
tp = (parseInt(f.height.value) / parseInt(t.preloadImg.height)) * t.preloadImg.width;
|
364 |
+
f.width.value = tp.toFixed(0);
|
365 |
+
},
|
366 |
+
|
367 |
+
updateStyle : function(ty) {
|
368 |
+
var dom = tinyMCEPopup.dom, b, bStyle, bColor, v, isIE = tinymce.isIE, f = document.forms[0], img = dom.create('img', {style : dom.get('style').value});
|
369 |
+
|
370 |
+
if (tinyMCEPopup.editor.settings.inline_styles) {
|
371 |
+
// Handle align
|
372 |
+
if (ty == 'align') {
|
373 |
+
dom.setStyle(img, 'float', '');
|
374 |
+
dom.setStyle(img, 'vertical-align', '');
|
375 |
+
|
376 |
+
v = getSelectValue(f, 'align');
|
377 |
+
if (v) {
|
378 |
+
if (v == 'left' || v == 'right')
|
379 |
+
dom.setStyle(img, 'float', v);
|
380 |
+
else
|
381 |
+
img.style.verticalAlign = v;
|
382 |
+
}
|
383 |
+
}
|
384 |
+
|
385 |
+
// Handle border
|
386 |
+
if (ty == 'border') {
|
387 |
+
b = img.style.border ? img.style.border.split(' ') : [];
|
388 |
+
bStyle = dom.getStyle(img, 'border-style');
|
389 |
+
bColor = dom.getStyle(img, 'border-color');
|
390 |
+
|
391 |
+
dom.setStyle(img, 'border', '');
|
392 |
+
|
393 |
+
v = f.border.value;
|
394 |
+
if (v || v == '0') {
|
395 |
+
if (v == '0')
|
396 |
+
img.style.border = isIE ? '0' : '0 none none';
|
397 |
+
else {
|
398 |
+
var isOldIE = tinymce.isIE && (!document.documentMode || document.documentMode < 9);
|
399 |
+
|
400 |
+
if (b.length == 3 && b[isOldIE ? 2 : 1])
|
401 |
+
bStyle = b[isOldIE ? 2 : 1];
|
402 |
+
else if (!bStyle || bStyle == 'none')
|
403 |
+
bStyle = 'solid';
|
404 |
+
if (b.length == 3 && b[isIE ? 0 : 2])
|
405 |
+
bColor = b[isOldIE ? 0 : 2];
|
406 |
+
else if (!bColor || bColor == 'none')
|
407 |
+
bColor = 'black';
|
408 |
+
img.style.border = v + 'px ' + bStyle + ' ' + bColor;
|
409 |
+
}
|
410 |
+
}
|
411 |
+
}
|
412 |
+
|
413 |
+
// Handle hspace
|
414 |
+
if (ty == 'hspace') {
|
415 |
+
dom.setStyle(img, 'marginLeft', '');
|
416 |
+
dom.setStyle(img, 'marginRight', '');
|
417 |
+
|
418 |
+
v = f.hspace.value;
|
419 |
+
if (v) {
|
420 |
+
img.style.marginLeft = v + 'px';
|
421 |
+
img.style.marginRight = v + 'px';
|
422 |
+
}
|
423 |
+
}
|
424 |
+
|
425 |
+
// Handle vspace
|
426 |
+
if (ty == 'vspace') {
|
427 |
+
dom.setStyle(img, 'marginTop', '');
|
428 |
+
dom.setStyle(img, 'marginBottom', '');
|
429 |
+
|
430 |
+
v = f.vspace.value;
|
431 |
+
if (v) {
|
432 |
+
img.style.marginTop = v + 'px';
|
433 |
+
img.style.marginBottom = v + 'px';
|
434 |
+
}
|
435 |
+
}
|
436 |
+
|
437 |
+
// Merge
|
438 |
+
dom.get('style').value = dom.serializeStyle(dom.parseStyle(img.style.cssText), 'img');
|
439 |
+
}
|
440 |
+
},
|
441 |
+
|
442 |
+
changeMouseMove : function() {
|
443 |
+
},
|
444 |
+
|
445 |
+
showPreviewImage : function(u, st) {
|
446 |
+
if (!u) {
|
447 |
+
tinyMCEPopup.dom.setHTML('prev', '');
|
448 |
+
return;
|
449 |
+
}
|
450 |
+
|
451 |
+
if (!st && tinyMCEPopup.getParam("advimage_update_dimensions_onchange", true))
|
452 |
+
this.resetImageData();
|
453 |
+
|
454 |
+
u = tinyMCEPopup.editor.documentBaseURI.toAbsolute(u);
|
455 |
+
|
456 |
+
if (!st)
|
457 |
+
tinyMCEPopup.dom.setHTML('prev', '<img id="previewImg" src="' + u + '" border="0" onload="ImageDialog.updateImageData(this);" onerror="ImageDialog.resetImageData();" />');
|
458 |
+
else
|
459 |
+
tinyMCEPopup.dom.setHTML('prev', '<img id="previewImg" src="' + u + '" border="0" onload="ImageDialog.updateImageData(this, 1);" />');
|
460 |
+
}
|
461 |
+
};
|
462 |
+
|
463 |
+
ImageDialog.preInit();
|
464 |
+
tinyMCEPopup.onInit.add(ImageDialog.init, ImageDialog);
|
mce/advimage/langs/de_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('de.advimage_dlg',{"image_list":"Bilderliste","align_right":"Rechts","align_left":"Links","align_textbottom":"Unten im Text","align_texttop":"Oben im Text","align_bottom":"Unten","align_middle":"Mittig","align_top":"Oben","align_baseline":"Zeile",align:"Ausrichtung",hspace:"Horizontaler Abstand",vspace:"Vertikaler Abstand",dimensions:"Ausma\u00dfe",border:"Rahmen",list:"Bilderliste",alt:"Beschreibung",src:"Adresse","dialog_title":"Bild einf\u00fcgen/ver\u00e4ndern","missing_alt":"
|
1 |
+
tinyMCE.addI18n('de.advimage_dlg',{"image_list":"Bilderliste","align_right":"Rechts","align_left":"Links","align_textbottom":"Unten im Text","align_texttop":"Oben im Text","align_bottom":"Unten","align_middle":"Mittig","align_top":"Oben","align_baseline":"Zeile",align:"Ausrichtung",hspace:"Horizontaler Abstand",vspace:"Vertikaler Abstand",dimensions:"Ausma\u00dfe",border:"Rahmen",list:"Bilderliste",alt:"Beschreibung",src:"Adresse","dialog_title":"Bild einf\u00fcgen/ver\u00e4ndern","missing_alt":"Soll wirklich keine Beschreibung f\u00fcr das Bild eingegeben werden? Bestimmte Benutzer mit k\u00f6rperlichen Einschr\u00e4nkungen k\u00f6nnen so nicht darauf zugreifen, ebenso solche, die einen Textbrowser benutzen oder die Anzeige von Bildern deaktiviert haben.","example_img":"Vorschau auf das Aussehen",misc:"Verschiedenes",mouseout:"bei keinem Mauskontakt",mouseover:"bei Mauskontakt","alt_image":"Alternatives Bild","swap_image":"Bild austauschen",map:"Image-Map",id:"ID",rtl:"Rechts nach links",ltr:"Links nach rechts",classes:"Klassen",style:"Format","long_desc":"Ausf\u00fchrliche Beschreibung",langcode:"Sprachcode",langdir:"Schriftrichtung","constrain_proportions":"Seitenverh\u00e4ltnis beibehalten",preview:"Vorschau",title:"Titel",general:"Allgemein","tab_advanced":"Erweitert","tab_appearance":"Aussehen","tab_general":"Allgemein",width:"Breite",height:"H\u00f6he"});
|
mce/advimage/langs/langs.php
CHANGED
@@ -1,9 +1,12 @@
|
|
1 |
-
<?php
|
2 |
-
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
-
|
4 |
-
if ( is_file($lang_file) &&
|
5 |
-
$
|
6 |
-
|
7 |
-
|
8 |
-
$strings =
|
9 |
-
}
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
+
|
4 |
+
if ( ! is_file( $lang_file ) && defined( 'TINYMCE_ADVANCED_LANGUAGES_PATH' ) )
|
5 |
+
$lang_file = TINYMCE_ADVANCED_LANGUAGES_PATH . 'advimage/langs/' . $mce_locale . '_dlg.js';
|
6 |
+
|
7 |
+
if ( is_file( $lang_file ) && is_readable( $lang_file ) ) {
|
8 |
+
$strings = tdav_get_file( $lang_file );
|
9 |
+
} else {
|
10 |
+
$strings = tdav_get_file( dirname(__FILE__) . '/en_dlg.js' );
|
11 |
+
$strings = preg_replace( '/([\'"])en\./', '$1' . $mce_locale . '.', $strings, 1 );
|
12 |
+
}
|
mce/advimage/langs/zh_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('zh.advimage_dlg',{"image_list":"\
|
1 |
+
tinyMCE.addI18n('zh.advimage_dlg',{"image_list":"\u56fe\u7247\u6e05\u5355","align_right":"\u9760\u53f3","align_left":"\u9760\u5de6","align_textbottom":"\u6587\u5b57\u4e0b\u65b9","align_texttop":"\u6587\u5b57\u4e0a\u65b9","align_bottom":"\u9760\u4e0b","align_middle":"\u5782\u76f4\u5c45\u4e2d","align_top":"\u9760\u4e0a","align_baseline":"\u57fa\u51c6\u7ebf",align:"\u5bf9\u9f50\u65b9\u5f0f",hspace:"\u6c34\u5e73\u95f4\u8ddd",vspace:"\u5782\u76f4\u95f4\u8ddd",dimensions:"\u5c3a\u5bf8",border:"\u8fb9\u6846",list:"\u56fe\u7247\u6e05\u5355",alt:"\u56fe\u7247\u8bf4\u660e",src:"\u56fe\u7247URL","dialog_title":"\u63d2\u5165/\u7f16\u8f91\u56fe\u7247","missing_alt":"\u60a8\u5c1a\u672a\u586b\u5199\u56fe\u7247\u8bf4\u660e\u6587\u5b57\uff0c\u662f\u5426\u8981\u7ee7\u7eed\uff1f\u5982\u679c\u4e0d\u586b\u5199\u8bf4\u660e\u6587\u5b57\uff0c\u5bf9\u4f7f\u7528\u975e\u53ef\u89c6\u6216\u5bf9\u8bbe\u5b9a\u4e3a\u4e0d\u663e\u793a\u56fe\u7247\u7684\u6d4f\u89c8\u5668\u4f7f\u7528\u8005\u5c06\u66f4\u96be\u9605\u8bfb\u6216\u7406\u89e3\u6b64\u56fe\u7247\u3002","example_img":"\u56fe\u7247\u9884\u89c8",misc:"\u5176\u5b83",mouseout:"\u9f20\u6807\u79fb\u51fa",mouseover:"\u9f20\u6807\u79fb\u5165","alt_image":"\u66ff\u4ee3\u56fe\u7247","swap_image":"\u56fe\u7247\u5207\u6362",map:"\u56fe\u7247\u70ed\u533a",id:"ID",rtl:"\u4ece\u53f3\u5230\u5de6",ltr:"\u4ece\u5de6\u5230\u53f3",classes:"\u7c7b",style:"\u6837\u5f0f","long_desc":"\u957f\u94fe\u63a5",langcode:"\u8bed\u8a00\u4ee3\u7801",langdir:"\u8bed\u8a00\u4e66\u5199\u65b9\u5411","constrain_proportions":"\u7ea6\u675f\u6bd4\u4f8b",preview:"\u9884\u89c8",title:"\u56fe\u7247\u6807\u9898",general:"\u666e\u901a","tab_advanced":"\u9ad8\u7ea7","tab_appearance":"\u5916\u89c2","tab_general":"\u666e\u901a",width:"\u5bbd",height:"\u9ad8"});
|
mce/advlink/css/advlink.css
CHANGED
@@ -1,8 +1,8 @@
|
|
1 |
-
.mceLinkList, .mceAnchorList, #targetlist {width:280px;}
|
2 |
-
.mceActionPanel {margin-top:7px;}
|
3 |
-
.panel_wrapper div.current {height:320px;}
|
4 |
-
#classlist, #title, #href {width:280px;}
|
5 |
-
#popupurl, #popupname {width:200px;}
|
6 |
-
#popupwidth, #popupheight, #popupleft, #popuptop {width:30px;vertical-align:middle;text-align:center;}
|
7 |
-
#id, #style, #classes, #target, #dir, #hreflang, #lang, #charset, #type, #rel, #rev, #tabindex, #accesskey {width:200px;}
|
8 |
-
#events_panel input {width:200px;}
|
1 |
+
.mceLinkList, .mceAnchorList, #targetlist {width:280px;}
|
2 |
+
.mceActionPanel {margin-top:7px;}
|
3 |
+
.panel_wrapper div.current {min-height:320px;height:auto;}
|
4 |
+
#classlist, #title, #href {width:280px;}
|
5 |
+
#popupurl, #popupname {width:200px;}
|
6 |
+
#popupwidth, #popupheight, #popupleft, #popuptop {width:30px;vertical-align:middle;text-align:center;}
|
7 |
+
#id, #style, #classes, #target, #dir, #hreflang, #lang, #charset, #type, #rel, #rev, #tabindex, #accesskey {width:200px;}
|
8 |
+
#events_panel input {width:200px;}
|
mce/advlink/js/advlink.js
CHANGED
@@ -1,543 +1,543 @@
|
|
1 |
-
/* Functions for the advlink plugin popup */
|
2 |
-
|
3 |
-
tinyMCEPopup.requireLangPack();
|
4 |
-
|
5 |
-
var templates = {
|
6 |
-
"window.open" : "window.open('${url}','${target}','${options}')"
|
7 |
-
};
|
8 |
-
|
9 |
-
function preinit() {
|
10 |
-
var url;
|
11 |
-
|
12 |
-
if (url = tinyMCEPopup.getParam("external_link_list_url"))
|
13 |
-
document.write('<script language="javascript" type="text/javascript" src="' + tinyMCEPopup.editor.documentBaseURI.toAbsolute(url) + '"></script>');
|
14 |
-
}
|
15 |
-
|
16 |
-
function changeClass() {
|
17 |
-
var f = document.forms[0];
|
18 |
-
|
19 |
-
f.classes.value = getSelectValue(f, 'classlist');
|
20 |
-
}
|
21 |
-
|
22 |
-
function init() {
|
23 |
-
tinyMCEPopup.resizeToInnerSize();
|
24 |
-
|
25 |
-
var formObj = document.forms[0];
|
26 |
-
var inst = tinyMCEPopup.editor;
|
27 |
-
var elm = inst.selection.getNode();
|
28 |
-
var action = "insert";
|
29 |
-
var html;
|
30 |
-
|
31 |
-
document.getElementById('hrefbrowsercontainer').innerHTML = getBrowserHTML('hrefbrowser','href','file','advlink');
|
32 |
-
document.getElementById('popupurlbrowsercontainer').innerHTML = getBrowserHTML('popupurlbrowser','popupurl','file','advlink');
|
33 |
-
document.getElementById('targetlistcontainer').innerHTML = getTargetListHTML('targetlist','target');
|
34 |
-
|
35 |
-
// Link list
|
36 |
-
html = getLinkListHTML('linklisthref','href');
|
37 |
-
if (html == "")
|
38 |
-
document.getElementById("linklisthrefrow").style.display = 'none';
|
39 |
-
else
|
40 |
-
document.getElementById("linklisthrefcontainer").innerHTML = html;
|
41 |
-
|
42 |
-
// Anchor list
|
43 |
-
html = getAnchorListHTML('anchorlist','href');
|
44 |
-
if (html == "")
|
45 |
-
document.getElementById("anchorlistrow").style.display = 'none';
|
46 |
-
else
|
47 |
-
document.getElementById("anchorlistcontainer").innerHTML = html;
|
48 |
-
|
49 |
-
// Resize some elements
|
50 |
-
if (isVisible('hrefbrowser'))
|
51 |
-
document.getElementById('href').style.width = '260px';
|
52 |
-
|
53 |
-
if (isVisible('popupurlbrowser'))
|
54 |
-
document.getElementById('popupurl').style.width = '180px';
|
55 |
-
|
56 |
-
elm = inst.dom.getParent(elm, "A");
|
57 |
-
if (elm == null) {
|
58 |
-
var prospect = inst.dom.create("p", null, inst.selection.getContent());
|
59 |
-
if (prospect.childNodes.length === 1) {
|
60 |
-
elm = prospect.firstChild;
|
61 |
-
}
|
62 |
-
}
|
63 |
-
|
64 |
-
if (elm != null && elm.nodeName == "A")
|
65 |
-
action = "update";
|
66 |
-
|
67 |
-
formObj.insert.value = tinyMCEPopup.getLang(action, 'Insert', true);
|
68 |
-
|
69 |
-
setPopupControlsDisabled(true);
|
70 |
-
|
71 |
-
if (action == "update") {
|
72 |
-
var href = inst.dom.getAttrib(elm, 'href');
|
73 |
-
var onclick = inst.dom.getAttrib(elm, 'onclick');
|
74 |
-
var linkTarget = inst.dom.getAttrib(elm, 'target') ? inst.dom.getAttrib(elm, 'target') : "_self";
|
75 |
-
|
76 |
-
// Setup form data
|
77 |
-
setFormValue('href', href);
|
78 |
-
setFormValue('title', inst.dom.getAttrib(elm, 'title'));
|
79 |
-
setFormValue('id', inst.dom.getAttrib(elm, 'id'));
|
80 |
-
setFormValue('style', inst.dom.getAttrib(elm, "style"));
|
81 |
-
setFormValue('rel', inst.dom.getAttrib(elm, 'rel'));
|
82 |
-
setFormValue('rev', inst.dom.getAttrib(elm, 'rev'));
|
83 |
-
setFormValue('charset', inst.dom.getAttrib(elm, 'charset'));
|
84 |
-
setFormValue('hreflang', inst.dom.getAttrib(elm, 'hreflang'));
|
85 |
-
setFormValue('dir', inst.dom.getAttrib(elm, 'dir'));
|
86 |
-
setFormValue('lang', inst.dom.getAttrib(elm, 'lang'));
|
87 |
-
setFormValue('tabindex', inst.dom.getAttrib(elm, 'tabindex', typeof(elm.tabindex) != "undefined" ? elm.tabindex : ""));
|
88 |
-
setFormValue('accesskey', inst.dom.getAttrib(elm, 'accesskey', typeof(elm.accesskey) != "undefined" ? elm.accesskey : ""));
|
89 |
-
setFormValue('type', inst.dom.getAttrib(elm, 'type'));
|
90 |
-
setFormValue('onfocus', inst.dom.getAttrib(elm, 'onfocus'));
|
91 |
-
setFormValue('onblur', inst.dom.getAttrib(elm, 'onblur'));
|
92 |
-
setFormValue('onclick', onclick);
|
93 |
-
setFormValue('ondblclick', inst.dom.getAttrib(elm, 'ondblclick'));
|
94 |
-
setFormValue('onmousedown', inst.dom.getAttrib(elm, 'onmousedown'));
|
95 |
-
setFormValue('onmouseup', inst.dom.getAttrib(elm, 'onmouseup'));
|
96 |
-
setFormValue('onmouseover', inst.dom.getAttrib(elm, 'onmouseover'));
|
97 |
-
setFormValue('onmousemove', inst.dom.getAttrib(elm, 'onmousemove'));
|
98 |
-
setFormValue('onmouseout', inst.dom.getAttrib(elm, 'onmouseout'));
|
99 |
-
setFormValue('onkeypress', inst.dom.getAttrib(elm, 'onkeypress'));
|
100 |
-
setFormValue('onkeydown', inst.dom.getAttrib(elm, 'onkeydown'));
|
101 |
-
setFormValue('onkeyup', inst.dom.getAttrib(elm, 'onkeyup'));
|
102 |
-
setFormValue('target', linkTarget);
|
103 |
-
setFormValue('classes', inst.dom.getAttrib(elm, 'class'));
|
104 |
-
|
105 |
-
// Parse onclick data
|
106 |
-
if (onclick != null && onclick.indexOf('window.open') != -1)
|
107 |
-
parseWindowOpen(onclick);
|
108 |
-
else
|
109 |
-
parseFunction(onclick);
|
110 |
-
|
111 |
-
// Select by the values
|
112 |
-
selectByValue(formObj, 'dir', inst.dom.getAttrib(elm, 'dir'));
|
113 |
-
selectByValue(formObj, 'rel', inst.dom.getAttrib(elm, 'rel'));
|
114 |
-
selectByValue(formObj, 'rev', inst.dom.getAttrib(elm, 'rev'));
|
115 |
-
selectByValue(formObj, 'linklisthref', href);
|
116 |
-
|
117 |
-
if (href.charAt(0) == '#')
|
118 |
-
selectByValue(formObj, 'anchorlist', href);
|
119 |
-
|
120 |
-
addClassesToList('classlist', 'advlink_styles');
|
121 |
-
|
122 |
-
selectByValue(formObj, 'classlist', inst.dom.getAttrib(elm, 'class'), true);
|
123 |
-
selectByValue(formObj, 'targetlist', linkTarget, true);
|
124 |
-
} else
|
125 |
-
addClassesToList('classlist', 'advlink_styles');
|
126 |
-
}
|
127 |
-
|
128 |
-
function checkPrefix(n) {
|
129 |
-
if (n.value && Validator.isEmail(n) && !/^\s*mailto:/i.test(n.value) && confirm(tinyMCEPopup.getLang('advlink_dlg.is_email')))
|
130 |
-
n.value = 'mailto:' + n.value;
|
131 |
-
|
132 |
-
if (/^\s*www\./i.test(n.value) && confirm(tinyMCEPopup.getLang('advlink_dlg.is_external')))
|
133 |
-
n.value = 'http://' + n.value;
|
134 |
-
}
|
135 |
-
|
136 |
-
function setFormValue(name, value) {
|
137 |
-
document.forms[0].elements[name].value = value;
|
138 |
-
}
|
139 |
-
|
140 |
-
function parseWindowOpen(onclick) {
|
141 |
-
var formObj = document.forms[0];
|
142 |
-
|
143 |
-
// Preprocess center code
|
144 |
-
if (onclick.indexOf('return false;') != -1) {
|
145 |
-
formObj.popupreturn.checked = true;
|
146 |
-
onclick = onclick.replace('return false;', '');
|
147 |
-
} else
|
148 |
-
formObj.popupreturn.checked = false;
|
149 |
-
|
150 |
-
var onClickData = parseLink(onclick);
|
151 |
-
|
152 |
-
if (onClickData != null) {
|
153 |
-
formObj.ispopup.checked = true;
|
154 |
-
setPopupControlsDisabled(false);
|
155 |
-
|
156 |
-
var onClickWindowOptions = parseOptions(onClickData['options']);
|
157 |
-
var url = onClickData['url'];
|
158 |
-
|
159 |
-
formObj.popupname.value = onClickData['target'];
|
160 |
-
formObj.popupurl.value = url;
|
161 |
-
formObj.popupwidth.value = getOption(onClickWindowOptions, 'width');
|
162 |
-
formObj.popupheight.value = getOption(onClickWindowOptions, 'height');
|
163 |
-
|
164 |
-
formObj.popupleft.value = getOption(onClickWindowOptions, 'left');
|
165 |
-
formObj.popuptop.value = getOption(onClickWindowOptions, 'top');
|
166 |
-
|
167 |
-
if (formObj.popupleft.value.indexOf('screen') != -1)
|
168 |
-
formObj.popupleft.value = "c";
|
169 |
-
|
170 |
-
if (formObj.popuptop.value.indexOf('screen') != -1)
|
171 |
-
formObj.popuptop.value = "c";
|
172 |
-
|
173 |
-
formObj.popuplocation.checked = getOption(onClickWindowOptions, 'location') == "yes";
|
174 |
-
formObj.popupscrollbars.checked = getOption(onClickWindowOptions, 'scrollbars') == "yes";
|
175 |
-
formObj.popupmenubar.checked = getOption(onClickWindowOptions, 'menubar') == "yes";
|
176 |
-
formObj.popupresizable.checked = getOption(onClickWindowOptions, 'resizable') == "yes";
|
177 |
-
formObj.popuptoolbar.checked = getOption(onClickWindowOptions, 'toolbar') == "yes";
|
178 |
-
formObj.popupstatus.checked = getOption(onClickWindowOptions, 'status') == "yes";
|
179 |
-
formObj.popupdependent.checked = getOption(onClickWindowOptions, 'dependent') == "yes";
|
180 |
-
|
181 |
-
buildOnClick();
|
182 |
-
}
|
183 |
-
}
|
184 |
-
|
185 |
-
function parseFunction(onclick) {
|
186 |
-
var formObj = document.forms[0];
|
187 |
-
var onClickData = parseLink(onclick);
|
188 |
-
|
189 |
-
// TODO: Add stuff here
|
190 |
-
}
|
191 |
-
|
192 |
-
function getOption(opts, name) {
|
193 |
-
return typeof(opts[name]) == "undefined" ? "" : opts[name];
|
194 |
-
}
|
195 |
-
|
196 |
-
function setPopupControlsDisabled(state) {
|
197 |
-
var formObj = document.forms[0];
|
198 |
-
|
199 |
-
formObj.popupname.disabled = state;
|
200 |
-
formObj.popupurl.disabled = state;
|
201 |
-
formObj.popupwidth.disabled = state;
|
202 |
-
formObj.popupheight.disabled = state;
|
203 |
-
formObj.popupleft.disabled = state;
|
204 |
-
formObj.popuptop.disabled = state;
|
205 |
-
formObj.popuplocation.disabled = state;
|
206 |
-
formObj.popupscrollbars.disabled = state;
|
207 |
-
formObj.popupmenubar.disabled = state;
|
208 |
-
formObj.popupresizable.disabled = state;
|
209 |
-
formObj.popuptoolbar.disabled = state;
|
210 |
-
formObj.popupstatus.disabled = state;
|
211 |
-
formObj.popupreturn.disabled = state;
|
212 |
-
formObj.popupdependent.disabled = state;
|
213 |
-
|
214 |
-
setBrowserDisabled('popupurlbrowser', state);
|
215 |
-
}
|
216 |
-
|
217 |
-
function parseLink(link) {
|
218 |
-
link = link.replace(new RegExp(''', 'g'), "'");
|
219 |
-
|
220 |
-
var fnName = link.replace(new RegExp("\\s*([A-Za-z0-9\.]*)\\s*\\(.*", "gi"), "$1");
|
221 |
-
|
222 |
-
// Is function name a template function
|
223 |
-
var template = templates[fnName];
|
224 |
-
if (template) {
|
225 |
-
// Build regexp
|
226 |
-
var variableNames = template.match(new RegExp("'?\\$\\{[A-Za-z0-9\.]*\\}'?", "gi"));
|
227 |
-
var regExp = "\\s*[A-Za-z0-9\.]*\\s*\\(";
|
228 |
-
var replaceStr = "";
|
229 |
-
for (var i=0; i<variableNames.length; i++) {
|
230 |
-
// Is string value
|
231 |
-
if (variableNames[i].indexOf("'${") != -1)
|
232 |
-
regExp += "'(.*)'";
|
233 |
-
else // Number value
|
234 |
-
regExp += "([0-9]*)";
|
235 |
-
|
236 |
-
replaceStr += "$" + (i+1);
|
237 |
-
|
238 |
-
// Cleanup variable name
|
239 |
-
variableNames[i] = variableNames[i].replace(new RegExp("[^A-Za-z0-9]", "gi"), "");
|
240 |
-
|
241 |
-
if (i != variableNames.length-1) {
|
242 |
-
regExp += "\\s*,\\s*";
|
243 |
-
replaceStr += "<delim>";
|
244 |
-
} else
|
245 |
-
regExp += ".*";
|
246 |
-
}
|
247 |
-
|
248 |
-
regExp += "\\);?";
|
249 |
-
|
250 |
-
// Build variable array
|
251 |
-
var variables = [];
|
252 |
-
variables["_function"] = fnName;
|
253 |
-
var variableValues = link.replace(new RegExp(regExp, "gi"), replaceStr).split('<delim>');
|
254 |
-
for (var i=0; i<variableNames.length; i++)
|
255 |
-
variables[variableNames[i]] = variableValues[i];
|
256 |
-
|
257 |
-
return variables;
|
258 |
-
}
|
259 |
-
|
260 |
-
return null;
|
261 |
-
}
|
262 |
-
|
263 |
-
function parseOptions(opts) {
|
264 |
-
if (opts == null || opts == "")
|
265 |
-
return [];
|
266 |
-
|
267 |
-
// Cleanup the options
|
268 |
-
opts = opts.toLowerCase();
|
269 |
-
opts = opts.replace(/;/g, ",");
|
270 |
-
opts = opts.replace(/[^0-9a-z=,]/g, "");
|
271 |
-
|
272 |
-
var optionChunks = opts.split(',');
|
273 |
-
var options = [];
|
274 |
-
|
275 |
-
for (var i=0; i<optionChunks.length; i++) {
|
276 |
-
var parts = optionChunks[i].split('=');
|
277 |
-
|
278 |
-
if (parts.length == 2)
|
279 |
-
options[parts[0]] = parts[1];
|
280 |
-
}
|
281 |
-
|
282 |
-
return options;
|
283 |
-
}
|
284 |
-
|
285 |
-
function buildOnClick() {
|
286 |
-
var formObj = document.forms[0];
|
287 |
-
|
288 |
-
if (!formObj.ispopup.checked) {
|
289 |
-
formObj.onclick.value = "";
|
290 |
-
return;
|
291 |
-
}
|
292 |
-
|
293 |
-
var onclick = "window.open('";
|
294 |
-
var url = formObj.popupurl.value;
|
295 |
-
|
296 |
-
onclick += url + "','";
|
297 |
-
onclick += formObj.popupname.value + "','";
|
298 |
-
|
299 |
-
if (formObj.popuplocation.checked)
|
300 |
-
onclick += "location=yes,";
|
301 |
-
|
302 |
-
if (formObj.popupscrollbars.checked)
|
303 |
-
onclick += "scrollbars=yes,";
|
304 |
-
|
305 |
-
if (formObj.popupmenubar.checked)
|
306 |
-
onclick += "menubar=yes,";
|
307 |
-
|
308 |
-
if (formObj.popupresizable.checked)
|
309 |
-
onclick += "resizable=yes,";
|
310 |
-
|
311 |
-
if (formObj.popuptoolbar.checked)
|
312 |
-
onclick += "toolbar=yes,";
|
313 |
-
|
314 |
-
if (formObj.popupstatus.checked)
|
315 |
-
onclick += "status=yes,";
|
316 |
-
|
317 |
-
if (formObj.popupdependent.checked)
|
318 |
-
onclick += "dependent=yes,";
|
319 |
-
|
320 |
-
if (formObj.popupwidth.value != "")
|
321 |
-
onclick += "width=" + formObj.popupwidth.value + ",";
|
322 |
-
|
323 |
-
if (formObj.popupheight.value != "")
|
324 |
-
onclick += "height=" + formObj.popupheight.value + ",";
|
325 |
-
|
326 |
-
if (formObj.popupleft.value != "") {
|
327 |
-
if (formObj.popupleft.value != "c")
|
328 |
-
onclick += "left=" + formObj.popupleft.value + ",";
|
329 |
-
else
|
330 |
-
onclick += "left='+(screen.availWidth/2-" + (formObj.popupwidth.value/2) + ")+',";
|
331 |
-
}
|
332 |
-
|
333 |
-
if (formObj.popuptop.value != "") {
|
334 |
-
if (formObj.popuptop.value != "c")
|
335 |
-
onclick += "top=" + formObj.popuptop.value + ",";
|
336 |
-
else
|
337 |
-
onclick += "top='+(screen.availHeight/2-" + (formObj.popupheight.value/2) + ")+',";
|
338 |
-
}
|
339 |
-
|
340 |
-
if (onclick.charAt(onclick.length-1) == ',')
|
341 |
-
onclick = onclick.substring(0, onclick.length-1);
|
342 |
-
|
343 |
-
onclick += "');";
|
344 |
-
|
345 |
-
if (formObj.popupreturn.checked)
|
346 |
-
onclick += "return false;";
|
347 |
-
|
348 |
-
// tinyMCE.debug(onclick);
|
349 |
-
|
350 |
-
formObj.onclick.value = onclick;
|
351 |
-
|
352 |
-
if (formObj.href.value == "")
|
353 |
-
formObj.href.value = url;
|
354 |
-
}
|
355 |
-
|
356 |
-
function setAttrib(elm, attrib, value) {
|
357 |
-
var formObj = document.forms[0];
|
358 |
-
var valueElm = formObj.elements[attrib.toLowerCase()];
|
359 |
-
var dom = tinyMCEPopup.editor.dom;
|
360 |
-
|
361 |
-
if (typeof(value) == "undefined" || value == null) {
|
362 |
-
value = "";
|
363 |
-
|
364 |
-
if (valueElm)
|
365 |
-
value = valueElm.value;
|
366 |
-
}
|
367 |
-
|
368 |
-
// Clean up the style
|
369 |
-
if (attrib == 'style')
|
370 |
-
value = dom.serializeStyle(dom.parseStyle(value), 'a');
|
371 |
-
|
372 |
-
dom.setAttrib(elm, attrib, value);
|
373 |
-
}
|
374 |
-
|
375 |
-
function getAnchorListHTML(id, target) {
|
376 |
-
var ed = tinyMCEPopup.editor, nodes = ed.dom.select('a'), name, i, len, html = "";
|
377 |
-
|
378 |
-
for (i=0, len=nodes.length; i<len; i++) {
|
379 |
-
if ((name = ed.dom.getAttrib(nodes[i], "name")) != "")
|
380 |
-
html += '<option value="#' + name + '">' + name + '</option>';
|
381 |
-
|
382 |
-
if ((name = nodes[i].id) != "" && !nodes[i].href)
|
383 |
-
html += '<option value="#' + name + '">' + name + '</option>';
|
384 |
-
}
|
385 |
-
|
386 |
-
if (html == "")
|
387 |
-
return "";
|
388 |
-
|
389 |
-
html = '<select id="' + id + '" name="' + id + '" class="mceAnchorList"'
|
390 |
-
+ ' onchange="this.form.' + target + '.value=this.options[this.selectedIndex].value"'
|
391 |
-
+ '>'
|
392 |
-
+ '<option value="">---</option>'
|
393 |
-
+ html
|
394 |
-
+ '</select>';
|
395 |
-
|
396 |
-
return html;
|
397 |
-
}
|
398 |
-
|
399 |
-
function insertAction() {
|
400 |
-
var inst = tinyMCEPopup.editor;
|
401 |
-
var elm, elementArray, i;
|
402 |
-
|
403 |
-
elm = inst.selection.getNode();
|
404 |
-
checkPrefix(document.forms[0].href);
|
405 |
-
|
406 |
-
elm = inst.dom.getParent(elm, "A");
|
407 |
-
|
408 |
-
// Remove element if there is no href
|
409 |
-
if (!document.forms[0].href.value) {
|
410 |
-
i = inst.selection.getBookmark();
|
411 |
-
inst.dom.remove(elm, 1);
|
412 |
-
inst.selection.moveToBookmark(i);
|
413 |
-
tinyMCEPopup.execCommand("mceEndUndoLevel");
|
414 |
-
tinyMCEPopup.close();
|
415 |
-
return;
|
416 |
-
}
|
417 |
-
|
418 |
-
// Create new anchor elements
|
419 |
-
if (elm == null) {
|
420 |
-
inst.getDoc().execCommand("unlink", false, null);
|
421 |
-
tinyMCEPopup.execCommand("mceInsertLink", false, "#mce_temp_url#", {skip_undo : 1});
|
422 |
-
|
423 |
-
elementArray = tinymce.grep(inst.dom.select("a"), function(n) {return inst.dom.getAttrib(n, 'href') == '#mce_temp_url#';});
|
424 |
-
for (i=0; i<elementArray.length; i++)
|
425 |
-
setAllAttribs(elm = elementArray[i]);
|
426 |
-
} else
|
427 |
-
setAllAttribs(elm);
|
428 |
-
|
429 |
-
// Don't move caret if selection was image
|
430 |
-
if (elm.childNodes.length != 1 || elm.firstChild.nodeName != 'IMG') {
|
431 |
-
inst.focus();
|
432 |
-
inst.selection.select(elm);
|
433 |
-
inst.selection.collapse(0);
|
434 |
-
tinyMCEPopup.storeSelection();
|
435 |
-
}
|
436 |
-
|
437 |
-
tinyMCEPopup.execCommand("mceEndUndoLevel");
|
438 |
-
tinyMCEPopup.close();
|
439 |
-
}
|
440 |
-
|
441 |
-
function setAllAttribs(elm) {
|
442 |
-
var formObj = document.forms[0];
|
443 |
-
var href = formObj.href.value.replace(/ /g, '%20');
|
444 |
-
var target = getSelectValue(formObj, 'targetlist');
|
445 |
-
|
446 |
-
setAttrib(elm, 'href', href);
|
447 |
-
setAttrib(elm, 'title');
|
448 |
-
setAttrib(elm, 'target', target == '_self' ? '' : target);
|
449 |
-
setAttrib(elm, 'id');
|
450 |
-
setAttrib(elm, 'style');
|
451 |
-
setAttrib(elm, 'class', getSelectValue(formObj, 'classlist'));
|
452 |
-
setAttrib(elm, 'rel');
|
453 |
-
setAttrib(elm, 'rev');
|
454 |
-
setAttrib(elm, 'charset');
|
455 |
-
setAttrib(elm, 'hreflang');
|
456 |
-
setAttrib(elm, 'dir');
|
457 |
-
setAttrib(elm, 'lang');
|
458 |
-
setAttrib(elm, 'tabindex');
|
459 |
-
setAttrib(elm, 'accesskey');
|
460 |
-
setAttrib(elm, 'type');
|
461 |
-
setAttrib(elm, 'onfocus');
|
462 |
-
setAttrib(elm, 'onblur');
|
463 |
-
setAttrib(elm, 'onclick');
|
464 |
-
setAttrib(elm, 'ondblclick');
|
465 |
-
setAttrib(elm, 'onmousedown');
|
466 |
-
setAttrib(elm, 'onmouseup');
|
467 |
-
setAttrib(elm, 'onmouseover');
|
468 |
-
setAttrib(elm, 'onmousemove');
|
469 |
-
setAttrib(elm, 'onmouseout');
|
470 |
-
setAttrib(elm, 'onkeypress');
|
471 |
-
setAttrib(elm, 'onkeydown');
|
472 |
-
setAttrib(elm, 'onkeyup');
|
473 |
-
|
474 |
-
// Refresh in old MSIE
|
475 |
-
if (tinyMCE.isMSIE5)
|
476 |
-
elm.outerHTML = elm.outerHTML;
|
477 |
-
}
|
478 |
-
|
479 |
-
function getSelectValue(form_obj, field_name) {
|
480 |
-
var elm = form_obj.elements[field_name];
|
481 |
-
|
482 |
-
if (!elm || elm.options == null || elm.selectedIndex == -1)
|
483 |
-
return "";
|
484 |
-
|
485 |
-
return elm.options[elm.selectedIndex].value;
|
486 |
-
}
|
487 |
-
|
488 |
-
function getLinkListHTML(elm_id, target_form_element, onchange_func) {
|
489 |
-
if (typeof(tinyMCELinkList) == "undefined" || tinyMCELinkList.length == 0)
|
490 |
-
return "";
|
491 |
-
|
492 |
-
var html = "";
|
493 |
-
|
494 |
-
html += '<select id="' + elm_id + '" name="' + elm_id + '"';
|
495 |
-
html += ' class="mceLinkList" onchange="this.form.' + target_form_element + '.value=';
|
496 |
-
html += 'this.options[this.selectedIndex].value;';
|
497 |
-
|
498 |
-
if (typeof(onchange_func) != "undefined")
|
499 |
-
html += onchange_func + '(\'' + target_form_element + '\',this.options[this.selectedIndex].text,this.options[this.selectedIndex].value);';
|
500 |
-
|
501 |
-
html += '"><option value="">---</option>';
|
502 |
-
|
503 |
-
for (var i=0; i<tinyMCELinkList.length; i++)
|
504 |
-
html += '<option value="' + tinyMCELinkList[i][1] + '">' + tinyMCELinkList[i][0] + '</option>';
|
505 |
-
|
506 |
-
html += '</select>';
|
507 |
-
|
508 |
-
return html;
|
509 |
-
|
510 |
-
// tinyMCE.debug('-- image list start --', html, '-- image list end --');
|
511 |
-
}
|
512 |
-
|
513 |
-
function getTargetListHTML(elm_id, target_form_element) {
|
514 |
-
var targets = tinyMCEPopup.getParam('theme_advanced_link_targets', '').split(';');
|
515 |
-
var html = '';
|
516 |
-
|
517 |
-
html += '<select id="' + elm_id + '" name="' + elm_id + '" onchange="this.form.' + target_form_element + '.value=';
|
518 |
-
html += 'this.options[this.selectedIndex].value;">';
|
519 |
-
html += '<option value="_self">' + tinyMCEPopup.getLang('advlink_dlg.target_same') + '</option>';
|
520 |
-
html += '<option value="_blank">' + tinyMCEPopup.getLang('advlink_dlg.target_blank') + ' (_blank)</option>';
|
521 |
-
html += '<option value="_parent">' + tinyMCEPopup.getLang('advlink_dlg.target_parent') + ' (_parent)</option>';
|
522 |
-
html += '<option value="_top">' + tinyMCEPopup.getLang('advlink_dlg.target_top') + ' (_top)</option>';
|
523 |
-
|
524 |
-
for (var i=0; i<targets.length; i++) {
|
525 |
-
var key, value;
|
526 |
-
|
527 |
-
if (targets[i] == "")
|
528 |
-
continue;
|
529 |
-
|
530 |
-
key = targets[i].split('=')[0];
|
531 |
-
value = targets[i].split('=')[1];
|
532 |
-
|
533 |
-
html += '<option value="' + key + '">' + value + ' (' + key + ')</option>';
|
534 |
-
}
|
535 |
-
|
536 |
-
html += '</select>';
|
537 |
-
|
538 |
-
return html;
|
539 |
-
}
|
540 |
-
|
541 |
-
// While loading
|
542 |
-
preinit();
|
543 |
-
tinyMCEPopup.onInit.add(init);
|
1 |
+
/* Functions for the advlink plugin popup */
|
2 |
+
|
3 |
+
tinyMCEPopup.requireLangPack();
|
4 |
+
|
5 |
+
var templates = {
|
6 |
+
"window.open" : "window.open('${url}','${target}','${options}')"
|
7 |
+
};
|
8 |
+
|
9 |
+
function preinit() {
|
10 |
+
var url;
|
11 |
+
|
12 |
+
if (url = tinyMCEPopup.getParam("external_link_list_url"))
|
13 |
+
document.write('<script language="javascript" type="text/javascript" src="' + tinyMCEPopup.editor.documentBaseURI.toAbsolute(url) + '"></script>');
|
14 |
+
}
|
15 |
+
|
16 |
+
function changeClass() {
|
17 |
+
var f = document.forms[0];
|
18 |
+
|
19 |
+
f.classes.value = getSelectValue(f, 'classlist');
|
20 |
+
}
|
21 |
+
|
22 |
+
function init() {
|
23 |
+
tinyMCEPopup.resizeToInnerSize();
|
24 |
+
|
25 |
+
var formObj = document.forms[0];
|
26 |
+
var inst = tinyMCEPopup.editor;
|
27 |
+
var elm = inst.selection.getNode();
|
28 |
+
var action = "insert";
|
29 |
+
var html;
|
30 |
+
|
31 |
+
document.getElementById('hrefbrowsercontainer').innerHTML = getBrowserHTML('hrefbrowser','href','file','advlink');
|
32 |
+
document.getElementById('popupurlbrowsercontainer').innerHTML = getBrowserHTML('popupurlbrowser','popupurl','file','advlink');
|
33 |
+
document.getElementById('targetlistcontainer').innerHTML = getTargetListHTML('targetlist','target');
|
34 |
+
|
35 |
+
// Link list
|
36 |
+
html = getLinkListHTML('linklisthref','href');
|
37 |
+
if (html == "")
|
38 |
+
document.getElementById("linklisthrefrow").style.display = 'none';
|
39 |
+
else
|
40 |
+
document.getElementById("linklisthrefcontainer").innerHTML = html;
|
41 |
+
|
42 |
+
// Anchor list
|
43 |
+
html = getAnchorListHTML('anchorlist','href');
|
44 |
+
if (html == "")
|
45 |
+
document.getElementById("anchorlistrow").style.display = 'none';
|
46 |
+
else
|
47 |
+
document.getElementById("anchorlistcontainer").innerHTML = html;
|
48 |
+
|
49 |
+
// Resize some elements
|
50 |
+
if (isVisible('hrefbrowser'))
|
51 |
+
document.getElementById('href').style.width = '260px';
|
52 |
+
|
53 |
+
if (isVisible('popupurlbrowser'))
|
54 |
+
document.getElementById('popupurl').style.width = '180px';
|
55 |
+
|
56 |
+
elm = inst.dom.getParent(elm, "A");
|
57 |
+
if (elm == null) {
|
58 |
+
var prospect = inst.dom.create("p", null, inst.selection.getContent());
|
59 |
+
if (prospect.childNodes.length === 1) {
|
60 |
+
elm = prospect.firstChild;
|
61 |
+
}
|
62 |
+
}
|
63 |
+
|
64 |
+
if (elm != null && elm.nodeName == "A")
|
65 |
+
action = "update";
|
66 |
+
|
67 |
+
formObj.insert.value = tinyMCEPopup.getLang(action, 'Insert', true);
|
68 |
+
|
69 |
+
setPopupControlsDisabled(true);
|
70 |
+
|
71 |
+
if (action == "update") {
|
72 |
+
var href = inst.dom.getAttrib(elm, 'href');
|
73 |
+
var onclick = inst.dom.getAttrib(elm, 'onclick');
|
74 |
+
var linkTarget = inst.dom.getAttrib(elm, 'target') ? inst.dom.getAttrib(elm, 'target') : "_self";
|
75 |
+
|
76 |
+
// Setup form data
|
77 |
+
setFormValue('href', href);
|
78 |
+
setFormValue('title', inst.dom.getAttrib(elm, 'title'));
|
79 |
+
setFormValue('id', inst.dom.getAttrib(elm, 'id'));
|
80 |
+
setFormValue('style', inst.dom.getAttrib(elm, "style"));
|
81 |
+
setFormValue('rel', inst.dom.getAttrib(elm, 'rel'));
|
82 |
+
setFormValue('rev', inst.dom.getAttrib(elm, 'rev'));
|
83 |
+
setFormValue('charset', inst.dom.getAttrib(elm, 'charset'));
|
84 |
+
setFormValue('hreflang', inst.dom.getAttrib(elm, 'hreflang'));
|
85 |
+
setFormValue('dir', inst.dom.getAttrib(elm, 'dir'));
|
86 |
+
setFormValue('lang', inst.dom.getAttrib(elm, 'lang'));
|
87 |
+
setFormValue('tabindex', inst.dom.getAttrib(elm, 'tabindex', typeof(elm.tabindex) != "undefined" ? elm.tabindex : ""));
|
88 |
+
setFormValue('accesskey', inst.dom.getAttrib(elm, 'accesskey', typeof(elm.accesskey) != "undefined" ? elm.accesskey : ""));
|
89 |
+
setFormValue('type', inst.dom.getAttrib(elm, 'type'));
|
90 |
+
setFormValue('onfocus', inst.dom.getAttrib(elm, 'onfocus'));
|
91 |
+
setFormValue('onblur', inst.dom.getAttrib(elm, 'onblur'));
|
92 |
+
setFormValue('onclick', onclick);
|
93 |
+
setFormValue('ondblclick', inst.dom.getAttrib(elm, 'ondblclick'));
|
94 |
+
setFormValue('onmousedown', inst.dom.getAttrib(elm, 'onmousedown'));
|
95 |
+
setFormValue('onmouseup', inst.dom.getAttrib(elm, 'onmouseup'));
|
96 |
+
setFormValue('onmouseover', inst.dom.getAttrib(elm, 'onmouseover'));
|
97 |
+
setFormValue('onmousemove', inst.dom.getAttrib(elm, 'onmousemove'));
|
98 |
+
setFormValue('onmouseout', inst.dom.getAttrib(elm, 'onmouseout'));
|
99 |
+
setFormValue('onkeypress', inst.dom.getAttrib(elm, 'onkeypress'));
|
100 |
+
setFormValue('onkeydown', inst.dom.getAttrib(elm, 'onkeydown'));
|
101 |
+
setFormValue('onkeyup', inst.dom.getAttrib(elm, 'onkeyup'));
|
102 |
+
setFormValue('target', linkTarget);
|
103 |
+
setFormValue('classes', inst.dom.getAttrib(elm, 'class'));
|
104 |
+
|
105 |
+
// Parse onclick data
|
106 |
+
if (onclick != null && onclick.indexOf('window.open') != -1)
|
107 |
+
parseWindowOpen(onclick);
|
108 |
+
else
|
109 |
+
parseFunction(onclick);
|
110 |
+
|
111 |
+
// Select by the values
|
112 |
+
selectByValue(formObj, 'dir', inst.dom.getAttrib(elm, 'dir'));
|
113 |
+
selectByValue(formObj, 'rel', inst.dom.getAttrib(elm, 'rel'));
|
114 |
+
selectByValue(formObj, 'rev', inst.dom.getAttrib(elm, 'rev'));
|
115 |
+
selectByValue(formObj, 'linklisthref', href);
|
116 |
+
|
117 |
+
if (href.charAt(0) == '#')
|
118 |
+
selectByValue(formObj, 'anchorlist', href);
|
119 |
+
|
120 |
+
addClassesToList('classlist', 'advlink_styles');
|
121 |
+
|
122 |
+
selectByValue(formObj, 'classlist', inst.dom.getAttrib(elm, 'class'), true);
|
123 |
+
selectByValue(formObj, 'targetlist', linkTarget, true);
|
124 |
+
} else
|
125 |
+
addClassesToList('classlist', 'advlink_styles');
|
126 |
+
}
|
127 |
+
|
128 |
+
function checkPrefix(n) {
|
129 |
+
if (n.value && Validator.isEmail(n) && !/^\s*mailto:/i.test(n.value) && confirm(tinyMCEPopup.getLang('advlink_dlg.is_email')))
|
130 |
+
n.value = 'mailto:' + n.value;
|
131 |
+
|
132 |
+
if (/^\s*www\./i.test(n.value) && confirm(tinyMCEPopup.getLang('advlink_dlg.is_external')))
|
133 |
+
n.value = 'http://' + n.value;
|
134 |
+
}
|
135 |
+
|
136 |
+
function setFormValue(name, value) {
|
137 |
+
document.forms[0].elements[name].value = value;
|
138 |
+
}
|
139 |
+
|
140 |
+
function parseWindowOpen(onclick) {
|
141 |
+
var formObj = document.forms[0];
|
142 |
+
|
143 |
+
// Preprocess center code
|
144 |
+
if (onclick.indexOf('return false;') != -1) {
|
145 |
+
formObj.popupreturn.checked = true;
|
146 |
+
onclick = onclick.replace('return false;', '');
|
147 |
+
} else
|
148 |
+
formObj.popupreturn.checked = false;
|
149 |
+
|
150 |
+
var onClickData = parseLink(onclick);
|
151 |
+
|
152 |
+
if (onClickData != null) {
|
153 |
+
formObj.ispopup.checked = true;
|
154 |
+
setPopupControlsDisabled(false);
|
155 |
+
|
156 |
+
var onClickWindowOptions = parseOptions(onClickData['options']);
|
157 |
+
var url = onClickData['url'];
|
158 |
+
|
159 |
+
formObj.popupname.value = onClickData['target'];
|
160 |
+
formObj.popupurl.value = url;
|
161 |
+
formObj.popupwidth.value = getOption(onClickWindowOptions, 'width');
|
162 |
+
formObj.popupheight.value = getOption(onClickWindowOptions, 'height');
|
163 |
+
|
164 |
+
formObj.popupleft.value = getOption(onClickWindowOptions, 'left');
|
165 |
+
formObj.popuptop.value = getOption(onClickWindowOptions, 'top');
|
166 |
+
|
167 |
+
if (formObj.popupleft.value.indexOf('screen') != -1)
|
168 |
+
formObj.popupleft.value = "c";
|
169 |
+
|
170 |
+
if (formObj.popuptop.value.indexOf('screen') != -1)
|
171 |
+
formObj.popuptop.value = "c";
|
172 |
+
|
173 |
+
formObj.popuplocation.checked = getOption(onClickWindowOptions, 'location') == "yes";
|
174 |
+
formObj.popupscrollbars.checked = getOption(onClickWindowOptions, 'scrollbars') == "yes";
|
175 |
+
formObj.popupmenubar.checked = getOption(onClickWindowOptions, 'menubar') == "yes";
|
176 |
+
formObj.popupresizable.checked = getOption(onClickWindowOptions, 'resizable') == "yes";
|
177 |
+
formObj.popuptoolbar.checked = getOption(onClickWindowOptions, 'toolbar') == "yes";
|
178 |
+
formObj.popupstatus.checked = getOption(onClickWindowOptions, 'status') == "yes";
|
179 |
+
formObj.popupdependent.checked = getOption(onClickWindowOptions, 'dependent') == "yes";
|
180 |
+
|
181 |
+
buildOnClick();
|
182 |
+
}
|
183 |
+
}
|
184 |
+
|
185 |
+
function parseFunction(onclick) {
|
186 |
+
var formObj = document.forms[0];
|
187 |
+
var onClickData = parseLink(onclick);
|
188 |
+
|
189 |
+
// TODO: Add stuff here
|
190 |
+
}
|
191 |
+
|
192 |
+
function getOption(opts, name) {
|
193 |
+
return typeof(opts[name]) == "undefined" ? "" : opts[name];
|
194 |
+
}
|
195 |
+
|
196 |
+
function setPopupControlsDisabled(state) {
|
197 |
+
var formObj = document.forms[0];
|
198 |
+
|
199 |
+
formObj.popupname.disabled = state;
|
200 |
+
formObj.popupurl.disabled = state;
|
201 |
+
formObj.popupwidth.disabled = state;
|
202 |
+
formObj.popupheight.disabled = state;
|
203 |
+
formObj.popupleft.disabled = state;
|
204 |
+
formObj.popuptop.disabled = state;
|
205 |
+
formObj.popuplocation.disabled = state;
|
206 |
+
formObj.popupscrollbars.disabled = state;
|
207 |
+
formObj.popupmenubar.disabled = state;
|
208 |
+
formObj.popupresizable.disabled = state;
|
209 |
+
formObj.popuptoolbar.disabled = state;
|
210 |
+
formObj.popupstatus.disabled = state;
|
211 |
+
formObj.popupreturn.disabled = state;
|
212 |
+
formObj.popupdependent.disabled = state;
|
213 |
+
|
214 |
+
setBrowserDisabled('popupurlbrowser', state);
|
215 |
+
}
|
216 |
+
|
217 |
+
function parseLink(link) {
|
218 |
+
link = link.replace(new RegExp(''', 'g'), "'");
|
219 |
+
|
220 |
+
var fnName = link.replace(new RegExp("\\s*([A-Za-z0-9\.]*)\\s*\\(.*", "gi"), "$1");
|
221 |
+
|
222 |
+
// Is function name a template function
|
223 |
+
var template = templates[fnName];
|
224 |
+
if (template) {
|
225 |
+
// Build regexp
|
226 |
+
var variableNames = template.match(new RegExp("'?\\$\\{[A-Za-z0-9\.]*\\}'?", "gi"));
|
227 |
+
var regExp = "\\s*[A-Za-z0-9\.]*\\s*\\(";
|
228 |
+
var replaceStr = "";
|
229 |
+
for (var i=0; i<variableNames.length; i++) {
|
230 |
+
// Is string value
|
231 |
+
if (variableNames[i].indexOf("'${") != -1)
|
232 |
+
regExp += "'(.*)'";
|
233 |
+
else // Number value
|
234 |
+
regExp += "([0-9]*)";
|
235 |
+
|
236 |
+
replaceStr += "$" + (i+1);
|
237 |
+
|
238 |
+
// Cleanup variable name
|
239 |
+
variableNames[i] = variableNames[i].replace(new RegExp("[^A-Za-z0-9]", "gi"), "");
|
240 |
+
|
241 |
+
if (i != variableNames.length-1) {
|
242 |
+
regExp += "\\s*,\\s*";
|
243 |
+
replaceStr += "<delim>";
|
244 |
+
} else
|
245 |
+
regExp += ".*";
|
246 |
+
}
|
247 |
+
|
248 |
+
regExp += "\\);?";
|
249 |
+
|
250 |
+
// Build variable array
|
251 |
+
var variables = [];
|
252 |
+
variables["_function"] = fnName;
|
253 |
+
var variableValues = link.replace(new RegExp(regExp, "gi"), replaceStr).split('<delim>');
|
254 |
+
for (var i=0; i<variableNames.length; i++)
|
255 |
+
variables[variableNames[i]] = variableValues[i];
|
256 |
+
|
257 |
+
return variables;
|
258 |
+
}
|
259 |
+
|
260 |
+
return null;
|
261 |
+
}
|
262 |
+
|
263 |
+
function parseOptions(opts) {
|
264 |
+
if (opts == null || opts == "")
|
265 |
+
return [];
|
266 |
+
|
267 |
+
// Cleanup the options
|
268 |
+
opts = opts.toLowerCase();
|
269 |
+
opts = opts.replace(/;/g, ",");
|
270 |
+
opts = opts.replace(/[^0-9a-z=,]/g, "");
|
271 |
+
|
272 |
+
var optionChunks = opts.split(',');
|
273 |
+
var options = [];
|
274 |
+
|
275 |
+
for (var i=0; i<optionChunks.length; i++) {
|
276 |
+
var parts = optionChunks[i].split('=');
|
277 |
+
|
278 |
+
if (parts.length == 2)
|
279 |
+
options[parts[0]] = parts[1];
|
280 |
+
}
|
281 |
+
|
282 |
+
return options;
|
283 |
+
}
|
284 |
+
|
285 |
+
function buildOnClick() {
|
286 |
+
var formObj = document.forms[0];
|
287 |
+
|
288 |
+
if (!formObj.ispopup.checked) {
|
289 |
+
formObj.onclick.value = "";
|
290 |
+
return;
|
291 |
+
}
|
292 |
+
|
293 |
+
var onclick = "window.open('";
|
294 |
+
var url = formObj.popupurl.value;
|
295 |
+
|
296 |
+
onclick += url + "','";
|
297 |
+
onclick += formObj.popupname.value + "','";
|
298 |
+
|
299 |
+
if (formObj.popuplocation.checked)
|
300 |
+
onclick += "location=yes,";
|
301 |
+
|
302 |
+
if (formObj.popupscrollbars.checked)
|
303 |
+
onclick += "scrollbars=yes,";
|
304 |
+
|
305 |
+
if (formObj.popupmenubar.checked)
|
306 |
+
onclick += "menubar=yes,";
|
307 |
+
|
308 |
+
if (formObj.popupresizable.checked)
|
309 |
+
onclick += "resizable=yes,";
|
310 |
+
|
311 |
+
if (formObj.popuptoolbar.checked)
|
312 |
+
onclick += "toolbar=yes,";
|
313 |
+
|
314 |
+
if (formObj.popupstatus.checked)
|
315 |
+
onclick += "status=yes,";
|
316 |
+
|
317 |
+
if (formObj.popupdependent.checked)
|
318 |
+
onclick += "dependent=yes,";
|
319 |
+
|
320 |
+
if (formObj.popupwidth.value != "")
|
321 |
+
onclick += "width=" + formObj.popupwidth.value + ",";
|
322 |
+
|
323 |
+
if (formObj.popupheight.value != "")
|
324 |
+
onclick += "height=" + formObj.popupheight.value + ",";
|
325 |
+
|
326 |
+
if (formObj.popupleft.value != "") {
|
327 |
+
if (formObj.popupleft.value != "c")
|
328 |
+
onclick += "left=" + formObj.popupleft.value + ",";
|
329 |
+
else
|
330 |
+
onclick += "left='+(screen.availWidth/2-" + (formObj.popupwidth.value/2) + ")+',";
|
331 |
+
}
|
332 |
+
|
333 |
+
if (formObj.popuptop.value != "") {
|
334 |
+
if (formObj.popuptop.value != "c")
|
335 |
+
onclick += "top=" + formObj.popuptop.value + ",";
|
336 |
+
else
|
337 |
+
onclick += "top='+(screen.availHeight/2-" + (formObj.popupheight.value/2) + ")+',";
|
338 |
+
}
|
339 |
+
|
340 |
+
if (onclick.charAt(onclick.length-1) == ',')
|
341 |
+
onclick = onclick.substring(0, onclick.length-1);
|
342 |
+
|
343 |
+
onclick += "');";
|
344 |
+
|
345 |
+
if (formObj.popupreturn.checked)
|
346 |
+
onclick += "return false;";
|
347 |
+
|
348 |
+
// tinyMCE.debug(onclick);
|
349 |
+
|
350 |
+
formObj.onclick.value = onclick;
|
351 |
+
|
352 |
+
if (formObj.href.value == "")
|
353 |
+
formObj.href.value = url;
|
354 |
+
}
|
355 |
+
|
356 |
+
function setAttrib(elm, attrib, value) {
|
357 |
+
var formObj = document.forms[0];
|
358 |
+
var valueElm = formObj.elements[attrib.toLowerCase()];
|
359 |
+
var dom = tinyMCEPopup.editor.dom;
|
360 |
+
|
361 |
+
if (typeof(value) == "undefined" || value == null) {
|
362 |
+
value = "";
|
363 |
+
|
364 |
+
if (valueElm)
|
365 |
+
value = valueElm.value;
|
366 |
+
}
|
367 |
+
|
368 |
+
// Clean up the style
|
369 |
+
if (attrib == 'style')
|
370 |
+
value = dom.serializeStyle(dom.parseStyle(value), 'a');
|
371 |
+
|
372 |
+
dom.setAttrib(elm, attrib, value);
|
373 |
+
}
|
374 |
+
|
375 |
+
function getAnchorListHTML(id, target) {
|
376 |
+
var ed = tinyMCEPopup.editor, nodes = ed.dom.select('a'), name, i, len, html = "";
|
377 |
+
|
378 |
+
for (i=0, len=nodes.length; i<len; i++) {
|
379 |
+
if ((name = ed.dom.getAttrib(nodes[i], "name")) != "")
|
380 |
+
html += '<option value="#' + name + '">' + name + '</option>';
|
381 |
+
|
382 |
+
if ((name = nodes[i].id) != "" && !nodes[i].href)
|
383 |
+
html += '<option value="#' + name + '">' + name + '</option>';
|
384 |
+
}
|
385 |
+
|
386 |
+
if (html == "")
|
387 |
+
return "";
|
388 |
+
|
389 |
+
html = '<select id="' + id + '" name="' + id + '" class="mceAnchorList"'
|
390 |
+
+ ' onchange="this.form.' + target + '.value=this.options[this.selectedIndex].value"'
|
391 |
+
+ '>'
|
392 |
+
+ '<option value="">---</option>'
|
393 |
+
+ html
|
394 |
+
+ '</select>';
|
395 |
+
|
396 |
+
return html;
|
397 |
+
}
|
398 |
+
|
399 |
+
function insertAction() {
|
400 |
+
var inst = tinyMCEPopup.editor;
|
401 |
+
var elm, elementArray, i;
|
402 |
+
|
403 |
+
elm = inst.selection.getNode();
|
404 |
+
checkPrefix(document.forms[0].href);
|
405 |
+
|
406 |
+
elm = inst.dom.getParent(elm, "A");
|
407 |
+
|
408 |
+
// Remove element if there is no href
|
409 |
+
if (!document.forms[0].href.value) {
|
410 |
+
i = inst.selection.getBookmark();
|
411 |
+
inst.dom.remove(elm, 1);
|
412 |
+
inst.selection.moveToBookmark(i);
|
413 |
+
tinyMCEPopup.execCommand("mceEndUndoLevel");
|
414 |
+
tinyMCEPopup.close();
|
415 |
+
return;
|
416 |
+
}
|
417 |
+
|
418 |
+
// Create new anchor elements
|
419 |
+
if (elm == null) {
|
420 |
+
inst.getDoc().execCommand("unlink", false, null);
|
421 |
+
tinyMCEPopup.execCommand("mceInsertLink", false, "#mce_temp_url#", {skip_undo : 1});
|
422 |
+
|
423 |
+
elementArray = tinymce.grep(inst.dom.select("a"), function(n) {return inst.dom.getAttrib(n, 'href') == '#mce_temp_url#';});
|
424 |
+
for (i=0; i<elementArray.length; i++)
|
425 |
+
setAllAttribs(elm = elementArray[i]);
|
426 |
+
} else
|
427 |
+
setAllAttribs(elm);
|
428 |
+
|
429 |
+
// Don't move caret if selection was image
|
430 |
+
if (elm.childNodes.length != 1 || elm.firstChild.nodeName != 'IMG') {
|
431 |
+
inst.focus();
|
432 |
+
inst.selection.select(elm);
|
433 |
+
inst.selection.collapse(0);
|
434 |
+
tinyMCEPopup.storeSelection();
|
435 |
+
}
|
436 |
+
|
437 |
+
tinyMCEPopup.execCommand("mceEndUndoLevel");
|
438 |
+
tinyMCEPopup.close();
|
439 |
+
}
|
440 |
+
|
441 |
+
function setAllAttribs(elm) {
|
442 |
+
var formObj = document.forms[0];
|
443 |
+
var href = formObj.href.value.replace(/ /g, '%20');
|
444 |
+
var target = getSelectValue(formObj, 'targetlist');
|
445 |
+
|
446 |
+
setAttrib(elm, 'href', href);
|
447 |
+
setAttrib(elm, 'title');
|
448 |
+
setAttrib(elm, 'target', target == '_self' ? '' : target);
|
449 |
+
setAttrib(elm, 'id');
|
450 |
+
setAttrib(elm, 'style');
|
451 |
+
setAttrib(elm, 'class', getSelectValue(formObj, 'classlist'));
|
452 |
+
setAttrib(elm, 'rel');
|
453 |
+
setAttrib(elm, 'rev');
|
454 |
+
setAttrib(elm, 'charset');
|
455 |
+
setAttrib(elm, 'hreflang');
|
456 |
+
setAttrib(elm, 'dir');
|
457 |
+
setAttrib(elm, 'lang');
|
458 |
+
setAttrib(elm, 'tabindex');
|
459 |
+
setAttrib(elm, 'accesskey');
|
460 |
+
setAttrib(elm, 'type');
|
461 |
+
setAttrib(elm, 'onfocus');
|
462 |
+
setAttrib(elm, 'onblur');
|
463 |
+
setAttrib(elm, 'onclick');
|
464 |
+
setAttrib(elm, 'ondblclick');
|
465 |
+
setAttrib(elm, 'onmousedown');
|
466 |
+
setAttrib(elm, 'onmouseup');
|
467 |
+
setAttrib(elm, 'onmouseover');
|
468 |
+
setAttrib(elm, 'onmousemove');
|
469 |
+
setAttrib(elm, 'onmouseout');
|
470 |
+
setAttrib(elm, 'onkeypress');
|
471 |
+
setAttrib(elm, 'onkeydown');
|
472 |
+
setAttrib(elm, 'onkeyup');
|
473 |
+
|
474 |
+
// Refresh in old MSIE
|
475 |
+
if (tinyMCE.isMSIE5)
|
476 |
+
elm.outerHTML = elm.outerHTML;
|
477 |
+
}
|
478 |
+
|
479 |
+
function getSelectValue(form_obj, field_name) {
|
480 |
+
var elm = form_obj.elements[field_name];
|
481 |
+
|
482 |
+
if (!elm || elm.options == null || elm.selectedIndex == -1)
|
483 |
+
return "";
|
484 |
+
|
485 |
+
return elm.options[elm.selectedIndex].value;
|
486 |
+
}
|
487 |
+
|
488 |
+
function getLinkListHTML(elm_id, target_form_element, onchange_func) {
|
489 |
+
if (typeof(tinyMCELinkList) == "undefined" || tinyMCELinkList.length == 0)
|
490 |
+
return "";
|
491 |
+
|
492 |
+
var html = "";
|
493 |
+
|
494 |
+
html += '<select id="' + elm_id + '" name="' + elm_id + '"';
|
495 |
+
html += ' class="mceLinkList" onchange="this.form.' + target_form_element + '.value=';
|
496 |
+
html += 'this.options[this.selectedIndex].value;';
|
497 |
+
|
498 |
+
if (typeof(onchange_func) != "undefined")
|
499 |
+
html += onchange_func + '(\'' + target_form_element + '\',this.options[this.selectedIndex].text,this.options[this.selectedIndex].value);';
|
500 |
+
|
501 |
+
html += '"><option value="">---</option>';
|
502 |
+
|
503 |
+
for (var i=0; i<tinyMCELinkList.length; i++)
|
504 |
+
html += '<option value="' + tinyMCELinkList[i][1] + '">' + tinyMCELinkList[i][0] + '</option>';
|
505 |
+
|
506 |
+
html += '</select>';
|
507 |
+
|
508 |
+
return html;
|
509 |
+
|
510 |
+
// tinyMCE.debug('-- image list start --', html, '-- image list end --');
|
511 |
+
}
|
512 |
+
|
513 |
+
function getTargetListHTML(elm_id, target_form_element) {
|
514 |
+
var targets = tinyMCEPopup.getParam('theme_advanced_link_targets', '').split(';');
|
515 |
+
var html = '';
|
516 |
+
|
517 |
+
html += '<select id="' + elm_id + '" name="' + elm_id + '" onchange="this.form.' + target_form_element + '.value=';
|
518 |
+
html += 'this.options[this.selectedIndex].value;">';
|
519 |
+
html += '<option value="_self">' + tinyMCEPopup.getLang('advlink_dlg.target_same') + '</option>';
|
520 |
+
html += '<option value="_blank">' + tinyMCEPopup.getLang('advlink_dlg.target_blank') + ' (_blank)</option>';
|
521 |
+
html += '<option value="_parent">' + tinyMCEPopup.getLang('advlink_dlg.target_parent') + ' (_parent)</option>';
|
522 |
+
html += '<option value="_top">' + tinyMCEPopup.getLang('advlink_dlg.target_top') + ' (_top)</option>';
|
523 |
+
|
524 |
+
for (var i=0; i<targets.length; i++) {
|
525 |
+
var key, value;
|
526 |
+
|
527 |
+
if (targets[i] == "")
|
528 |
+
continue;
|
529 |
+
|
530 |
+
key = targets[i].split('=')[0];
|
531 |
+
value = targets[i].split('=')[1];
|
532 |
+
|
533 |
+
html += '<option value="' + key + '">' + value + ' (' + key + ')</option>';
|
534 |
+
}
|
535 |
+
|
536 |
+
html += '</select>';
|
537 |
+
|
538 |
+
return html;
|
539 |
+
}
|
540 |
+
|
541 |
+
// While loading
|
542 |
+
preinit();
|
543 |
+
tinyMCEPopup.onInit.add(init);
|
mce/advlink/langs/de_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('de.advlink_dlg',{"target_name":"Name der Zielseite",classes:"Klassen",style:"Format",id:"ID","popup_position":"Position (X/Y)",langdir:"Schriftrichtung","popup_size":"Gr\u00f6\u00dfe","popup_dependent":"Vom Elternfenster abh\u00e4ngig <br /> (nur Mozilla/Firefox) ","popup_resizable":"Vergr\u00f6\u00dfern des Fenster zulassen","popup_location":"Adressleiste anzeigen","popup_menubar":"Browsermen\u00fc anzeigen","popup_toolbar":"Werkzeugleisten anzeigen","popup_statusbar":"Statusleiste anzeigen","popup_scrollbars":"Scrollbalken anzeigen","popup_return":"Link trotz Popup folgen","popup_name":"Name des Fensters","popup_url":"Popup-Adresse",popup:"JavaScript-Popup","target_blank":"In neuem Fenster \u00f6ffnen","target_top":"Im obersten Frame \u00f6ffnen (sprengt das Frameset)","target_parent":"Im \u00fcbergeordneten Fenster/Frame \u00f6ffnen","target_same":"Im selben Fenster/Frame \u00f6ffnen","anchor_names":"Anker","popup_opts":"Optionen","advanced_props":"Erweiterte Eigenschaften","event_props":"Ereignisse","popup_props":"Popup-Eigenschaften","general_props":"Allemeine Eigenschaften","advanced_tab":"Erweitert","events_tab":"Ereignisse","popup_tab":"Popup","general_tab":"Allgemein",list:"Linkliste","is_external":"Diese Adresse scheint ein externer Link zu sein.
|
1 |
+
tinyMCE.addI18n('de.advlink_dlg',{"target_name":"Name der Zielseite",classes:"Klassen",style:"Format",id:"ID","popup_position":"Position (X/Y)",langdir:"Schriftrichtung","popup_size":"Gr\u00f6\u00dfe","popup_dependent":"Vom Elternfenster abh\u00e4ngig <br /> (nur Mozilla/Firefox) ","popup_resizable":"Vergr\u00f6\u00dfern des Fenster zulassen","popup_location":"Adressleiste anzeigen","popup_menubar":"Browsermen\u00fc anzeigen","popup_toolbar":"Werkzeugleisten anzeigen","popup_statusbar":"Statusleiste anzeigen","popup_scrollbars":"Scrollbalken anzeigen","popup_return":"Link trotz Popup folgen","popup_name":"Name des Fensters","popup_url":"Popup-Adresse",popup:"JavaScript-Popup","target_blank":"In neuem Fenster \u00f6ffnen","target_top":"Im obersten Frame \u00f6ffnen (sprengt das Frameset)","target_parent":"Im \u00fcbergeordneten Fenster/Frame \u00f6ffnen","target_same":"Im selben Fenster/Frame \u00f6ffnen","anchor_names":"Anker","popup_opts":"Optionen","advanced_props":"Erweiterte Eigenschaften","event_props":"Ereignisse","popup_props":"Popup-Eigenschaften","general_props":"Allemeine Eigenschaften","advanced_tab":"Erweitert","events_tab":"Ereignisse","popup_tab":"Popup","general_tab":"Allgemein",list:"Linkliste","is_external":"Diese Adresse scheint ein externer Link zu sein. Soll das dazu ben\u00f6tigte \"http://\" vorangestellt werden?","is_email":"Diese Adresse scheint eine E-Mail Adresse zu sein. Soll das dazu ben\u00f6tigte \"mailto:\" vorangestellt werden?",titlefield:"Titel",target:"Fenster",url:"Adresse",title:"Link einf\u00fcgen/bearbeiten","link_list":"Linkliste",rtl:"Rechts nach links",ltr:"Links nach rechts",accesskey:"Tastenk\u00fcrzel",tabindex:"Tabindex",rev:"Beziehung des Linkziels zur Seite",rel:"Beziehung der Seite zum Linkziel",mime:"MIME-Type der Zielseite",encoding:"Zeichenkodierung der Zielseite",langcode:"Sprachcode","target_langcode":"Sprache der Zielseite",width:"Breite",height:"H\u00f6he"});
|
mce/advlink/langs/langs.php
CHANGED
@@ -1,9 +1,12 @@
|
|
1 |
-
<?php
|
2 |
-
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
-
|
4 |
-
if ( is_file($lang_file) &&
|
5 |
-
$
|
6 |
-
|
7 |
-
|
8 |
-
$strings =
|
9 |
-
}
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
+
|
4 |
+
if ( ! is_file( $lang_file ) && defined( 'TINYMCE_ADVANCED_LANGUAGES_PATH' ) )
|
5 |
+
$lang_file = TINYMCE_ADVANCED_LANGUAGES_PATH . 'advlink/langs/' . $mce_locale . '_dlg.js';
|
6 |
+
|
7 |
+
if ( is_file( $lang_file ) && is_readable( $lang_file ) ) {
|
8 |
+
$strings = tdav_get_file( $lang_file );
|
9 |
+
} else {
|
10 |
+
$strings = tdav_get_file( dirname(__FILE__) . '/en_dlg.js' );
|
11 |
+
$strings = preg_replace( '/([\'"])en\./', '$1' . $mce_locale . '.', $strings, 1 );
|
12 |
+
}
|
mce/advlink/langs/ru_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('ru.advlink_dlg',{"target_name":"\u0418\u043c\u044f \u0446\u0435\u043b\u0438",classes:"\u041a\u043b\u0430\u0441\u0441\u044b",style:"\u0421\u0442\u0438\u043b\u044c",id:"\u0418\u043c\u044f","popup_position":"\u041f\u043e\u0437\u0438\u0446\u0438\u044f (X/Y)",langdir:"\u041d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0442\u0435\u043a\u0441\u0442\u0430","popup_size":"\u0420\u0430\u0437\u043c\u0435\u0440","popup_dependent":"\u0417\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c (\u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f Firefox)","popup_resizable":"\u0420\u0430\u0437\u0440\u0435\u0448\u0430\u0442\u044c \u0438\u0437\u043c\u0435\u043d\u044f\u0442\u044c \u0440\u0430\u0437\u043c\u0435\u0440","popup_location":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u043f\u0430\u043d\u0435\u043b\u044c \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u044f","popup_menubar":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u043c\u0435\u043d\u044e","popup_toolbar":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u043f\u0430\u043d\u0435\u043b\u0438 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432","popup_statusbar":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u0441\u0442\u0440\u043e\u043a\u0443 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f","popup_scrollbars":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u043f\u043e\u043b\u043e\u0441\u044b \u043f\u0440\u043e\u043a\u0440\u0443\u0442\u043a\u0438","popup_return":"\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \'return false\'","popup_name":"\u041d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u043e\u043a\u043d\u0430","popup_url":"\u0410\u0434\u0440\u0435\u0441",popup:"\u0420\u0430\u0437\u0432\u0435\u0440\u0442\u044b\u0432\u0430\u043d\u0438\u0435 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c Java","target_blank":"\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u0432 \u043d\u043e\u0432\u043e\u043c \u043e\u043a\u043d\u0435","target_top":"\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u0432 \u0432\u0435\u0440\u0445\u043d\u0435\u043c \u043a\u0430\u0434\u0440\u0435 (\u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0432\u0441\u0435 \u043a\u0430\u0434\u0440\u044b)","target_parent":"\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u0432 \u0440\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u043c \u043e\u043a\u043d\u0435/\u043a\u0430\u0434\u0440\u0435","target_same":"\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u0432 \u044d\u0442\u043e\u043c \u043e\u043a\u043d\u0435/\u043a\u0430\u0434\u0440\u0435","anchor_names":"\u042f\u043a\u043e\u0440\u044f","popup_opts":"\u0421\u0432\u043e\u0439\u0441\u0442\u0432\u0430","advanced_props":"\u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b","event_props":"\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0441\u043e\u0431\u044b\u0442\u0438\u0439","popup_props":"\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0440\u0430\u0437\u0432\u0435\u0440\u0442\u044b\u0432\u0430\u043d\u0438\u044f","general_props":"\u041e\u0431\u0449\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b","advanced_tab":"\u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e","events_tab":"\u0421\u043e\u0431\u044b\u0442\u0438\u044f","popup_tab":"\u0420\u0430\u0437\u0432\u0435\u0440\u0442\u044b\u0432\u0430\u043d\u0438\u0435","general_tab":"\u041e\u0431\u0449\u0435\u0435",list:"\u0421\u043f\u0438\u0441\u043e\u043a","is_external":"\u0412\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0439 \u0430\u0434\u0440\u0435\u0441 \u043d\u0430\u043f\u043e\u043c\u0438\u043d\u0430\u0435\u0442 \u0432\u043d\u0435\u0448\u043d\u044e\u044e \u0441\u0441\u044b\u043b\u043a\u0443, \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043f\u0440\u0435\u0444\u0438\u043a\u0441 http://?","is_email":"\u0412\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0439 \u0430\u0434\u0440\u0435\u0441 \u043d\u0430\u043f\u043e\u043c\u0438\u043d\u0430\u0435\u0442 \u044d\u043b\u0435\u043a\u0442\u0440\u043e\u043d\u043d\u0443\u044e \u043f\u043e\u0447\u0442\u0443, \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043f\u0440\u0435\u0444\u0438\u043a\u0441 mailto:?",titlefield:"\
|
1 |
+
tinyMCE.addI18n('ru.advlink_dlg',{"target_name":"\u0418\u043c\u044f \u0446\u0435\u043b\u0438",classes:"\u041a\u043b\u0430\u0441\u0441\u044b",style:"\u0421\u0442\u0438\u043b\u044c",id:"\u0418\u043c\u044f","popup_position":"\u041f\u043e\u0437\u0438\u0446\u0438\u044f (X/Y)",langdir:"\u041d\u0430\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0442\u0435\u043a\u0441\u0442\u0430","popup_size":"\u0420\u0430\u0437\u043c\u0435\u0440","popup_dependent":"\u0417\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u044c (\u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f Firefox)","popup_resizable":"\u0420\u0430\u0437\u0440\u0435\u0448\u0430\u0442\u044c \u0438\u0437\u043c\u0435\u043d\u044f\u0442\u044c \u0440\u0430\u0437\u043c\u0435\u0440","popup_location":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u043f\u0430\u043d\u0435\u043b\u044c \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u044f","popup_menubar":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u043c\u0435\u043d\u044e","popup_toolbar":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u043f\u0430\u043d\u0435\u043b\u0438 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432","popup_statusbar":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u0441\u0442\u0440\u043e\u043a\u0443 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f","popup_scrollbars":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c \u043f\u043e\u043b\u043e\u0441\u044b \u043f\u0440\u043e\u043a\u0440\u0443\u0442\u043a\u0438","popup_return":"\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \'return false\'","popup_name":"\u041d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u043e\u043a\u043d\u0430","popup_url":"\u0410\u0434\u0440\u0435\u0441",popup:"\u0420\u0430\u0437\u0432\u0435\u0440\u0442\u044b\u0432\u0430\u043d\u0438\u0435 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c Java","target_blank":"\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u0432 \u043d\u043e\u0432\u043e\u043c \u043e\u043a\u043d\u0435","target_top":"\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u0432 \u0432\u0435\u0440\u0445\u043d\u0435\u043c \u043a\u0430\u0434\u0440\u0435 (\u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0432\u0441\u0435 \u043a\u0430\u0434\u0440\u044b)","target_parent":"\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u0432 \u0440\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u043c \u043e\u043a\u043d\u0435/\u043a\u0430\u0434\u0440\u0435","target_same":"\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u0432 \u044d\u0442\u043e\u043c \u043e\u043a\u043d\u0435/\u043a\u0430\u0434\u0440\u0435","anchor_names":"\u042f\u043a\u043e\u0440\u044f","popup_opts":"\u0421\u0432\u043e\u0439\u0441\u0442\u0432\u0430","advanced_props":"\u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b","event_props":"\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0441\u043e\u0431\u044b\u0442\u0438\u0439","popup_props":"\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0440\u0430\u0437\u0432\u0435\u0440\u0442\u044b\u0432\u0430\u043d\u0438\u044f","general_props":"\u041e\u0431\u0449\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b","advanced_tab":"\u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e","events_tab":"\u0421\u043e\u0431\u044b\u0442\u0438\u044f","popup_tab":"\u0420\u0430\u0437\u0432\u0435\u0440\u0442\u044b\u0432\u0430\u043d\u0438\u0435","general_tab":"\u041e\u0431\u0449\u0435\u0435",list:"\u0421\u043f\u0438\u0441\u043e\u043a","is_external":"\u0412\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0439 \u0430\u0434\u0440\u0435\u0441 \u043d\u0430\u043f\u043e\u043c\u0438\u043d\u0430\u0435\u0442 \u0432\u043d\u0435\u0448\u043d\u044e\u044e \u0441\u0441\u044b\u043b\u043a\u0443, \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043f\u0440\u0435\u0444\u0438\u043a\u0441 http://?","is_email":"\u0412\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0439 \u0430\u0434\u0440\u0435\u0441 \u043d\u0430\u043f\u043e\u043c\u0438\u043d\u0430\u0435\u0442 \u044d\u043b\u0435\u043a\u0442\u0440\u043e\u043d\u043d\u0443\u044e \u043f\u043e\u0447\u0442\u0443, \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043f\u0440\u0435\u0444\u0438\u043a\u0441 mailto:?",titlefield:"\u041f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0430",target:"\u041e\u043a\u043d\u043e",url:"\u0410\u0434\u0440\u0435\u0441",title:"\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0441\u0441\u044b\u043b\u043a\u0438","link_list":"\u0421\u043f\u0438\u0441\u043e\u043a \u0441\u0441\u044b\u043b\u043e\u043a",rtl:"\u0421\u043f\u0440\u0430\u0432\u0430 \u043d\u0430\u043b\u0435\u0432\u043e",ltr:"\u0421\u043b\u0435\u0432\u0430 \u043d\u0430\u043f\u0440\u0430\u0432\u043e",accesskey:"\u041a\u043b\u044e\u0447 \u0434\u043e\u0441\u0442\u0443\u043f\u0430",tabindex:"\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u043a",rev:"\u041e\u0442\u043d\u043e\u0448\u0435\u043d\u0438\u0435 \u0446\u0435\u043b\u0438 \u043a \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435",rel:"\u041e\u0442\u043d\u043e\u0448\u0435\u043d\u0438\u0435 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043a \u0446\u0435\u043b\u0438",mime:"MIME \u0442\u0438\u043f \u0446\u0435\u043b\u0438",encoding:"\u041a\u043e\u0434\u0438\u0440\u043e\u0432\u043a\u0430 \u0446\u0435\u043b\u0438",langcode:"\u041a\u043e\u0434 \u044f\u0437\u044b\u043a\u0430","target_langcode":"\u042f\u0437\u044b\u043a \u0446\u0435\u043b\u0438",width:"\u0428\u0438\u0440\u0438\u043d\u0430",height:"\u0412\u044b\u0441\u043e\u0442\u0430"});
|
mce/advlink/langs/zh_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('zh.advlink_dlg',{"target_name":"\
|
1 |
+
tinyMCE.addI18n('zh.advlink_dlg',{"target_name":"\u94fe\u63a5\u76ee\u6807\u540d\u79f0",classes:"\u7c7b",style:"\u6837\u5f0f",id:"ID","popup_position":"\u4f4d\u7f6e(X/Y)",langdir:"\u8bed\u8a00\u4e66\u5199\u65b9\u5411","popup_size":"\u5927\u5c0f","popup_dependent":"\u6d4f\u89c8\u5668\u9650\u5236(\u4ec5\u652f\u6301Mozilla/Firefox)","popup_resizable":"\u53ef\u8c03\u6574\u5927\u5c0f\u7684\u5f39\u51fa\u7a97\u53e3","popup_location":"\u663e\u793a\u7f51\u5740\u680f","popup_menubar":"\u663e\u793a\u83dc\u5355\u680f","popup_toolbar":"\u663e\u793a\u5de5\u5177\u680f","popup_statusbar":"\u663e\u793a\u72b6\u6001\u680f","popup_scrollbars":"\u663e\u793a\u6eda\u52a8\u680f","popup_return":"\u63d2\u5165\'return false\'","popup_name":"\u7a97\u53e3\u540d\u79f0","popup_url":"\u5f39\u51fa\u7a97\u53e3\u7684URL",popup:"JavaScript\u5f39\u51fa\u7a97\u53e3","target_blank":"\u5728\u65b0\u7a97\u53e3\u6253\u5f00\u94fe\u63a5","target_top":"\u5728top\u6846\u67b6\u6253\u5f00\u94fe\u63a5 (\u5957\u7528\u5728\u6240\u6709\u6846\u67b6)","target_parent":"\u5728\u7236(\u4e0a\u5c42)\u7a97\u53e3/\u6846\u67b6\u6253\u5f00\u94fe\u63a5","target_same":"\u5728\u5f53\u524d\u7a97\u53e3\u6253\u5f00\u94fe\u63a5","anchor_names":"\u951a\u70b9","popup_opts":"\u9009\u9879","advanced_props":"\u9ad8\u7ea7\u5c5e\u6027","event_props":"Javascript\u4e8b\u4ef6","popup_props":"\u5f39\u51fa\u7a97\u53e3\u5c5e\u6027","general_props":"\u666e\u901a\u5c5e\u6027","advanced_tab":"\u9ad8\u7ea7","events_tab":"Javascript\u4e8b\u4ef6","popup_tab":"\u5f39\u51fa\u7a97\u53e3","general_tab":"\u666e\u901a",list:"\u94fe\u63a5\u6e05\u5355","is_external":"\u60a8\u6240\u8f93\u5165\u7684URL\u4f3c\u4e4e\u4e3a\u5916\u90e8\u94fe\u63a5\uff0c\u662f\u5426\u9700\u8981\u52a0\u4e0ahttp://\u524d\u7f00\uff1f","is_email":"\u60a8\u8f93\u5165\u7684URL\u4f3c\u4e4e\u662f\u7535\u5b50\u90ae\u4ef6\u4f4d\u5740\uff0c\u662f\u5426\u9700\u8981\u52a0\u4e0amailto:\u524d\u7f00\uff1f",titlefield:"\u94fe\u63a5\u6807\u9898",target:"\u94fe\u63a5\u76ee\u6807",url:"URL\u94fe\u63a5",title:"\u63d2\u5165/\u7f16\u8f91\u94fe\u63a5","link_list":"\u94fe\u63a5\u6e05\u5355",rtl:"\u4ece\u53f3\u5230\u5de6",ltr:"\u4ece\u5de6\u5230\u53f3",accesskey:"\u5feb\u6377\u952e",tabindex:"Tab\u7d22\u5f15",rev:"\u76ee\u6807\u5230\u7f51\u9875\u7684\u5173\u7cfb",rel:"\u7f51\u9875\u5230\u76ee\u6807\u7684\u5173\u7cfb",mime:"\u76ee\u6807MIME\u7c7b\u578b",encoding:"\u76ee\u6807\u5b57\u7b26\u7f16\u7801",langcode:"\u8bed\u8a00\u4ee3\u7801","target_langcode":"\u76ee\u6807\u8bed\u8a00",width:"\u5bbd",height:"\u9ad8"});
|
mce/advlink/link.htm
CHANGED
@@ -1,338 +1,338 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#advlink_dlg.title}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/validate.js?ver=
|
9 |
-
<script type="text/javascript" src="js/advlink.js?ver=
|
10 |
-
<link href="css/advlink.css?ver=
|
11 |
-
</head>
|
12 |
-
<body id="advlink" style="display: none" role="application" onload="javascript:mcTabs.displayTab('general_tab','general_panel', true);" aria-labelledby="app_label">
|
13 |
-
<span class="mceVoiceLabel" id="app_label" style="display:none;">{#advlink_dlg.title}</span>
|
14 |
-
<form onsubmit="insertAction();return false;" action="#">
|
15 |
-
<div class="tabs" role="presentation">
|
16 |
-
<ul>
|
17 |
-
<li id="general_tab" class="current" aria-controls="general_panel" ><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#advlink_dlg.general_tab}</a></span></li>
|
18 |
-
<li id="popup_tab" aria-controls="popup_panel" ><span><a href="javascript:mcTabs.displayTab('popup_tab','popup_panel');" onmousedown="return false;">{#advlink_dlg.popup_tab}</a></span></li>
|
19 |
-
<li id="events_tab" aria-controls="events_panel"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#advlink_dlg.events_tab}</a></span></li>
|
20 |
-
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#advlink_dlg.advanced_tab}</a></span></li>
|
21 |
-
</ul>
|
22 |
-
</div>
|
23 |
-
|
24 |
-
<div class="panel_wrapper" role="presentation">
|
25 |
-
<div id="general_panel" class="panel current">
|
26 |
-
<fieldset>
|
27 |
-
<legend>{#advlink_dlg.general_props}</legend>
|
28 |
-
|
29 |
-
<table border="0" cellpadding="4" cellspacing="0" role="presentation">
|
30 |
-
<tr>
|
31 |
-
<td class="nowrap"><label id="hreflabel" for="href">{#advlink_dlg.url}</label></td>
|
32 |
-
<td><table border="0" cellspacing="0" cellpadding="0">
|
33 |
-
<tr>
|
34 |
-
<td><input id="href" name="href" type="text" class="mceFocus" value="" onchange="selectByValue(this.form,'linklisthref',this.value);" aria-required="true" /></td>
|
35 |
-
<td id="hrefbrowsercontainer"> </td>
|
36 |
-
</tr>
|
37 |
-
</table></td>
|
38 |
-
</tr>
|
39 |
-
<tr id="linklisthrefrow">
|
40 |
-
<td class="column1"><label for="linklisthref">{#advlink_dlg.list}</label></td>
|
41 |
-
<td colspan="2" id="linklisthrefcontainer"><select id="linklisthref"><option value=""></option></select></td>
|
42 |
-
</tr>
|
43 |
-
<tr id="anchorlistrow">
|
44 |
-
<td class="column1"><label for="anchorlist">{#advlink_dlg.anchor_names}</label></td>
|
45 |
-
<td colspan="2" id="anchorlistcontainer"><select id="anchorlist"><option value=""></option></select></td>
|
46 |
-
</tr>
|
47 |
-
<tr>
|
48 |
-
<td><label id="targetlistlabel" for="targetlist">{#advlink_dlg.target}</label></td>
|
49 |
-
<td id="targetlistcontainer"><select id="targetlist"><option value=""></option></select></td>
|
50 |
-
</tr>
|
51 |
-
<tr>
|
52 |
-
<td class="nowrap"><label id="titlelabel" for="title">{#advlink_dlg.titlefield}</label></td>
|
53 |
-
<td><input id="title" name="title" type="text" value="" /></td>
|
54 |
-
</tr>
|
55 |
-
<tr>
|
56 |
-
<td><label id="classlabel" for="classlist">{#class_name}</label></td>
|
57 |
-
<td>
|
58 |
-
<select id="classlist" name="classlist" onchange="changeClass();">
|
59 |
-
<option value="" selected="selected">{#not_set}</option>
|
60 |
-
</select>
|
61 |
-
</td>
|
62 |
-
</tr>
|
63 |
-
</table>
|
64 |
-
</fieldset>
|
65 |
-
</div>
|
66 |
-
|
67 |
-
<div id="popup_panel" class="panel">
|
68 |
-
<fieldset>
|
69 |
-
<legend>{#advlink_dlg.popup_props}</legend>
|
70 |
-
|
71 |
-
<input type="checkbox" id="ispopup" name="ispopup" class="radio" onclick="setPopupControlsDisabled(!this.checked);buildOnClick();" />
|
72 |
-
<label id="ispopuplabel" for="ispopup">{#advlink_dlg.popup}</label>
|
73 |
-
|
74 |
-
<table border="0" cellpadding="0" cellspacing="4" role="presentation" >
|
75 |
-
<tr>
|
76 |
-
<td class="nowrap"><label for="popupurl">{#advlink_dlg.popup_url}</label> </td>
|
77 |
-
<td>
|
78 |
-
<table border="0" cellspacing="0" cellpadding="0">
|
79 |
-
<tr>
|
80 |
-
<td><input type="text" name="popupurl" id="popupurl" value="" onchange="buildOnClick();" /></td>
|
81 |
-
<td id="popupurlbrowsercontainer"> </td>
|
82 |
-
</tr>
|
83 |
-
</table>
|
84 |
-
</td>
|
85 |
-
</tr>
|
86 |
-
<tr>
|
87 |
-
<td class="nowrap"><label for="popupname">{#advlink_dlg.popup_name}</label> </td>
|
88 |
-
<td><input type="text" name="popupname" id="popupname" value="" onchange="buildOnClick();" /></td>
|
89 |
-
</tr>
|
90 |
-
<tr role="group" aria-labelledby="popup_size_label">
|
91 |
-
<td class="nowrap"><label id="popup_size_label">{#advlink_dlg.popup_size}</label> </td>
|
92 |
-
<td class="nowrap">
|
93 |
-
<span style="display:none" id="width_voiceLabel">{#advlink_dlg.width}</span>
|
94 |
-
<input type="text" id="popupwidth" name="popupwidth" value="" onchange="buildOnClick();" aria-labelledby="width_voiceLabel" /> x
|
95 |
-
<span style="display:none" id="height_voiceLabel">{#advlink_dlg.height}</span>
|
96 |
-
<input type="text" id="popupheight" name="popupheight" value="" onchange="buildOnClick();" aria-labelledby="height_voiceLabel" /> px
|
97 |
-
</td>
|
98 |
-
</tr>
|
99 |
-
<tr role="group" aria-labelledby="popup_position_label center_hint">
|
100 |
-
<td class="nowrap" id="labelleft"><label id="popup_position_label">{#advlink_dlg.popup_position}</label> </td>
|
101 |
-
<td class="nowrap">
|
102 |
-
<span style="display:none" id="x_voiceLabel">X</span>
|
103 |
-
<input type="text" id="popupleft" name="popupleft" value="" onchange="buildOnClick();" aria-labelledby="x_voiceLabel" /> /
|
104 |
-
<span style="display:none" id="y_voiceLabel">Y</span>
|
105 |
-
<input type="text" id="popuptop" name="popuptop" value="" onchange="buildOnClick();" aria-labelledby="y_voiceLabel" /> <span id="center_hint">(c /c = center)</span>
|
106 |
-
</td>
|
107 |
-
</tr>
|
108 |
-
</table>
|
109 |
-
|
110 |
-
<fieldset>
|
111 |
-
<legend>{#advlink_dlg.popup_opts}</legend>
|
112 |
-
|
113 |
-
<table border="0" cellpadding="0" cellspacing="4" role="presentation" >
|
114 |
-
<tr>
|
115 |
-
<td><input type="checkbox" id="popuplocation" name="popuplocation" class="checkbox" onchange="buildOnClick();" /></td>
|
116 |
-
<td class="nowrap"><label id="popuplocationlabel" for="popuplocation">{#advlink_dlg.popup_location}</label></td>
|
117 |
-
<td><input type="checkbox" id="popupscrollbars" name="popupscrollbars" class="checkbox" onchange="buildOnClick();" /></td>
|
118 |
-
<td class="nowrap"><label id="popupscrollbarslabel" for="popupscrollbars">{#advlink_dlg.popup_scrollbars}</label></td>
|
119 |
-
</tr>
|
120 |
-
<tr>
|
121 |
-
<td><input type="checkbox" id="popupmenubar" name="popupmenubar" class="checkbox" onchange="buildOnClick();" /></td>
|
122 |
-
<td class="nowrap"><label id="popupmenubarlabel" for="popupmenubar">{#advlink_dlg.popup_menubar}</label></td>
|
123 |
-
<td><input type="checkbox" id="popupresizable" name="popupresizable" class="checkbox" onchange="buildOnClick();" /></td>
|
124 |
-
<td class="nowrap"><label id="popupresizablelabel" for="popupresizable">{#advlink_dlg.popup_resizable}</label></td>
|
125 |
-
</tr>
|
126 |
-
<tr>
|
127 |
-
<td><input type="checkbox" id="popuptoolbar" name="popuptoolbar" class="checkbox" onchange="buildOnClick();" /></td>
|
128 |
-
<td class="nowrap"><label id="popuptoolbarlabel" for="popuptoolbar">{#advlink_dlg.popup_toolbar}</label></td>
|
129 |
-
<td><input type="checkbox" id="popupdependent" name="popupdependent" class="checkbox" onchange="buildOnClick();" /></td>
|
130 |
-
<td class="nowrap"><label id="popupdependentlabel" for="popupdependent">{#advlink_dlg.popup_dependent}</label></td>
|
131 |
-
</tr>
|
132 |
-
<tr>
|
133 |
-
<td><input type="checkbox" id="popupstatus" name="popupstatus" class="checkbox" onchange="buildOnClick();" /></td>
|
134 |
-
<td class="nowrap"><label id="popupstatuslabel" for="popupstatus">{#advlink_dlg.popup_statusbar}</label></td>
|
135 |
-
<td><input type="checkbox" id="popupreturn" name="popupreturn" class="checkbox" onchange="buildOnClick();" checked="checked" /></td>
|
136 |
-
<td class="nowrap"><label id="popupreturnlabel" for="popupreturn">{#advlink_dlg.popup_return}</label></td>
|
137 |
-
</tr>
|
138 |
-
</table>
|
139 |
-
</fieldset>
|
140 |
-
</fieldset>
|
141 |
-
</div>
|
142 |
-
|
143 |
-
<div id="advanced_panel" class="panel">
|
144 |
-
<fieldset>
|
145 |
-
<legend>{#advlink_dlg.advanced_props}</legend>
|
146 |
-
|
147 |
-
<table border="0" cellpadding="0" cellspacing="4" role="presentation" >
|
148 |
-
<tr>
|
149 |
-
<td class="column1"><label id="idlabel" for="id">{#advlink_dlg.id}</label></td>
|
150 |
-
<td><input id="id" name="id" type="text" value="" /></td>
|
151 |
-
</tr>
|
152 |
-
|
153 |
-
<tr>
|
154 |
-
<td><label id="stylelabel" for="style">{#advlink_dlg.style}</label></td>
|
155 |
-
<td><input type="text" id="style" name="style" value="" /></td>
|
156 |
-
</tr>
|
157 |
-
|
158 |
-
<tr>
|
159 |
-
<td><label id="classeslabel" for="classes">{#advlink_dlg.classes}</label></td>
|
160 |
-
<td><input type="text" id="classes" name="classes" value="" onchange="selectByValue(this.form,'classlist',this.value,true);" /></td>
|
161 |
-
</tr>
|
162 |
-
|
163 |
-
<tr>
|
164 |
-
<td><label id="targetlabel" for="target">{#advlink_dlg.target_name}</label></td>
|
165 |
-
<td><input type="text" id="target" name="target" value="" onchange="selectByValue(this.form,'targetlist',this.value,true);" /></td>
|
166 |
-
</tr>
|
167 |
-
|
168 |
-
<tr>
|
169 |
-
<td class="column1"><label id="dirlabel" for="dir">{#advlink_dlg.langdir}</label></td>
|
170 |
-
<td>
|
171 |
-
<select id="dir" name="dir">
|
172 |
-
<option value="">{#not_set}</option>
|
173 |
-
<option value="ltr">{#advlink_dlg.ltr}</option>
|
174 |
-
<option value="rtl">{#advlink_dlg.rtl}</option>
|
175 |
-
</select>
|
176 |
-
</td>
|
177 |
-
</tr>
|
178 |
-
|
179 |
-
<tr>
|
180 |
-
<td><label id="hreflanglabel" for="hreflang">{#advlink_dlg.target_langcode}</label></td>
|
181 |
-
<td><input type="text" id="hreflang" name="hreflang" value="" /></td>
|
182 |
-
</tr>
|
183 |
-
|
184 |
-
<tr>
|
185 |
-
<td class="column1"><label id="langlabel" for="lang">{#advlink_dlg.langcode}</label></td>
|
186 |
-
<td>
|
187 |
-
<input id="lang" name="lang" type="text" value="" />
|
188 |
-
</td>
|
189 |
-
</tr>
|
190 |
-
|
191 |
-
<tr>
|
192 |
-
<td><label id="charsetlabel" for="charset">{#advlink_dlg.encoding}</label></td>
|
193 |
-
<td><input type="text" id="charset" name="charset" value="" /></td>
|
194 |
-
</tr>
|
195 |
-
|
196 |
-
<tr>
|
197 |
-
<td><label id="typelabel" for="type">{#advlink_dlg.mime}</label></td>
|
198 |
-
<td><input type="text" id="type" name="type" value="" /></td>
|
199 |
-
</tr>
|
200 |
-
|
201 |
-
<tr>
|
202 |
-
<td><label id="rellabel" for="rel">{#advlink_dlg.rel}</label></td>
|
203 |
-
<td><select id="rel" name="rel">
|
204 |
-
<option value="">{#not_set}</option>
|
205 |
-
<option value="lightbox">Lightbox</option>
|
206 |
-
<option value="alternate">Alternate</option>
|
207 |
-
<option value="designates">Designates</option>
|
208 |
-
<option value="stylesheet">Stylesheet</option>
|
209 |
-
<option value="start">Start</option>
|
210 |
-
<option value="next">Next</option>
|
211 |
-
<option value="prev">Prev</option>
|
212 |
-
<option value="contents">Contents</option>
|
213 |
-
<option value="index">Index</option>
|
214 |
-
<option value="glossary">Glossary</option>
|
215 |
-
<option value="copyright">Copyright</option>
|
216 |
-
<option value="chapter">Chapter</option>
|
217 |
-
<option value="subsection">Subsection</option>
|
218 |
-
<option value="appendix">Appendix</option>
|
219 |
-
<option value="help">Help</option>
|
220 |
-
<option value="bookmark">Bookmark</option>
|
221 |
-
<option value="nofollow">No Follow</option>
|
222 |
-
<option value="tag">Tag</option>
|
223 |
-
</select>
|
224 |
-
</td>
|
225 |
-
</tr>
|
226 |
-
|
227 |
-
<tr>
|
228 |
-
<td><label id="revlabel" for="rev">{#advlink_dlg.rev}</label></td>
|
229 |
-
<td><select id="rev" name="rev">
|
230 |
-
<option value="">{#not_set}</option>
|
231 |
-
<option value="alternate">Alternate</option>
|
232 |
-
<option value="designates">Designates</option>
|
233 |
-
<option value="stylesheet">Stylesheet</option>
|
234 |
-
<option value="start">Start</option>
|
235 |
-
<option value="next">Next</option>
|
236 |
-
<option value="prev">Prev</option>
|
237 |
-
<option value="contents">Contents</option>
|
238 |
-
<option value="index">Index</option>
|
239 |
-
<option value="glossary">Glossary</option>
|
240 |
-
<option value="copyright">Copyright</option>
|
241 |
-
<option value="chapter">Chapter</option>
|
242 |
-
<option value="subsection">Subsection</option>
|
243 |
-
<option value="appendix">Appendix</option>
|
244 |
-
<option value="help">Help</option>
|
245 |
-
<option value="bookmark">Bookmark</option>
|
246 |
-
</select>
|
247 |
-
</td>
|
248 |
-
</tr>
|
249 |
-
|
250 |
-
<tr>
|
251 |
-
<td><label id="tabindexlabel" for="tabindex">{#advlink_dlg.tabindex}</label></td>
|
252 |
-
<td><input type="text" id="tabindex" name="tabindex" value="" /></td>
|
253 |
-
</tr>
|
254 |
-
|
255 |
-
<tr>
|
256 |
-
<td><label id="accesskeylabel" for="accesskey">{#advlink_dlg.accesskey}</label></td>
|
257 |
-
<td><input type="text" id="accesskey" name="accesskey" value="" /></td>
|
258 |
-
</tr>
|
259 |
-
</table>
|
260 |
-
</fieldset>
|
261 |
-
</div>
|
262 |
-
|
263 |
-
<div id="events_panel" class="panel">
|
264 |
-
<fieldset>
|
265 |
-
<legend>{#advlink_dlg.event_props}</legend>
|
266 |
-
|
267 |
-
<table border="0" cellpadding="0" cellspacing="4" role="presentation" >
|
268 |
-
<tr>
|
269 |
-
<td class="column1"><label for="onfocus">onfocus</label></td>
|
270 |
-
<td><input id="onfocus" name="onfocus" type="text" value="" /></td>
|
271 |
-
</tr>
|
272 |
-
|
273 |
-
<tr>
|
274 |
-
<td class="column1"><label for="onblur">onblur</label></td>
|
275 |
-
<td><input id="onblur" name="onblur" type="text" value="" /></td>
|
276 |
-
</tr>
|
277 |
-
|
278 |
-
<tr>
|
279 |
-
<td class="column1"><label for="onclick">onclick</label></td>
|
280 |
-
<td><input id="onclick" name="onclick" type="text" value="" /></td>
|
281 |
-
</tr>
|
282 |
-
|
283 |
-
<tr>
|
284 |
-
<td class="column1"><label for="ondblclick">ondblclick</label></td>
|
285 |
-
<td><input id="ondblclick" name="ondblclick" type="text" value="" /></td>
|
286 |
-
</tr>
|
287 |
-
|
288 |
-
<tr>
|
289 |
-
<td class="column1"><label for="onmousedown">onmousedown</label></td>
|
290 |
-
<td><input id="onmousedown" name="onmousedown" type="text" value="" /></td>
|
291 |
-
</tr>
|
292 |
-
|
293 |
-
<tr>
|
294 |
-
<td class="column1"><label for="onmouseup">onmouseup</label></td>
|
295 |
-
<td><input id="onmouseup" name="onmouseup" type="text" value="" /></td>
|
296 |
-
</tr>
|
297 |
-
|
298 |
-
<tr>
|
299 |
-
<td class="column1"><label for="onmouseover">onmouseover</label></td>
|
300 |
-
<td><input id="onmouseover" name="onmouseover" type="text" value="" /></td>
|
301 |
-
</tr>
|
302 |
-
|
303 |
-
<tr>
|
304 |
-
<td class="column1"><label for="onmousemove">onmousemove</label></td>
|
305 |
-
<td><input id="onmousemove" name="onmousemove" type="text" value="" /></td>
|
306 |
-
</tr>
|
307 |
-
|
308 |
-
<tr>
|
309 |
-
<td class="column1"><label for="onmouseout">onmouseout</label></td>
|
310 |
-
<td><input id="onmouseout" name="onmouseout" type="text" value="" /></td>
|
311 |
-
</tr>
|
312 |
-
|
313 |
-
<tr>
|
314 |
-
<td class="column1"><label for="onkeypress">onkeypress</label></td>
|
315 |
-
<td><input id="onkeypress" name="onkeypress" type="text" value="" /></td>
|
316 |
-
</tr>
|
317 |
-
|
318 |
-
<tr>
|
319 |
-
<td class="column1"><label for="onkeydown">onkeydown</label></td>
|
320 |
-
<td><input id="onkeydown" name="onkeydown" type="text" value="" /></td>
|
321 |
-
</tr>
|
322 |
-
|
323 |
-
<tr>
|
324 |
-
<td class="column1"><label for="onkeyup">onkeyup</label></td>
|
325 |
-
<td><input id="onkeyup" name="onkeyup" type="text" value="" /></td>
|
326 |
-
</tr>
|
327 |
-
</table>
|
328 |
-
</fieldset>
|
329 |
-
</div>
|
330 |
-
</div>
|
331 |
-
|
332 |
-
<div class="mceActionPanel">
|
333 |
-
<input type="submit" id="insert" name="insert" value="{#insert}" />
|
334 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
335 |
-
</div>
|
336 |
-
</form>
|
337 |
-
</body>
|
338 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#advlink_dlg.title}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/validate.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="js/advlink.js?ver=359"></script>
|
10 |
+
<link href="css/advlink.css?ver=359" rel="stylesheet" type="text/css" />
|
11 |
+
</head>
|
12 |
+
<body id="advlink" style="display: none" role="application" onload="javascript:mcTabs.displayTab('general_tab','general_panel', true);" aria-labelledby="app_label">
|
13 |
+
<span class="mceVoiceLabel" id="app_label" style="display:none;">{#advlink_dlg.title}</span>
|
14 |
+
<form onsubmit="insertAction();return false;" action="#">
|
15 |
+
<div class="tabs" role="presentation">
|
16 |
+
<ul>
|
17 |
+
<li id="general_tab" class="current" aria-controls="general_panel" ><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#advlink_dlg.general_tab}</a></span></li>
|
18 |
+
<li id="popup_tab" aria-controls="popup_panel" ><span><a href="javascript:mcTabs.displayTab('popup_tab','popup_panel');" onmousedown="return false;">{#advlink_dlg.popup_tab}</a></span></li>
|
19 |
+
<li id="events_tab" aria-controls="events_panel"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#advlink_dlg.events_tab}</a></span></li>
|
20 |
+
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#advlink_dlg.advanced_tab}</a></span></li>
|
21 |
+
</ul>
|
22 |
+
</div>
|
23 |
+
|
24 |
+
<div class="panel_wrapper" role="presentation">
|
25 |
+
<div id="general_panel" class="panel current">
|
26 |
+
<fieldset>
|
27 |
+
<legend>{#advlink_dlg.general_props}</legend>
|
28 |
+
|
29 |
+
<table border="0" cellpadding="4" cellspacing="0" role="presentation">
|
30 |
+
<tr>
|
31 |
+
<td class="nowrap"><label id="hreflabel" for="href">{#advlink_dlg.url}</label></td>
|
32 |
+
<td><table border="0" cellspacing="0" cellpadding="0">
|
33 |
+
<tr>
|
34 |
+
<td><input id="href" name="href" type="text" class="mceFocus" value="" onchange="selectByValue(this.form,'linklisthref',this.value);" aria-required="true" /></td>
|
35 |
+
<td id="hrefbrowsercontainer"> </td>
|
36 |
+
</tr>
|
37 |
+
</table></td>
|
38 |
+
</tr>
|
39 |
+
<tr id="linklisthrefrow">
|
40 |
+
<td class="column1"><label for="linklisthref">{#advlink_dlg.list}</label></td>
|
41 |
+
<td colspan="2" id="linklisthrefcontainer"><select id="linklisthref"><option value=""></option></select></td>
|
42 |
+
</tr>
|
43 |
+
<tr id="anchorlistrow">
|
44 |
+
<td class="column1"><label for="anchorlist">{#advlink_dlg.anchor_names}</label></td>
|
45 |
+
<td colspan="2" id="anchorlistcontainer"><select id="anchorlist"><option value=""></option></select></td>
|
46 |
+
</tr>
|
47 |
+
<tr>
|
48 |
+
<td><label id="targetlistlabel" for="targetlist">{#advlink_dlg.target}</label></td>
|
49 |
+
<td id="targetlistcontainer"><select id="targetlist"><option value=""></option></select></td>
|
50 |
+
</tr>
|
51 |
+
<tr>
|
52 |
+
<td class="nowrap"><label id="titlelabel" for="title">{#advlink_dlg.titlefield}</label></td>
|
53 |
+
<td><input id="title" name="title" type="text" value="" /></td>
|
54 |
+
</tr>
|
55 |
+
<tr>
|
56 |
+
<td><label id="classlabel" for="classlist">{#class_name}</label></td>
|
57 |
+
<td>
|
58 |
+
<select id="classlist" name="classlist" onchange="changeClass();">
|
59 |
+
<option value="" selected="selected">{#not_set}</option>
|
60 |
+
</select>
|
61 |
+
</td>
|
62 |
+
</tr>
|
63 |
+
</table>
|
64 |
+
</fieldset>
|
65 |
+
</div>
|
66 |
+
|
67 |
+
<div id="popup_panel" class="panel">
|
68 |
+
<fieldset>
|
69 |
+
<legend>{#advlink_dlg.popup_props}</legend>
|
70 |
+
|
71 |
+
<input type="checkbox" id="ispopup" name="ispopup" class="radio" onclick="setPopupControlsDisabled(!this.checked);buildOnClick();" />
|
72 |
+
<label id="ispopuplabel" for="ispopup">{#advlink_dlg.popup}</label>
|
73 |
+
|
74 |
+
<table border="0" cellpadding="0" cellspacing="4" role="presentation" >
|
75 |
+
<tr>
|
76 |
+
<td class="nowrap"><label for="popupurl">{#advlink_dlg.popup_url}</label> </td>
|
77 |
+
<td>
|
78 |
+
<table border="0" cellspacing="0" cellpadding="0">
|
79 |
+
<tr>
|
80 |
+
<td><input type="text" name="popupurl" id="popupurl" value="" onchange="buildOnClick();" /></td>
|
81 |
+
<td id="popupurlbrowsercontainer"> </td>
|
82 |
+
</tr>
|
83 |
+
</table>
|
84 |
+
</td>
|
85 |
+
</tr>
|
86 |
+
<tr>
|
87 |
+
<td class="nowrap"><label for="popupname">{#advlink_dlg.popup_name}</label> </td>
|
88 |
+
<td><input type="text" name="popupname" id="popupname" value="" onchange="buildOnClick();" /></td>
|
89 |
+
</tr>
|
90 |
+
<tr role="group" aria-labelledby="popup_size_label">
|
91 |
+
<td class="nowrap"><label id="popup_size_label">{#advlink_dlg.popup_size}</label> </td>
|
92 |
+
<td class="nowrap">
|
93 |
+
<span style="display:none" id="width_voiceLabel">{#advlink_dlg.width}</span>
|
94 |
+
<input type="text" id="popupwidth" name="popupwidth" value="" onchange="buildOnClick();" aria-labelledby="width_voiceLabel" /> x
|
95 |
+
<span style="display:none" id="height_voiceLabel">{#advlink_dlg.height}</span>
|
96 |
+
<input type="text" id="popupheight" name="popupheight" value="" onchange="buildOnClick();" aria-labelledby="height_voiceLabel" /> px
|
97 |
+
</td>
|
98 |
+
</tr>
|
99 |
+
<tr role="group" aria-labelledby="popup_position_label center_hint">
|
100 |
+
<td class="nowrap" id="labelleft"><label id="popup_position_label">{#advlink_dlg.popup_position}</label> </td>
|
101 |
+
<td class="nowrap">
|
102 |
+
<span style="display:none" id="x_voiceLabel">X</span>
|
103 |
+
<input type="text" id="popupleft" name="popupleft" value="" onchange="buildOnClick();" aria-labelledby="x_voiceLabel" /> /
|
104 |
+
<span style="display:none" id="y_voiceLabel">Y</span>
|
105 |
+
<input type="text" id="popuptop" name="popuptop" value="" onchange="buildOnClick();" aria-labelledby="y_voiceLabel" /> <span id="center_hint">(c /c = center)</span>
|
106 |
+
</td>
|
107 |
+
</tr>
|
108 |
+
</table>
|
109 |
+
|
110 |
+
<fieldset>
|
111 |
+
<legend>{#advlink_dlg.popup_opts}</legend>
|
112 |
+
|
113 |
+
<table border="0" cellpadding="0" cellspacing="4" role="presentation" >
|
114 |
+
<tr>
|
115 |
+
<td><input type="checkbox" id="popuplocation" name="popuplocation" class="checkbox" onchange="buildOnClick();" /></td>
|
116 |
+
<td class="nowrap"><label id="popuplocationlabel" for="popuplocation">{#advlink_dlg.popup_location}</label></td>
|
117 |
+
<td><input type="checkbox" id="popupscrollbars" name="popupscrollbars" class="checkbox" onchange="buildOnClick();" /></td>
|
118 |
+
<td class="nowrap"><label id="popupscrollbarslabel" for="popupscrollbars">{#advlink_dlg.popup_scrollbars}</label></td>
|
119 |
+
</tr>
|
120 |
+
<tr>
|
121 |
+
<td><input type="checkbox" id="popupmenubar" name="popupmenubar" class="checkbox" onchange="buildOnClick();" /></td>
|
122 |
+
<td class="nowrap"><label id="popupmenubarlabel" for="popupmenubar">{#advlink_dlg.popup_menubar}</label></td>
|
123 |
+
<td><input type="checkbox" id="popupresizable" name="popupresizable" class="checkbox" onchange="buildOnClick();" /></td>
|
124 |
+
<td class="nowrap"><label id="popupresizablelabel" for="popupresizable">{#advlink_dlg.popup_resizable}</label></td>
|
125 |
+
</tr>
|
126 |
+
<tr>
|
127 |
+
<td><input type="checkbox" id="popuptoolbar" name="popuptoolbar" class="checkbox" onchange="buildOnClick();" /></td>
|
128 |
+
<td class="nowrap"><label id="popuptoolbarlabel" for="popuptoolbar">{#advlink_dlg.popup_toolbar}</label></td>
|
129 |
+
<td><input type="checkbox" id="popupdependent" name="popupdependent" class="checkbox" onchange="buildOnClick();" /></td>
|
130 |
+
<td class="nowrap"><label id="popupdependentlabel" for="popupdependent">{#advlink_dlg.popup_dependent}</label></td>
|
131 |
+
</tr>
|
132 |
+
<tr>
|
133 |
+
<td><input type="checkbox" id="popupstatus" name="popupstatus" class="checkbox" onchange="buildOnClick();" /></td>
|
134 |
+
<td class="nowrap"><label id="popupstatuslabel" for="popupstatus">{#advlink_dlg.popup_statusbar}</label></td>
|
135 |
+
<td><input type="checkbox" id="popupreturn" name="popupreturn" class="checkbox" onchange="buildOnClick();" checked="checked" /></td>
|
136 |
+
<td class="nowrap"><label id="popupreturnlabel" for="popupreturn">{#advlink_dlg.popup_return}</label></td>
|
137 |
+
</tr>
|
138 |
+
</table>
|
139 |
+
</fieldset>
|
140 |
+
</fieldset>
|
141 |
+
</div>
|
142 |
+
|
143 |
+
<div id="advanced_panel" class="panel">
|
144 |
+
<fieldset>
|
145 |
+
<legend>{#advlink_dlg.advanced_props}</legend>
|
146 |
+
|
147 |
+
<table border="0" cellpadding="0" cellspacing="4" role="presentation" >
|
148 |
+
<tr>
|
149 |
+
<td class="column1"><label id="idlabel" for="id">{#advlink_dlg.id}</label></td>
|
150 |
+
<td><input id="id" name="id" type="text" value="" /></td>
|
151 |
+
</tr>
|
152 |
+
|
153 |
+
<tr>
|
154 |
+
<td><label id="stylelabel" for="style">{#advlink_dlg.style}</label></td>
|
155 |
+
<td><input type="text" id="style" name="style" value="" /></td>
|
156 |
+
</tr>
|
157 |
+
|
158 |
+
<tr>
|
159 |
+
<td><label id="classeslabel" for="classes">{#advlink_dlg.classes}</label></td>
|
160 |
+
<td><input type="text" id="classes" name="classes" value="" onchange="selectByValue(this.form,'classlist',this.value,true);" /></td>
|
161 |
+
</tr>
|
162 |
+
|
163 |
+
<tr>
|
164 |
+
<td><label id="targetlabel" for="target">{#advlink_dlg.target_name}</label></td>
|
165 |
+
<td><input type="text" id="target" name="target" value="" onchange="selectByValue(this.form,'targetlist',this.value,true);" /></td>
|
166 |
+
</tr>
|
167 |
+
|
168 |
+
<tr>
|
169 |
+
<td class="column1"><label id="dirlabel" for="dir">{#advlink_dlg.langdir}</label></td>
|
170 |
+
<td>
|
171 |
+
<select id="dir" name="dir">
|
172 |
+
<option value="">{#not_set}</option>
|
173 |
+
<option value="ltr">{#advlink_dlg.ltr}</option>
|
174 |
+
<option value="rtl">{#advlink_dlg.rtl}</option>
|
175 |
+
</select>
|
176 |
+
</td>
|
177 |
+
</tr>
|
178 |
+
|
179 |
+
<tr>
|
180 |
+
<td><label id="hreflanglabel" for="hreflang">{#advlink_dlg.target_langcode}</label></td>
|
181 |
+
<td><input type="text" id="hreflang" name="hreflang" value="" /></td>
|
182 |
+
</tr>
|
183 |
+
|
184 |
+
<tr>
|
185 |
+
<td class="column1"><label id="langlabel" for="lang">{#advlink_dlg.langcode}</label></td>
|
186 |
+
<td>
|
187 |
+
<input id="lang" name="lang" type="text" value="" />
|
188 |
+
</td>
|
189 |
+
</tr>
|
190 |
+
|
191 |
+
<tr>
|
192 |
+
<td><label id="charsetlabel" for="charset">{#advlink_dlg.encoding}</label></td>
|
193 |
+
<td><input type="text" id="charset" name="charset" value="" /></td>
|
194 |
+
</tr>
|
195 |
+
|
196 |
+
<tr>
|
197 |
+
<td><label id="typelabel" for="type">{#advlink_dlg.mime}</label></td>
|
198 |
+
<td><input type="text" id="type" name="type" value="" /></td>
|
199 |
+
</tr>
|
200 |
+
|
201 |
+
<tr>
|
202 |
+
<td><label id="rellabel" for="rel">{#advlink_dlg.rel}</label></td>
|
203 |
+
<td><select id="rel" name="rel">
|
204 |
+
<option value="">{#not_set}</option>
|
205 |
+
<option value="lightbox">Lightbox</option>
|
206 |
+
<option value="alternate">Alternate</option>
|
207 |
+
<option value="designates">Designates</option>
|
208 |
+
<option value="stylesheet">Stylesheet</option>
|
209 |
+
<option value="start">Start</option>
|
210 |
+
<option value="next">Next</option>
|
211 |
+
<option value="prev">Prev</option>
|
212 |
+
<option value="contents">Contents</option>
|
213 |
+
<option value="index">Index</option>
|
214 |
+
<option value="glossary">Glossary</option>
|
215 |
+
<option value="copyright">Copyright</option>
|
216 |
+
<option value="chapter">Chapter</option>
|
217 |
+
<option value="subsection">Subsection</option>
|
218 |
+
<option value="appendix">Appendix</option>
|
219 |
+
<option value="help">Help</option>
|
220 |
+
<option value="bookmark">Bookmark</option>
|
221 |
+
<option value="nofollow">No Follow</option>
|
222 |
+
<option value="tag">Tag</option>
|
223 |
+
</select>
|
224 |
+
</td>
|
225 |
+
</tr>
|
226 |
+
|
227 |
+
<tr>
|
228 |
+
<td><label id="revlabel" for="rev">{#advlink_dlg.rev}</label></td>
|
229 |
+
<td><select id="rev" name="rev">
|
230 |
+
<option value="">{#not_set}</option>
|
231 |
+
<option value="alternate">Alternate</option>
|
232 |
+
<option value="designates">Designates</option>
|
233 |
+
<option value="stylesheet">Stylesheet</option>
|
234 |
+
<option value="start">Start</option>
|
235 |
+
<option value="next">Next</option>
|
236 |
+
<option value="prev">Prev</option>
|
237 |
+
<option value="contents">Contents</option>
|
238 |
+
<option value="index">Index</option>
|
239 |
+
<option value="glossary">Glossary</option>
|
240 |
+
<option value="copyright">Copyright</option>
|
241 |
+
<option value="chapter">Chapter</option>
|
242 |
+
<option value="subsection">Subsection</option>
|
243 |
+
<option value="appendix">Appendix</option>
|
244 |
+
<option value="help">Help</option>
|
245 |
+
<option value="bookmark">Bookmark</option>
|
246 |
+
</select>
|
247 |
+
</td>
|
248 |
+
</tr>
|
249 |
+
|
250 |
+
<tr>
|
251 |
+
<td><label id="tabindexlabel" for="tabindex">{#advlink_dlg.tabindex}</label></td>
|
252 |
+
<td><input type="text" id="tabindex" name="tabindex" value="" /></td>
|
253 |
+
</tr>
|
254 |
+
|
255 |
+
<tr>
|
256 |
+
<td><label id="accesskeylabel" for="accesskey">{#advlink_dlg.accesskey}</label></td>
|
257 |
+
<td><input type="text" id="accesskey" name="accesskey" value="" /></td>
|
258 |
+
</tr>
|
259 |
+
</table>
|
260 |
+
</fieldset>
|
261 |
+
</div>
|
262 |
+
|
263 |
+
<div id="events_panel" class="panel">
|
264 |
+
<fieldset>
|
265 |
+
<legend>{#advlink_dlg.event_props}</legend>
|
266 |
+
|
267 |
+
<table border="0" cellpadding="0" cellspacing="4" role="presentation" >
|
268 |
+
<tr>
|
269 |
+
<td class="column1"><label for="onfocus">onfocus</label></td>
|
270 |
+
<td><input id="onfocus" name="onfocus" type="text" value="" /></td>
|
271 |
+
</tr>
|
272 |
+
|
273 |
+
<tr>
|
274 |
+
<td class="column1"><label for="onblur">onblur</label></td>
|
275 |
+
<td><input id="onblur" name="onblur" type="text" value="" /></td>
|
276 |
+
</tr>
|
277 |
+
|
278 |
+
<tr>
|
279 |
+
<td class="column1"><label for="onclick">onclick</label></td>
|
280 |
+
<td><input id="onclick" name="onclick" type="text" value="" /></td>
|
281 |
+
</tr>
|
282 |
+
|
283 |
+
<tr>
|
284 |
+
<td class="column1"><label for="ondblclick">ondblclick</label></td>
|
285 |
+
<td><input id="ondblclick" name="ondblclick" type="text" value="" /></td>
|
286 |
+
</tr>
|
287 |
+
|
288 |
+
<tr>
|
289 |
+
<td class="column1"><label for="onmousedown">onmousedown</label></td>
|
290 |
+
<td><input id="onmousedown" name="onmousedown" type="text" value="" /></td>
|
291 |
+
</tr>
|
292 |
+
|
293 |
+
<tr>
|
294 |
+
<td class="column1"><label for="onmouseup">onmouseup</label></td>
|
295 |
+
<td><input id="onmouseup" name="onmouseup" type="text" value="" /></td>
|
296 |
+
</tr>
|
297 |
+
|
298 |
+
<tr>
|
299 |
+
<td class="column1"><label for="onmouseover">onmouseover</label></td>
|
300 |
+
<td><input id="onmouseover" name="onmouseover" type="text" value="" /></td>
|
301 |
+
</tr>
|
302 |
+
|
303 |
+
<tr>
|
304 |
+
<td class="column1"><label for="onmousemove">onmousemove</label></td>
|
305 |
+
<td><input id="onmousemove" name="onmousemove" type="text" value="" /></td>
|
306 |
+
</tr>
|
307 |
+
|
308 |
+
<tr>
|
309 |
+
<td class="column1"><label for="onmouseout">onmouseout</label></td>
|
310 |
+
<td><input id="onmouseout" name="onmouseout" type="text" value="" /></td>
|
311 |
+
</tr>
|
312 |
+
|
313 |
+
<tr>
|
314 |
+
<td class="column1"><label for="onkeypress">onkeypress</label></td>
|
315 |
+
<td><input id="onkeypress" name="onkeypress" type="text" value="" /></td>
|
316 |
+
</tr>
|
317 |
+
|
318 |
+
<tr>
|
319 |
+
<td class="column1"><label for="onkeydown">onkeydown</label></td>
|
320 |
+
<td><input id="onkeydown" name="onkeydown" type="text" value="" /></td>
|
321 |
+
</tr>
|
322 |
+
|
323 |
+
<tr>
|
324 |
+
<td class="column1"><label for="onkeyup">onkeyup</label></td>
|
325 |
+
<td><input id="onkeyup" name="onkeyup" type="text" value="" /></td>
|
326 |
+
</tr>
|
327 |
+
</table>
|
328 |
+
</fieldset>
|
329 |
+
</div>
|
330 |
+
</div>
|
331 |
+
|
332 |
+
<div class="mceActionPanel">
|
333 |
+
<input type="submit" id="insert" name="insert" value="{#insert}" />
|
334 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
335 |
+
</div>
|
336 |
+
</form>
|
337 |
+
</body>
|
338 |
+
</html>
|
mce/emotions/editor_plugin.js
CHANGED
@@ -1,40 +1,40 @@
|
|
1 |
-
/**
|
2 |
-
* $Id: editor_plugin_src.js 520 2008-01-07 16:30:32Z spocke $
|
3 |
-
*
|
4 |
-
* @author Moxiecode
|
5 |
-
* @copyright Copyright � 2004-2008, Moxiecode Systems AB, All rights reserved.
|
6 |
-
*/
|
7 |
-
|
8 |
-
(function() {
|
9 |
-
tinymce.create('tinymce.plugins.EmotionsPlugin', {
|
10 |
-
init : function(ed, url) {
|
11 |
-
// Register commands
|
12 |
-
ed.addCommand('mceEmotion', function() {
|
13 |
-
ed.windowManager.open({
|
14 |
-
file : url + '/emotions.htm',
|
15 |
-
width : 250 + parseInt(ed.getLang('emotions.delta_width', 0)),
|
16 |
-
height : 160 + parseInt(ed.getLang('emotions.delta_height', 0)),
|
17 |
-
inline : 1
|
18 |
-
}, {
|
19 |
-
plugin_url : url
|
20 |
-
});
|
21 |
-
});
|
22 |
-
|
23 |
-
// Register buttons
|
24 |
-
ed.addButton('emotions', {title : 'emotions.emotions_desc', cmd : 'mceEmotion'});
|
25 |
-
},
|
26 |
-
|
27 |
-
getInfo : function() {
|
28 |
-
return {
|
29 |
-
longname : 'Emotions',
|
30 |
-
author : 'Moxiecode Systems AB',
|
31 |
-
authorurl : 'http://tinymce.moxiecode.com',
|
32 |
-
infourl : 'http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/emotions',
|
33 |
-
version : tinymce.majorVersion + "." + tinymce.minorVersion
|
34 |
-
};
|
35 |
-
}
|
36 |
-
});
|
37 |
-
|
38 |
-
// Register plugin
|
39 |
-
tinymce.PluginManager.add('emotions', tinymce.plugins.EmotionsPlugin);
|
40 |
})();
|
1 |
+
/**
|
2 |
+
* $Id: editor_plugin_src.js 520 2008-01-07 16:30:32Z spocke $
|
3 |
+
*
|
4 |
+
* @author Moxiecode
|
5 |
+
* @copyright Copyright � 2004-2008, Moxiecode Systems AB, All rights reserved.
|
6 |
+
*/
|
7 |
+
|
8 |
+
(function() {
|
9 |
+
tinymce.create('tinymce.plugins.EmotionsPlugin', {
|
10 |
+
init : function(ed, url) {
|
11 |
+
// Register commands
|
12 |
+
ed.addCommand('mceEmotion', function() {
|
13 |
+
ed.windowManager.open({
|
14 |
+
file : url + '/emotions.htm',
|
15 |
+
width : 250 + parseInt(ed.getLang('emotions.delta_width', 0)),
|
16 |
+
height : 160 + parseInt(ed.getLang('emotions.delta_height', 0)),
|
17 |
+
inline : 1
|
18 |
+
}, {
|
19 |
+
plugin_url : url
|
20 |
+
});
|
21 |
+
});
|
22 |
+
|
23 |
+
// Register buttons
|
24 |
+
ed.addButton('emotions', {title : 'emotions.emotions_desc', cmd : 'mceEmotion'});
|
25 |
+
},
|
26 |
+
|
27 |
+
getInfo : function() {
|
28 |
+
return {
|
29 |
+
longname : 'Emotions',
|
30 |
+
author : 'Moxiecode Systems AB',
|
31 |
+
authorurl : 'http://tinymce.moxiecode.com',
|
32 |
+
infourl : 'http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/emotions',
|
33 |
+
version : tinymce.majorVersion + "." + tinymce.minorVersion
|
34 |
+
};
|
35 |
+
}
|
36 |
+
});
|
37 |
+
|
38 |
+
// Register plugin
|
39 |
+
tinymce.PluginManager.add('emotions', tinymce.plugins.EmotionsPlugin);
|
40 |
})();
|
mce/searchreplace/css/searchreplace.css
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
-
.panel_wrapper {height:85px;}
|
2 |
-
.panel_wrapper div.current {height:85px;}
|
3 |
-
|
4 |
-
/* IE */
|
5 |
-
* html .panel_wrapper {height:100px;}
|
6 |
-
* html .panel_wrapper div.current {height:100px;}
|
1 |
+
.panel_wrapper {height:85px;}
|
2 |
+
.panel_wrapper div.current {min-height:85px;height:auto;}
|
3 |
+
|
4 |
+
/* IE */
|
5 |
+
* html .panel_wrapper {height:100px;}
|
6 |
+
* html .panel_wrapper div.current {height:100px;}
|
mce/searchreplace/js/searchreplace.js
CHANGED
@@ -1,142 +1,148 @@
|
|
1 |
-
tinyMCEPopup.requireLangPack();
|
2 |
-
|
3 |
-
var SearchReplaceDialog = {
|
4 |
-
init : function(ed) {
|
5 |
-
var t = this, f = document.forms[0], m = tinyMCEPopup.getWindowArg("mode");
|
6 |
-
|
7 |
-
t.switchMode(m);
|
8 |
-
|
9 |
-
f[m + '_panel_searchstring'].value = tinyMCEPopup.getWindowArg("search_string");
|
10 |
-
|
11 |
-
// Focus input field
|
12 |
-
f[m + '_panel_searchstring'].focus();
|
13 |
-
|
14 |
-
mcTabs.onChange.add(function(tab_id, panel_id) {
|
15 |
-
t.switchMode(tab_id.substring(0, tab_id.indexOf('_')));
|
16 |
-
});
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
f[m + '
|
28 |
-
f[m + '
|
29 |
-
f[m + '
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
document.getElementById("
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
108 |
-
|
109 |
-
|
110 |
-
|
111 |
-
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
122 |
-
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
-
|
127 |
-
|
128 |
-
|
129 |
-
|
130 |
-
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
-
|
137 |
-
|
138 |
-
|
139 |
-
|
140 |
-
|
141 |
-
|
142 |
-
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
tinyMCEPopup.requireLangPack();
|
2 |
+
|
3 |
+
var SearchReplaceDialog = {
|
4 |
+
init : function(ed) {
|
5 |
+
var t = this, f = document.forms[0], m = tinyMCEPopup.getWindowArg("mode");
|
6 |
+
|
7 |
+
t.switchMode(m);
|
8 |
+
|
9 |
+
f[m + '_panel_searchstring'].value = tinyMCEPopup.getWindowArg("search_string");
|
10 |
+
|
11 |
+
// Focus input field
|
12 |
+
f[m + '_panel_searchstring'].focus();
|
13 |
+
|
14 |
+
mcTabs.onChange.add(function(tab_id, panel_id) {
|
15 |
+
t.switchMode(tab_id.substring(0, tab_id.indexOf('_')));
|
16 |
+
});
|
17 |
+
|
18 |
+
},
|
19 |
+
|
20 |
+
switchMode : function(m) {
|
21 |
+
var f, lm = this.lastMode;
|
22 |
+
|
23 |
+
if (lm != m) {
|
24 |
+
f = document.forms[0];
|
25 |
+
|
26 |
+
if (lm) {
|
27 |
+
f[m + '_panel_searchstring'].value = f[lm + '_panel_searchstring'].value;
|
28 |
+
f[m + '_panel_backwardsu'].checked = f[lm + '_panel_backwardsu'].checked;
|
29 |
+
f[m + '_panel_backwardsd'].checked = f[lm + '_panel_backwardsd'].checked;
|
30 |
+
f[m + '_panel_casesensitivebox'].checked = f[lm + '_panel_casesensitivebox'].checked;
|
31 |
+
}
|
32 |
+
|
33 |
+
mcTabs.displayTab(m + '_tab', m + '_panel');
|
34 |
+
document.getElementById("replaceBtn").style.display = (m == "replace") ? "inline" : "none";
|
35 |
+
document.getElementById("replaceAllBtn").style.display = (m == "replace") ? "inline" : "none";
|
36 |
+
this.lastMode = m;
|
37 |
+
}
|
38 |
+
},
|
39 |
+
|
40 |
+
searchNext : function(a) {
|
41 |
+
var ed = tinyMCEPopup.editor, se = ed.selection, r = se.getRng(), f, m = this.lastMode, s, b, fl = 0, w = ed.getWin(), wm = ed.windowManager, fo = 0;
|
42 |
+
|
43 |
+
if (tinymce.isIE11 && !window.find) {
|
44 |
+
ed.windowManager.alert("This feature is not available in IE 11+. Upgrade TinyMCE to 4.x to get this functionallity back.");
|
45 |
+
return;
|
46 |
+
}
|
47 |
+
|
48 |
+
// Get input
|
49 |
+
f = document.forms[0];
|
50 |
+
s = f[m + '_panel_searchstring'].value;
|
51 |
+
b = f[m + '_panel_backwardsu'].checked;
|
52 |
+
ca = f[m + '_panel_casesensitivebox'].checked;
|
53 |
+
rs = f['replace_panel_replacestring'].value;
|
54 |
+
|
55 |
+
if (tinymce.isIE) {
|
56 |
+
r = ed.getDoc().selection.createRange();
|
57 |
+
}
|
58 |
+
|
59 |
+
if (s == '')
|
60 |
+
return;
|
61 |
+
|
62 |
+
function fix() {
|
63 |
+
// Correct Firefox graphics glitches
|
64 |
+
// TODO: Verify if this is actually needed any more, maybe it was for very old FF versions?
|
65 |
+
r = se.getRng().cloneRange();
|
66 |
+
ed.getDoc().execCommand('SelectAll', false, null);
|
67 |
+
se.setRng(r);
|
68 |
+
};
|
69 |
+
|
70 |
+
function replace() {
|
71 |
+
ed.selection.setContent(rs); // Needs to be duplicated due to selection bug in IE
|
72 |
+
};
|
73 |
+
|
74 |
+
// IE flags
|
75 |
+
if (ca)
|
76 |
+
fl = fl | 4;
|
77 |
+
|
78 |
+
switch (a) {
|
79 |
+
case 'all':
|
80 |
+
// Move caret to beginning of text
|
81 |
+
ed.execCommand('SelectAll');
|
82 |
+
ed.selection.collapse(true);
|
83 |
+
|
84 |
+
if (tinymce.isIE) {
|
85 |
+
ed.focus();
|
86 |
+
r = ed.getDoc().selection.createRange();
|
87 |
+
|
88 |
+
while (r.findText(s, b ? -1 : 1, fl)) {
|
89 |
+
r.scrollIntoView();
|
90 |
+
r.select();
|
91 |
+
replace();
|
92 |
+
fo = 1;
|
93 |
+
|
94 |
+
if (b) {
|
95 |
+
r.moveEnd("character", -(rs.length)); // Otherwise will loop forever
|
96 |
+
}
|
97 |
+
}
|
98 |
+
|
99 |
+
tinyMCEPopup.storeSelection();
|
100 |
+
} else {
|
101 |
+
while (w.find(s, ca, b, false, false, false, false)) {
|
102 |
+
replace();
|
103 |
+
fo = 1;
|
104 |
+
}
|
105 |
+
}
|
106 |
+
|
107 |
+
if (fo)
|
108 |
+
tinyMCEPopup.alert(ed.getLang('searchreplace_dlg.allreplaced'));
|
109 |
+
else
|
110 |
+
tinyMCEPopup.alert(ed.getLang('searchreplace_dlg.notfound'));
|
111 |
+
|
112 |
+
return;
|
113 |
+
|
114 |
+
case 'current':
|
115 |
+
if (!ed.selection.isCollapsed())
|
116 |
+
replace();
|
117 |
+
|
118 |
+
break;
|
119 |
+
}
|
120 |
+
|
121 |
+
se.collapse(b);
|
122 |
+
r = se.getRng();
|
123 |
+
|
124 |
+
// Whats the point
|
125 |
+
if (!s)
|
126 |
+
return;
|
127 |
+
|
128 |
+
if (tinymce.isIE) {
|
129 |
+
ed.focus();
|
130 |
+
r = ed.getDoc().selection.createRange();
|
131 |
+
|
132 |
+
if (r.findText(s, b ? -1 : 1, fl)) {
|
133 |
+
r.scrollIntoView();
|
134 |
+
r.select();
|
135 |
+
} else
|
136 |
+
tinyMCEPopup.alert(ed.getLang('searchreplace_dlg.notfound'));
|
137 |
+
|
138 |
+
tinyMCEPopup.storeSelection();
|
139 |
+
} else {
|
140 |
+
if (!w.find(s, ca, b, false, false, false, false))
|
141 |
+
tinyMCEPopup.alert(ed.getLang('searchreplace_dlg.notfound'));
|
142 |
+
else
|
143 |
+
fix();
|
144 |
+
}
|
145 |
+
}
|
146 |
+
};
|
147 |
+
|
148 |
+
tinyMCEPopup.onInit.add(SearchReplaceDialog.init, SearchReplaceDialog);
|
mce/searchreplace/langs/langs.php
CHANGED
@@ -1,9 +1,12 @@
|
|
1 |
-
<?php
|
2 |
-
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
-
|
4 |
-
if ( is_file($lang_file) &&
|
5 |
-
$
|
6 |
-
|
7 |
-
|
8 |
-
$strings =
|
9 |
-
}
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
+
|
4 |
+
if ( ! is_file( $lang_file ) && defined( 'TINYMCE_ADVANCED_LANGUAGES_PATH' ) )
|
5 |
+
$lang_file = TINYMCE_ADVANCED_LANGUAGES_PATH . 'searchreplace/langs/' . $mce_locale . '_dlg.js';
|
6 |
+
|
7 |
+
if ( is_file( $lang_file ) && is_readable( $lang_file ) ) {
|
8 |
+
$strings = tdav_get_file( $lang_file );
|
9 |
+
} else {
|
10 |
+
$strings = tdav_get_file( dirname(__FILE__) . '/en_dlg.js' );
|
11 |
+
$strings = preg_replace( '/([\'"])en\./', '$1' . $mce_locale . '.', $strings, 1 );
|
12 |
+
}
|
mce/searchreplace/langs/zh_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('zh.searchreplace_dlg',{findwhat:"\
|
1 |
+
tinyMCE.addI18n('zh.searchreplace_dlg',{findwhat:"\u67e5\u627e\u76ee\u6807",replacewith:"\u66ff\u6362\u4e3a",direction:"\u5bfb\u627e\u65b9\u5411",up:"\u5411\u4e0a",down:"\u5411\u4e0b",mcase:"\u533a\u5206\u5927\u5c0f\u5199",findnext:"\u67e5\u627e\u4e0b\u4e00\u4e2a",allreplaced:"\u6240\u6709\u7b26\u5408\u7684\u5b57\u7b26\u4e32\u90fd\u5df2\u88ab\u66ff\u6362\u3002","searchnext_desc":"\u7ee7\u7eed\u67e5\u627e",notfound:"\u5b8c\u6210\u641c\u7d22\uff0c\u672a\u627e\u5230\u641c\u7d22\u9879\u3002","search_title":"\u67e5\u627e","replace_title":"\u67e5\u627e/\u66ff\u6362",replaceall:"\u5168\u90e8\u66ff\u6362",replace:"\u66ff\u6362"});
|
mce/searchreplace/searchreplace.htm
CHANGED
@@ -1,100 +1,100 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#searchreplace_dlg.replace_title}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="js/searchreplace.js?ver=
|
9 |
-
<link rel="stylesheet" type="text/css" href="css/searchreplace.css?ver=
|
10 |
-
</head>
|
11 |
-
<body style="display:none;" role="application" aria-labelledby="app_title">
|
12 |
-
<span id="app_title" style="display:none">{#searchreplace_dlg.replace_title}</span>
|
13 |
-
<form onsubmit="SearchReplaceDialog.searchNext('none');return false;" action="#">
|
14 |
-
<div class="tabs">
|
15 |
-
<ul>
|
16 |
-
<li id="search_tab" aria-controls="search_panel"><span><a href="javascript:SearchReplaceDialog.switchMode('search');" onmousedown="return false;">{#searchreplace.search_desc}</a></span></li>
|
17 |
-
<li id="replace_tab" aria-controls="replace_panel"><span><a href="javascript:SearchReplaceDialog.switchMode('replace');" onmousedown="return false;">{#searchreplace_dlg.replace}</a></span></li>
|
18 |
-
</ul>
|
19 |
-
</div>
|
20 |
-
|
21 |
-
<div class="panel_wrapper">
|
22 |
-
<div id="search_panel" class="panel">
|
23 |
-
<table role="presentation" border="0" cellspacing="0" cellpadding="2">
|
24 |
-
<tr>
|
25 |
-
<td><label for="search_panel_searchstring">{#searchreplace_dlg.findwhat}</label></td>
|
26 |
-
<td><input type="text" id="search_panel_searchstring" name="search_panel_searchstring" style="width: 200px" aria-required="true" /></td>
|
27 |
-
</tr>
|
28 |
-
<tr>
|
29 |
-
<td colspan="2">
|
30 |
-
<table role="presentation" border="0" cellspacing="0" cellpadding="0" class="direction">
|
31 |
-
<tr role="group" aria-labelledby="search_panel_backwards_label">
|
32 |
-
<td><label id="search_panel_backwards_label">{#searchreplace_dlg.direction}</label></td>
|
33 |
-
<td><input id="search_panel_backwardsu" name="search_panel_backwards" class="radio" type="radio" /></td>
|
34 |
-
<td><label for="search_panel_backwardsu">{#searchreplace_dlg.up}</label></td>
|
35 |
-
<td><input id="search_panel_backwardsd" name="search_panel_backwards" class="radio" type="radio" checked="checked" /></td>
|
36 |
-
<td><label for="search_panel_backwardsd">{#searchreplace_dlg.down}</label></td>
|
37 |
-
</tr>
|
38 |
-
</table>
|
39 |
-
</td>
|
40 |
-
</tr>
|
41 |
-
<tr>
|
42 |
-
<td colspan="2">
|
43 |
-
<table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
44 |
-
<tr>
|
45 |
-
<td><input id="search_panel_casesensitivebox" name="search_panel_casesensitivebox" class="checkbox" type="checkbox" /></td>
|
46 |
-
<td><label for="search_panel_casesensitivebox">{#searchreplace_dlg.mcase}</label></td>
|
47 |
-
</tr>
|
48 |
-
</table>
|
49 |
-
</td>
|
50 |
-
</tr>
|
51 |
-
</table>
|
52 |
-
</div>
|
53 |
-
|
54 |
-
<div id="replace_panel" class="panel">
|
55 |
-
<table role="presentation" border="0" cellspacing="0" cellpadding="2">
|
56 |
-
<tr>
|
57 |
-
<td><label for="replace_panel_searchstring">{#searchreplace_dlg.findwhat}</label></td>
|
58 |
-
<td><input type="text" id="replace_panel_searchstring" name="replace_panel_searchstring" style="width: 200px" aria-required="true" /></td>
|
59 |
-
</tr>
|
60 |
-
<tr>
|
61 |
-
<td><label for="replace_panel_replacestring">{#searchreplace_dlg.replacewith}</label></td>
|
62 |
-
<td><input type="text" id="replace_panel_replacestring" name="replace_panel_replacestring" style="width: 200px" aria-required="true" /></td>
|
63 |
-
</tr>
|
64 |
-
<tr>
|
65 |
-
<td colspan="2">
|
66 |
-
<table role="presentation" border="0" cellspacing="0" cellpadding="0" class="direction">
|
67 |
-
<tr role="group" aria-labelledby="replace_panel_dir_label">
|
68 |
-
<td><label id="replace_panel_dir_label">{#searchreplace_dlg.direction}</label></td>
|
69 |
-
<td><input id="replace_panel_backwardsu" name="replace_panel_backwards" class="radio" type="radio" /></td>
|
70 |
-
<td><label for="replace_panel_backwardsu">{#searchreplace_dlg.up}</label></td>
|
71 |
-
<td><input id="replace_panel_backwardsd" name="replace_panel_backwards" class="radio" type="radio" checked="checked" /></td>
|
72 |
-
<td><label for="replace_panel_backwardsd">{#searchreplace_dlg.down}</label></td>
|
73 |
-
</tr>
|
74 |
-
</table>
|
75 |
-
</td>
|
76 |
-
</tr>
|
77 |
-
<tr>
|
78 |
-
<td colspan="2">
|
79 |
-
<table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
80 |
-
<tr>
|
81 |
-
<td><input id="replace_panel_casesensitivebox" name="replace_panel_casesensitivebox" class="checkbox" type="checkbox" /></td>
|
82 |
-
<td><label for="replace_panel_casesensitivebox">{#searchreplace_dlg.mcase}</label></td>
|
83 |
-
</tr>
|
84 |
-
</table>
|
85 |
-
</td>
|
86 |
-
</tr>
|
87 |
-
</table>
|
88 |
-
</div>
|
89 |
-
|
90 |
-
</div>
|
91 |
-
|
92 |
-
<div class="mceActionPanel">
|
93 |
-
<input type="submit" id="insert" name="insert" value="{#searchreplace_dlg.findnext}" />
|
94 |
-
<input type="button" class="button" id="replaceBtn" name="replaceBtn" value="{#searchreplace_dlg.replace}" onclick="SearchReplaceDialog.searchNext('current');" />
|
95 |
-
<input type="button" class="button" id="replaceAllBtn" name="replaceAllBtn" value="{#searchreplace_dlg.replaceall}" onclick="SearchReplaceDialog.searchNext('all');" />
|
96 |
-
<input type="button" id="cancel" name="close" value="{#close}" onclick="tinyMCEPopup.close();" />
|
97 |
-
</div>
|
98 |
-
</form>
|
99 |
-
</body>
|
100 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#searchreplace_dlg.replace_title}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="js/searchreplace.js?ver=359"></script>
|
9 |
+
<link rel="stylesheet" type="text/css" href="css/searchreplace.css?ver=359" />
|
10 |
+
</head>
|
11 |
+
<body style="display:none;" role="application" aria-labelledby="app_title">
|
12 |
+
<span id="app_title" style="display:none">{#searchreplace_dlg.replace_title}</span>
|
13 |
+
<form onsubmit="SearchReplaceDialog.searchNext('none');return false;" action="#">
|
14 |
+
<div class="tabs">
|
15 |
+
<ul>
|
16 |
+
<li id="search_tab" aria-controls="search_panel"><span><a href="javascript:SearchReplaceDialog.switchMode('search');" onmousedown="return false;">{#searchreplace.search_desc}</a></span></li>
|
17 |
+
<li id="replace_tab" aria-controls="replace_panel"><span><a href="javascript:SearchReplaceDialog.switchMode('replace');" onmousedown="return false;">{#searchreplace_dlg.replace}</a></span></li>
|
18 |
+
</ul>
|
19 |
+
</div>
|
20 |
+
|
21 |
+
<div class="panel_wrapper">
|
22 |
+
<div id="search_panel" class="panel">
|
23 |
+
<table role="presentation" border="0" cellspacing="0" cellpadding="2">
|
24 |
+
<tr>
|
25 |
+
<td><label for="search_panel_searchstring">{#searchreplace_dlg.findwhat}</label></td>
|
26 |
+
<td><input type="text" id="search_panel_searchstring" name="search_panel_searchstring" style="width: 200px" aria-required="true" /></td>
|
27 |
+
</tr>
|
28 |
+
<tr>
|
29 |
+
<td colspan="2">
|
30 |
+
<table role="presentation" border="0" cellspacing="0" cellpadding="0" class="direction">
|
31 |
+
<tr role="group" aria-labelledby="search_panel_backwards_label">
|
32 |
+
<td><label id="search_panel_backwards_label">{#searchreplace_dlg.direction}</label></td>
|
33 |
+
<td><input id="search_panel_backwardsu" name="search_panel_backwards" class="radio" type="radio" /></td>
|
34 |
+
<td><label for="search_panel_backwardsu">{#searchreplace_dlg.up}</label></td>
|
35 |
+
<td><input id="search_panel_backwardsd" name="search_panel_backwards" class="radio" type="radio" checked="checked" /></td>
|
36 |
+
<td><label for="search_panel_backwardsd">{#searchreplace_dlg.down}</label></td>
|
37 |
+
</tr>
|
38 |
+
</table>
|
39 |
+
</td>
|
40 |
+
</tr>
|
41 |
+
<tr>
|
42 |
+
<td colspan="2">
|
43 |
+
<table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
44 |
+
<tr>
|
45 |
+
<td><input id="search_panel_casesensitivebox" name="search_panel_casesensitivebox" class="checkbox" type="checkbox" /></td>
|
46 |
+
<td><label for="search_panel_casesensitivebox">{#searchreplace_dlg.mcase}</label></td>
|
47 |
+
</tr>
|
48 |
+
</table>
|
49 |
+
</td>
|
50 |
+
</tr>
|
51 |
+
</table>
|
52 |
+
</div>
|
53 |
+
|
54 |
+
<div id="replace_panel" class="panel">
|
55 |
+
<table role="presentation" border="0" cellspacing="0" cellpadding="2">
|
56 |
+
<tr>
|
57 |
+
<td><label for="replace_panel_searchstring">{#searchreplace_dlg.findwhat}</label></td>
|
58 |
+
<td><input type="text" id="replace_panel_searchstring" name="replace_panel_searchstring" style="width: 200px" aria-required="true" /></td>
|
59 |
+
</tr>
|
60 |
+
<tr>
|
61 |
+
<td><label for="replace_panel_replacestring">{#searchreplace_dlg.replacewith}</label></td>
|
62 |
+
<td><input type="text" id="replace_panel_replacestring" name="replace_panel_replacestring" style="width: 200px" aria-required="true" /></td>
|
63 |
+
</tr>
|
64 |
+
<tr>
|
65 |
+
<td colspan="2">
|
66 |
+
<table role="presentation" border="0" cellspacing="0" cellpadding="0" class="direction">
|
67 |
+
<tr role="group" aria-labelledby="replace_panel_dir_label">
|
68 |
+
<td><label id="replace_panel_dir_label">{#searchreplace_dlg.direction}</label></td>
|
69 |
+
<td><input id="replace_panel_backwardsu" name="replace_panel_backwards" class="radio" type="radio" /></td>
|
70 |
+
<td><label for="replace_panel_backwardsu">{#searchreplace_dlg.up}</label></td>
|
71 |
+
<td><input id="replace_panel_backwardsd" name="replace_panel_backwards" class="radio" type="radio" checked="checked" /></td>
|
72 |
+
<td><label for="replace_panel_backwardsd">{#searchreplace_dlg.down}</label></td>
|
73 |
+
</tr>
|
74 |
+
</table>
|
75 |
+
</td>
|
76 |
+
</tr>
|
77 |
+
<tr>
|
78 |
+
<td colspan="2">
|
79 |
+
<table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
80 |
+
<tr>
|
81 |
+
<td><input id="replace_panel_casesensitivebox" name="replace_panel_casesensitivebox" class="checkbox" type="checkbox" /></td>
|
82 |
+
<td><label for="replace_panel_casesensitivebox">{#searchreplace_dlg.mcase}</label></td>
|
83 |
+
</tr>
|
84 |
+
</table>
|
85 |
+
</td>
|
86 |
+
</tr>
|
87 |
+
</table>
|
88 |
+
</div>
|
89 |
+
|
90 |
+
</div>
|
91 |
+
|
92 |
+
<div class="mceActionPanel">
|
93 |
+
<input type="submit" id="insert" name="insert" value="{#searchreplace_dlg.findnext}" />
|
94 |
+
<input type="button" class="button" id="replaceBtn" name="replaceBtn" value="{#searchreplace_dlg.replace}" onclick="SearchReplaceDialog.searchNext('current');" />
|
95 |
+
<input type="button" class="button" id="replaceAllBtn" name="replaceAllBtn" value="{#searchreplace_dlg.replaceall}" onclick="SearchReplaceDialog.searchNext('all');" />
|
96 |
+
<input type="button" id="cancel" name="close" value="{#close}" onclick="tinyMCEPopup.close();" />
|
97 |
+
</div>
|
98 |
+
</form>
|
99 |
+
</body>
|
100 |
+
</html>
|
mce/style/css/props.css
CHANGED
@@ -1,14 +1,15 @@
|
|
1 |
-
#text_font {width:250px;}
|
2 |
-
#text_size {width:70px;}
|
3 |
-
.mceAddSelectValue {background:#DDD;}
|
4 |
-
select, #block_text_indent, #box_width, #box_height, #box_padding_top, #box_padding_right, #box_padding_bottom, #box_padding_left {width:70px;}
|
5 |
-
#box_margin_top, #box_margin_right, #box_margin_bottom, #box_margin_left, #positioning_width, #positioning_height, #positioning_zindex {width:70px;}
|
6 |
-
#positioning_placement_top, #positioning_placement_right, #positioning_placement_bottom, #positioning_placement_left {width:70px;}
|
7 |
-
#positioning_clip_top, #positioning_clip_right, #positioning_clip_bottom, #positioning_clip_left {width:70px;}
|
8 |
-
.panel_toggle_insert_span {padding-top:10px;}
|
9 |
-
.panel_wrapper div.current {padding-top:10px;height:
|
10 |
-
.delim {border-left:1px solid gray;}
|
11 |
-
.tdelim {border-bottom:1px solid gray;}
|
12 |
-
#block_display {width:145px;}
|
13 |
-
#list_type {width:115px;}
|
14 |
-
.disabled {background:#EEE;}
|
|
1 |
+
#text_font {width:250px;}
|
2 |
+
#text_size {width:70px;}
|
3 |
+
.mceAddSelectValue {background:#DDD;}
|
4 |
+
select, #block_text_indent, #box_width, #box_height, #box_padding_top, #box_padding_right, #box_padding_bottom, #box_padding_left {width:70px;}
|
5 |
+
#box_margin_top, #box_margin_right, #box_margin_bottom, #box_margin_left, #positioning_width, #positioning_height, #positioning_zindex {width:70px;}
|
6 |
+
#positioning_placement_top, #positioning_placement_right, #positioning_placement_bottom, #positioning_placement_left {width:70px;}
|
7 |
+
#positioning_clip_top, #positioning_clip_right, #positioning_clip_bottom, #positioning_clip_left {width:70px;}
|
8 |
+
.panel_toggle_insert_span {padding-top:10px;}
|
9 |
+
.panel_wrapper div.current {padding-top:10px;min-height:220px;height:auto;}
|
10 |
+
.delim {border-left:1px solid gray;}
|
11 |
+
.tdelim {border-bottom:1px solid gray;}
|
12 |
+
#block_display {width:145px;}
|
13 |
+
#list_type {width:115px;}
|
14 |
+
.disabled {background:#EEE;}
|
15 |
+
.mceActionPanel {margin:5px 0;}
|
mce/style/js/props.js
CHANGED
@@ -1,709 +1,709 @@
|
|
1 |
-
tinyMCEPopup.requireLangPack();
|
2 |
-
|
3 |
-
var defaultFonts = "" +
|
4 |
-
"Arial, Helvetica, sans-serif=Arial, Helvetica, sans-serif;" +
|
5 |
-
"Times New Roman, Times, serif=Times New Roman, Times, serif;" +
|
6 |
-
"Courier New, Courier, mono=Courier New, Courier, mono;" +
|
7 |
-
"Times New Roman, Times, serif=Times New Roman, Times, serif;" +
|
8 |
-
"Georgia, Times New Roman, Times, serif=Georgia, Times New Roman, Times, serif;" +
|
9 |
-
"Verdana, Arial, Helvetica, sans-serif=Verdana, Arial, Helvetica, sans-serif;" +
|
10 |
-
"Geneva, Arial, Helvetica, sans-serif=Geneva, Arial, Helvetica, sans-serif";
|
11 |
-
|
12 |
-
var defaultSizes = "9;10;12;14;16;18;24;xx-small;x-small;small;medium;large;x-large;xx-large;smaller;larger";
|
13 |
-
var defaultMeasurement = "+pixels=px;points=pt;inches=in;centimetres=cm;millimetres=mm;picas=pc;ems=em;exs=ex;%";
|
14 |
-
var defaultSpacingMeasurement = "pixels=px;points=pt;inches=in;centimetres=cm;millimetres=mm;picas=pc;+ems=em;exs=ex;%";
|
15 |
-
var defaultIndentMeasurement = "pixels=px;+points=pt;inches=in;centimetres=cm;millimetres=mm;picas=pc;ems=em;exs=ex;%";
|
16 |
-
var defaultWeight = "normal;bold;bolder;lighter;100;200;300;400;500;600;700;800;900";
|
17 |
-
var defaultTextStyle = "normal;italic;oblique";
|
18 |
-
var defaultVariant = "normal;small-caps";
|
19 |
-
var defaultLineHeight = "normal";
|
20 |
-
var defaultAttachment = "fixed;scroll";
|
21 |
-
var defaultRepeat = "no-repeat;repeat;repeat-x;repeat-y";
|
22 |
-
var defaultPosH = "left;center;right";
|
23 |
-
var defaultPosV = "top;center;bottom";
|
24 |
-
var defaultVAlign = "baseline;sub;super;top;text-top;middle;bottom;text-bottom";
|
25 |
-
var defaultDisplay = "inline;block;list-item;run-in;compact;marker;table;inline-table;table-row-group;table-header-group;table-footer-group;table-row;table-column-group;table-column;table-cell;table-caption;none";
|
26 |
-
var defaultBorderStyle = "none;solid;dashed;dotted;double;groove;ridge;inset;outset";
|
27 |
-
var defaultBorderWidth = "thin;medium;thick";
|
28 |
-
var defaultListType = "disc;circle;square;decimal;lower-roman;upper-roman;lower-alpha;upper-alpha;none";
|
29 |
-
|
30 |
-
function aggregateStyles(allStyles) {
|
31 |
-
var mergedStyles = {};
|
32 |
-
|
33 |
-
tinymce.each(allStyles, function(style) {
|
34 |
-
if (style !== '') {
|
35 |
-
var parsedStyles = tinyMCEPopup.editor.dom.parseStyle(style);
|
36 |
-
for (var name in parsedStyles) {
|
37 |
-
if (parsedStyles.hasOwnProperty(name)) {
|
38 |
-
if (mergedStyles[name] === undefined) {
|
39 |
-
mergedStyles[name] = parsedStyles[name];
|
40 |
-
}
|
41 |
-
else if (name === 'text-decoration') {
|
42 |
-
if (mergedStyles[name].indexOf(parsedStyles[name]) === -1) {
|
43 |
-
mergedStyles[name] = mergedStyles[name] +' '+ parsedStyles[name];
|
44 |
-
}
|
45 |
-
}
|
46 |
-
}
|
47 |
-
}
|
48 |
-
}
|
49 |
-
});
|
50 |
-
|
51 |
-
return mergedStyles;
|
52 |
-
}
|
53 |
-
|
54 |
-
var applyActionIsInsert;
|
55 |
-
var existingStyles;
|
56 |
-
|
57 |
-
function init(ed) {
|
58 |
-
var ce = document.getElementById('container'), h;
|
59 |
-
|
60 |
-
existingStyles = aggregateStyles(tinyMCEPopup.getWindowArg('styles'));
|
61 |
-
ce.style.cssText = tinyMCEPopup.editor.dom.serializeStyle(existingStyles);
|
62 |
-
|
63 |
-
applyActionIsInsert = ed.getParam("edit_css_style_insert_span", false);
|
64 |
-
document.getElementById('toggle_insert_span').checked = applyActionIsInsert;
|
65 |
-
|
66 |
-
h = getBrowserHTML('background_image_browser','background_image','image','advimage');
|
67 |
-
document.getElementById("background_image_browser").innerHTML = h;
|
68 |
-
|
69 |
-
document.getElementById('text_color_pickcontainer').innerHTML = getColorPickerHTML('text_color_pick','text_color');
|
70 |
-
document.getElementById('background_color_pickcontainer').innerHTML = getColorPickerHTML('background_color_pick','background_color');
|
71 |
-
document.getElementById('border_color_top_pickcontainer').innerHTML = getColorPickerHTML('border_color_top_pick','border_color_top');
|
72 |
-
document.getElementById('border_color_right_pickcontainer').innerHTML = getColorPickerHTML('border_color_right_pick','border_color_right');
|
73 |
-
document.getElementById('border_color_bottom_pickcontainer').innerHTML = getColorPickerHTML('border_color_bottom_pick','border_color_bottom');
|
74 |
-
document.getElementById('border_color_left_pickcontainer').innerHTML = getColorPickerHTML('border_color_left_pick','border_color_left');
|
75 |
-
|
76 |
-
fillSelect(0, 'text_font', 'style_font', defaultFonts, ';', true);
|
77 |
-
fillSelect(0, 'text_size', 'style_font_size', defaultSizes, ';', true);
|
78 |
-
fillSelect(0, 'text_size_measurement', 'style_font_size_measurement', defaultMeasurement, ';', true);
|
79 |
-
fillSelect(0, 'text_case', 'style_text_case', "capitalize;uppercase;lowercase", ';', true);
|
80 |
-
fillSelect(0, 'text_weight', 'style_font_weight', defaultWeight, ';', true);
|
81 |
-
fillSelect(0, 'text_style', 'style_font_style', defaultTextStyle, ';', true);
|
82 |
-
fillSelect(0, 'text_variant', 'style_font_variant', defaultVariant, ';', true);
|
83 |
-
fillSelect(0, 'text_lineheight', 'style_font_line_height', defaultLineHeight, ';', true);
|
84 |
-
fillSelect(0, 'text_lineheight_measurement', 'style_font_line_height_measurement', defaultMeasurement, ';', true);
|
85 |
-
|
86 |
-
fillSelect(0, 'background_attachment', 'style_background_attachment', defaultAttachment, ';', true);
|
87 |
-
fillSelect(0, 'background_repeat', 'style_background_repeat', defaultRepeat, ';', true);
|
88 |
-
|
89 |
-
fillSelect(0, 'background_hpos_measurement', 'style_background_hpos_measurement', defaultMeasurement, ';', true);
|
90 |
-
fillSelect(0, 'background_vpos_measurement', 'style_background_vpos_measurement', defaultMeasurement, ';', true);
|
91 |
-
|
92 |
-
fillSelect(0, 'background_hpos', 'style_background_hpos', defaultPosH, ';', true);
|
93 |
-
fillSelect(0, 'background_vpos', 'style_background_vpos', defaultPosV, ';', true);
|
94 |
-
|
95 |
-
fillSelect(0, 'block_wordspacing', 'style_wordspacing', 'normal', ';', true);
|
96 |
-
fillSelect(0, 'block_wordspacing_measurement', 'style_wordspacing_measurement', defaultSpacingMeasurement, ';', true);
|
97 |
-
fillSelect(0, 'block_letterspacing', 'style_letterspacing', 'normal', ';', true);
|
98 |
-
fillSelect(0, 'block_letterspacing_measurement', 'style_letterspacing_measurement', defaultSpacingMeasurement, ';', true);
|
99 |
-
fillSelect(0, 'block_vertical_alignment', 'style_vertical_alignment', defaultVAlign, ';', true);
|
100 |
-
fillSelect(0, 'block_text_align', 'style_text_align', "left;right;center;justify", ';', true);
|
101 |
-
fillSelect(0, 'block_whitespace', 'style_whitespace', "normal;pre;nowrap", ';', true);
|
102 |
-
fillSelect(0, 'block_display', 'style_display', defaultDisplay, ';', true);
|
103 |
-
fillSelect(0, 'block_text_indent_measurement', 'style_text_indent_measurement', defaultIndentMeasurement, ';', true);
|
104 |
-
|
105 |
-
fillSelect(0, 'box_width_measurement', 'style_box_width_measurement', defaultMeasurement, ';', true);
|
106 |
-
fillSelect(0, 'box_height_measurement', 'style_box_height_measurement', defaultMeasurement, ';', true);
|
107 |
-
fillSelect(0, 'box_float', 'style_float', 'left;right;none', ';', true);
|
108 |
-
fillSelect(0, 'box_clear', 'style_clear', 'left;right;both;none', ';', true);
|
109 |
-
fillSelect(0, 'box_padding_left_measurement', 'style_padding_left_measurement', defaultMeasurement, ';', true);
|
110 |
-
fillSelect(0, 'box_padding_top_measurement', 'style_padding_top_measurement', defaultMeasurement, ';', true);
|
111 |
-
fillSelect(0, 'box_padding_bottom_measurement', 'style_padding_bottom_measurement', defaultMeasurement, ';', true);
|
112 |
-
fillSelect(0, 'box_padding_right_measurement', 'style_padding_right_measurement', defaultMeasurement, ';', true);
|
113 |
-
fillSelect(0, 'box_margin_left_measurement', 'style_margin_left_measurement', defaultMeasurement, ';', true);
|
114 |
-
fillSelect(0, 'box_margin_top_measurement', 'style_margin_top_measurement', defaultMeasurement, ';', true);
|
115 |
-
fillSelect(0, 'box_margin_bottom_measurement', 'style_margin_bottom_measurement', defaultMeasurement, ';', true);
|
116 |
-
fillSelect(0, 'box_margin_right_measurement', 'style_margin_right_measurement', defaultMeasurement, ';', true);
|
117 |
-
|
118 |
-
fillSelect(0, 'border_style_top', 'style_border_style_top', defaultBorderStyle, ';', true);
|
119 |
-
fillSelect(0, 'border_style_right', 'style_border_style_right', defaultBorderStyle, ';', true);
|
120 |
-
fillSelect(0, 'border_style_bottom', 'style_border_style_bottom', defaultBorderStyle, ';', true);
|
121 |
-
fillSelect(0, 'border_style_left', 'style_border_style_left', defaultBorderStyle, ';', true);
|
122 |
-
|
123 |
-
fillSelect(0, 'border_width_top', 'style_border_width_top', defaultBorderWidth, ';', true);
|
124 |
-
fillSelect(0, 'border_width_right', 'style_border_width_right', defaultBorderWidth, ';', true);
|
125 |
-
fillSelect(0, 'border_width_bottom', 'style_border_width_bottom', defaultBorderWidth, ';', true);
|
126 |
-
fillSelect(0, 'border_width_left', 'style_border_width_left', defaultBorderWidth, ';', true);
|
127 |
-
|
128 |
-
fillSelect(0, 'border_width_top_measurement', 'style_border_width_top_measurement', defaultMeasurement, ';', true);
|
129 |
-
fillSelect(0, 'border_width_right_measurement', 'style_border_width_right_measurement', defaultMeasurement, ';', true);
|
130 |
-
fillSelect(0, 'border_width_bottom_measurement', 'style_border_width_bottom_measurement', defaultMeasurement, ';', true);
|
131 |
-
fillSelect(0, 'border_width_left_measurement', 'style_border_width_left_measurement', defaultMeasurement, ';', true);
|
132 |
-
|
133 |
-
fillSelect(0, 'list_type', 'style_list_type', defaultListType, ';', true);
|
134 |
-
fillSelect(0, 'list_position', 'style_list_position', "inside;outside", ';', true);
|
135 |
-
|
136 |
-
fillSelect(0, 'positioning_type', 'style_positioning_type', "absolute;relative;static", ';', true);
|
137 |
-
fillSelect(0, 'positioning_visibility', 'style_positioning_visibility', "inherit;visible;hidden", ';', true);
|
138 |
-
|
139 |
-
fillSelect(0, 'positioning_width_measurement', 'style_positioning_width_measurement', defaultMeasurement, ';', true);
|
140 |
-
fillSelect(0, 'positioning_height_measurement', 'style_positioning_height_measurement', defaultMeasurement, ';', true);
|
141 |
-
fillSelect(0, 'positioning_overflow', 'style_positioning_overflow', "visible;hidden;scroll;auto", ';', true);
|
142 |
-
|
143 |
-
fillSelect(0, 'positioning_placement_top_measurement', 'style_positioning_placement_top_measurement', defaultMeasurement, ';', true);
|
144 |
-
fillSelect(0, 'positioning_placement_right_measurement', 'style_positioning_placement_right_measurement', defaultMeasurement, ';', true);
|
145 |
-
fillSelect(0, 'positioning_placement_bottom_measurement', 'style_positioning_placement_bottom_measurement', defaultMeasurement, ';', true);
|
146 |
-
fillSelect(0, 'positioning_placement_left_measurement', 'style_positioning_placement_left_measurement', defaultMeasurement, ';', true);
|
147 |
-
|
148 |
-
fillSelect(0, 'positioning_clip_top_measurement', 'style_positioning_clip_top_measurement', defaultMeasurement, ';', true);
|
149 |
-
fillSelect(0, 'positioning_clip_right_measurement', 'style_positioning_clip_right_measurement', defaultMeasurement, ';', true);
|
150 |
-
fillSelect(0, 'positioning_clip_bottom_measurement', 'style_positioning_clip_bottom_measurement', defaultMeasurement, ';', true);
|
151 |
-
fillSelect(0, 'positioning_clip_left_measurement', 'style_positioning_clip_left_measurement', defaultMeasurement, ';', true);
|
152 |
-
|
153 |
-
TinyMCE_EditableSelects.init();
|
154 |
-
setupFormData();
|
155 |
-
showDisabledControls();
|
156 |
-
}
|
157 |
-
|
158 |
-
function setupFormData() {
|
159 |
-
var ce = document.getElementById('container'), f = document.forms[0], s, b, i;
|
160 |
-
|
161 |
-
// Setup text fields
|
162 |
-
|
163 |
-
selectByValue(f, 'text_font', ce.style.fontFamily, true, true);
|
164 |
-
selectByValue(f, 'text_size', getNum(ce.style.fontSize), true, true);
|
165 |
-
selectByValue(f, 'text_size_measurement', getMeasurement(ce.style.fontSize));
|
166 |
-
selectByValue(f, 'text_weight', ce.style.fontWeight, true, true);
|
167 |
-
selectByValue(f, 'text_style', ce.style.fontStyle, true, true);
|
168 |
-
selectByValue(f, 'text_lineheight', getNum(ce.style.lineHeight), true, true);
|
169 |
-
selectByValue(f, 'text_lineheight_measurement', getMeasurement(ce.style.lineHeight));
|
170 |
-
selectByValue(f, 'text_case', ce.style.textTransform, true, true);
|
171 |
-
selectByValue(f, 'text_variant', ce.style.fontVariant, true, true);
|
172 |
-
f.text_color.value = tinyMCEPopup.editor.dom.toHex(ce.style.color);
|
173 |
-
updateColor('text_color_pick', 'text_color');
|
174 |
-
f.text_underline.checked = inStr(ce.style.textDecoration, 'underline');
|
175 |
-
f.text_overline.checked = inStr(ce.style.textDecoration, 'overline');
|
176 |
-
f.text_linethrough.checked = inStr(ce.style.textDecoration, 'line-through');
|
177 |
-
f.text_blink.checked = inStr(ce.style.textDecoration, 'blink');
|
178 |
-
f.text_none.checked = inStr(ce.style.textDecoration, 'none');
|
179 |
-
updateTextDecorations();
|
180 |
-
|
181 |
-
// Setup background fields
|
182 |
-
|
183 |
-
f.background_color.value = tinyMCEPopup.editor.dom.toHex(ce.style.backgroundColor);
|
184 |
-
updateColor('background_color_pick', 'background_color');
|
185 |
-
f.background_image.value = ce.style.backgroundImage.replace(new RegExp("url\\('?([^']*)'?\\)", 'gi'), "$1");
|
186 |
-
selectByValue(f, 'background_repeat', ce.style.backgroundRepeat, true, true);
|
187 |
-
selectByValue(f, 'background_attachment', ce.style.backgroundAttachment, true, true);
|
188 |
-
selectByValue(f, 'background_hpos', getNum(getVal(ce.style.backgroundPosition, 0)), true, true);
|
189 |
-
selectByValue(f, 'background_hpos_measurement', getMeasurement(getVal(ce.style.backgroundPosition, 0)));
|
190 |
-
selectByValue(f, 'background_vpos', getNum(getVal(ce.style.backgroundPosition, 1)), true, true);
|
191 |
-
selectByValue(f, 'background_vpos_measurement', getMeasurement(getVal(ce.style.backgroundPosition, 1)));
|
192 |
-
|
193 |
-
// Setup block fields
|
194 |
-
|
195 |
-
selectByValue(f, 'block_wordspacing', getNum(ce.style.wordSpacing), true, true);
|
196 |
-
selectByValue(f, 'block_wordspacing_measurement', getMeasurement(ce.style.wordSpacing));
|
197 |
-
selectByValue(f, 'block_letterspacing', getNum(ce.style.letterSpacing), true, true);
|
198 |
-
selectByValue(f, 'block_letterspacing_measurement', getMeasurement(ce.style.letterSpacing));
|
199 |
-
selectByValue(f, 'block_vertical_alignment', ce.style.verticalAlign, true, true);
|
200 |
-
selectByValue(f, 'block_text_align', ce.style.textAlign, true, true);
|
201 |
-
f.block_text_indent.value = getNum(ce.style.textIndent);
|
202 |
-
selectByValue(f, 'block_text_indent_measurement', getMeasurement(ce.style.textIndent));
|
203 |
-
selectByValue(f, 'block_whitespace', ce.style.whiteSpace, true, true);
|
204 |
-
selectByValue(f, 'block_display', ce.style.display, true, true);
|
205 |
-
|
206 |
-
// Setup box fields
|
207 |
-
|
208 |
-
f.box_width.value = getNum(ce.style.width);
|
209 |
-
selectByValue(f, 'box_width_measurement', getMeasurement(ce.style.width));
|
210 |
-
|
211 |
-
f.box_height.value = getNum(ce.style.height);
|
212 |
-
selectByValue(f, 'box_height_measurement', getMeasurement(ce.style.height));
|
213 |
-
selectByValue(f, 'box_float', ce.style.cssFloat || ce.style.styleFloat, true, true);
|
214 |
-
|
215 |
-
selectByValue(f, 'box_clear', ce.style.clear, true, true);
|
216 |
-
|
217 |
-
setupBox(f, ce, 'box_padding', 'padding', '');
|
218 |
-
setupBox(f, ce, 'box_margin', 'margin', '');
|
219 |
-
|
220 |
-
// Setup border fields
|
221 |
-
|
222 |
-
setupBox(f, ce, 'border_style', 'border', 'Style');
|
223 |
-
setupBox(f, ce, 'border_width', 'border', 'Width');
|
224 |
-
setupBox(f, ce, 'border_color', 'border', 'Color');
|
225 |
-
|
226 |
-
updateColor('border_color_top_pick', 'border_color_top');
|
227 |
-
updateColor('border_color_right_pick', 'border_color_right');
|
228 |
-
updateColor('border_color_bottom_pick', 'border_color_bottom');
|
229 |
-
updateColor('border_color_left_pick', 'border_color_left');
|
230 |
-
|
231 |
-
f.elements.border_color_top.value = tinyMCEPopup.editor.dom.toHex(f.elements.border_color_top.value);
|
232 |
-
f.elements.border_color_right.value = tinyMCEPopup.editor.dom.toHex(f.elements.border_color_right.value);
|
233 |
-
f.elements.border_color_bottom.value = tinyMCEPopup.editor.dom.toHex(f.elements.border_color_bottom.value);
|
234 |
-
f.elements.border_color_left.value = tinyMCEPopup.editor.dom.toHex(f.elements.border_color_left.value);
|
235 |
-
|
236 |
-
// Setup list fields
|
237 |
-
|
238 |
-
selectByValue(f, 'list_type', ce.style.listStyleType, true, true);
|
239 |
-
selectByValue(f, 'list_position', ce.style.listStylePosition, true, true);
|
240 |
-
f.list_bullet_image.value = ce.style.listStyleImage.replace(new RegExp("url\\('?([^']*)'?\\)", 'gi'), "$1");
|
241 |
-
|
242 |
-
// Setup box fields
|
243 |
-
|
244 |
-
selectByValue(f, 'positioning_type', ce.style.position, true, true);
|
245 |
-
selectByValue(f, 'positioning_visibility', ce.style.visibility, true, true);
|
246 |
-
selectByValue(f, 'positioning_overflow', ce.style.overflow, true, true);
|
247 |
-
f.positioning_zindex.value = ce.style.zIndex ? ce.style.zIndex : "";
|
248 |
-
|
249 |
-
f.positioning_width.value = getNum(ce.style.width);
|
250 |
-
selectByValue(f, 'positioning_width_measurement', getMeasurement(ce.style.width));
|
251 |
-
|
252 |
-
f.positioning_height.value = getNum(ce.style.height);
|
253 |
-
selectByValue(f, 'positioning_height_measurement', getMeasurement(ce.style.height));
|
254 |
-
|
255 |
-
setupBox(f, ce, 'positioning_placement', '', '', ['top', 'right', 'bottom', 'left']);
|
256 |
-
|
257 |
-
s = ce.style.clip.replace(new RegExp("rect\\('?([^']*)'?\\)", 'gi'), "$1");
|
258 |
-
s = s.replace(/,/g, ' ');
|
259 |
-
|
260 |
-
if (!hasEqualValues([getVal(s, 0), getVal(s, 1), getVal(s, 2), getVal(s, 3)])) {
|
261 |
-
f.positioning_clip_top.value = getNum(getVal(s, 0));
|
262 |
-
selectByValue(f, 'positioning_clip_top_measurement', getMeasurement(getVal(s, 0)));
|
263 |
-
f.positioning_clip_right.value = getNum(getVal(s, 1));
|
264 |
-
selectByValue(f, 'positioning_clip_right_measurement', getMeasurement(getVal(s, 1)));
|
265 |
-
f.positioning_clip_bottom.value = getNum(getVal(s, 2));
|
266 |
-
selectByValue(f, 'positioning_clip_bottom_measurement', getMeasurement(getVal(s, 2)));
|
267 |
-
f.positioning_clip_left.value = getNum(getVal(s, 3));
|
268 |
-
selectByValue(f, 'positioning_clip_left_measurement', getMeasurement(getVal(s, 3)));
|
269 |
-
} else {
|
270 |
-
f.positioning_clip_top.value = getNum(getVal(s, 0));
|
271 |
-
selectByValue(f, 'positioning_clip_top_measurement', getMeasurement(getVal(s, 0)));
|
272 |
-
f.positioning_clip_right.value = f.positioning_clip_bottom.value = f.positioning_clip_left.value;
|
273 |
-
}
|
274 |
-
|
275 |
-
// setupBox(f, ce, '', 'border', 'Color');
|
276 |
-
}
|
277 |
-
|
278 |
-
function getMeasurement(s) {
|
279 |
-
return s.replace(/^([0-9.]+)(.*)$/, "$2");
|
280 |
-
}
|
281 |
-
|
282 |
-
function getNum(s) {
|
283 |
-
if (new RegExp('^(?:[0-9.]+)(?:[a-z%]+)$', 'gi').test(s))
|
284 |
-
return s.replace(/[^0-9.]/g, '');
|
285 |
-
|
286 |
-
return s;
|
287 |
-
}
|
288 |
-
|
289 |
-
function inStr(s, n) {
|
290 |
-
return new RegExp(n, 'gi').test(s);
|
291 |
-
}
|
292 |
-
|
293 |
-
function getVal(s, i) {
|
294 |
-
var a = s.split(' ');
|
295 |
-
|
296 |
-
if (a.length > 1)
|
297 |
-
return a[i];
|
298 |
-
|
299 |
-
return "";
|
300 |
-
}
|
301 |
-
|
302 |
-
function setValue(f, n, v) {
|
303 |
-
if (f.elements[n].type == "text")
|
304 |
-
f.elements[n].value = v;
|
305 |
-
else
|
306 |
-
selectByValue(f, n, v, true, true);
|
307 |
-
}
|
308 |
-
|
309 |
-
function setupBox(f, ce, fp, pr, sf, b) {
|
310 |
-
if (typeof(b) == "undefined")
|
311 |
-
b = ['Top', 'Right', 'Bottom', 'Left'];
|
312 |
-
|
313 |
-
if (isSame(ce, pr, sf, b)) {
|
314 |
-
f.elements[fp + "_same"].checked = true;
|
315 |
-
|
316 |
-
setValue(f, fp + "_top", getNum(ce.style[pr + b[0] + sf]));
|
317 |
-
f.elements[fp + "_top"].disabled = false;
|
318 |
-
|
319 |
-
f.elements[fp + "_right"].value = "";
|
320 |
-
f.elements[fp + "_right"].disabled = true;
|
321 |
-
f.elements[fp + "_bottom"].value = "";
|
322 |
-
f.elements[fp + "_bottom"].disabled = true;
|
323 |
-
f.elements[fp + "_left"].value = "";
|
324 |
-
f.elements[fp + "_left"].disabled = true;
|
325 |
-
|
326 |
-
if (f.elements[fp + "_top_measurement"]) {
|
327 |
-
selectByValue(f, fp + '_top_measurement', getMeasurement(ce.style[pr + b[0] + sf]));
|
328 |
-
f.elements[fp + "_left_measurement"].disabled = true;
|
329 |
-
f.elements[fp + "_bottom_measurement"].disabled = true;
|
330 |
-
f.elements[fp + "_right_measurement"].disabled = true;
|
331 |
-
}
|
332 |
-
} else {
|
333 |
-
f.elements[fp + "_same"].checked = false;
|
334 |
-
|
335 |
-
setValue(f, fp + "_top", getNum(ce.style[pr + b[0] + sf]));
|
336 |
-
f.elements[fp + "_top"].disabled = false;
|
337 |
-
|
338 |
-
setValue(f, fp + "_right", getNum(ce.style[pr + b[1] + sf]));
|
339 |
-
f.elements[fp + "_right"].disabled = false;
|
340 |
-
|
341 |
-
setValue(f, fp + "_bottom", getNum(ce.style[pr + b[2] + sf]));
|
342 |
-
f.elements[fp + "_bottom"].disabled = false;
|
343 |
-
|
344 |
-
setValue(f, fp + "_left", getNum(ce.style[pr + b[3] + sf]));
|
345 |
-
f.elements[fp + "_left"].disabled = false;
|
346 |
-
|
347 |
-
if (f.elements[fp + "_top_measurement"]) {
|
348 |
-
selectByValue(f, fp + '_top_measurement', getMeasurement(ce.style[pr + b[0] + sf]));
|
349 |
-
selectByValue(f, fp + '_right_measurement', getMeasurement(ce.style[pr + b[1] + sf]));
|
350 |
-
selectByValue(f, fp + '_bottom_measurement', getMeasurement(ce.style[pr + b[2] + sf]));
|
351 |
-
selectByValue(f, fp + '_left_measurement', getMeasurement(ce.style[pr + b[3] + sf]));
|
352 |
-
f.elements[fp + "_left_measurement"].disabled = false;
|
353 |
-
f.elements[fp + "_bottom_measurement"].disabled = false;
|
354 |
-
f.elements[fp + "_right_measurement"].disabled = false;
|
355 |
-
}
|
356 |
-
}
|
357 |
-
}
|
358 |
-
|
359 |
-
function isSame(e, pr, sf, b) {
|
360 |
-
var a = [], i, x;
|
361 |
-
|
362 |
-
if (typeof(b) == "undefined")
|
363 |
-
b = ['Top', 'Right', 'Bottom', 'Left'];
|
364 |
-
|
365 |
-
if (typeof(sf) == "undefined" || sf == null)
|
366 |
-
sf = "";
|
367 |
-
|
368 |
-
a[0] = e.style[pr + b[0] + sf];
|
369 |
-
a[1] = e.style[pr + b[1] + sf];
|
370 |
-
a[2] = e.style[pr + b[2] + sf];
|
371 |
-
a[3] = e.style[pr + b[3] + sf];
|
372 |
-
|
373 |
-
for (i=0; i<a.length; i++) {
|
374 |
-
if (a[i] == null)
|
375 |
-
return false;
|
376 |
-
|
377 |
-
for (x=0; x<a.length; x++) {
|
378 |
-
if (a[x] != a[i])
|
379 |
-
return false;
|
380 |
-
}
|
381 |
-
}
|
382 |
-
|
383 |
-
return true;
|
384 |
-
};
|
385 |
-
|
386 |
-
function hasEqualValues(a) {
|
387 |
-
var i, x;
|
388 |
-
|
389 |
-
for (i=0; i<a.length; i++) {
|
390 |
-
if (a[i] == null)
|
391 |
-
return false;
|
392 |
-
|
393 |
-
for (x=0; x<a.length; x++) {
|
394 |
-
if (a[x] != a[i])
|
395 |
-
return false;
|
396 |
-
}
|
397 |
-
}
|
398 |
-
|
399 |
-
return true;
|
400 |
-
}
|
401 |
-
|
402 |
-
function toggleApplyAction() {
|
403 |
-
applyActionIsInsert = ! applyActionIsInsert;
|
404 |
-
}
|
405 |
-
|
406 |
-
function applyAction() {
|
407 |
-
var ce = document.getElementById('container'), ed = tinyMCEPopup.editor;
|
408 |
-
|
409 |
-
generateCSS();
|
410 |
-
|
411 |
-
tinyMCEPopup.restoreSelection();
|
412 |
-
|
413 |
-
var newStyles = tinyMCEPopup.editor.dom.parseStyle(ce.style.cssText);
|
414 |
-
|
415 |
-
if (applyActionIsInsert) {
|
416 |
-
ed.formatter.register('plugin_style', {
|
417 |
-
inline: 'span', styles: existingStyles
|
418 |
-
});
|
419 |
-
ed.formatter.remove('plugin_style');
|
420 |
-
|
421 |
-
ed.formatter.register('plugin_style', {
|
422 |
-
inline: 'span', styles: newStyles
|
423 |
-
});
|
424 |
-
ed.formatter.apply('plugin_style');
|
425 |
-
} else {
|
426 |
-
var nodes;
|
427 |
-
|
428 |
-
if (tinyMCEPopup.getWindowArg('applyStyleToBlocks')) {
|
429 |
-
nodes = ed.selection.getSelectedBlocks();
|
430 |
-
}
|
431 |
-
else {
|
432 |
-
nodes = ed.selection.getNode();
|
433 |
-
}
|
434 |
-
|
435 |
-
ed.dom.setAttrib(nodes, 'style', tinyMCEPopup.editor.dom.serializeStyle(newStyles));
|
436 |
-
}
|
437 |
-
}
|
438 |
-
|
439 |
-
function updateAction() {
|
440 |
-
applyAction();
|
441 |
-
tinyMCEPopup.close();
|
442 |
-
}
|
443 |
-
|
444 |
-
function generateCSS() {
|
445 |
-
var ce = document.getElementById('container'), f = document.forms[0], num = new RegExp('[0-9]+', 'g'), s, t;
|
446 |
-
|
447 |
-
ce.style.cssText = "";
|
448 |
-
|
449 |
-
// Build text styles
|
450 |
-
ce.style.fontFamily = f.text_font.value;
|
451 |
-
ce.style.fontSize = f.text_size.value + (isNum(f.text_size.value) ? (f.text_size_measurement.value || 'px') : "");
|
452 |
-
ce.style.fontStyle = f.text_style.value;
|
453 |
-
ce.style.lineHeight = f.text_lineheight.value + (isNum(f.text_lineheight.value) ? f.text_lineheight_measurement.value : "");
|
454 |
-
ce.style.textTransform = f.text_case.value;
|
455 |
-
ce.style.fontWeight = f.text_weight.value;
|
456 |
-
ce.style.fontVariant = f.text_variant.value;
|
457 |
-
ce.style.color = f.text_color.value;
|
458 |
-
|
459 |
-
s = "";
|
460 |
-
s += f.text_underline.checked ? " underline" : "";
|
461 |
-
s += f.text_overline.checked ? " overline" : "";
|
462 |
-
s += f.text_linethrough.checked ? " line-through" : "";
|
463 |
-
s += f.text_blink.checked ? " blink" : "";
|
464 |
-
s = s.length > 0 ? s.substring(1) : s;
|
465 |
-
|
466 |
-
if (f.text_none.checked)
|
467 |
-
s = "none";
|
468 |
-
|
469 |
-
ce.style.textDecoration = s;
|
470 |
-
|
471 |
-
// Build background styles
|
472 |
-
|
473 |
-
ce.style.backgroundColor = f.background_color.value;
|
474 |
-
ce.style.backgroundImage = f.background_image.value != "" ? "url(" + f.background_image.value + ")" : "";
|
475 |
-
ce.style.backgroundRepeat = f.background_repeat.value;
|
476 |
-
ce.style.backgroundAttachment = f.background_attachment.value;
|
477 |
-
|
478 |
-
if (f.background_hpos.value != "") {
|
479 |
-
s = "";
|
480 |
-
s += f.background_hpos.value + (isNum(f.background_hpos.value) ? f.background_hpos_measurement.value : "") + " ";
|
481 |
-
s += f.background_vpos.value + (isNum(f.background_vpos.value) ? f.background_vpos_measurement.value : "");
|
482 |
-
ce.style.backgroundPosition = s;
|
483 |
-
}
|
484 |
-
|
485 |
-
// Build block styles
|
486 |
-
|
487 |
-
ce.style.wordSpacing = f.block_wordspacing.value + (isNum(f.block_wordspacing.value) ? f.block_wordspacing_measurement.value : "");
|
488 |
-
ce.style.letterSpacing = f.block_letterspacing.value + (isNum(f.block_letterspacing.value) ? f.block_letterspacing_measurement.value : "");
|
489 |
-
ce.style.verticalAlign = f.block_vertical_alignment.value;
|
490 |
-
ce.style.textAlign = f.block_text_align.value;
|
491 |
-
ce.style.textIndent = f.block_text_indent.value + (isNum(f.block_text_indent.value) ? f.block_text_indent_measurement.value : "");
|
492 |
-
ce.style.whiteSpace = f.block_whitespace.value;
|
493 |
-
ce.style.display = f.block_display.value;
|
494 |
-
|
495 |
-
// Build box styles
|
496 |
-
|
497 |
-
ce.style.width = f.box_width.value + (isNum(f.box_width.value) ? f.box_width_measurement.value : "");
|
498 |
-
ce.style.height = f.box_height.value + (isNum(f.box_height.value) ? f.box_height_measurement.value : "");
|
499 |
-
ce.style.styleFloat = f.box_float.value;
|
500 |
-
ce.style.cssFloat = f.box_float.value;
|
501 |
-
|
502 |
-
ce.style.clear = f.box_clear.value;
|
503 |
-
|
504 |
-
if (!f.box_padding_same.checked) {
|
505 |
-
ce.style.paddingTop = f.box_padding_top.value + (isNum(f.box_padding_top.value) ? f.box_padding_top_measurement.value : "");
|
506 |
-
ce.style.paddingRight = f.box_padding_right.value + (isNum(f.box_padding_right.value) ? f.box_padding_right_measurement.value : "");
|
507 |
-
ce.style.paddingBottom = f.box_padding_bottom.value + (isNum(f.box_padding_bottom.value) ? f.box_padding_bottom_measurement.value : "");
|
508 |
-
ce.style.paddingLeft = f.box_padding_left.value + (isNum(f.box_padding_left.value) ? f.box_padding_left_measurement.value : "");
|
509 |
-
} else
|
510 |
-
ce.style.padding = f.box_padding_top.value + (isNum(f.box_padding_top.value) ? f.box_padding_top_measurement.value : "");
|
511 |
-
|
512 |
-
if (!f.box_margin_same.checked) {
|
513 |
-
ce.style.marginTop = f.box_margin_top.value + (isNum(f.box_margin_top.value) ? f.box_margin_top_measurement.value : "");
|
514 |
-
ce.style.marginRight = f.box_margin_right.value + (isNum(f.box_margin_right.value) ? f.box_margin_right_measurement.value : "");
|
515 |
-
ce.style.marginBottom = f.box_margin_bottom.value + (isNum(f.box_margin_bottom.value) ? f.box_margin_bottom_measurement.value : "");
|
516 |
-
ce.style.marginLeft = f.box_margin_left.value + (isNum(f.box_margin_left.value) ? f.box_margin_left_measurement.value : "");
|
517 |
-
} else
|
518 |
-
ce.style.margin = f.box_margin_top.value + (isNum(f.box_margin_top.value) ? f.box_margin_top_measurement.value : "");
|
519 |
-
|
520 |
-
// Build border styles
|
521 |
-
|
522 |
-
if (!f.border_style_same.checked) {
|
523 |
-
ce.style.borderTopStyle = f.border_style_top.value;
|
524 |
-
ce.style.borderRightStyle = f.border_style_right.value;
|
525 |
-
ce.style.borderBottomStyle = f.border_style_bottom.value;
|
526 |
-
ce.style.borderLeftStyle = f.border_style_left.value;
|
527 |
-
} else
|
528 |
-
ce.style.borderStyle = f.border_style_top.value;
|
529 |
-
|
530 |
-
if (!f.border_width_same.checked) {
|
531 |
-
ce.style.borderTopWidth = f.border_width_top.value + (isNum(f.border_width_top.value) ? f.border_width_top_measurement.value : "");
|
532 |
-
ce.style.borderRightWidth = f.border_width_right.value + (isNum(f.border_width_right.value) ? f.border_width_right_measurement.value : "");
|
533 |
-
ce.style.borderBottomWidth = f.border_width_bottom.value + (isNum(f.border_width_bottom.value) ? f.border_width_bottom_measurement.value : "");
|
534 |
-
ce.style.borderLeftWidth = f.border_width_left.value + (isNum(f.border_width_left.value) ? f.border_width_left_measurement.value : "");
|
535 |
-
} else
|
536 |
-
ce.style.borderWidth = f.border_width_top.value + (isNum(f.border_width_top.value) ? f.border_width_top_measurement.value : "");
|
537 |
-
|
538 |
-
if (!f.border_color_same.checked) {
|
539 |
-
ce.style.borderTopColor = f.border_color_top.value;
|
540 |
-
ce.style.borderRightColor = f.border_color_right.value;
|
541 |
-
ce.style.borderBottomColor = f.border_color_bottom.value;
|
542 |
-
ce.style.borderLeftColor = f.border_color_left.value;
|
543 |
-
} else
|
544 |
-
ce.style.borderColor = f.border_color_top.value;
|
545 |
-
|
546 |
-
// Build list styles
|
547 |
-
|
548 |
-
ce.style.listStyleType = f.list_type.value;
|
549 |
-
ce.style.listStylePosition = f.list_position.value;
|
550 |
-
ce.style.listStyleImage = f.list_bullet_image.value != "" ? "url(" + f.list_bullet_image.value + ")" : "";
|
551 |
-
|
552 |
-
// Build positioning styles
|
553 |
-
|
554 |
-
ce.style.position = f.positioning_type.value;
|
555 |
-
ce.style.visibility = f.positioning_visibility.value;
|
556 |
-
|
557 |
-
if (ce.style.width == "")
|
558 |
-
ce.style.width = f.positioning_width.value + (isNum(f.positioning_width.value) ? f.positioning_width_measurement.value : "");
|
559 |
-
|
560 |
-
if (ce.style.height == "")
|
561 |
-
ce.style.height = f.positioning_height.value + (isNum(f.positioning_height.value) ? f.positioning_height_measurement.value : "");
|
562 |
-
|
563 |
-
ce.style.zIndex = f.positioning_zindex.value;
|
564 |
-
ce.style.overflow = f.positioning_overflow.value;
|
565 |
-
|
566 |
-
if (!f.positioning_placement_same.checked) {
|
567 |
-
ce.style.top = f.positioning_placement_top.value + (isNum(f.positioning_placement_top.value) ? f.positioning_placement_top_measurement.value : "");
|
568 |
-
ce.style.right = f.positioning_placement_right.value + (isNum(f.positioning_placement_right.value) ? f.positioning_placement_right_measurement.value : "");
|
569 |
-
ce.style.bottom = f.positioning_placement_bottom.value + (isNum(f.positioning_placement_bottom.value) ? f.positioning_placement_bottom_measurement.value : "");
|
570 |
-
ce.style.left = f.positioning_placement_left.value + (isNum(f.positioning_placement_left.value) ? f.positioning_placement_left_measurement.value : "");
|
571 |
-
} else {
|
572 |
-
s = f.positioning_placement_top.value + (isNum(f.positioning_placement_top.value) ? f.positioning_placement_top_measurement.value : "");
|
573 |
-
ce.style.top = s;
|
574 |
-
ce.style.right = s;
|
575 |
-
ce.style.bottom = s;
|
576 |
-
ce.style.left = s;
|
577 |
-
}
|
578 |
-
|
579 |
-
if (!f.positioning_clip_same.checked) {
|
580 |
-
s = "rect(";
|
581 |
-
s += (isNum(f.positioning_clip_top.value) ? f.positioning_clip_top.value + f.positioning_clip_top_measurement.value : "auto") + " ";
|
582 |
-
s += (isNum(f.positioning_clip_right.value) ? f.positioning_clip_right.value + f.positioning_clip_right_measurement.value : "auto") + " ";
|
583 |
-
s += (isNum(f.positioning_clip_bottom.value) ? f.positioning_clip_bottom.value + f.positioning_clip_bottom_measurement.value : "auto") + " ";
|
584 |
-
s += (isNum(f.positioning_clip_left.value) ? f.positioning_clip_left.value + f.positioning_clip_left_measurement.value : "auto");
|
585 |
-
s += ")";
|
586 |
-
|
587 |
-
if (s != "rect(auto auto auto auto)")
|
588 |
-
ce.style.clip = s;
|
589 |
-
} else {
|
590 |
-
s = "rect(";
|
591 |
-
t = isNum(f.positioning_clip_top.value) ? f.positioning_clip_top.value + f.positioning_clip_top_measurement.value : "auto";
|
592 |
-
s += t + " ";
|
593 |
-
s += t + " ";
|
594 |
-
s += t + " ";
|
595 |
-
s += t + ")";
|
596 |
-
|
597 |
-
if (s != "rect(auto auto auto auto)")
|
598 |
-
ce.style.clip = s;
|
599 |
-
}
|
600 |
-
|
601 |
-
ce.style.cssText = ce.style.cssText;
|
602 |
-
}
|
603 |
-
|
604 |
-
function isNum(s) {
|
605 |
-
return new RegExp('[0-9]+', 'g').test(s);
|
606 |
-
}
|
607 |
-
|
608 |
-
function showDisabledControls() {
|
609 |
-
var f = document.forms, i, a;
|
610 |
-
|
611 |
-
for (i=0; i<f.length; i++) {
|
612 |
-
for (a=0; a<f[i].elements.length; a++) {
|
613 |
-
if (f[i].elements[a].disabled)
|
614 |
-
tinyMCEPopup.editor.dom.addClass(f[i].elements[a], "disabled");
|
615 |
-
else
|
616 |
-
tinyMCEPopup.editor.dom.removeClass(f[i].elements[a], "disabled");
|
617 |
-
}
|
618 |
-
}
|
619 |
-
}
|
620 |
-
|
621 |
-
function fillSelect(f, s, param, dval, sep, em) {
|
622 |
-
var i, ar, p, se;
|
623 |
-
|
624 |
-
f = document.forms[f];
|
625 |
-
sep = typeof(sep) == "undefined" ? ";" : sep;
|
626 |
-
|
627 |
-
if (em)
|
628 |
-
addSelectValue(f, s, "", "");
|
629 |
-
|
630 |
-
ar = tinyMCEPopup.getParam(param, dval).split(sep);
|
631 |
-
for (i=0; i<ar.length; i++) {
|
632 |
-
se = false;
|
633 |
-
|
634 |
-
if (ar[i].charAt(0) == '+') {
|
635 |
-
ar[i] = ar[i].substring(1);
|
636 |
-
se = true;
|
637 |
-
}
|
638 |
-
|
639 |
-
p = ar[i].split('=');
|
640 |
-
|
641 |
-
if (p.length > 1) {
|
642 |
-
addSelectValue(f, s, p[0], p[1]);
|
643 |
-
|
644 |
-
if (se)
|
645 |
-
selectByValue(f, s, p[1]);
|
646 |
-
} else {
|
647 |
-
addSelectValue(f, s, p[0], p[0]);
|
648 |
-
|
649 |
-
if (se)
|
650 |
-
selectByValue(f, s, p[0]);
|
651 |
-
}
|
652 |
-
}
|
653 |
-
}
|
654 |
-
|
655 |
-
function toggleSame(ce, pre) {
|
656 |
-
var el = document.forms[0].elements, i;
|
657 |
-
|
658 |
-
if (ce.checked) {
|
659 |
-
el[pre + "_top"].disabled = false;
|
660 |
-
el[pre + "_right"].disabled = true;
|
661 |
-
el[pre + "_bottom"].disabled = true;
|
662 |
-
el[pre + "_left"].disabled = true;
|
663 |
-
|
664 |
-
if (el[pre + "_top_measurement"]) {
|
665 |
-
el[pre + "_top_measurement"].disabled = false;
|
666 |
-
el[pre + "_right_measurement"].disabled = true;
|
667 |
-
el[pre + "_bottom_measurement"].disabled = true;
|
668 |
-
el[pre + "_left_measurement"].disabled = true;
|
669 |
-
}
|
670 |
-
} else {
|
671 |
-
el[pre + "_top"].disabled = false;
|
672 |
-
el[pre + "_right"].disabled = false;
|
673 |
-
el[pre + "_bottom"].disabled = false;
|
674 |
-
el[pre + "_left"].disabled = false;
|
675 |
-
|
676 |
-
if (el[pre + "_top_measurement"]) {
|
677 |
-
el[pre + "_top_measurement"].disabled = false;
|
678 |
-
el[pre + "_right_measurement"].disabled = false;
|
679 |
-
el[pre + "_bottom_measurement"].disabled = false;
|
680 |
-
el[pre + "_left_measurement"].disabled = false;
|
681 |
-
}
|
682 |
-
}
|
683 |
-
|
684 |
-
showDisabledControls();
|
685 |
-
}
|
686 |
-
|
687 |
-
function synch(fr, to) {
|
688 |
-
var f = document.forms[0];
|
689 |
-
|
690 |
-
f.elements[to].value = f.elements[fr].value;
|
691 |
-
|
692 |
-
if (f.elements[fr + "_measurement"])
|
693 |
-
selectByValue(f, to + "_measurement", f.elements[fr + "_measurement"].value);
|
694 |
-
}
|
695 |
-
|
696 |
-
function updateTextDecorations(){
|
697 |
-
var el = document.forms[0].elements;
|
698 |
-
|
699 |
-
var textDecorations = ["text_underline", "text_overline", "text_linethrough", "text_blink"];
|
700 |
-
var noneChecked = el["text_none"].checked;
|
701 |
-
tinymce.each(textDecorations, function(id) {
|
702 |
-
el[id].disabled = noneChecked;
|
703 |
-
if (noneChecked) {
|
704 |
-
el[id].checked = false;
|
705 |
-
}
|
706 |
-
});
|
707 |
-
}
|
708 |
-
|
709 |
-
tinyMCEPopup.onInit.add(init);
|
1 |
+
tinyMCEPopup.requireLangPack();
|
2 |
+
|
3 |
+
var defaultFonts = "" +
|
4 |
+
"Arial, Helvetica, sans-serif=Arial, Helvetica, sans-serif;" +
|
5 |
+
"Times New Roman, Times, serif=Times New Roman, Times, serif;" +
|
6 |
+
"Courier New, Courier, mono=Courier New, Courier, mono;" +
|
7 |
+
"Times New Roman, Times, serif=Times New Roman, Times, serif;" +
|
8 |
+
"Georgia, Times New Roman, Times, serif=Georgia, Times New Roman, Times, serif;" +
|
9 |
+
"Verdana, Arial, Helvetica, sans-serif=Verdana, Arial, Helvetica, sans-serif;" +
|
10 |
+
"Geneva, Arial, Helvetica, sans-serif=Geneva, Arial, Helvetica, sans-serif";
|
11 |
+
|
12 |
+
var defaultSizes = "9;10;12;14;16;18;24;xx-small;x-small;small;medium;large;x-large;xx-large;smaller;larger";
|
13 |
+
var defaultMeasurement = "+pixels=px;points=pt;inches=in;centimetres=cm;millimetres=mm;picas=pc;ems=em;exs=ex;%";
|
14 |
+
var defaultSpacingMeasurement = "pixels=px;points=pt;inches=in;centimetres=cm;millimetres=mm;picas=pc;+ems=em;exs=ex;%";
|
15 |
+
var defaultIndentMeasurement = "pixels=px;+points=pt;inches=in;centimetres=cm;millimetres=mm;picas=pc;ems=em;exs=ex;%";
|
16 |
+
var defaultWeight = "normal;bold;bolder;lighter;100;200;300;400;500;600;700;800;900";
|
17 |
+
var defaultTextStyle = "normal;italic;oblique";
|
18 |
+
var defaultVariant = "normal;small-caps";
|
19 |
+
var defaultLineHeight = "normal";
|
20 |
+
var defaultAttachment = "fixed;scroll";
|
21 |
+
var defaultRepeat = "no-repeat;repeat;repeat-x;repeat-y";
|
22 |
+
var defaultPosH = "left;center;right";
|
23 |
+
var defaultPosV = "top;center;bottom";
|
24 |
+
var defaultVAlign = "baseline;sub;super;top;text-top;middle;bottom;text-bottom";
|
25 |
+
var defaultDisplay = "inline;block;list-item;run-in;compact;marker;table;inline-table;table-row-group;table-header-group;table-footer-group;table-row;table-column-group;table-column;table-cell;table-caption;none";
|
26 |
+
var defaultBorderStyle = "none;solid;dashed;dotted;double;groove;ridge;inset;outset";
|
27 |
+
var defaultBorderWidth = "thin;medium;thick";
|
28 |
+
var defaultListType = "disc;circle;square;decimal;lower-roman;upper-roman;lower-alpha;upper-alpha;none";
|
29 |
+
|
30 |
+
function aggregateStyles(allStyles) {
|
31 |
+
var mergedStyles = {};
|
32 |
+
|
33 |
+
tinymce.each(allStyles, function(style) {
|
34 |
+
if (style !== '') {
|
35 |
+
var parsedStyles = tinyMCEPopup.editor.dom.parseStyle(style);
|
36 |
+
for (var name in parsedStyles) {
|
37 |
+
if (parsedStyles.hasOwnProperty(name)) {
|
38 |
+
if (mergedStyles[name] === undefined) {
|
39 |
+
mergedStyles[name] = parsedStyles[name];
|
40 |
+
}
|
41 |
+
else if (name === 'text-decoration') {
|
42 |
+
if (mergedStyles[name].indexOf(parsedStyles[name]) === -1) {
|
43 |
+
mergedStyles[name] = mergedStyles[name] +' '+ parsedStyles[name];
|
44 |
+
}
|
45 |
+
}
|
46 |
+
}
|
47 |
+
}
|
48 |
+
}
|
49 |
+
});
|
50 |
+
|
51 |
+
return mergedStyles;
|
52 |
+
}
|
53 |
+
|
54 |
+
var applyActionIsInsert;
|
55 |
+
var existingStyles;
|
56 |
+
|
57 |
+
function init(ed) {
|
58 |
+
var ce = document.getElementById('container'), h;
|
59 |
+
|
60 |
+
existingStyles = aggregateStyles(tinyMCEPopup.getWindowArg('styles'));
|
61 |
+
ce.style.cssText = tinyMCEPopup.editor.dom.serializeStyle(existingStyles);
|
62 |
+
|
63 |
+
applyActionIsInsert = ed.getParam("edit_css_style_insert_span", false);
|
64 |
+
document.getElementById('toggle_insert_span').checked = applyActionIsInsert;
|
65 |
+
|
66 |
+
h = getBrowserHTML('background_image_browser','background_image','image','advimage');
|
67 |
+
document.getElementById("background_image_browser").innerHTML = h;
|
68 |
+
|
69 |
+
document.getElementById('text_color_pickcontainer').innerHTML = getColorPickerHTML('text_color_pick','text_color');
|
70 |
+
document.getElementById('background_color_pickcontainer').innerHTML = getColorPickerHTML('background_color_pick','background_color');
|
71 |
+
document.getElementById('border_color_top_pickcontainer').innerHTML = getColorPickerHTML('border_color_top_pick','border_color_top');
|
72 |
+
document.getElementById('border_color_right_pickcontainer').innerHTML = getColorPickerHTML('border_color_right_pick','border_color_right');
|
73 |
+
document.getElementById('border_color_bottom_pickcontainer').innerHTML = getColorPickerHTML('border_color_bottom_pick','border_color_bottom');
|
74 |
+
document.getElementById('border_color_left_pickcontainer').innerHTML = getColorPickerHTML('border_color_left_pick','border_color_left');
|
75 |
+
|
76 |
+
fillSelect(0, 'text_font', 'style_font', defaultFonts, ';', true);
|
77 |
+
fillSelect(0, 'text_size', 'style_font_size', defaultSizes, ';', true);
|
78 |
+
fillSelect(0, 'text_size_measurement', 'style_font_size_measurement', defaultMeasurement, ';', true);
|
79 |
+
fillSelect(0, 'text_case', 'style_text_case', "capitalize;uppercase;lowercase", ';', true);
|
80 |
+
fillSelect(0, 'text_weight', 'style_font_weight', defaultWeight, ';', true);
|
81 |
+
fillSelect(0, 'text_style', 'style_font_style', defaultTextStyle, ';', true);
|
82 |
+
fillSelect(0, 'text_variant', 'style_font_variant', defaultVariant, ';', true);
|
83 |
+
fillSelect(0, 'text_lineheight', 'style_font_line_height', defaultLineHeight, ';', true);
|
84 |
+
fillSelect(0, 'text_lineheight_measurement', 'style_font_line_height_measurement', defaultMeasurement, ';', true);
|
85 |
+
|
86 |
+
fillSelect(0, 'background_attachment', 'style_background_attachment', defaultAttachment, ';', true);
|
87 |
+
fillSelect(0, 'background_repeat', 'style_background_repeat', defaultRepeat, ';', true);
|
88 |
+
|
89 |
+
fillSelect(0, 'background_hpos_measurement', 'style_background_hpos_measurement', defaultMeasurement, ';', true);
|
90 |
+
fillSelect(0, 'background_vpos_measurement', 'style_background_vpos_measurement', defaultMeasurement, ';', true);
|
91 |
+
|
92 |
+
fillSelect(0, 'background_hpos', 'style_background_hpos', defaultPosH, ';', true);
|
93 |
+
fillSelect(0, 'background_vpos', 'style_background_vpos', defaultPosV, ';', true);
|
94 |
+
|
95 |
+
fillSelect(0, 'block_wordspacing', 'style_wordspacing', 'normal', ';', true);
|
96 |
+
fillSelect(0, 'block_wordspacing_measurement', 'style_wordspacing_measurement', defaultSpacingMeasurement, ';', true);
|
97 |
+
fillSelect(0, 'block_letterspacing', 'style_letterspacing', 'normal', ';', true);
|
98 |
+
fillSelect(0, 'block_letterspacing_measurement', 'style_letterspacing_measurement', defaultSpacingMeasurement, ';', true);
|
99 |
+
fillSelect(0, 'block_vertical_alignment', 'style_vertical_alignment', defaultVAlign, ';', true);
|
100 |
+
fillSelect(0, 'block_text_align', 'style_text_align', "left;right;center;justify", ';', true);
|
101 |
+
fillSelect(0, 'block_whitespace', 'style_whitespace', "normal;pre;nowrap", ';', true);
|
102 |
+
fillSelect(0, 'block_display', 'style_display', defaultDisplay, ';', true);
|
103 |
+
fillSelect(0, 'block_text_indent_measurement', 'style_text_indent_measurement', defaultIndentMeasurement, ';', true);
|
104 |
+
|
105 |
+
fillSelect(0, 'box_width_measurement', 'style_box_width_measurement', defaultMeasurement, ';', true);
|
106 |
+
fillSelect(0, 'box_height_measurement', 'style_box_height_measurement', defaultMeasurement, ';', true);
|
107 |
+
fillSelect(0, 'box_float', 'style_float', 'left;right;none', ';', true);
|
108 |
+
fillSelect(0, 'box_clear', 'style_clear', 'left;right;both;none', ';', true);
|
109 |
+
fillSelect(0, 'box_padding_left_measurement', 'style_padding_left_measurement', defaultMeasurement, ';', true);
|
110 |
+
fillSelect(0, 'box_padding_top_measurement', 'style_padding_top_measurement', defaultMeasurement, ';', true);
|
111 |
+
fillSelect(0, 'box_padding_bottom_measurement', 'style_padding_bottom_measurement', defaultMeasurement, ';', true);
|
112 |
+
fillSelect(0, 'box_padding_right_measurement', 'style_padding_right_measurement', defaultMeasurement, ';', true);
|
113 |
+
fillSelect(0, 'box_margin_left_measurement', 'style_margin_left_measurement', defaultMeasurement, ';', true);
|
114 |
+
fillSelect(0, 'box_margin_top_measurement', 'style_margin_top_measurement', defaultMeasurement, ';', true);
|
115 |
+
fillSelect(0, 'box_margin_bottom_measurement', 'style_margin_bottom_measurement', defaultMeasurement, ';', true);
|
116 |
+
fillSelect(0, 'box_margin_right_measurement', 'style_margin_right_measurement', defaultMeasurement, ';', true);
|
117 |
+
|
118 |
+
fillSelect(0, 'border_style_top', 'style_border_style_top', defaultBorderStyle, ';', true);
|
119 |
+
fillSelect(0, 'border_style_right', 'style_border_style_right', defaultBorderStyle, ';', true);
|
120 |
+
fillSelect(0, 'border_style_bottom', 'style_border_style_bottom', defaultBorderStyle, ';', true);
|
121 |
+
fillSelect(0, 'border_style_left', 'style_border_style_left', defaultBorderStyle, ';', true);
|
122 |
+
|
123 |
+
fillSelect(0, 'border_width_top', 'style_border_width_top', defaultBorderWidth, ';', true);
|
124 |
+
fillSelect(0, 'border_width_right', 'style_border_width_right', defaultBorderWidth, ';', true);
|
125 |
+
fillSelect(0, 'border_width_bottom', 'style_border_width_bottom', defaultBorderWidth, ';', true);
|
126 |
+
fillSelect(0, 'border_width_left', 'style_border_width_left', defaultBorderWidth, ';', true);
|
127 |
+
|
128 |
+
fillSelect(0, 'border_width_top_measurement', 'style_border_width_top_measurement', defaultMeasurement, ';', true);
|
129 |
+
fillSelect(0, 'border_width_right_measurement', 'style_border_width_right_measurement', defaultMeasurement, ';', true);
|
130 |
+
fillSelect(0, 'border_width_bottom_measurement', 'style_border_width_bottom_measurement', defaultMeasurement, ';', true);
|
131 |
+
fillSelect(0, 'border_width_left_measurement', 'style_border_width_left_measurement', defaultMeasurement, ';', true);
|
132 |
+
|
133 |
+
fillSelect(0, 'list_type', 'style_list_type', defaultListType, ';', true);
|
134 |
+
fillSelect(0, 'list_position', 'style_list_position', "inside;outside", ';', true);
|
135 |
+
|
136 |
+
fillSelect(0, 'positioning_type', 'style_positioning_type', "absolute;relative;static", ';', true);
|
137 |
+
fillSelect(0, 'positioning_visibility', 'style_positioning_visibility', "inherit;visible;hidden", ';', true);
|
138 |
+
|
139 |
+
fillSelect(0, 'positioning_width_measurement', 'style_positioning_width_measurement', defaultMeasurement, ';', true);
|
140 |
+
fillSelect(0, 'positioning_height_measurement', 'style_positioning_height_measurement', defaultMeasurement, ';', true);
|
141 |
+
fillSelect(0, 'positioning_overflow', 'style_positioning_overflow', "visible;hidden;scroll;auto", ';', true);
|
142 |
+
|
143 |
+
fillSelect(0, 'positioning_placement_top_measurement', 'style_positioning_placement_top_measurement', defaultMeasurement, ';', true);
|
144 |
+
fillSelect(0, 'positioning_placement_right_measurement', 'style_positioning_placement_right_measurement', defaultMeasurement, ';', true);
|
145 |
+
fillSelect(0, 'positioning_placement_bottom_measurement', 'style_positioning_placement_bottom_measurement', defaultMeasurement, ';', true);
|
146 |
+
fillSelect(0, 'positioning_placement_left_measurement', 'style_positioning_placement_left_measurement', defaultMeasurement, ';', true);
|
147 |
+
|
148 |
+
fillSelect(0, 'positioning_clip_top_measurement', 'style_positioning_clip_top_measurement', defaultMeasurement, ';', true);
|
149 |
+
fillSelect(0, 'positioning_clip_right_measurement', 'style_positioning_clip_right_measurement', defaultMeasurement, ';', true);
|
150 |
+
fillSelect(0, 'positioning_clip_bottom_measurement', 'style_positioning_clip_bottom_measurement', defaultMeasurement, ';', true);
|
151 |
+
fillSelect(0, 'positioning_clip_left_measurement', 'style_positioning_clip_left_measurement', defaultMeasurement, ';', true);
|
152 |
+
|
153 |
+
TinyMCE_EditableSelects.init();
|
154 |
+
setupFormData();
|
155 |
+
showDisabledControls();
|
156 |
+
}
|
157 |
+
|
158 |
+
function setupFormData() {
|
159 |
+
var ce = document.getElementById('container'), f = document.forms[0], s, b, i;
|
160 |
+
|
161 |
+
// Setup text fields
|
162 |
+
|
163 |
+
selectByValue(f, 'text_font', ce.style.fontFamily, true, true);
|
164 |
+
selectByValue(f, 'text_size', getNum(ce.style.fontSize), true, true);
|
165 |
+
selectByValue(f, 'text_size_measurement', getMeasurement(ce.style.fontSize));
|
166 |
+
selectByValue(f, 'text_weight', ce.style.fontWeight, true, true);
|
167 |
+
selectByValue(f, 'text_style', ce.style.fontStyle, true, true);
|
168 |
+
selectByValue(f, 'text_lineheight', getNum(ce.style.lineHeight), true, true);
|
169 |
+
selectByValue(f, 'text_lineheight_measurement', getMeasurement(ce.style.lineHeight));
|
170 |
+
selectByValue(f, 'text_case', ce.style.textTransform, true, true);
|
171 |
+
selectByValue(f, 'text_variant', ce.style.fontVariant, true, true);
|
172 |
+
f.text_color.value = tinyMCEPopup.editor.dom.toHex(ce.style.color);
|
173 |
+
updateColor('text_color_pick', 'text_color');
|
174 |
+
f.text_underline.checked = inStr(ce.style.textDecoration, 'underline');
|
175 |
+
f.text_overline.checked = inStr(ce.style.textDecoration, 'overline');
|
176 |
+
f.text_linethrough.checked = inStr(ce.style.textDecoration, 'line-through');
|
177 |
+
f.text_blink.checked = inStr(ce.style.textDecoration, 'blink');
|
178 |
+
f.text_none.checked = inStr(ce.style.textDecoration, 'none');
|
179 |
+
updateTextDecorations();
|
180 |
+
|
181 |
+
// Setup background fields
|
182 |
+
|
183 |
+
f.background_color.value = tinyMCEPopup.editor.dom.toHex(ce.style.backgroundColor);
|
184 |
+
updateColor('background_color_pick', 'background_color');
|
185 |
+
f.background_image.value = ce.style.backgroundImage.replace(new RegExp("url\\('?([^']*)'?\\)", 'gi'), "$1");
|
186 |
+
selectByValue(f, 'background_repeat', ce.style.backgroundRepeat, true, true);
|
187 |
+
selectByValue(f, 'background_attachment', ce.style.backgroundAttachment, true, true);
|
188 |
+
selectByValue(f, 'background_hpos', getNum(getVal(ce.style.backgroundPosition, 0)), true, true);
|
189 |
+
selectByValue(f, 'background_hpos_measurement', getMeasurement(getVal(ce.style.backgroundPosition, 0)));
|
190 |
+
selectByValue(f, 'background_vpos', getNum(getVal(ce.style.backgroundPosition, 1)), true, true);
|
191 |
+
selectByValue(f, 'background_vpos_measurement', getMeasurement(getVal(ce.style.backgroundPosition, 1)));
|
192 |
+
|
193 |
+
// Setup block fields
|
194 |
+
|
195 |
+
selectByValue(f, 'block_wordspacing', getNum(ce.style.wordSpacing), true, true);
|
196 |
+
selectByValue(f, 'block_wordspacing_measurement', getMeasurement(ce.style.wordSpacing));
|
197 |
+
selectByValue(f, 'block_letterspacing', getNum(ce.style.letterSpacing), true, true);
|
198 |
+
selectByValue(f, 'block_letterspacing_measurement', getMeasurement(ce.style.letterSpacing));
|
199 |
+
selectByValue(f, 'block_vertical_alignment', ce.style.verticalAlign, true, true);
|
200 |
+
selectByValue(f, 'block_text_align', ce.style.textAlign, true, true);
|
201 |
+
f.block_text_indent.value = getNum(ce.style.textIndent);
|
202 |
+
selectByValue(f, 'block_text_indent_measurement', getMeasurement(ce.style.textIndent));
|
203 |
+
selectByValue(f, 'block_whitespace', ce.style.whiteSpace, true, true);
|
204 |
+
selectByValue(f, 'block_display', ce.style.display, true, true);
|
205 |
+
|
206 |
+
// Setup box fields
|
207 |
+
|
208 |
+
f.box_width.value = getNum(ce.style.width);
|
209 |
+
selectByValue(f, 'box_width_measurement', getMeasurement(ce.style.width));
|
210 |
+
|
211 |
+
f.box_height.value = getNum(ce.style.height);
|
212 |
+
selectByValue(f, 'box_height_measurement', getMeasurement(ce.style.height));
|
213 |
+
selectByValue(f, 'box_float', ce.style.cssFloat || ce.style.styleFloat, true, true);
|
214 |
+
|
215 |
+
selectByValue(f, 'box_clear', ce.style.clear, true, true);
|
216 |
+
|
217 |
+
setupBox(f, ce, 'box_padding', 'padding', '');
|
218 |
+
setupBox(f, ce, 'box_margin', 'margin', '');
|
219 |
+
|
220 |
+
// Setup border fields
|
221 |
+
|
222 |
+
setupBox(f, ce, 'border_style', 'border', 'Style');
|
223 |
+
setupBox(f, ce, 'border_width', 'border', 'Width');
|
224 |
+
setupBox(f, ce, 'border_color', 'border', 'Color');
|
225 |
+
|
226 |
+
updateColor('border_color_top_pick', 'border_color_top');
|
227 |
+
updateColor('border_color_right_pick', 'border_color_right');
|
228 |
+
updateColor('border_color_bottom_pick', 'border_color_bottom');
|
229 |
+
updateColor('border_color_left_pick', 'border_color_left');
|
230 |
+
|
231 |
+
f.elements.border_color_top.value = tinyMCEPopup.editor.dom.toHex(f.elements.border_color_top.value);
|
232 |
+
f.elements.border_color_right.value = tinyMCEPopup.editor.dom.toHex(f.elements.border_color_right.value);
|
233 |
+
f.elements.border_color_bottom.value = tinyMCEPopup.editor.dom.toHex(f.elements.border_color_bottom.value);
|
234 |
+
f.elements.border_color_left.value = tinyMCEPopup.editor.dom.toHex(f.elements.border_color_left.value);
|
235 |
+
|
236 |
+
// Setup list fields
|
237 |
+
|
238 |
+
selectByValue(f, 'list_type', ce.style.listStyleType, true, true);
|
239 |
+
selectByValue(f, 'list_position', ce.style.listStylePosition, true, true);
|
240 |
+
f.list_bullet_image.value = ce.style.listStyleImage.replace(new RegExp("url\\('?([^']*)'?\\)", 'gi'), "$1");
|
241 |
+
|
242 |
+
// Setup box fields
|
243 |
+
|
244 |
+
selectByValue(f, 'positioning_type', ce.style.position, true, true);
|
245 |
+
selectByValue(f, 'positioning_visibility', ce.style.visibility, true, true);
|
246 |
+
selectByValue(f, 'positioning_overflow', ce.style.overflow, true, true);
|
247 |
+
f.positioning_zindex.value = ce.style.zIndex ? ce.style.zIndex : "";
|
248 |
+
|
249 |
+
f.positioning_width.value = getNum(ce.style.width);
|
250 |
+
selectByValue(f, 'positioning_width_measurement', getMeasurement(ce.style.width));
|
251 |
+
|
252 |
+
f.positioning_height.value = getNum(ce.style.height);
|
253 |
+
selectByValue(f, 'positioning_height_measurement', getMeasurement(ce.style.height));
|
254 |
+
|
255 |
+
setupBox(f, ce, 'positioning_placement', '', '', ['top', 'right', 'bottom', 'left']);
|
256 |
+
|
257 |
+
s = ce.style.clip.replace(new RegExp("rect\\('?([^']*)'?\\)", 'gi'), "$1");
|
258 |
+
s = s.replace(/,/g, ' ');
|
259 |
+
|
260 |
+
if (!hasEqualValues([getVal(s, 0), getVal(s, 1), getVal(s, 2), getVal(s, 3)])) {
|
261 |
+
f.positioning_clip_top.value = getNum(getVal(s, 0));
|
262 |
+
selectByValue(f, 'positioning_clip_top_measurement', getMeasurement(getVal(s, 0)));
|
263 |
+
f.positioning_clip_right.value = getNum(getVal(s, 1));
|
264 |
+
selectByValue(f, 'positioning_clip_right_measurement', getMeasurement(getVal(s, 1)));
|
265 |
+
f.positioning_clip_bottom.value = getNum(getVal(s, 2));
|
266 |
+
selectByValue(f, 'positioning_clip_bottom_measurement', getMeasurement(getVal(s, 2)));
|
267 |
+
f.positioning_clip_left.value = getNum(getVal(s, 3));
|
268 |
+
selectByValue(f, 'positioning_clip_left_measurement', getMeasurement(getVal(s, 3)));
|
269 |
+
} else {
|
270 |
+
f.positioning_clip_top.value = getNum(getVal(s, 0));
|
271 |
+
selectByValue(f, 'positioning_clip_top_measurement', getMeasurement(getVal(s, 0)));
|
272 |
+
f.positioning_clip_right.value = f.positioning_clip_bottom.value = f.positioning_clip_left.value;
|
273 |
+
}
|
274 |
+
|
275 |
+
// setupBox(f, ce, '', 'border', 'Color');
|
276 |
+
}
|
277 |
+
|
278 |
+
function getMeasurement(s) {
|
279 |
+
return s.replace(/^([0-9.]+)(.*)$/, "$2");
|
280 |
+
}
|
281 |
+
|
282 |
+
function getNum(s) {
|
283 |
+
if (new RegExp('^(?:[0-9.]+)(?:[a-z%]+)$', 'gi').test(s))
|
284 |
+
return s.replace(/[^0-9.]/g, '');
|
285 |
+
|
286 |
+
return s;
|
287 |
+
}
|
288 |
+
|
289 |
+
function inStr(s, n) {
|
290 |
+
return new RegExp(n, 'gi').test(s);
|
291 |
+
}
|
292 |
+
|
293 |
+
function getVal(s, i) {
|
294 |
+
var a = s.split(' ');
|
295 |
+
|
296 |
+
if (a.length > 1)
|
297 |
+
return a[i];
|
298 |
+
|
299 |
+
return "";
|
300 |
+
}
|
301 |
+
|
302 |
+
function setValue(f, n, v) {
|
303 |
+
if (f.elements[n].type == "text")
|
304 |
+
f.elements[n].value = v;
|
305 |
+
else
|
306 |
+
selectByValue(f, n, v, true, true);
|
307 |
+
}
|
308 |
+
|
309 |
+
function setupBox(f, ce, fp, pr, sf, b) {
|
310 |
+
if (typeof(b) == "undefined")
|
311 |
+
b = ['Top', 'Right', 'Bottom', 'Left'];
|
312 |
+
|
313 |
+
if (isSame(ce, pr, sf, b)) {
|
314 |
+
f.elements[fp + "_same"].checked = true;
|
315 |
+
|
316 |
+
setValue(f, fp + "_top", getNum(ce.style[pr + b[0] + sf]));
|
317 |
+
f.elements[fp + "_top"].disabled = false;
|
318 |
+
|
319 |
+
f.elements[fp + "_right"].value = "";
|
320 |
+
f.elements[fp + "_right"].disabled = true;
|
321 |
+
f.elements[fp + "_bottom"].value = "";
|
322 |
+
f.elements[fp + "_bottom"].disabled = true;
|
323 |
+
f.elements[fp + "_left"].value = "";
|
324 |
+
f.elements[fp + "_left"].disabled = true;
|
325 |
+
|
326 |
+
if (f.elements[fp + "_top_measurement"]) {
|
327 |
+
selectByValue(f, fp + '_top_measurement', getMeasurement(ce.style[pr + b[0] + sf]));
|
328 |
+
f.elements[fp + "_left_measurement"].disabled = true;
|
329 |
+
f.elements[fp + "_bottom_measurement"].disabled = true;
|
330 |
+
f.elements[fp + "_right_measurement"].disabled = true;
|
331 |
+
}
|
332 |
+
} else {
|
333 |
+
f.elements[fp + "_same"].checked = false;
|
334 |
+
|
335 |
+
setValue(f, fp + "_top", getNum(ce.style[pr + b[0] + sf]));
|
336 |
+
f.elements[fp + "_top"].disabled = false;
|
337 |
+
|
338 |
+
setValue(f, fp + "_right", getNum(ce.style[pr + b[1] + sf]));
|
339 |
+
f.elements[fp + "_right"].disabled = false;
|
340 |
+
|
341 |
+
setValue(f, fp + "_bottom", getNum(ce.style[pr + b[2] + sf]));
|
342 |
+
f.elements[fp + "_bottom"].disabled = false;
|
343 |
+
|
344 |
+
setValue(f, fp + "_left", getNum(ce.style[pr + b[3] + sf]));
|
345 |
+
f.elements[fp + "_left"].disabled = false;
|
346 |
+
|
347 |
+
if (f.elements[fp + "_top_measurement"]) {
|
348 |
+
selectByValue(f, fp + '_top_measurement', getMeasurement(ce.style[pr + b[0] + sf]));
|
349 |
+
selectByValue(f, fp + '_right_measurement', getMeasurement(ce.style[pr + b[1] + sf]));
|
350 |
+
selectByValue(f, fp + '_bottom_measurement', getMeasurement(ce.style[pr + b[2] + sf]));
|
351 |
+
selectByValue(f, fp + '_left_measurement', getMeasurement(ce.style[pr + b[3] + sf]));
|
352 |
+
f.elements[fp + "_left_measurement"].disabled = false;
|
353 |
+
f.elements[fp + "_bottom_measurement"].disabled = false;
|
354 |
+
f.elements[fp + "_right_measurement"].disabled = false;
|
355 |
+
}
|
356 |
+
}
|
357 |
+
}
|
358 |
+
|
359 |
+
function isSame(e, pr, sf, b) {
|
360 |
+
var a = [], i, x;
|
361 |
+
|
362 |
+
if (typeof(b) == "undefined")
|
363 |
+
b = ['Top', 'Right', 'Bottom', 'Left'];
|
364 |
+
|
365 |
+
if (typeof(sf) == "undefined" || sf == null)
|
366 |
+
sf = "";
|
367 |
+
|
368 |
+
a[0] = e.style[pr + b[0] + sf];
|
369 |
+
a[1] = e.style[pr + b[1] + sf];
|
370 |
+
a[2] = e.style[pr + b[2] + sf];
|
371 |
+
a[3] = e.style[pr + b[3] + sf];
|
372 |
+
|
373 |
+
for (i=0; i<a.length; i++) {
|
374 |
+
if (a[i] == null)
|
375 |
+
return false;
|
376 |
+
|
377 |
+
for (x=0; x<a.length; x++) {
|
378 |
+
if (a[x] != a[i])
|
379 |
+
return false;
|
380 |
+
}
|
381 |
+
}
|
382 |
+
|
383 |
+
return true;
|
384 |
+
};
|
385 |
+
|
386 |
+
function hasEqualValues(a) {
|
387 |
+
var i, x;
|
388 |
+
|
389 |
+
for (i=0; i<a.length; i++) {
|
390 |
+
if (a[i] == null)
|
391 |
+
return false;
|
392 |
+
|
393 |
+
for (x=0; x<a.length; x++) {
|
394 |
+
if (a[x] != a[i])
|
395 |
+
return false;
|
396 |
+
}
|
397 |
+
}
|
398 |
+
|
399 |
+
return true;
|
400 |
+
}
|
401 |
+
|
402 |
+
function toggleApplyAction() {
|
403 |
+
applyActionIsInsert = ! applyActionIsInsert;
|
404 |
+
}
|
405 |
+
|
406 |
+
function applyAction() {
|
407 |
+
var ce = document.getElementById('container'), ed = tinyMCEPopup.editor;
|
408 |
+
|
409 |
+
generateCSS();
|
410 |
+
|
411 |
+
tinyMCEPopup.restoreSelection();
|
412 |
+
|
413 |
+
var newStyles = tinyMCEPopup.editor.dom.parseStyle(ce.style.cssText);
|
414 |
+
|
415 |
+
if (applyActionIsInsert) {
|
416 |
+
ed.formatter.register('plugin_style', {
|
417 |
+
inline: 'span', styles: existingStyles
|
418 |
+
});
|
419 |
+
ed.formatter.remove('plugin_style');
|
420 |
+
|
421 |
+
ed.formatter.register('plugin_style', {
|
422 |
+
inline: 'span', styles: newStyles
|
423 |
+
});
|
424 |
+
ed.formatter.apply('plugin_style');
|
425 |
+
} else {
|
426 |
+
var nodes;
|
427 |
+
|
428 |
+
if (tinyMCEPopup.getWindowArg('applyStyleToBlocks')) {
|
429 |
+
nodes = ed.selection.getSelectedBlocks();
|
430 |
+
}
|
431 |
+
else {
|
432 |
+
nodes = ed.selection.getNode();
|
433 |
+
}
|
434 |
+
|
435 |
+
ed.dom.setAttrib(nodes, 'style', tinyMCEPopup.editor.dom.serializeStyle(newStyles));
|
436 |
+
}
|
437 |
+
}
|
438 |
+
|
439 |
+
function updateAction() {
|
440 |
+
applyAction();
|
441 |
+
tinyMCEPopup.close();
|
442 |
+
}
|
443 |
+
|
444 |
+
function generateCSS() {
|
445 |
+
var ce = document.getElementById('container'), f = document.forms[0], num = new RegExp('[0-9]+', 'g'), s, t;
|
446 |
+
|
447 |
+
ce.style.cssText = "";
|
448 |
+
|
449 |
+
// Build text styles
|
450 |
+
ce.style.fontFamily = f.text_font.value;
|
451 |
+
ce.style.fontSize = f.text_size.value + (isNum(f.text_size.value) ? (f.text_size_measurement.value || 'px') : "");
|
452 |
+
ce.style.fontStyle = f.text_style.value;
|
453 |
+
ce.style.lineHeight = f.text_lineheight.value + (isNum(f.text_lineheight.value) ? f.text_lineheight_measurement.value : "");
|
454 |
+
ce.style.textTransform = f.text_case.value;
|
455 |
+
ce.style.fontWeight = f.text_weight.value;
|
456 |
+
ce.style.fontVariant = f.text_variant.value;
|
457 |
+
ce.style.color = f.text_color.value;
|
458 |
+
|
459 |
+
s = "";
|
460 |
+
s += f.text_underline.checked ? " underline" : "";
|
461 |
+
s += f.text_overline.checked ? " overline" : "";
|
462 |
+
s += f.text_linethrough.checked ? " line-through" : "";
|
463 |
+
s += f.text_blink.checked ? " blink" : "";
|
464 |
+
s = s.length > 0 ? s.substring(1) : s;
|
465 |
+
|
466 |
+
if (f.text_none.checked)
|
467 |
+
s = "none";
|
468 |
+
|
469 |
+
ce.style.textDecoration = s;
|
470 |
+
|
471 |
+
// Build background styles
|
472 |
+
|
473 |
+
ce.style.backgroundColor = f.background_color.value;
|
474 |
+
ce.style.backgroundImage = f.background_image.value != "" ? "url(" + f.background_image.value + ")" : "";
|
475 |
+
ce.style.backgroundRepeat = f.background_repeat.value;
|
476 |
+
ce.style.backgroundAttachment = f.background_attachment.value;
|
477 |
+
|
478 |
+
if (f.background_hpos.value != "") {
|
479 |
+
s = "";
|
480 |
+
s += f.background_hpos.value + (isNum(f.background_hpos.value) ? f.background_hpos_measurement.value : "") + " ";
|
481 |
+
s += f.background_vpos.value + (isNum(f.background_vpos.value) ? f.background_vpos_measurement.value : "");
|
482 |
+
ce.style.backgroundPosition = s;
|
483 |
+
}
|
484 |
+
|
485 |
+
// Build block styles
|
486 |
+
|
487 |
+
ce.style.wordSpacing = f.block_wordspacing.value + (isNum(f.block_wordspacing.value) ? f.block_wordspacing_measurement.value : "");
|
488 |
+
ce.style.letterSpacing = f.block_letterspacing.value + (isNum(f.block_letterspacing.value) ? f.block_letterspacing_measurement.value : "");
|
489 |
+
ce.style.verticalAlign = f.block_vertical_alignment.value;
|
490 |
+
ce.style.textAlign = f.block_text_align.value;
|
491 |
+
ce.style.textIndent = f.block_text_indent.value + (isNum(f.block_text_indent.value) ? f.block_text_indent_measurement.value : "");
|
492 |
+
ce.style.whiteSpace = f.block_whitespace.value;
|
493 |
+
ce.style.display = f.block_display.value;
|
494 |
+
|
495 |
+
// Build box styles
|
496 |
+
|
497 |
+
ce.style.width = f.box_width.value + (isNum(f.box_width.value) ? f.box_width_measurement.value : "");
|
498 |
+
ce.style.height = f.box_height.value + (isNum(f.box_height.value) ? f.box_height_measurement.value : "");
|
499 |
+
ce.style.styleFloat = f.box_float.value;
|
500 |
+
ce.style.cssFloat = f.box_float.value;
|
501 |
+
|
502 |
+
ce.style.clear = f.box_clear.value;
|
503 |
+
|
504 |
+
if (!f.box_padding_same.checked) {
|
505 |
+
ce.style.paddingTop = f.box_padding_top.value + (isNum(f.box_padding_top.value) ? f.box_padding_top_measurement.value : "");
|
506 |
+
ce.style.paddingRight = f.box_padding_right.value + (isNum(f.box_padding_right.value) ? f.box_padding_right_measurement.value : "");
|
507 |
+
ce.style.paddingBottom = f.box_padding_bottom.value + (isNum(f.box_padding_bottom.value) ? f.box_padding_bottom_measurement.value : "");
|
508 |
+
ce.style.paddingLeft = f.box_padding_left.value + (isNum(f.box_padding_left.value) ? f.box_padding_left_measurement.value : "");
|
509 |
+
} else
|
510 |
+
ce.style.padding = f.box_padding_top.value + (isNum(f.box_padding_top.value) ? f.box_padding_top_measurement.value : "");
|
511 |
+
|
512 |
+
if (!f.box_margin_same.checked) {
|
513 |
+
ce.style.marginTop = f.box_margin_top.value + (isNum(f.box_margin_top.value) ? f.box_margin_top_measurement.value : "");
|
514 |
+
ce.style.marginRight = f.box_margin_right.value + (isNum(f.box_margin_right.value) ? f.box_margin_right_measurement.value : "");
|
515 |
+
ce.style.marginBottom = f.box_margin_bottom.value + (isNum(f.box_margin_bottom.value) ? f.box_margin_bottom_measurement.value : "");
|
516 |
+
ce.style.marginLeft = f.box_margin_left.value + (isNum(f.box_margin_left.value) ? f.box_margin_left_measurement.value : "");
|
517 |
+
} else
|
518 |
+
ce.style.margin = f.box_margin_top.value + (isNum(f.box_margin_top.value) ? f.box_margin_top_measurement.value : "");
|
519 |
+
|
520 |
+
// Build border styles
|
521 |
+
|
522 |
+
if (!f.border_style_same.checked) {
|
523 |
+
ce.style.borderTopStyle = f.border_style_top.value;
|
524 |
+
ce.style.borderRightStyle = f.border_style_right.value;
|
525 |
+
ce.style.borderBottomStyle = f.border_style_bottom.value;
|
526 |
+
ce.style.borderLeftStyle = f.border_style_left.value;
|
527 |
+
} else
|
528 |
+
ce.style.borderStyle = f.border_style_top.value;
|
529 |
+
|
530 |
+
if (!f.border_width_same.checked) {
|
531 |
+
ce.style.borderTopWidth = f.border_width_top.value + (isNum(f.border_width_top.value) ? f.border_width_top_measurement.value : "");
|
532 |
+
ce.style.borderRightWidth = f.border_width_right.value + (isNum(f.border_width_right.value) ? f.border_width_right_measurement.value : "");
|
533 |
+
ce.style.borderBottomWidth = f.border_width_bottom.value + (isNum(f.border_width_bottom.value) ? f.border_width_bottom_measurement.value : "");
|
534 |
+
ce.style.borderLeftWidth = f.border_width_left.value + (isNum(f.border_width_left.value) ? f.border_width_left_measurement.value : "");
|
535 |
+
} else
|
536 |
+
ce.style.borderWidth = f.border_width_top.value + (isNum(f.border_width_top.value) ? f.border_width_top_measurement.value : "");
|
537 |
+
|
538 |
+
if (!f.border_color_same.checked) {
|
539 |
+
ce.style.borderTopColor = f.border_color_top.value;
|
540 |
+
ce.style.borderRightColor = f.border_color_right.value;
|
541 |
+
ce.style.borderBottomColor = f.border_color_bottom.value;
|
542 |
+
ce.style.borderLeftColor = f.border_color_left.value;
|
543 |
+
} else
|
544 |
+
ce.style.borderColor = f.border_color_top.value;
|
545 |
+
|
546 |
+
// Build list styles
|
547 |
+
|
548 |
+
ce.style.listStyleType = f.list_type.value;
|
549 |
+
ce.style.listStylePosition = f.list_position.value;
|
550 |
+
ce.style.listStyleImage = f.list_bullet_image.value != "" ? "url(" + f.list_bullet_image.value + ")" : "";
|
551 |
+
|
552 |
+
// Build positioning styles
|
553 |
+
|
554 |
+
ce.style.position = f.positioning_type.value;
|
555 |
+
ce.style.visibility = f.positioning_visibility.value;
|
556 |
+
|
557 |
+
if (ce.style.width == "")
|
558 |
+
ce.style.width = f.positioning_width.value + (isNum(f.positioning_width.value) ? f.positioning_width_measurement.value : "");
|
559 |
+
|
560 |
+
if (ce.style.height == "")
|
561 |
+
ce.style.height = f.positioning_height.value + (isNum(f.positioning_height.value) ? f.positioning_height_measurement.value : "");
|
562 |
+
|
563 |
+
ce.style.zIndex = f.positioning_zindex.value;
|
564 |
+
ce.style.overflow = f.positioning_overflow.value;
|
565 |
+
|
566 |
+
if (!f.positioning_placement_same.checked) {
|
567 |
+
ce.style.top = f.positioning_placement_top.value + (isNum(f.positioning_placement_top.value) ? f.positioning_placement_top_measurement.value : "");
|
568 |
+
ce.style.right = f.positioning_placement_right.value + (isNum(f.positioning_placement_right.value) ? f.positioning_placement_right_measurement.value : "");
|
569 |
+
ce.style.bottom = f.positioning_placement_bottom.value + (isNum(f.positioning_placement_bottom.value) ? f.positioning_placement_bottom_measurement.value : "");
|
570 |
+
ce.style.left = f.positioning_placement_left.value + (isNum(f.positioning_placement_left.value) ? f.positioning_placement_left_measurement.value : "");
|
571 |
+
} else {
|
572 |
+
s = f.positioning_placement_top.value + (isNum(f.positioning_placement_top.value) ? f.positioning_placement_top_measurement.value : "");
|
573 |
+
ce.style.top = s;
|
574 |
+
ce.style.right = s;
|
575 |
+
ce.style.bottom = s;
|
576 |
+
ce.style.left = s;
|
577 |
+
}
|
578 |
+
|
579 |
+
if (!f.positioning_clip_same.checked) {
|
580 |
+
s = "rect(";
|
581 |
+
s += (isNum(f.positioning_clip_top.value) ? f.positioning_clip_top.value + f.positioning_clip_top_measurement.value : "auto") + " ";
|
582 |
+
s += (isNum(f.positioning_clip_right.value) ? f.positioning_clip_right.value + f.positioning_clip_right_measurement.value : "auto") + " ";
|
583 |
+
s += (isNum(f.positioning_clip_bottom.value) ? f.positioning_clip_bottom.value + f.positioning_clip_bottom_measurement.value : "auto") + " ";
|
584 |
+
s += (isNum(f.positioning_clip_left.value) ? f.positioning_clip_left.value + f.positioning_clip_left_measurement.value : "auto");
|
585 |
+
s += ")";
|
586 |
+
|
587 |
+
if (s != "rect(auto auto auto auto)")
|
588 |
+
ce.style.clip = s;
|
589 |
+
} else {
|
590 |
+
s = "rect(";
|
591 |
+
t = isNum(f.positioning_clip_top.value) ? f.positioning_clip_top.value + f.positioning_clip_top_measurement.value : "auto";
|
592 |
+
s += t + " ";
|
593 |
+
s += t + " ";
|
594 |
+
s += t + " ";
|
595 |
+
s += t + ")";
|
596 |
+
|
597 |
+
if (s != "rect(auto auto auto auto)")
|
598 |
+
ce.style.clip = s;
|
599 |
+
}
|
600 |
+
|
601 |
+
ce.style.cssText = ce.style.cssText;
|
602 |
+
}
|
603 |
+
|
604 |
+
function isNum(s) {
|
605 |
+
return new RegExp('[0-9]+', 'g').test(s);
|
606 |
+
}
|
607 |
+
|
608 |
+
function showDisabledControls() {
|
609 |
+
var f = document.forms, i, a;
|
610 |
+
|
611 |
+
for (i=0; i<f.length; i++) {
|
612 |
+
for (a=0; a<f[i].elements.length; a++) {
|
613 |
+
if (f[i].elements[a].disabled)
|
614 |
+
tinyMCEPopup.editor.dom.addClass(f[i].elements[a], "disabled");
|
615 |
+
else
|
616 |
+
tinyMCEPopup.editor.dom.removeClass(f[i].elements[a], "disabled");
|
617 |
+
}
|
618 |
+
}
|
619 |
+
}
|
620 |
+
|
621 |
+
function fillSelect(f, s, param, dval, sep, em) {
|
622 |
+
var i, ar, p, se;
|
623 |
+
|
624 |
+
f = document.forms[f];
|
625 |
+
sep = typeof(sep) == "undefined" ? ";" : sep;
|
626 |
+
|
627 |
+
if (em)
|
628 |
+
addSelectValue(f, s, "", "");
|
629 |
+
|
630 |
+
ar = tinyMCEPopup.getParam(param, dval).split(sep);
|
631 |
+
for (i=0; i<ar.length; i++) {
|
632 |
+
se = false;
|
633 |
+
|
634 |
+
if (ar[i].charAt(0) == '+') {
|
635 |
+
ar[i] = ar[i].substring(1);
|
636 |
+
se = true;
|
637 |
+
}
|
638 |
+
|
639 |
+
p = ar[i].split('=');
|
640 |
+
|
641 |
+
if (p.length > 1) {
|
642 |
+
addSelectValue(f, s, p[0], p[1]);
|
643 |
+
|
644 |
+
if (se)
|
645 |
+
selectByValue(f, s, p[1]);
|
646 |
+
} else {
|
647 |
+
addSelectValue(f, s, p[0], p[0]);
|
648 |
+
|
649 |
+
if (se)
|
650 |
+
selectByValue(f, s, p[0]);
|
651 |
+
}
|
652 |
+
}
|
653 |
+
}
|
654 |
+
|
655 |
+
function toggleSame(ce, pre) {
|
656 |
+
var el = document.forms[0].elements, i;
|
657 |
+
|
658 |
+
if (ce.checked) {
|
659 |
+
el[pre + "_top"].disabled = false;
|
660 |
+
el[pre + "_right"].disabled = true;
|
661 |
+
el[pre + "_bottom"].disabled = true;
|
662 |
+
el[pre + "_left"].disabled = true;
|
663 |
+
|
664 |
+
if (el[pre + "_top_measurement"]) {
|
665 |
+
el[pre + "_top_measurement"].disabled = false;
|
666 |
+
el[pre + "_right_measurement"].disabled = true;
|
667 |
+
el[pre + "_bottom_measurement"].disabled = true;
|
668 |
+
el[pre + "_left_measurement"].disabled = true;
|
669 |
+
}
|
670 |
+
} else {
|
671 |
+
el[pre + "_top"].disabled = false;
|
672 |
+
el[pre + "_right"].disabled = false;
|
673 |
+
el[pre + "_bottom"].disabled = false;
|
674 |
+
el[pre + "_left"].disabled = false;
|
675 |
+
|
676 |
+
if (el[pre + "_top_measurement"]) {
|
677 |
+
el[pre + "_top_measurement"].disabled = false;
|
678 |
+
el[pre + "_right_measurement"].disabled = false;
|
679 |
+
el[pre + "_bottom_measurement"].disabled = false;
|
680 |
+
el[pre + "_left_measurement"].disabled = false;
|
681 |
+
}
|
682 |
+
}
|
683 |
+
|
684 |
+
showDisabledControls();
|
685 |
+
}
|
686 |
+
|
687 |
+
function synch(fr, to) {
|
688 |
+
var f = document.forms[0];
|
689 |
+
|
690 |
+
f.elements[to].value = f.elements[fr].value;
|
691 |
+
|
692 |
+
if (f.elements[fr + "_measurement"])
|
693 |
+
selectByValue(f, to + "_measurement", f.elements[fr + "_measurement"].value);
|
694 |
+
}
|
695 |
+
|
696 |
+
function updateTextDecorations(){
|
697 |
+
var el = document.forms[0].elements;
|
698 |
+
|
699 |
+
var textDecorations = ["text_underline", "text_overline", "text_linethrough", "text_blink"];
|
700 |
+
var noneChecked = el["text_none"].checked;
|
701 |
+
tinymce.each(textDecorations, function(id) {
|
702 |
+
el[id].disabled = noneChecked;
|
703 |
+
if (noneChecked) {
|
704 |
+
el[id].checked = false;
|
705 |
+
}
|
706 |
+
});
|
707 |
+
}
|
708 |
+
|
709 |
+
tinyMCEPopup.onInit.add(init);
|
mce/style/langs/de_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('de.style_dlg',{"text_lineheight":"Zeilenh\u00f6he","text_variant":"Variante","text_style":"Stil","text_weight":"Dicke","text_size":"Gr\u00f6\u00dfe","text_font":"Schriftart","text_props":"Text","positioning_tab":"Positionierung","list_tab":"Liste","border_tab":"Rahmen","box_tab":"Box","block_tab":"Block","background_tab":"Hintergrund","text_tab":"Text",apply:"\u00dcbernehmen",title:"CSS-Styles bearbeiten",clip:"Ausschnitt",placement:"Platzierung",overflow:"Verhalten bei \u00dcbergr\u00f6\u00dfe",zindex:"Z-Wert",visibility:"Sichtbar","positioning_type":"Art der Positionierung",position:"Positionierung","bullet_image":"Listenpunkt-Grafik","list_type":"Listenpunkt-Art",color:"Textfarbe",height:"H\u00f6he",width:"Breite",style:"Format",margin:"\u00c4u\u00dferer Abstand",left:"Links",bottom:"Unten",right:"Rechts",top:"Oben",same:"Alle gleich",padding:"Innerer Abstand","box_clear":"Umflie\u00dfung verhindern","box_float":"Umflie\u00dfung","box_height":"H\u00f6he","box_width":"Breite","block_display":"Umbruchverhalten","block_whitespace":"Automatischer Umbruch","block_text_indent":"Einr\u00fcckung","block_text_align":"Ausrichtung","block_vertical_alignment":"Vertikale Ausrichtung","block_letterspacing":"Buchstabenabstand","block_wordspacing":"Wortabstand","background_vpos":"Position Y","background_hpos":"Position X","background_attachment":"Wasserzeicheneffekt","background_repeat":"Wiederholung","background_image":"Hintergrundbild","background_color":"Hintergrundfarbe","text_none":"keine","text_blink":"blinkend","text_case":"Schreibung","text_striketrough":"durchgestrichen","text_underline":"unterstrichen","text_overline":"\u00fcberstrichen","text_decoration":"Gestaltung","text_color":"Farbe",text:"Text",background:"Hintergrund",block:"Block",box:"Box",border:"Rahmen",list:"Liste"});
|
1 |
+
tinyMCE.addI18n('de.style_dlg',{"text_lineheight":"Zeilenh\u00f6he","text_variant":"Variante","text_style":"Stil","text_weight":"Dicke","text_size":"Gr\u00f6\u00dfe","text_font":"Schriftart","text_props":"Text","positioning_tab":"Positionierung","list_tab":"Liste","border_tab":"Rahmen","box_tab":"Box","block_tab":"Block","background_tab":"Hintergrund","text_tab":"Text",apply:"\u00dcbernehmen",title:"CSS-Styles bearbeiten",clip:"Ausschnitt",placement:"Platzierung",overflow:"Verhalten bei \u00dcbergr\u00f6\u00dfe",zindex:"Z-Wert",visibility:"Sichtbar","positioning_type":"Art der Positionierung",position:"Positionierung","bullet_image":"Listenpunkt-Grafik","list_type":"Listenpunkt-Art",color:"Textfarbe",height:"H\u00f6he",width:"Breite",style:"Format",margin:"\u00c4u\u00dferer Abstand",left:"Links",bottom:"Unten",right:"Rechts",top:"Oben",same:"Alle gleich",padding:"Innerer Abstand","box_clear":"Umflie\u00dfung verhindern","box_float":"Umflie\u00dfung","box_height":"H\u00f6he","box_width":"Breite","block_display":"Umbruchverhalten","block_whitespace":"Automatischer Umbruch","block_text_indent":"Einr\u00fcckung","block_text_align":"Ausrichtung","block_vertical_alignment":"Vertikale Ausrichtung","block_letterspacing":"Buchstabenabstand","block_wordspacing":"Wortabstand","background_vpos":"Position Y","background_hpos":"Position X","background_attachment":"Wasserzeicheneffekt","background_repeat":"Wiederholung","background_image":"Hintergrundbild","background_color":"Hintergrundfarbe","text_none":"keine","text_blink":"blinkend","text_case":"Schreibung","text_striketrough":"durchgestrichen","text_underline":"unterstrichen","text_overline":"\u00fcberstrichen","text_decoration":"Gestaltung","text_color":"Farbe",text:"Text",background:"Hintergrund",block:"Block",box:"Box",border:"Rahmen",list:"Liste",toggle_insert_span:"Insert span at selection"});
|
mce/style/langs/en_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('en.style_dlg',{"text_lineheight":"Line Height","text_variant":"Variant","text_style":"Style","text_weight":"Weight","text_size":"Size","text_font":"Font","text_props":"Text","positioning_tab":"Positioning","list_tab":"List","border_tab":"Border","box_tab":"Box","block_tab":"Block","background_tab":"Background","text_tab":"Text",apply:"Apply",title:"Edit CSS Style",clip:"Clip",placement:"Placement",overflow:"Overflow",zindex:"Z-index",visibility:"Visibility","positioning_type":"Type",position:"Position","bullet_image":"Bullet Image","list_type":"Type",color:"Color",height:"Height",width:"Width",style:"Style",margin:"Margin",left:"Left",bottom:"Bottom",right:"Right",top:"Top",same:"Same for All",padding:"Padding","box_clear":"Clear","box_float":"Float","box_height":"Height","box_width":"Width","block_display":"Display","block_whitespace":"Whitespace","block_text_indent":"Text Indent","block_text_align":"Text Align","block_vertical_alignment":"Vertical Alignment","block_letterspacing":"Letter Spacing","block_wordspacing":"Word Spacing","background_vpos":"Vertical Position","background_hpos":"Horizontal Position","background_attachment":"Attachment","background_repeat":"Repeat","background_image":"Background Image","background_color":"Background Color","text_none":"None","text_blink":"Blink","text_case":"Case","text_striketrough":"Strikethrough","text_underline":"Underline","text_overline":"Overline","text_decoration":"Decoration","text_color":"Color",text:"Text",background:"Background",block:"Block",box:"Box",border:"Border",list:"List"});
|
1 |
+
tinyMCE.addI18n('en.style_dlg',{"text_lineheight":"Line Height","text_variant":"Variant","text_style":"Style","text_weight":"Weight","text_size":"Size","text_font":"Font","text_props":"Text","positioning_tab":"Positioning","list_tab":"List","border_tab":"Border","box_tab":"Box","block_tab":"Block","background_tab":"Background","text_tab":"Text",apply:"Apply",toggle_insert_span:"Insert span at selection",title:"Edit CSS Style",clip:"Clip",placement:"Placement",overflow:"Overflow",zindex:"Z-index",visibility:"Visibility","positioning_type":"Type",position:"Position","bullet_image":"Bullet Image","list_type":"Type",color:"Color",height:"Height",width:"Width",style:"Style",margin:"Margin",left:"Left",bottom:"Bottom",right:"Right",top:"Top",same:"Same for All",padding:"Padding","box_clear":"Clear","box_float":"Float","box_height":"Height","box_width":"Width","block_display":"Display","block_whitespace":"Whitespace","block_text_indent":"Text Indent","block_text_align":"Text Align","block_vertical_alignment":"Vertical Alignment","block_letterspacing":"Letter Spacing","block_wordspacing":"Word Spacing","background_vpos":"Vertical Position","background_hpos":"Horizontal Position","background_attachment":"Attachment","background_repeat":"Repeat","background_image":"Background Image","background_color":"Background Color","text_none":"None","text_blink":"Blink","text_case":"Case","text_striketrough":"Strikethrough","text_underline":"Underline","text_overline":"Overline","text_decoration":"Decoration","text_color":"Color",text:"Text",background:"Background",block:"Block",box:"Box",border:"Border",list:"List"});
|
mce/style/langs/es_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('es.style_dlg',{"text_lineheight":"Ancho de la fila","text_variant":"Variante","text_style":"Estilo","text_weight":"Peso","text_size":"Tama\u00f1o","text_font":"Fuente","text_props":"Texto","positioning_tab":"
|
1 |
+
tinyMCE.addI18n('es.style_dlg',{"text_lineheight":"Ancho de la fila","text_variant":"Variante","text_style":"Estilo","text_weight":"Peso","text_size":"Tama\u00f1o","text_font":"Fuente","text_props":"Texto","positioning_tab":"Posicionamiento","list_tab":"Lista","border_tab":"Borde","box_tab":"Caja","block_tab":"Bloque","background_tab":"Fondo","text_tab":"Texto",apply:"Aplicar",title:"Editar Estilo CSS",clip:"Clip",placement:"Placement",overflow:"Overflow",zindex:"Z-index",visibility:"Visibilidad","positioning_type":"Tipo",position:"Posici\u00f3n","bullet_image":"Imagen de la vi\u00f1eta","list_type":"Tipo",color:"Color",height:"Alto",width:"Ancho",style:"Estilo",margin:"Margen",left:"Izquierda",bottom:"Inferior",right:"Derecha",top:"Superior",same:"Lo mismo en todos",padding:"Padding","box_clear":"Clear","box_float":"Float","box_height":"Alto","box_width":"Ancho","block_display":"Display","block_whitespace":"Espacio en blanco","block_text_indent":"Sangr\u00eda","block_text_align":"Alineaci\u00f3n del texto","block_vertical_alignment":"Alineaci\u00f3n vertical","block_letterspacing":"Espacio entre letra","block_wordspacing":"Espacio entre palabra","background_vpos":"Posici\u00f3n vertical","background_hpos":"Posici\u00f3n horizontal","background_attachment":"Adjunto","background_repeat":"Repetici\u00f3n","background_image":"Imagen de fondo","background_color":"Color de fondo","text_none":"Ninguno","text_blink":"Parpadeo","text_case":"Min\u00fas./May\u00fas.","text_striketrough":"Tachado","text_underline":"Subrayado","text_overline":"Subrayado superior","text_decoration":"Decorativos","text_color":"Color",text:"Texto",background:"Fondo",block:"Bloque",box:"Caja",border:"Borde",list:"Lista",toggle_insert_span:"Insert span at selection"});
|
mce/style/langs/fr_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('fr.style_dlg',{"text_lineheight":"Hauteur de ligne","text_variant":"Variante","text_style":"Style","text_weight":"Gras","text_size":"Taille","text_font":"Police","text_props":"Texte","positioning_tab":"Positionnement","list_tab":"Liste","border_tab":"Bordure","box_tab":"Bo\u00eete","block_tab":"Bloc","background_tab":"Fond","text_tab":"Texte",apply:"Appliquer",title:"\u00c9diter la feuille de style",clip:"Clip",placement:"Placement",overflow:"D\u00e9bordement",zindex:"Z-index",visibility:"Visibilit\u00e9","positioning_type":"Type",position:"Position","bullet_image":"Image de puce","list_type":"Type",color:"Couleur",height:"Hauteur",width:"Largeur",style:"Style",margin:"Marge",left:"Gauche",bottom:"Bas",right:"Droit",top:"Haut",same:"Identique pour tous",padding:"Espacement","box_clear":"Vider","box_float":"Flottant","box_height":"Hauteur","box_width":"Largeur","block_display":"Affichage","block_whitespace":"Fin de ligne","block_text_indent":"Indentation du texte","block_text_align":"Alignement du texte","block_vertical_alignment":"Alignement vertical","block_letterspacing":"Espacement des lettres","block_wordspacing":"Espacement des mots ","background_vpos":"Position verticale","background_hpos":"Position horizontale","background_attachment":"Attachement","background_repeat":"R\u00e9p\u00e9ter","background_image":"Image de fond","background_color":"Couleur de fond","text_none":"aucun","text_blink":"clignotant","text_case":"Casse","text_striketrough":"barr\u00e9","text_underline":"soulign\u00e9","text_overline":"ligne au-dessus","text_decoration":"D\u00e9coration","text_color":"Couleur",text:"Texte",background:"Fond",block:"Bloc",box:"Bo\u00eete",border:"Bordure",list:"Liste"});
|
1 |
+
tinyMCE.addI18n('fr.style_dlg',{"text_lineheight":"Hauteur de ligne","text_variant":"Variante","text_style":"Style","text_weight":"Gras","text_size":"Taille","text_font":"Police","text_props":"Texte","positioning_tab":"Positionnement","list_tab":"Liste","border_tab":"Bordure","box_tab":"Bo\u00eete","block_tab":"Bloc","background_tab":"Fond","text_tab":"Texte",apply:"Appliquer",title:"\u00c9diter la feuille de style",clip:"Clip",placement:"Placement",overflow:"D\u00e9bordement",zindex:"Z-index",visibility:"Visibilit\u00e9","positioning_type":"Type",position:"Position","bullet_image":"Image de puce","list_type":"Type",color:"Couleur",height:"Hauteur",width:"Largeur",style:"Style",margin:"Marge",left:"Gauche",bottom:"Bas",right:"Droit",top:"Haut",same:"Identique pour tous",padding:"Espacement","box_clear":"Vider","box_float":"Flottant","box_height":"Hauteur","box_width":"Largeur","block_display":"Affichage","block_whitespace":"Fin de ligne","block_text_indent":"Indentation du texte","block_text_align":"Alignement du texte","block_vertical_alignment":"Alignement vertical","block_letterspacing":"Espacement des lettres","block_wordspacing":"Espacement des mots ","background_vpos":"Position verticale","background_hpos":"Position horizontale","background_attachment":"Attachement","background_repeat":"R\u00e9p\u00e9ter","background_image":"Image de fond","background_color":"Couleur de fond","text_none":"aucun","text_blink":"clignotant","text_case":"Casse","text_striketrough":"barr\u00e9","text_underline":"soulign\u00e9","text_overline":"ligne au-dessus","text_decoration":"D\u00e9coration","text_color":"Couleur",text:"Texte",background:"Fond",block:"Bloc",box:"Bo\u00eete",border:"Bordure",list:"Liste",toggle_insert_span:"Insert span at selection"});
|
mce/style/langs/it_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('it.style_dlg',{"text_lineheight":"Altezza linea","text_variant":"Variante","text_style":"Stile","text_weight":"Spessore","text_size":"Dimensione","text_font":"Carattere","text_props":"Testo","positioning_tab":"Posizionamento","list_tab":"Liste","border_tab":"Bordi","box_tab":"Contenitore","block_tab":"Blocco","background_tab":"Sfondo","text_tab":"Testo",apply:"Applica",title:"Modifica stile CSS",clip:"Clip",placement:"Piazzamento",overflow:"Overflow",zindex:"Z-index",visibility:"Visibilit\u00e0","positioning_type":"Tipo",position:"Posizione","bullet_image":"Immagine Punto","list_type":"Tipo",color:"Colore",height:"Altezza",width:"Larghezza",style:"Stile",margin:"Margine",left:"Sinistro",bottom:"Inferiore",right:"Destro",top:"Superiore",same:"Uguale per tutti",padding:"Spazio dal bordo","box_clear":"Pulito","box_float":"Fluttuante","box_height":"Altezza","box_width":"Larghezza","block_display":"Visualizzazione","block_whitespace":"Whitespace","block_text_indent":"Indentazione testo","block_text_align":"Allineamento testo","block_vertical_alignment":"Allineamento verticale","block_letterspacing":"Spaziatura caratteri","block_wordspacing":"Spaziatura parole","background_vpos":"Posizione verticale","background_hpos":"Posizione orizzontale","background_attachment":"Allegato","background_repeat":"Repetizione","background_image":"Immagine sfondo","background_color":"Colore sfondo","text_none":"nessuna","text_blink":"lampeggiante","text_case":"Tipo","text_striketrough":"barrato","text_underline":"sottolineato","text_overline":"sopralineato","text_decoration":"Decorazione","text_color":"Colore",text:"Testo",background:"Sfondo",block:"Blocco",box:"Box",border:"Bordo",list:"Lista"});
|
1 |
+
tinyMCE.addI18n('it.style_dlg',{"text_lineheight":"Altezza linea","text_variant":"Variante","text_style":"Stile","text_weight":"Spessore","text_size":"Dimensione","text_font":"Carattere","text_props":"Testo","positioning_tab":"Posizionamento","list_tab":"Liste","border_tab":"Bordi","box_tab":"Contenitore","block_tab":"Blocco","background_tab":"Sfondo","text_tab":"Testo",apply:"Applica",title:"Modifica stile CSS",clip:"Clip",placement:"Piazzamento",overflow:"Overflow",zindex:"Z-index",visibility:"Visibilit\u00e0","positioning_type":"Tipo",position:"Posizione","bullet_image":"Immagine Punto","list_type":"Tipo",color:"Colore",height:"Altezza",width:"Larghezza",style:"Stile",margin:"Margine",left:"Sinistro",bottom:"Inferiore",right:"Destro",top:"Superiore",same:"Uguale per tutti",padding:"Spazio dal bordo","box_clear":"Pulito","box_float":"Fluttuante","box_height":"Altezza","box_width":"Larghezza","block_display":"Visualizzazione","block_whitespace":"Whitespace","block_text_indent":"Indentazione testo","block_text_align":"Allineamento testo","block_vertical_alignment":"Allineamento verticale","block_letterspacing":"Spaziatura caratteri","block_wordspacing":"Spaziatura parole","background_vpos":"Posizione verticale","background_hpos":"Posizione orizzontale","background_attachment":"Allegato","background_repeat":"Repetizione","background_image":"Immagine sfondo","background_color":"Colore sfondo","text_none":"nessuna","text_blink":"lampeggiante","text_case":"Tipo","text_striketrough":"barrato","text_underline":"sottolineato","text_overline":"sopralineato","text_decoration":"Decorazione","text_color":"Colore",text:"Testo",background:"Sfondo",block:"Blocco",box:"Box",border:"Bordo",list:"Lista",toggle_insert_span:"Insert span at selection"});
|
mce/style/langs/ja_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('ja.style_dlg',{"text_lineheight":"\u884c\u306e\u9ad8\u3055","text_variant":"\u5909\u5f62","text_style":"\u30b9\u30bf\u30a4\u30eb","text_weight":"\u592a\u3055","text_size":"\u5927\u304d\u3055","text_font":"\u30d5\u30a9\u30f3\u30c8","text_props":"\u30c6\u30ad\u30b9\u30c8","positioning_tab":"\u4f4d\u7f6e","list_tab":"\u7b87\u6761\u66f8\u304d","border_tab":"\u67a0\u7dda","box_tab":"\u30dc\u30c3\u30af\u30b9","block_tab":"\u30d6\u30ed\u30c3\u30af","background_tab":"\u80cc\u666f","text_tab":"\u6587\u5b57",apply:"\u9069\u7528",title:"CSS\u306e\u30b9\u30bf\u30a4\u30eb\u3092\u7de8\u96c6",clip:"\u5207\u308a\u629c\u304d",placement:"\u914d\u7f6e",overflow:"\u30aa\u30fc\u30d0\u30fc\u30d5\u30ed\u30fc",zindex:"Z-index",visibility:"\u53ef\u8996\u6027","positioning_type":"\u914d\u7f6e\u65b9\u6cd5",position:"\u8868\u793a\u4f4d\u7f6e","bullet_image":"\u884c\u982d\u6587\u5b57","list_type":"\u7b87\u6761\u66f8\u304d\u306e\u7a2e\u985e",color:"\u8272",height:"\u9ad8\u3055",width:"\u5e45",style:"\u30b9\u30bf\u30a4\u30eb",margin:"\u30de\u30fc\u30b8\u30f3",left:"\u5de6",bottom:"\u4e0b",right:"\u53f3",top:"\u4e0a",same:"\u3059\u3079\u3066\u540c\u3058",padding:"\u30d1\u30c7\u30a3\u30f3\u30b0","box_clear":"\u56de\u308a\u8fbc\u307f\u89e3\u9664","box_float":"\u56de\u308a\u8fbc\u307f","box_height":"\u9ad8\u3055","box_width":"\u5e45","block_display":"\u30c7\u30a3\u30b9\u30d7\u30ec\u30a4","block_whitespace":"\u7a7a\u767d\u6587\u5b57","block_text_indent":"\u30c6\u30ad\u30b9\u30c8\u306e\u5b57\u4e0b\u3052","block_text_align":"\u30c6\u30ad\u30b9\u30c8\u306e\u6c34\u5e73\u914d\u7f6e","block_vertical_alignment":"\u5782\u76f4\u914d\u7f6e","block_letterspacing":"\u6587\u5b57\u9593\u9694","block_wordspacing":"\u5358\u8a9e\u9593\u9694","background_vpos":"\u5782\u76f4\u4f4d\u7f6e","background_hpos":"\u6c34\u5e73\u4f4d\u7f6e","background_attachment":"\u6dfb\u4ed8","background_repeat":"\u7e70\u308a\u8fd4\u3057","background_image":"\u80cc\u666f\u753b\u50cf","background_color":"\u80cc\u666f\u8272","text_none":"\u306a\u3057","text_blink":"\u70b9\u6ec5","text_case":"\u5927\u6587\u5b57/\u5c0f\u6587\u5b57","text_striketrough":"\u6253\u6d88\u3057\u7dda","text_underline":"\u4e0b\u7dda","text_overline":"\u4e0a\u7dda","text_decoration":"\u88c5\u98fe","text_color":"\u8272",text:"\u6587\u5b57",background:"\u80cc\u666f",block:"\u30d6\u30ed\u30c3\u30af",box:"\u30dc\u30c3\u30af\u30b9",border:"\u67a0\u7dda",list:"\u7b87\u6761\u66f8\u304d"});
|
1 |
+
tinyMCE.addI18n('ja.style_dlg',{"text_lineheight":"\u884c\u306e\u9ad8\u3055","text_variant":"\u5909\u5f62","text_style":"\u30b9\u30bf\u30a4\u30eb","text_weight":"\u592a\u3055","text_size":"\u5927\u304d\u3055","text_font":"\u30d5\u30a9\u30f3\u30c8","text_props":"\u30c6\u30ad\u30b9\u30c8","positioning_tab":"\u4f4d\u7f6e","list_tab":"\u7b87\u6761\u66f8\u304d","border_tab":"\u67a0\u7dda","box_tab":"\u30dc\u30c3\u30af\u30b9","block_tab":"\u30d6\u30ed\u30c3\u30af","background_tab":"\u80cc\u666f","text_tab":"\u6587\u5b57",apply:"\u9069\u7528",title:"CSS\u306e\u30b9\u30bf\u30a4\u30eb\u3092\u7de8\u96c6",clip:"\u5207\u308a\u629c\u304d",placement:"\u914d\u7f6e",overflow:"\u30aa\u30fc\u30d0\u30fc\u30d5\u30ed\u30fc",zindex:"Z-index",visibility:"\u53ef\u8996\u6027","positioning_type":"\u914d\u7f6e\u65b9\u6cd5",position:"\u8868\u793a\u4f4d\u7f6e","bullet_image":"\u884c\u982d\u6587\u5b57","list_type":"\u7b87\u6761\u66f8\u304d\u306e\u7a2e\u985e",color:"\u8272",height:"\u9ad8\u3055",width:"\u5e45",style:"\u30b9\u30bf\u30a4\u30eb",margin:"\u30de\u30fc\u30b8\u30f3",left:"\u5de6",bottom:"\u4e0b",right:"\u53f3",top:"\u4e0a",same:"\u3059\u3079\u3066\u540c\u3058",padding:"\u30d1\u30c7\u30a3\u30f3\u30b0","box_clear":"\u56de\u308a\u8fbc\u307f\u89e3\u9664","box_float":"\u56de\u308a\u8fbc\u307f","box_height":"\u9ad8\u3055","box_width":"\u5e45","block_display":"\u30c7\u30a3\u30b9\u30d7\u30ec\u30a4","block_whitespace":"\u7a7a\u767d\u6587\u5b57","block_text_indent":"\u30c6\u30ad\u30b9\u30c8\u306e\u5b57\u4e0b\u3052","block_text_align":"\u30c6\u30ad\u30b9\u30c8\u306e\u6c34\u5e73\u914d\u7f6e","block_vertical_alignment":"\u5782\u76f4\u914d\u7f6e","block_letterspacing":"\u6587\u5b57\u9593\u9694","block_wordspacing":"\u5358\u8a9e\u9593\u9694","background_vpos":"\u5782\u76f4\u4f4d\u7f6e","background_hpos":"\u6c34\u5e73\u4f4d\u7f6e","background_attachment":"\u6dfb\u4ed8","background_repeat":"\u7e70\u308a\u8fd4\u3057","background_image":"\u80cc\u666f\u753b\u50cf","background_color":"\u80cc\u666f\u8272","text_none":"\u306a\u3057","text_blink":"\u70b9\u6ec5","text_case":"\u5927\u6587\u5b57/\u5c0f\u6587\u5b57","text_striketrough":"\u6253\u6d88\u3057\u7dda","text_underline":"\u4e0b\u7dda","text_overline":"\u4e0a\u7dda","text_decoration":"\u88c5\u98fe","text_color":"\u8272",text:"\u6587\u5b57",background:"\u80cc\u666f",block:"\u30d6\u30ed\u30c3\u30af",box:"\u30dc\u30c3\u30af\u30b9",border:"\u67a0\u7dda",list:"\u7b87\u6761\u66f8\u304d",toggle_insert_span:"Insert span at selection"});
|
mce/style/langs/langs.php
CHANGED
@@ -1,9 +1,12 @@
|
|
1 |
-
<?php
|
2 |
-
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
-
|
4 |
-
if ( is_file($lang_file) &&
|
5 |
-
$
|
6 |
-
|
7 |
-
|
8 |
-
$strings =
|
9 |
-
}
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
+
|
4 |
+
if ( ! is_file( $lang_file ) && defined( 'TINYMCE_ADVANCED_LANGUAGES_PATH' ) )
|
5 |
+
$lang_file = TINYMCE_ADVANCED_LANGUAGES_PATH . 'style/langs/' . $mce_locale . '_dlg.js';
|
6 |
+
|
7 |
+
if ( is_file( $lang_file ) && is_readable( $lang_file ) ) {
|
8 |
+
$strings = tdav_get_file( $lang_file );
|
9 |
+
} else {
|
10 |
+
$strings = tdav_get_file( dirname(__FILE__) . '/en_dlg.js' );
|
11 |
+
$strings = preg_replace( '/([\'"])en\./', '$1' . $mce_locale . '.', $strings, 1 );
|
12 |
+
}
|
mce/style/langs/pt_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('pt.style_dlg',{"text_lineheight":"Altura da linha","text_variant":"Variante","text_style":"Estilo","text_weight":"Peso","text_size":"Tamanho","text_font":"Fonte","text_props":"Texto","positioning_tab":"Posicionamento","list_tab":"Lista","border_tab":"Limites","box_tab":"Caixa","block_tab":"Bloco","background_tab":"Fundo","text_tab":"Texto",apply:"Aplicar",title:"Editar CSS",clip:"Clip",placement:"Posicionamento",overflow:"Overflow",zindex:"Z-index",visibility:"Visibilidade","positioning_type":"Tipo",position:"Posi\u00e7\u00e3o","bullet_image":"Imagem de lista","list_type":"Tipo",color:"Cor",height:"Altura",width:"Largura",style:"Estilo",margin:"Margem",left:"Esquerda",bottom:"Abaixo",right:"Direita",top:"Topo",same:"O mesmo para todos",padding:"Padding","box_clear":"Clear","box_float":"Float","box_height":"Altura","box_width":"Largura","block_display":"Display","block_whitespace":"Espa\u00e7o","block_text_indent":"Indent","block_text_align":"Alinhamento de texto","block_vertical_alignment":"Alinhamento vertical","block_letterspacing":"Espa\u00e7amento de letras","block_wordspacing":"Espa\u00e7amento de palavras","background_vpos":"Posi\u00e7\u00e3o vertical","background_hpos":"Posi\u00e7\u00e3o horizontal","background_attachment":"Fixar","background_repeat":"Repetir","background_image":"Imagem de fundo","background_color":"Cor de fundo","text_none":"nenhum","text_blink":"Piscar","text_case":"Mai\u00fascula","text_striketrough":"Riscado","text_underline":"Sublinhado","text_overline":"Sobrelinha","text_decoration":"Decora\u00e7\u00e3o","text_color":"Cor",text:"Texto",background:"Fundo",block:"Bloco",box:"Caixa",border:"Borda",list:"Lista"});
|
1 |
+
tinyMCE.addI18n('pt.style_dlg',{"text_lineheight":"Altura da linha","text_variant":"Variante","text_style":"Estilo","text_weight":"Peso","text_size":"Tamanho","text_font":"Fonte","text_props":"Texto","positioning_tab":"Posicionamento","list_tab":"Lista","border_tab":"Limites","box_tab":"Caixa","block_tab":"Bloco","background_tab":"Fundo","text_tab":"Texto",apply:"Aplicar",title:"Editar CSS",clip:"Clip",placement:"Posicionamento",overflow:"Overflow",zindex:"Z-index",visibility:"Visibilidade","positioning_type":"Tipo",position:"Posi\u00e7\u00e3o","bullet_image":"Imagem de lista","list_type":"Tipo",color:"Cor",height:"Altura",width:"Largura",style:"Estilo",margin:"Margem",left:"Esquerda",bottom:"Abaixo",right:"Direita",top:"Topo",same:"O mesmo para todos",padding:"Padding","box_clear":"Clear","box_float":"Float","box_height":"Altura","box_width":"Largura","block_display":"Display","block_whitespace":"Espa\u00e7o","block_text_indent":"Indent","block_text_align":"Alinhamento de texto","block_vertical_alignment":"Alinhamento vertical","block_letterspacing":"Espa\u00e7amento de letras","block_wordspacing":"Espa\u00e7amento de palavras","background_vpos":"Posi\u00e7\u00e3o vertical","background_hpos":"Posi\u00e7\u00e3o horizontal","background_attachment":"Fixar","background_repeat":"Repetir","background_image":"Imagem de fundo","background_color":"Cor de fundo","text_none":"nenhum","text_blink":"Piscar","text_case":"Mai\u00fascula","text_striketrough":"Riscado","text_underline":"Sublinhado","text_overline":"Sobrelinha","text_decoration":"Decora\u00e7\u00e3o","text_color":"Cor",text:"Texto",background:"Fundo",block:"Bloco",box:"Caixa",border:"Borda",list:"Lista",toggle_insert_span:"Insert span at selection"});
|
mce/style/langs/ru_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('ru.style_dlg',{"text_lineheight":"\u0412\u044b\u0441\u043e\u0442\u0430 \u0441\u0442\u0440\u043e\u043a\u0438","text_variant":"\u0412\u0430\u0440\u0438\u0430\u043d\u0442","text_style":"\u0421\u0442\u0438\u043b\u044c","text_weight":"\u0422\u043e\u043b\u0449\u0438\u043d\u0430","text_size":"\u0420\u0430\u0437\u043c\u0435\u0440","text_font":"\u0428\u0440\u0438\u0444\u0442","text_props":"\u0422\u0435\u043a\u0441\u0442","positioning_tab":"\u041f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435","list_tab":"\u0421\u043f\u0438\u0441\u043e\u043a","border_tab":"\u0413\u0440\u0430\u043d\u0438\u0446\u0430","box_tab":"\u041a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440","block_tab":"\u0411\u043b\u043e\u043a","background_tab":"\u0424\u043e\u043d","text_tab":"\u0422\u0435\u043a\u0441\u0442",apply:"\u041f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c",title:"\u0420\u0435\u0434\u0430\u043a\u0442\u043e\u0440 CSS \u0441\u0442\u0438\u043b\u044f",clip:"\u041e\u0442\u0441\u0435\u0447\u0435\u043d\u0438\u0435",placement:"\u0420\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u0435",overflow:"\u041f\u0435\u0440\u0435\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435",zindex:"Z-\u0438\u043d\u0434\u0435\u043a\u0441",visibility:"\u0412\u0438\u0434\u0438\u043c\u043e\u0441\u0442\u044c","positioning_type":"\u0422\u0438\u043f",position:"\u041f\u043e\u0437\u0438\u0446\u0438\u044f","bullet_image":"\u041c\u0430\u0440\u043a\u0435\u0440","list_type":"\u0422\u0438\u043f",color:"\u0426\u0432\u0435\u0442",height:"\u0412\u044b\u0441\u043e\u0442\u0430",width:"\u0428\u0438\u0440\u0438\u043d\u0430",style:"\u0421\u0442\u0438\u043b\u044c",margin:"\u041e\u0442\u0441\u0442\u0443\u043f",left:"\u0421\u043b\u0435\u0432\u0430",bottom:"\u0421\u043d\u0438\u0437\u0443",right:"\u0421\u043f\u0440\u0430\u0432\u0430",top:"\u0412\u0432\u0435\u0440\u0445",same:"\u041e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u043e \u0434\u043b\u044f \u0432\u0441\u0435\u0445",padding:"\u041f\u043e\u043b\u044f","box_clear":"\u042f\u0432\u043d\u044b\u0439","box_float":"\u041f\u043b\u0430\u0432\u0430\u044e\u0449\u0438\u0439","box_height":"\u0412\u044b\u0441\u043e\u0442\u0430","box_width":"\u0428\u0438\u0440\u0438\u043d\u0430","block_display":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435","block_whitespace":"\u041f\u0440\u043e\u0431\u0435\u043b","block_text_indent":"\u041e\u0442\u0441\u0442\u0443\u043f \u0442\u0435\u043a\u0441\u0442\u0430","block_text_align":"\u0412\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435 \u0442\u0435\u043a\u0441\u0442\u0430","block_vertical_alignment":"\u0412\u0435\u0440\u0442\u0438\u043a\u0430\u043b\u044c\u043d\u043e\u0435 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435","block_letterspacing":"\u041e\u0442\u0441\u0442\u0443\u043f\u044b \u043c\u0435\u0436\u0434\u0443 \u0431\u0443\u043a\u0432\u0430\u043c\u0438","block_wordspacing":"\u041e\u0442\u0441\u0442\u0443\u043f\u044b \u043c\u0435\u0436\u0434\u0443 \u0441\u043b\u043e\u0432\u0430\u043c\u0438","background_vpos":"\u0412\u0435\u0440\u0442\u0438\u043a\u0430\u043b\u044c\u043d\u0430\u044f \u043f\u043e\u0437\u0438\u0446\u0438\u044f","background_hpos":"\u0413\u043e\u0440\u0438\u0437\u043e\u043d\u0442\u0430\u043b\u044c\u043d\u0430\u044f \u043f\u043e\u0437\u0438\u0446\u0438\u044f","background_attachment":"\u041f\u0440\u0438\u0432\u044f\u0437\u043a\u0430","background_repeat":"\u041f\u043e\u0432\u0442\u043e\u0440","background_image":"\u0424\u043e\u043d\u043e\u0432\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435","background_color":"\u0426\u0432\u0435\u0442 \u0444\u043e\u043d\u0430","text_none":"\u0411\u0435\u0437 \u0432\u0441\u0435\u0433\u043e","text_blink":"\u041c\u0435\u0440\u0446\u0430\u044e\u0449\u0438\u0439","text_case":"\u0420\u0435\u0433\u0438\u0441\u0442\u0440","text_striketrough":"\u0417\u0430\u0447\u0435\u0440\u043a\u043d\u0443\u0442\u044b\u0439","text_underline":"\u041f\u043e\u0434\u0447\u0435\u0440\u043a\u043d\u0443\u0442\u044b\u0439","text_overline":"\u0421 \u0432\u0435\u0440\u0445\u043d\u0435\u0439 \u0447\u0435\u0440\u0442\u043e\u0439","text_decoration":"\u041e\u0444\u043e\u0440\u043c\u043b\u0435\u043d\u0438\u0435","text_color":"\u0426\u0432\u0435\u0442",text:"\u0422\u0435\u043a\u0441\u0442",background:"\u0424\u043e\u043d",block:"\u0411\u043b\u043e\u043a",box:"\u041a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440",border:"\u0413\u0440\u0430\u043d\u0438\u0446\u0430",list:"\u0421\u043f\u0438\u0441\u043e\u043a"});
|
1 |
+
tinyMCE.addI18n('ru.style_dlg',{"text_lineheight":"\u0412\u044b\u0441\u043e\u0442\u0430 \u0441\u0442\u0440\u043e\u043a\u0438","text_variant":"\u0412\u0430\u0440\u0438\u0430\u043d\u0442","text_style":"\u0421\u0442\u0438\u043b\u044c","text_weight":"\u0422\u043e\u043b\u0449\u0438\u043d\u0430","text_size":"\u0420\u0430\u0437\u043c\u0435\u0440","text_font":"\u0428\u0440\u0438\u0444\u0442","text_props":"\u0422\u0435\u043a\u0441\u0442","positioning_tab":"\u041f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435","list_tab":"\u0421\u043f\u0438\u0441\u043e\u043a","border_tab":"\u0413\u0440\u0430\u043d\u0438\u0446\u0430","box_tab":"\u041a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440","block_tab":"\u0411\u043b\u043e\u043a","background_tab":"\u0424\u043e\u043d","text_tab":"\u0422\u0435\u043a\u0441\u0442",apply:"\u041f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c",title:"\u0420\u0435\u0434\u0430\u043a\u0442\u043e\u0440 CSS \u0441\u0442\u0438\u043b\u044f",clip:"\u041e\u0442\u0441\u0435\u0447\u0435\u043d\u0438\u0435",placement:"\u0420\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u0435",overflow:"\u041f\u0435\u0440\u0435\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435",zindex:"Z-\u0438\u043d\u0434\u0435\u043a\u0441",visibility:"\u0412\u0438\u0434\u0438\u043c\u043e\u0441\u0442\u044c","positioning_type":"\u0422\u0438\u043f",position:"\u041f\u043e\u0437\u0438\u0446\u0438\u044f","bullet_image":"\u041c\u0430\u0440\u043a\u0435\u0440","list_type":"\u0422\u0438\u043f",color:"\u0426\u0432\u0435\u0442",height:"\u0412\u044b\u0441\u043e\u0442\u0430",width:"\u0428\u0438\u0440\u0438\u043d\u0430",style:"\u0421\u0442\u0438\u043b\u044c",margin:"\u041e\u0442\u0441\u0442\u0443\u043f",left:"\u0421\u043b\u0435\u0432\u0430",bottom:"\u0421\u043d\u0438\u0437\u0443",right:"\u0421\u043f\u0440\u0430\u0432\u0430",top:"\u0412\u0432\u0435\u0440\u0445",same:"\u041e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u043e \u0434\u043b\u044f \u0432\u0441\u0435\u0445",padding:"\u041f\u043e\u043b\u044f","box_clear":"\u042f\u0432\u043d\u044b\u0439","box_float":"\u041f\u043b\u0430\u0432\u0430\u044e\u0449\u0438\u0439","box_height":"\u0412\u044b\u0441\u043e\u0442\u0430","box_width":"\u0428\u0438\u0440\u0438\u043d\u0430","block_display":"\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435","block_whitespace":"\u041f\u0440\u043e\u0431\u0435\u043b","block_text_indent":"\u041e\u0442\u0441\u0442\u0443\u043f \u0442\u0435\u043a\u0441\u0442\u0430","block_text_align":"\u0412\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435 \u0442\u0435\u043a\u0441\u0442\u0430","block_vertical_alignment":"\u0412\u0435\u0440\u0442\u0438\u043a\u0430\u043b\u044c\u043d\u043e\u0435 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435","block_letterspacing":"\u041e\u0442\u0441\u0442\u0443\u043f\u044b \u043c\u0435\u0436\u0434\u0443 \u0431\u0443\u043a\u0432\u0430\u043c\u0438","block_wordspacing":"\u041e\u0442\u0441\u0442\u0443\u043f\u044b \u043c\u0435\u0436\u0434\u0443 \u0441\u043b\u043e\u0432\u0430\u043c\u0438","background_vpos":"\u0412\u0435\u0440\u0442\u0438\u043a\u0430\u043b\u044c\u043d\u0430\u044f \u043f\u043e\u0437\u0438\u0446\u0438\u044f","background_hpos":"\u0413\u043e\u0440\u0438\u0437\u043e\u043d\u0442\u0430\u043b\u044c\u043d\u0430\u044f \u043f\u043e\u0437\u0438\u0446\u0438\u044f","background_attachment":"\u041f\u0440\u0438\u0432\u044f\u0437\u043a\u0430","background_repeat":"\u041f\u043e\u0432\u0442\u043e\u0440","background_image":"\u0424\u043e\u043d\u043e\u0432\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435","background_color":"\u0426\u0432\u0435\u0442 \u0444\u043e\u043d\u0430","text_none":"\u0411\u0435\u0437 \u0432\u0441\u0435\u0433\u043e","text_blink":"\u041c\u0435\u0440\u0446\u0430\u044e\u0449\u0438\u0439","text_case":"\u0420\u0435\u0433\u0438\u0441\u0442\u0440","text_striketrough":"\u0417\u0430\u0447\u0435\u0440\u043a\u043d\u0443\u0442\u044b\u0439","text_underline":"\u041f\u043e\u0434\u0447\u0435\u0440\u043a\u043d\u0443\u0442\u044b\u0439","text_overline":"\u0421 \u0432\u0435\u0440\u0445\u043d\u0435\u0439 \u0447\u0435\u0440\u0442\u043e\u0439","text_decoration":"\u041e\u0444\u043e\u0440\u043c\u043b\u0435\u043d\u0438\u0435","text_color":"\u0426\u0432\u0435\u0442",text:"\u0422\u0435\u043a\u0441\u0442",background:"\u0424\u043e\u043d",block:"\u0411\u043b\u043e\u043a",box:"\u041a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440",border:"\u0413\u0440\u0430\u043d\u0438\u0446\u0430",list:"\u0421\u043f\u0438\u0441\u043e\u043a",toggle_insert_span:"Insert span at selection"});
|
mce/style/langs/zh_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('zh.style_dlg',{"text_lineheight":"\u884c\u9ad8","text_variant":"\u7279\u6b8a\u5b57\u4f53","text_style":"\u6837\u5f0f","text_weight":"\u7c97\u4f53","text_size":"\u5b57\u4f53\u5927\u5c0f","text_font":"\u5b57\u4f53","text_props":"\u6587\u5b57","positioning_tab":"\u4f4d\u7f6e","list_tab":"\u5217\u8868","border_tab":"\u8fb9\u6846","box_tab":"\u65b9\
|
1 |
+
tinyMCE.addI18n('zh.style_dlg',{"text_lineheight":"\u884c\u9ad8","text_variant":"\u7279\u6b8a\u5b57\u4f53","text_style":"\u6837\u5f0f","text_weight":"\u7c97\u4f53","text_size":"\u5b57\u4f53\u5927\u5c0f","text_font":"\u5b57\u4f53","text_props":"\u6587\u5b57","positioning_tab":"\u4f4d\u7f6e","list_tab":"\u5217\u8868","border_tab":"\u8fb9\u6846","box_tab":"\u65b9\u76d2","block_tab":"\u533a\u5757","background_tab":"\u80cc\u666f","text_tab":"\u6587\u5b57",apply:"\u5e94\u7528",title:"\u7f16\u8f91CSS",clip:"\u526a\u8f91",placement:"\u653e\u7f6e",overflow:"\u6ea2\u51fa",zindex:"Z\u8f74\u5750\u6807",visibility:"\u53ef\u89c1","positioning_type":"\u7c7b\u578b",position:"\u4f4d\u7f6e","bullet_image":"\u56fe\u7247\u9879\u76ee\u7b26\u53f7","list_type":"\u7c7b\u578b",color:"\u989c\u8272",height:"\u9ad8",width:"\u5bbd",style:"\u6837\u5f0f",margin:"\u5916\u8fb9\u8ddd",left:"\u5de6",bottom:"\u4e0b",right:"\u53f3",top:"\u4e0a",same:"\u4e00\u81f4",padding:"\u5185\u8fb9\u8ddd","box_clear":"\u6e05\u9664\u6d6e\u52a8","box_float":"\u6d6e\u52a8","box_height":"\u9ad8","box_width":"\u5bbd","block_display":"\u663e\u793a","block_whitespace":"\u7a7a\u683c","block_text_indent":"\u6587\u5b57\u7f29\u8fdb","block_text_align":"\u6587\u5b57\u5bf9\u9f50","block_vertical_alignment":"\u5782\u76f4\u5bf9\u9f50","block_letterspacing":"\u5b57\u95f4\u8ddd","block_wordspacing":"\u8bcd\u95f4\u8ddd","background_vpos":"\u5782\u76f4\u4f4d\u7f6e","background_hpos":"\u6c34\u5e73\u4f4d\u7f6e","background_attachment":"\u9644\u4ef6","background_repeat":"\u91cd\u590d","background_image":"\u80cc\u666f\u56fe\u7247","background_color":"\u80cc\u666f\u989c\u8272","text_none":"\u65e0","text_blink":"\u95ea\u70c1","text_case":"\u5b57\u578b","text_striketrough":"\u5220\u9664\u7ebf","text_underline":"\u4e0b\u5212\u7ebf","text_overline":"\u4e0a\u5212\u7ebf","text_decoration":"\u88c5\u9970","text_color":"\u989c\u8272",text:"\u6587\u5b57",background:"\u80cc\u666f",block:"\u533a\u5757",box:"\u65b9\u76d2",border:"\u8fb9\u6846",list:"\u5217\u8868",toggle_insert_span:"Insert span at selection"});
|
mce/style/props.htm
CHANGED
@@ -2,12 +2,12 @@
|
|
2 |
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
<head>
|
4 |
<title>{#style_dlg.title}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
9 |
-
<script type="text/javascript" src="js/props.js?ver=
|
10 |
-
<link href="css/props.css?ver=
|
11 |
</head>
|
12 |
|
13 |
<body id="styleprops" style="display: none" role="application" aria-labelledby="app_title">
|
2 |
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
<head>
|
4 |
<title>{#style_dlg.title}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="js/props.js?ver=359"></script>
|
10 |
+
<link href="css/props.css?ver=359" rel="stylesheet" type="text/css" />
|
11 |
</head>
|
12 |
|
13 |
<body id="styleprops" style="display: none" role="application" aria-labelledby="app_title">
|
mce/table/cell.htm
CHANGED
@@ -1,180 +1,180 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#table_dlg.cell_title}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/validate.js?ver=
|
9 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
10 |
-
<script type="text/javascript" src="js/cell.js?ver=
|
11 |
-
<link href="css/cell.css?ver=
|
12 |
-
</head>
|
13 |
-
<body id="tablecell" style="display: none" role="application">
|
14 |
-
<form onsubmit="updateAction();return false;" action="#">
|
15 |
-
<div class="tabs">
|
16 |
-
<ul>
|
17 |
-
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#table_dlg.general_tab}</a></span></li>
|
18 |
-
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#table_dlg.advanced_tab}</a></span></li>
|
19 |
-
</ul>
|
20 |
-
</div>
|
21 |
-
|
22 |
-
<div class="panel_wrapper">
|
23 |
-
<div id="general_panel" class="panel current">
|
24 |
-
<fieldset>
|
25 |
-
<legend>{#table_dlg.general_props}</legend>
|
26 |
-
|
27 |
-
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
|
28 |
-
<tr>
|
29 |
-
<td><label for="align">{#table_dlg.align}</label></td>
|
30 |
-
<td>
|
31 |
-
<select id="align" name="align" class="mceFocus">
|
32 |
-
<option value="">{#not_set}</option>
|
33 |
-
<option value="center">{#table_dlg.align_middle}</option>
|
34 |
-
<option value="left">{#table_dlg.align_left}</option>
|
35 |
-
<option value="right">{#table_dlg.align_right}</option>
|
36 |
-
</select>
|
37 |
-
</td>
|
38 |
-
|
39 |
-
<td><label for="celltype">{#table_dlg.cell_type}</label></td>
|
40 |
-
<td>
|
41 |
-
<select id="celltype" name="celltype">
|
42 |
-
<option value="td">{#table_dlg.td}</option>
|
43 |
-
<option value="th">{#table_dlg.th}</option>
|
44 |
-
</select>
|
45 |
-
</td>
|
46 |
-
</tr>
|
47 |
-
|
48 |
-
<tr>
|
49 |
-
<td><label for="valign">{#table_dlg.valign}</label></td>
|
50 |
-
<td>
|
51 |
-
<select id="valign" name="valign">
|
52 |
-
<option value="">{#not_set}</option>
|
53 |
-
<option value="top">{#table_dlg.align_top}</option>
|
54 |
-
<option value="middle">{#table_dlg.align_middle}</option>
|
55 |
-
<option value="bottom">{#table_dlg.align_bottom}</option>
|
56 |
-
</select>
|
57 |
-
</td>
|
58 |
-
|
59 |
-
<td><label for="scope">{#table_dlg.scope}</label></td>
|
60 |
-
<td>
|
61 |
-
<select id="scope" name="scope">
|
62 |
-
<option value="">{#not_set}</option>
|
63 |
-
<option value="col">{#table.col}</option>
|
64 |
-
<option value="row">{#table.row}</option>
|
65 |
-
<option value="rowgroup">{#table_dlg.rowgroup}</option>
|
66 |
-
<option value="colgroup">{#table_dlg.colgroup}</option>
|
67 |
-
</select>
|
68 |
-
</td>
|
69 |
-
|
70 |
-
</tr>
|
71 |
-
|
72 |
-
<tr>
|
73 |
-
<td><label for="width">{#table_dlg.width}</label></td>
|
74 |
-
<td><input id="width" name="width" type="text" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
|
75 |
-
|
76 |
-
<td><label for="height">{#table_dlg.height}</label></td>
|
77 |
-
<td><input id="height" name="height" type="text" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
|
78 |
-
</tr>
|
79 |
-
|
80 |
-
<tr id="styleSelectRow">
|
81 |
-
<td><label for="class">{#class_name}</label></td>
|
82 |
-
<td colspan="3">
|
83 |
-
<select id="class" name="class" class="mceEditableSelect">
|
84 |
-
<option value="" selected="selected">{#not_set}</option>
|
85 |
-
</select>
|
86 |
-
</td>
|
87 |
-
</tr>
|
88 |
-
</table>
|
89 |
-
</fieldset>
|
90 |
-
</div>
|
91 |
-
|
92 |
-
<div id="advanced_panel" class="panel">
|
93 |
-
<fieldset>
|
94 |
-
<legend>{#table_dlg.advanced_props}</legend>
|
95 |
-
|
96 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
97 |
-
<tr>
|
98 |
-
<td class="column1"><label for="id">{#table_dlg.id}</label></td>
|
99 |
-
<td><input id="id" name="id" type="text" value="" style="width: 200px" /></td>
|
100 |
-
</tr>
|
101 |
-
|
102 |
-
<tr>
|
103 |
-
<td><label for="style">{#table_dlg.style}</label></td>
|
104 |
-
<td><input type="text" id="style" name="style" value="" style="width: 200px;" onchange="changedStyle();" /></td>
|
105 |
-
</tr>
|
106 |
-
|
107 |
-
<tr>
|
108 |
-
<td class="column1"><label for="dir">{#table_dlg.langdir}</label></td>
|
109 |
-
<td>
|
110 |
-
<select id="dir" name="dir" style="width: 200px">
|
111 |
-
<option value="">{#not_set}</option>
|
112 |
-
<option value="ltr">{#table_dlg.ltr}</option>
|
113 |
-
<option value="rtl">{#table_dlg.rtl}</option>
|
114 |
-
</select>
|
115 |
-
</td>
|
116 |
-
</tr>
|
117 |
-
|
118 |
-
<tr>
|
119 |
-
<td class="column1"><label for="lang">{#table_dlg.langcode}</label></td>
|
120 |
-
<td>
|
121 |
-
<input id="lang" name="lang" type="text" value="" style="width: 200px" />
|
122 |
-
</td>
|
123 |
-
</tr>
|
124 |
-
|
125 |
-
<tr>
|
126 |
-
<td class="column1"><label for="backgroundimage">{#table_dlg.bgimage}</label></td>
|
127 |
-
<td>
|
128 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
129 |
-
<tr>
|
130 |
-
<td><input id="backgroundimage" name="backgroundimage" type="text" value="" style="width: 200px" onchange="changedBackgroundImage();" /></td>
|
131 |
-
<td id="backgroundimagebrowsercontainer"> </td>
|
132 |
-
</tr>
|
133 |
-
</table>
|
134 |
-
</td>
|
135 |
-
</tr>
|
136 |
-
|
137 |
-
<tr role="group" aria-labelledby="bordercolor_label">
|
138 |
-
<td class="column1"><label id="bordercolor_label" for="bordercolor">{#table_dlg.bordercolor}</label></td>
|
139 |
-
<td>
|
140 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
141 |
-
<tr>
|
142 |
-
<td><input id="bordercolor" name="bordercolor" type="text" value="" size="9" onchange="updateColor('bordercolor_pick','bordercolor');changedColor();" /></td>
|
143 |
-
<td id="bordercolor_pickcontainer"> </td>
|
144 |
-
</tr>
|
145 |
-
</table>
|
146 |
-
</td>
|
147 |
-
</tr>
|
148 |
-
|
149 |
-
<tr role="group" aria-labelledby="bgcolor_label">
|
150 |
-
<td class="column1"><label id="bgcolor_label" for="bgcolor">{#table_dlg.bgcolor}</label></td>
|
151 |
-
<td>
|
152 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
153 |
-
<tr>
|
154 |
-
<td><input id="bgcolor" name="bgcolor" type="text" value="" size="9" onchange="updateColor('bgcolor_pick','bgcolor');changedColor();" /></td>
|
155 |
-
<td id="bgcolor_pickcontainer"> </td>
|
156 |
-
</tr>
|
157 |
-
</table>
|
158 |
-
</td>
|
159 |
-
</tr>
|
160 |
-
</table>
|
161 |
-
</fieldset>
|
162 |
-
</div>
|
163 |
-
</div>
|
164 |
-
|
165 |
-
<div class="mceActionPanel">
|
166 |
-
<div>
|
167 |
-
<select id="action" name="action">
|
168 |
-
<option value="cell">{#table_dlg.cell_cell}</option>
|
169 |
-
<option value="row">{#table_dlg.cell_row}</option>
|
170 |
-
<option value="col">{#table_dlg.cell_col}</option>
|
171 |
-
<option value="all">{#table_dlg.cell_all}</option>
|
172 |
-
</select>
|
173 |
-
</div>
|
174 |
-
|
175 |
-
<input type="submit" id="insert" name="insert" value="{#update}" />
|
176 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
177 |
-
</div>
|
178 |
-
</form>
|
179 |
-
</body>
|
180 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#table_dlg.cell_title}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/validate.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
10 |
+
<script type="text/javascript" src="js/cell.js?ver=359"></script>
|
11 |
+
<link href="css/cell.css?ver=359" rel="stylesheet" type="text/css" />
|
12 |
+
</head>
|
13 |
+
<body id="tablecell" style="display: none" role="application">
|
14 |
+
<form onsubmit="updateAction();return false;" action="#">
|
15 |
+
<div class="tabs">
|
16 |
+
<ul>
|
17 |
+
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#table_dlg.general_tab}</a></span></li>
|
18 |
+
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#table_dlg.advanced_tab}</a></span></li>
|
19 |
+
</ul>
|
20 |
+
</div>
|
21 |
+
|
22 |
+
<div class="panel_wrapper">
|
23 |
+
<div id="general_panel" class="panel current">
|
24 |
+
<fieldset>
|
25 |
+
<legend>{#table_dlg.general_props}</legend>
|
26 |
+
|
27 |
+
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
|
28 |
+
<tr>
|
29 |
+
<td><label for="align">{#table_dlg.align}</label></td>
|
30 |
+
<td>
|
31 |
+
<select id="align" name="align" class="mceFocus">
|
32 |
+
<option value="">{#not_set}</option>
|
33 |
+
<option value="center">{#table_dlg.align_middle}</option>
|
34 |
+
<option value="left">{#table_dlg.align_left}</option>
|
35 |
+
<option value="right">{#table_dlg.align_right}</option>
|
36 |
+
</select>
|
37 |
+
</td>
|
38 |
+
|
39 |
+
<td><label for="celltype">{#table_dlg.cell_type}</label></td>
|
40 |
+
<td>
|
41 |
+
<select id="celltype" name="celltype">
|
42 |
+
<option value="td">{#table_dlg.td}</option>
|
43 |
+
<option value="th">{#table_dlg.th}</option>
|
44 |
+
</select>
|
45 |
+
</td>
|
46 |
+
</tr>
|
47 |
+
|
48 |
+
<tr>
|
49 |
+
<td><label for="valign">{#table_dlg.valign}</label></td>
|
50 |
+
<td>
|
51 |
+
<select id="valign" name="valign">
|
52 |
+
<option value="">{#not_set}</option>
|
53 |
+
<option value="top">{#table_dlg.align_top}</option>
|
54 |
+
<option value="middle">{#table_dlg.align_middle}</option>
|
55 |
+
<option value="bottom">{#table_dlg.align_bottom}</option>
|
56 |
+
</select>
|
57 |
+
</td>
|
58 |
+
|
59 |
+
<td><label for="scope">{#table_dlg.scope}</label></td>
|
60 |
+
<td>
|
61 |
+
<select id="scope" name="scope">
|
62 |
+
<option value="">{#not_set}</option>
|
63 |
+
<option value="col">{#table.col}</option>
|
64 |
+
<option value="row">{#table.row}</option>
|
65 |
+
<option value="rowgroup">{#table_dlg.rowgroup}</option>
|
66 |
+
<option value="colgroup">{#table_dlg.colgroup}</option>
|
67 |
+
</select>
|
68 |
+
</td>
|
69 |
+
|
70 |
+
</tr>
|
71 |
+
|
72 |
+
<tr>
|
73 |
+
<td><label for="width">{#table_dlg.width}</label></td>
|
74 |
+
<td><input id="width" name="width" type="text" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
|
75 |
+
|
76 |
+
<td><label for="height">{#table_dlg.height}</label></td>
|
77 |
+
<td><input id="height" name="height" type="text" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
|
78 |
+
</tr>
|
79 |
+
|
80 |
+
<tr id="styleSelectRow">
|
81 |
+
<td><label for="class">{#class_name}</label></td>
|
82 |
+
<td colspan="3">
|
83 |
+
<select id="class" name="class" class="mceEditableSelect">
|
84 |
+
<option value="" selected="selected">{#not_set}</option>
|
85 |
+
</select>
|
86 |
+
</td>
|
87 |
+
</tr>
|
88 |
+
</table>
|
89 |
+
</fieldset>
|
90 |
+
</div>
|
91 |
+
|
92 |
+
<div id="advanced_panel" class="panel">
|
93 |
+
<fieldset>
|
94 |
+
<legend>{#table_dlg.advanced_props}</legend>
|
95 |
+
|
96 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
97 |
+
<tr>
|
98 |
+
<td class="column1"><label for="id">{#table_dlg.id}</label></td>
|
99 |
+
<td><input id="id" name="id" type="text" value="" style="width: 200px" /></td>
|
100 |
+
</tr>
|
101 |
+
|
102 |
+
<tr>
|
103 |
+
<td><label for="style">{#table_dlg.style}</label></td>
|
104 |
+
<td><input type="text" id="style" name="style" value="" style="width: 200px;" onchange="changedStyle();" /></td>
|
105 |
+
</tr>
|
106 |
+
|
107 |
+
<tr>
|
108 |
+
<td class="column1"><label for="dir">{#table_dlg.langdir}</label></td>
|
109 |
+
<td>
|
110 |
+
<select id="dir" name="dir" style="width: 200px">
|
111 |
+
<option value="">{#not_set}</option>
|
112 |
+
<option value="ltr">{#table_dlg.ltr}</option>
|
113 |
+
<option value="rtl">{#table_dlg.rtl}</option>
|
114 |
+
</select>
|
115 |
+
</td>
|
116 |
+
</tr>
|
117 |
+
|
118 |
+
<tr>
|
119 |
+
<td class="column1"><label for="lang">{#table_dlg.langcode}</label></td>
|
120 |
+
<td>
|
121 |
+
<input id="lang" name="lang" type="text" value="" style="width: 200px" />
|
122 |
+
</td>
|
123 |
+
</tr>
|
124 |
+
|
125 |
+
<tr>
|
126 |
+
<td class="column1"><label for="backgroundimage">{#table_dlg.bgimage}</label></td>
|
127 |
+
<td>
|
128 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
129 |
+
<tr>
|
130 |
+
<td><input id="backgroundimage" name="backgroundimage" type="text" value="" style="width: 200px" onchange="changedBackgroundImage();" /></td>
|
131 |
+
<td id="backgroundimagebrowsercontainer"> </td>
|
132 |
+
</tr>
|
133 |
+
</table>
|
134 |
+
</td>
|
135 |
+
</tr>
|
136 |
+
|
137 |
+
<tr role="group" aria-labelledby="bordercolor_label">
|
138 |
+
<td class="column1"><label id="bordercolor_label" for="bordercolor">{#table_dlg.bordercolor}</label></td>
|
139 |
+
<td>
|
140 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
141 |
+
<tr>
|
142 |
+
<td><input id="bordercolor" name="bordercolor" type="text" value="" size="9" onchange="updateColor('bordercolor_pick','bordercolor');changedColor();" /></td>
|
143 |
+
<td id="bordercolor_pickcontainer"> </td>
|
144 |
+
</tr>
|
145 |
+
</table>
|
146 |
+
</td>
|
147 |
+
</tr>
|
148 |
+
|
149 |
+
<tr role="group" aria-labelledby="bgcolor_label">
|
150 |
+
<td class="column1"><label id="bgcolor_label" for="bgcolor">{#table_dlg.bgcolor}</label></td>
|
151 |
+
<td>
|
152 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
153 |
+
<tr>
|
154 |
+
<td><input id="bgcolor" name="bgcolor" type="text" value="" size="9" onchange="updateColor('bgcolor_pick','bgcolor');changedColor();" /></td>
|
155 |
+
<td id="bgcolor_pickcontainer"> </td>
|
156 |
+
</tr>
|
157 |
+
</table>
|
158 |
+
</td>
|
159 |
+
</tr>
|
160 |
+
</table>
|
161 |
+
</fieldset>
|
162 |
+
</div>
|
163 |
+
</div>
|
164 |
+
|
165 |
+
<div class="mceActionPanel">
|
166 |
+
<div>
|
167 |
+
<select id="action" name="action">
|
168 |
+
<option value="cell">{#table_dlg.cell_cell}</option>
|
169 |
+
<option value="row">{#table_dlg.cell_row}</option>
|
170 |
+
<option value="col">{#table_dlg.cell_col}</option>
|
171 |
+
<option value="all">{#table_dlg.cell_all}</option>
|
172 |
+
</select>
|
173 |
+
</div>
|
174 |
+
|
175 |
+
<input type="submit" id="insert" name="insert" value="{#update}" />
|
176 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
177 |
+
</div>
|
178 |
+
</form>
|
179 |
+
</body>
|
180 |
+
</html>
|
mce/table/css/cell.css
CHANGED
@@ -1,17 +1,18 @@
|
|
1 |
-
/* CSS file for cell dialog in the table plugin */
|
2 |
-
|
3 |
-
.panel_wrapper div.current {
|
4 |
-
height: 200px;
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
|
1 |
+
/* CSS file for cell dialog in the table plugin */
|
2 |
+
|
3 |
+
.panel_wrapper div.current {
|
4 |
+
min-height: 200px;
|
5 |
+
height: auto;
|
6 |
+
}
|
7 |
+
|
8 |
+
.advfield {
|
9 |
+
width: 200px;
|
10 |
+
}
|
11 |
+
|
12 |
+
#action {
|
13 |
+
margin-bottom: 3px;
|
14 |
+
}
|
15 |
+
|
16 |
+
#class {
|
17 |
+
width: 150px;
|
18 |
+
}
|
mce/table/css/row.css
CHANGED
@@ -1,25 +1,26 @@
|
|
1 |
-
/* CSS file for row dialog in the table plugin */
|
2 |
-
|
3 |
-
.panel_wrapper div.current {
|
4 |
-
height: 200px;
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
|
1 |
+
/* CSS file for row dialog in the table plugin */
|
2 |
+
|
3 |
+
.panel_wrapper div.current {
|
4 |
+
min-height: 200px;
|
5 |
+
height: auto;
|
6 |
+
}
|
7 |
+
|
8 |
+
.advfield {
|
9 |
+
width: 200px;
|
10 |
+
}
|
11 |
+
|
12 |
+
#action {
|
13 |
+
margin-bottom: 3px;
|
14 |
+
}
|
15 |
+
|
16 |
+
#rowtype,#align,#valign,#class,#height {
|
17 |
+
width: 150px;
|
18 |
+
}
|
19 |
+
|
20 |
+
#height {
|
21 |
+
width: 50px;
|
22 |
+
}
|
23 |
+
|
24 |
+
.col2 {
|
25 |
+
padding-left: 20px;
|
26 |
+
}
|
mce/table/css/table.css
CHANGED
@@ -1,13 +1,14 @@
|
|
1 |
-
/* CSS file for table dialog in the table plugin */
|
2 |
-
|
3 |
-
.panel_wrapper div.current {
|
4 |
-
height: 245px;
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
|
1 |
+
/* CSS file for table dialog in the table plugin */
|
2 |
+
|
3 |
+
.panel_wrapper div.current {
|
4 |
+
min-height: 245px;
|
5 |
+
height: auto;
|
6 |
+
}
|
7 |
+
|
8 |
+
.advfield {
|
9 |
+
width: 200px;
|
10 |
+
}
|
11 |
+
|
12 |
+
#class {
|
13 |
+
width: 150px;
|
14 |
+
}
|
mce/table/editor_plugin.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
(function(d){var e=d.each;function c(g,h){var j=h.ownerDocument,f=j.createRange(),k;f.setStartBefore(h);f.setEnd(g.endContainer,g.endOffset);k=j.createElement("body");k.appendChild(f.cloneContents());return k.innerHTML.replace(/<(br|img|object|embed|input|textarea)[^>]*>/gi,"-").replace(/<[^>]+>/g,"").length==0}function a(g,f){return parseInt(g.getAttribute(f)||1)}function b(H,G,K){var g,L,D,o;t();o=G.getParent(K.getStart(),"th,td");if(o){L=F(o);D=I();o=z(L.x,L.y)}function A(N,M){N=N.cloneNode(M);N.removeAttribute("id");return N}function t(){var M=0;g=[];e(["thead","tbody","tfoot"],function(N){var O=G.select("> "+N+" tr",H);e(O,function(P,Q){Q+=M;e(G.select("> td, > th",P),function(W,R){var S,T,U,V;if(g[Q]){while(g[Q][R]){R++}}U=a(W,"rowspan");V=a(W,"colspan");for(T=Q;T<Q+U;T++){if(!g[T]){g[T]=[]}for(S=R;S<R+V;S++){g[T][S]={part:N,real:T==Q&&S==R,elm:W,rowspan:U,colspan:V}}}})});M+=O.length})}function z(M,O){var N;N=g[O];if(N){return N[M]}}function s(O,M,N){if(O){N=parseInt(N);if(N===1){O.removeAttribute(M,1)}else{O.setAttribute(M,N,1)}}}function j(M){return M&&(G.hasClass(M.elm,"mceSelected")||M==o)}function k(){var M=[];e(H.rows,function(N){e(N.cells,function(O){if(G.hasClass(O,"mceSelected")||O==o.elm){M.push(N);return false}})});return M}function r(){var M=G.createRng();M.setStartAfter(H);M.setEndAfter(H);K.setRng(M);G.remove(H)}function f(M){var N;d.walk(M,function(P){var O;if(P.nodeType==3){e(G.getParents(P.parentNode,null,M).reverse(),function(Q){Q=A(Q,false);if(!N){N=O=Q}else{if(O){O.appendChild(Q)}}O=Q});if(O){O.innerHTML=d.isIE?" ":'<br data-mce-bogus="1" />'}return false}},"childNodes");M=A(M,false);s(M,"rowSpan",1);s(M,"colSpan",1);if(N){M.appendChild(N)}else{if(!d.isIE){M.innerHTML='<br data-mce-bogus="1" />'}}return M}function q(){var M=G.createRng();e(G.select("tr",H),function(N){if(N.cells.length==0){G.remove(N)}});if(G.select("tr",H).length==0){M.setStartAfter(H);M.setEndAfter(H);K.setRng(M);G.remove(H);return}e(G.select("thead,tbody,tfoot",H),function(N){if(N.rows.length==0){G.remove(N)}});t();row=g[Math.min(g.length-1,L.y)];if(row){K.select(row[Math.min(row.length-1,L.x)].elm,true);K.collapse(true)}}function u(S,Q,U,R){var P,N,M,O,T;P=g[Q][S].elm.parentNode;for(M=1;M<=U;M++){P=G.getNext(P,"tr");if(P){for(N=S;N>=0;N--){T=g[Q+M][N].elm;if(T.parentNode==P){for(O=1;O<=R;O++){G.insertAfter(f(T),T)}break}}if(N==-1){for(O=1;O<=R;O++){P.insertBefore(f(P.cells[0]),P.cells[0])}}}}}function C(){e(g,function(M,N){e(M,function(P,O){var S,R,T,Q;if(j(P)){P=P.elm;S=a(P,"colspan");R=a(P,"rowspan");if(S>1||R>1){s(P,"rowSpan",1);s(P,"colSpan",1);for(Q=0;Q<S-1;Q++){G.insertAfter(f(P),P)}u(O,N,R-1,S)}}})})}function p(V,S,Y){var P,O,X,W,U,R,T,M,V,N,Q;if(V){pos=F(V);P=pos.x;O=pos.y;X=P+(S-1);W=O+(Y-1)}else{L=D=null;e(g,function(Z,aa){e(Z,function(ac,ab){if(j(ac)){if(!L){L={x:ab,y:aa}}D={x:ab,y:aa}}})});P=L.x;O=L.y;X=D.x;W=D.y}T=z(P,O);M=z(X,W);if(T&&M&&T.part==M.part){C();t();T=z(P,O).elm;s(T,"colSpan",(X-P)+1);s(T,"rowSpan",(W-O)+1);for(R=O;R<=W;R++){for(U=P;U<=X;U++){if(!g[R]||!g[R][U]){continue}V=g[R][U].elm;if(V!=T){N=d.grep(V.childNodes);e(N,function(Z){T.appendChild(Z)});if(N.length){N=d.grep(T.childNodes);Q=0;e(N,function(Z){if(Z.nodeName=="BR"&&G.getAttrib(Z,"data-mce-bogus")&&Q++<N.length-1){T.removeChild(Z)}})}G.remove(V)}}}q()}}function l(Q){var M,S,P,R,T,U,N,V,O;e(g,function(W,X){e(W,function(Z,Y){if(j(Z)){Z=Z.elm;T=Z.parentNode;U=A(T,false);M=X;if(Q){return false}}});if(Q){return !M}});for(R=0;R<g[0].length;R++){if(!g[M][R]){continue}S=g[M][R].elm;if(S!=P){if(!Q){O=a(S,"rowspan");if(O>1){s(S,"rowSpan",O+1);continue}}else{if(M>0&&g[M-1][R]){V=g[M-1][R].elm;O=a(V,"rowSpan");if(O>1){s(V,"rowSpan",O+1);continue}}}N=f(S);s(N,"colSpan",S.colSpan);U.appendChild(N);P=S}}if(U.hasChildNodes()){if(!Q){G.insertAfter(U,T)}else{T.parentNode.insertBefore(U,T)}}}function h(N){var O,M;e(g,function(P,Q){e(P,function(S,R){if(j(S)){O=R;if(N){return false}}});if(N){return !O}});e(g,function(S,T){var P,Q,R;if(!S[O]){return}P=S[O].elm;if(P!=M){R=a(P,"colspan");Q=a(P,"rowspan");if(R==1){if(!N){G.insertAfter(f(P),P);u(O,T,Q-1,R)}else{P.parentNode.insertBefore(f(P),P);u(O,T,Q-1,R)}}else{s(P,"colSpan",P.colSpan+1)}M=P}})}function n(){var M=[];e(g,function(N,O){e(N,function(Q,P){if(j(Q)&&d.inArray(M,P)===-1){e(g,function(T){var R=T[P].elm,S;S=a(R,"colSpan");if(S>1){s(R,"colSpan",S-1)}else{G.remove(R)}});M.push(P)}})});q()}function m(){var N;function M(Q){var P,R,O;P=G.getNext(Q,"tr");e(Q.cells,function(S){var T=a(S,"rowSpan");if(T>1){s(S,"rowSpan",T-1);R=F(S);u(R.x,R.y,1,1)}});R=F(Q.cells[0]);e(g[R.y],function(S){var T;S=S.elm;if(S!=O){T=a(S,"rowSpan");if(T<=1){G.remove(S)}else{s(S,"rowSpan",T-1)}O=S}})}N=k();e(N.reverse(),function(O){M(O)});q()}function E(){var M=k();G.remove(M);q();return M}function J(){var M=k();e(M,function(O,N){M[N]=A(O,true)});return M}function B(O,N){if(!O){return}var P=k(),M=P[N?0:P.length-1],Q=M.cells.length;e(g,function(S){var R;Q=0;e(S,function(U,T){if(U.real){Q+=U.colspan}if(U.elm.parentNode==M){R=1}});if(R){return false}});if(!N){O.reverse()}e(O,function(T){var S=T.cells.length,R;for(i=0;i<S;i++){R=T.cells[i];s(R,"colSpan",1);s(R,"rowSpan",1)}for(i=S;i<Q;i++){T.appendChild(f(T.cells[S-1]))}for(i=Q;i<S;i++){G.remove(T.cells[i])}if(N){M.parentNode.insertBefore(T,M)}else{G.insertAfter(T,M)}});G.removeClass(G.select("td.mceSelected,th.mceSelected"),"mceSelected")}function F(M){var N;e(g,function(O,P){e(O,function(R,Q){if(R.elm==M){N={x:Q,y:P};return false}});return !N});return N}function w(M){L=F(M)}function I(){var O,N,M;N=M=0;e(g,function(P,Q){e(P,function(S,R){var U,T;if(j(S)){S=g[Q][R];if(R>N){N=R}if(Q>M){M=Q}if(S.real){U=S.colspan-1;T=S.rowspan-1;if(U){if(R+U>N){N=R+U}}if(T){if(Q+T>M){M=Q+T}}}}})});return{x:N,y:M}}function v(S){var P,O,U,T,N,M,Q,R;D=F(S);if(L&&D){P=Math.min(L.x,D.x);O=Math.min(L.y,D.y);U=Math.max(L.x,D.x);T=Math.max(L.y,D.y);N=U;M=T;for(y=O;y<=M;y++){S=g[y][P];if(!S.real){if(P-(S.colspan-1)<P){P-=S.colspan-1}}}for(x=P;x<=N;x++){S=g[O][x];if(!S.real){if(O-(S.rowspan-1)<O){O-=S.rowspan-1}}}for(y=O;y<=T;y++){for(x=P;x<=U;x++){S=g[y][x];if(S.real){Q=S.colspan-1;R=S.rowspan-1;if(Q){if(x+Q>N){N=x+Q}}if(R){if(y+R>M){M=y+R}}}}}G.removeClass(G.select("td.mceSelected,th.mceSelected"),"mceSelected");for(y=O;y<=M;y++){for(x=P;x<=N;x++){if(g[y][x]){G.addClass(g[y][x].elm,"mceSelected")}}}}}d.extend(this,{deleteTable:r,split:C,merge:p,insertRow:l,insertCol:h,deleteCols:n,deleteRows:m,cutRows:E,copyRows:J,pasteRows:B,getPos:F,setStartCell:w,setEndCell:v})}d.create("tinymce.plugins.TablePlugin",{init:function(g,h){var f,m,j=true;function l(p){var o=g.selection,n=g.dom.getParent(p||o.getNode(),"table");if(n){return new b(n,g.dom,o)}}function k(){g.getBody().style.webkitUserSelect="";if(j){g.dom.removeClass(g.dom.select("td.mceSelected,th.mceSelected"),"mceSelected");j=false}}e([["table","table.desc","mceInsertTable",true],["delete_table","table.del","mceTableDelete"],["delete_col","table.delete_col_desc","mceTableDeleteCol"],["delete_row","table.delete_row_desc","mceTableDeleteRow"],["col_after","table.col_after_desc","mceTableInsertColAfter"],["col_before","table.col_before_desc","mceTableInsertColBefore"],["row_after","table.row_after_desc","mceTableInsertRowAfter"],["row_before","table.row_before_desc","mceTableInsertRowBefore"],["row_props","table.row_desc","mceTableRowProps",true],["cell_props","table.cell_desc","mceTableCellProps",true],["split_cells","table.split_cells_desc","mceTableSplitCells",true],["merge_cells","table.merge_cells_desc","mceTableMergeCells",true]],function(n){g.addButton(n[0],{title:n[1],cmd:n[2],ui:n[3]})});if(!d.isIE){g.onClick.add(function(n,o){o=o.target;if(o.nodeName==="TABLE"){n.selection.select(o);n.nodeChanged()}})}g.onPreProcess.add(function(o,p){var n,q,r,t=o.dom,s;n=t.select("table",p.node);q=n.length;while(q--){r=n[q];t.setAttrib(r,"data-mce-style","");if((s=t.getAttrib(r,"width"))){t.setStyle(r,"width",s);t.setAttrib(r,"width","")}if((s=t.getAttrib(r,"height"))){t.setStyle(r,"height",s);t.setAttrib(r,"height","")}}});g.onNodeChange.add(function(q,o,s){var r;s=q.selection.getStart();r=q.dom.getParent(s,"td,th,caption");o.setActive("table",s.nodeName==="TABLE"||!!r);if(r&&r.nodeName==="CAPTION"){r=0}o.setDisabled("delete_table",!r);o.setDisabled("delete_col",!r);o.setDisabled("delete_table",!r);o.setDisabled("delete_row",!r);o.setDisabled("col_after",!r);o.setDisabled("col_before",!r);o.setDisabled("row_after",!r);o.setDisabled("row_before",!r);o.setDisabled("row_props",!r);o.setDisabled("cell_props",!r);o.setDisabled("split_cells",!r);o.setDisabled("merge_cells",!r)});g.onInit.add(function(r){var p,t,q=r.dom,u;f=r.windowManager;r.onMouseDown.add(function(w,z){if(z.button!=2){k();t=q.getParent(z.target,"td,th");p=q.getParent(t,"table")}});q.bind(r.getDoc(),"mouseover",function(C){var A,z,B=C.target;if(t&&(u||B!=t)&&(B.nodeName=="TD"||B.nodeName=="TH")){z=q.getParent(B,"table");if(z==p){if(!u){u=l(z);u.setStartCell(t);r.getBody().style.webkitUserSelect="none"}u.setEndCell(B);j=true}A=r.selection.getSel();try{if(A.removeAllRanges){A.removeAllRanges()}else{A.empty()}}catch(w){}C.preventDefault()}});r.onMouseUp.add(function(F,G){var z,B=F.selection,H,I=B.getSel(),w,C,A,E;if(t){if(u){F.getBody().style.webkitUserSelect=""}function D(J,L){var K=new d.dom.TreeWalker(J,J);do{if(J.nodeType==3&&d.trim(J.nodeValue).length!=0){if(L){z.setStart(J,0)}else{z.setEnd(J,J.nodeValue.length)}return}if(J.nodeName=="BR"){if(L){z.setStartBefore(J)}else{z.setEndBefore(J)}return}}while(J=(L?K.next():K.prev()))}H=q.select("td.mceSelected,th.mceSelected");if(H.length>0){z=q.createRng();C=H[0];E=H[H.length-1];z.setStartBefore(C);z.setEndAfter(C);D(C,1);w=new d.dom.TreeWalker(C,q.getParent(H[0],"table"));do{if(C.nodeName=="TD"||C.nodeName=="TH"){if(!q.hasClass(C,"mceSelected")){break}A=C}}while(C=w.next());D(A);B.setRng(z)}F.nodeChanged();t=u=p=null}});r.onKeyUp.add(function(w,z){k()});r.onKeyDown.add(function(w,z){n(w)});r.onMouseDown.add(function(w,z){if(z.button!=2){n(w)}});function o(D,z,A,F){var B=3,G=D.dom.getParent(z.startContainer,"TABLE"),C,w,E;if(G){C=G.parentNode}w=z.startContainer.nodeType==B&&z.startOffset==0&&z.endOffset==0&&F&&(A.nodeName=="TR"||A==C);E=(A.nodeName=="TD"||A.nodeName=="TH")&&!F;return w||E}function n(A){if(!d.isWebKit){return}var z=A.selection.getRng();var C=A.selection.getNode();var B=A.dom.getParent(z.startContainer,"TD,TH");if(!o(A,z,C,B)){return}if(!B){B=C}var w=B.lastChild;while(w.lastChild){w=w.lastChild}z.setEnd(w,w.nodeValue.length);A.selection.setRng(z)}r.plugins.table.fixTableCellSelection=n;if(r&&r.plugins.contextmenu){r.plugins.contextmenu.onContextMenu.add(function(A,w,C){var D,B=r.selection,z=B.getNode()||r.getBody();if(r.dom.getParent(C,"td")||r.dom.getParent(C,"th")||r.dom.select("td.mceSelected,th.mceSelected").length){w.removeAll();if(z.nodeName=="A"&&!r.dom.getAttrib(z,"name")){w.add({title:"advanced.link_desc",icon:"link",cmd:r.plugins.advlink?"mceAdvLink":"mceLink",ui:true});w.add({title:"advanced.unlink_desc",icon:"unlink",cmd:"UnLink"});w.addSeparator()}if(z.nodeName=="IMG"&&z.className.indexOf("mceItem")==-1){w.add({title:"advanced.image_desc",icon:"image",cmd:r.plugins.advimage?"mceAdvImage":"mceImage",ui:true});w.addSeparator()}w.add({title:"table.desc",icon:"table",cmd:"mceInsertTable",value:{action:"insert"}});w.add({title:"table.props_desc",icon:"table_props",cmd:"mceInsertTable"});w.add({title:"table.del",icon:"delete_table",cmd:"mceTableDelete"});w.addSeparator();D=w.addMenu({title:"table.cell"});D.add({title:"table.cell_desc",icon:"cell_props",cmd:"mceTableCellProps"});D.add({title:"table.split_cells_desc",icon:"split_cells",cmd:"mceTableSplitCells"});D.add({title:"table.merge_cells_desc",icon:"merge_cells",cmd:"mceTableMergeCells"});D=w.addMenu({title:"table.row"});D.add({title:"table.row_desc",icon:"row_props",cmd:"mceTableRowProps"});D.add({title:"table.row_before_desc",icon:"row_before",cmd:"mceTableInsertRowBefore"});D.add({title:"table.row_after_desc",icon:"row_after",cmd:"mceTableInsertRowAfter"});D.add({title:"table.delete_row_desc",icon:"delete_row",cmd:"mceTableDeleteRow"});D.addSeparator();D.add({title:"table.cut_row_desc",icon:"cut",cmd:"mceTableCutRow"});D.add({title:"table.copy_row_desc",icon:"copy",cmd:"mceTableCopyRow"});D.add({title:"table.paste_row_before_desc",icon:"paste",cmd:"mceTablePasteRowBefore"}).setDisabled(!m);D.add({title:"table.paste_row_after_desc",icon:"paste",cmd:"mceTablePasteRowAfter"}).setDisabled(!m);D=w.addMenu({title:"table.col"});D.add({title:"table.col_before_desc",icon:"col_before",cmd:"mceTableInsertColBefore"});D.add({title:"table.col_after_desc",icon:"col_after",cmd:"mceTableInsertColAfter"});D.add({title:"table.delete_col_desc",icon:"delete_col",cmd:"mceTableDeleteCol"})}else{w.add({title:"table.desc",icon:"table",cmd:"mceInsertTable"})}})}if(d.isWebKit){function v(C,N){var L=d.VK;var Q=N.keyCode;function O(Y,U,S){var T=Y?"previousSibling":"nextSibling";var Z=C.dom.getParent(U,"tr");var X=Z[T];if(X){z(C,U,X,Y);d.dom.Event.cancel(S);return true}else{var aa=C.dom.getParent(Z,"table");var W=Z.parentNode;var R=W.nodeName.toLowerCase();if(R==="tbody"||R===(Y?"tfoot":"thead")){var V=w(Y,aa,W,"tbody");if(V!==null){return K(Y,V,U,S)}}return M(Y,Z,T,aa,S)}}function w(V,T,U,X){var S=C.dom.select(">"+X,T);var R=S.indexOf(U);if(V&&R===0||!V&&R===S.length-1){return B(V,T)}else{if(R===-1){var W=U.tagName.toLowerCase()==="thead"?0:S.length-1;return S[W]}else{return S[R+(V?-1:1)]}}}function B(U,T){var S=U?"thead":"tfoot";var R=C.dom.select(">"+S,T);return R.length!==0?R[0]:null}function K(V,T,S,U){var R=J(T,V);R&&z(C,S,R,V);d.dom.Event.cancel(U);return true}function M(Y,U,R,X,W){var S=X[R];if(S){F(S);return true}else{var V=C.dom.getParent(X,"td,th");if(V){return O(Y,V,W)}else{var T=J(U,!Y);F(T);return d.dom.Event.cancel(W)}}}function J(S,R){var T=S&&S[R?"lastChild":"firstChild"];return T&&T.nodeName==="BR"?C.dom.getParent(T,"td,th"):T}function F(R){C.selection.setCursorLocation(R,0)}function A(){return Q==L.UP||Q==L.DOWN}function D(R){var T=R.selection.getNode();var S=R.dom.getParent(T,"tr");return S!==null}function P(S){var R=0;var T=S;while(T.previousSibling){T=T.previousSibling;R=R+a(T,"colspan")}return R}function E(T,R){var U=0;var S=0;e(T.children,function(V,W){U=U+a(V,"colspan");S=W;if(U>R){return false}});return S}function z(T,W,Y,V){var X=P(T.dom.getParent(W,"td,th"));var S=E(Y,X);var R=Y.childNodes[S];var U=J(R,V);F(U||R)}function H(R){var T=C.selection.getNode();var U=C.dom.getParent(T,"td,th");var S=C.dom.getParent(R,"td,th");return U&&U!==S&&I(U,S)}function I(S,R){return C.dom.getParent(S,"TABLE")===C.dom.getParent(R,"TABLE")}if(A()&&D(C)){var G=C.selection.getNode();setTimeout(function(){if(H(G)){O(!N.shiftKey&&Q===L.UP,G,N)}},0)}}r.onKeyDown.add(v)}function s(){var w;for(w=r.getBody().lastChild;w&&w.nodeType==3&&!w.nodeValue.length;w=w.previousSibling){}if(w&&w.nodeName=="TABLE"){if(r.settings.forced_root_block){r.dom.add(r.getBody(),r.settings.forced_root_block,null,d.isIE?" ":'<br data-mce-bogus="1" />')}else{r.dom.add(r.getBody(),"br",{"data-mce-bogus":"1"})}}}if(d.isGecko){r.onKeyDown.add(function(z,B){var w,A,C=z.dom;if(B.keyCode==37||B.keyCode==38){w=z.selection.getRng();A=C.getParent(w.startContainer,"table");if(A&&z.getBody().firstChild==A){if(c(w,A)){w=C.createRng();w.setStartBefore(A);w.setEndBefore(A);z.selection.setRng(w);B.preventDefault()}}}})}r.onKeyUp.add(s);r.onSetContent.add(s);r.onVisualAid.add(s);r.onPreProcess.add(function(w,A){var z=A.node.lastChild;if(z&&(z.nodeName=="BR"||(z.childNodes.length==1&&(z.firstChild.nodeName=="BR"||z.firstChild.nodeValue=="\u00a0")))&&z.previousSibling&&z.previousSibling.nodeName=="TABLE"){w.dom.remove(z)}});s();r.startContent=r.getContent({format:"raw"})});e({mceTableSplitCells:function(n){n.split()},mceTableMergeCells:function(o){var p,q,n;n=g.dom.getParent(g.selection.getNode(),"th,td");if(n){p=n.rowSpan;q=n.colSpan}if(!g.dom.select("td.mceSelected,th.mceSelected").length){f.open({url:h+"/merge_cells.htm",width:240+parseInt(g.getLang("table.merge_cells_delta_width",0)),height:110+parseInt(g.getLang("table.merge_cells_delta_height",0)),inline:1},{rows:p,cols:q,onaction:function(r){o.merge(n,r.cols,r.rows)},plugin_url:h})}else{o.merge()}},mceTableInsertRowBefore:function(n){n.insertRow(true)},mceTableInsertRowAfter:function(n){n.insertRow()},mceTableInsertColBefore:function(n){n.insertCol(true)},mceTableInsertColAfter:function(n){n.insertCol()},mceTableDeleteCol:function(n){n.deleteCols()},mceTableDeleteRow:function(n){n.deleteRows()},mceTableCutRow:function(n){m=n.cutRows()},mceTableCopyRow:function(n){m=n.copyRows()},mceTablePasteRowBefore:function(n){n.pasteRows(m,true)},mceTablePasteRowAfter:function(n){n.pasteRows(m)},mceTableDelete:function(n){n.deleteTable()}},function(o,n){g.addCommand(n,function(){var p=l();if(p){o(p);g.execCommand("mceRepaint");k()}})});e({mceInsertTable:function(n){f.open({url:h+"/table.htm",width:400+parseInt(g.getLang("table.table_delta_width",0)),height:320+parseInt(g.getLang("table.table_delta_height",0)),inline:1},{plugin_url:h,action:n?n.action:0})},mceTableRowProps:function(){f.open({url:h+"/row.htm",width:400+parseInt(g.getLang("table.rowprops_delta_width",0)),height:295+parseInt(g.getLang("table.rowprops_delta_height",0)),inline:1},{plugin_url:h})},mceTableCellProps:function(){f.open({url:h+"/cell.htm",width:400+parseInt(g.getLang("table.cellprops_delta_width",0)),height:295+parseInt(g.getLang("table.cellprops_delta_height",0)),inline:1},{plugin_url:h})}},function(o,n){g.addCommand(n,function(p,q){o(q)})})}});d.PluginManager.add("table",d.plugins.TablePlugin)})(tinymce);
|
1 |
+
(function(d){var e=d.each;function c(g,h){var j=h.ownerDocument,f=j.createRange(),k;f.setStartBefore(h);f.setEnd(g.endContainer,g.endOffset);k=j.createElement("body");k.appendChild(f.cloneContents());return k.innerHTML.replace(/<(br|img|object|embed|input|textarea)[^>]*>/gi,"-").replace(/<[^>]+>/g,"").length==0}function a(g,f){return parseInt(g.getAttribute(f)||1)}function b(H,G,K){var g,L,D,o;t();o=G.getParent(K.getStart(),"th,td");if(o){L=F(o);D=I();o=z(L.x,L.y)}function A(N,M){N=N.cloneNode(M);N.removeAttribute("id");return N}function t(){var M=0;g=[];e(["thead","tbody","tfoot"],function(N){var O=G.select("> "+N+" tr",H);e(O,function(P,Q){Q+=M;e(G.select("> td, > th",P),function(W,R){var S,T,U,V;if(g[Q]){while(g[Q][R]){R++}}U=a(W,"rowspan");V=a(W,"colspan");for(T=Q;T<Q+U;T++){if(!g[T]){g[T]=[]}for(S=R;S<R+V;S++){g[T][S]={part:N,real:T==Q&&S==R,elm:W,rowspan:U,colspan:V}}}})});M+=O.length})}function z(M,O){var N;N=g[O];if(N){return N[M]}}function s(O,M,N){if(O){N=parseInt(N);if(N===1){O.removeAttribute(M,1)}else{O.setAttribute(M,N,1)}}}function j(M){return M&&(G.hasClass(M.elm,"mceSelected")||M==o)}function k(){var M=[];e(H.rows,function(N){e(N.cells,function(O){if(G.hasClass(O,"mceSelected")||O==o.elm){M.push(N);return false}})});return M}function r(){var M=G.createRng();M.setStartAfter(H);M.setEndAfter(H);K.setRng(M);G.remove(H)}function f(M){var N;d.walk(M,function(P){var O;if(P.nodeType==3){e(G.getParents(P.parentNode,null,M).reverse(),function(Q){Q=A(Q,false);if(!N){N=O=Q}else{if(O){O.appendChild(Q)}}O=Q});if(O){O.innerHTML=d.isIE&&!d.isIE11?" ":'<br data-mce-bogus="1" />'}return false}},"childNodes");M=A(M,false);s(M,"rowSpan",1);s(M,"colSpan",1);if(N){M.appendChild(N)}else{if(!d.isIE||d.isIE11){M.innerHTML='<br data-mce-bogus="1" />'}}return M}function q(){var M=G.createRng();e(G.select("tr",H),function(N){if(N.cells.length==0){G.remove(N)}});if(G.select("tr",H).length==0){M.setStartAfter(H);M.setEndAfter(H);K.setRng(M);G.remove(H);return}e(G.select("thead,tbody,tfoot",H),function(N){if(N.rows.length==0){G.remove(N)}});t();row=g[Math.min(g.length-1,L.y)];if(row){K.select(row[Math.min(row.length-1,L.x)].elm,true);K.collapse(true)}}function u(S,Q,U,R){var P,N,M,O,T;P=g[Q][S].elm.parentNode;for(M=1;M<=U;M++){P=G.getNext(P,"tr");if(P){for(N=S;N>=0;N--){T=g[Q+M][N].elm;if(T.parentNode==P){for(O=1;O<=R;O++){G.insertAfter(f(T),T)}break}}if(N==-1){for(O=1;O<=R;O++){P.insertBefore(f(P.cells[0]),P.cells[0])}}}}}function C(){e(g,function(M,N){e(M,function(P,O){var S,R,T,Q;if(j(P)){P=P.elm;S=a(P,"colspan");R=a(P,"rowspan");if(S>1||R>1){s(P,"rowSpan",1);s(P,"colSpan",1);for(Q=0;Q<S-1;Q++){G.insertAfter(f(P),P)}u(O,N,R-1,S)}}})})}function p(V,S,Y){var P,O,X,W,U,R,T,M,V,N,Q;if(V){pos=F(V);P=pos.x;O=pos.y;X=P+(S-1);W=O+(Y-1)}else{L=D=null;e(g,function(Z,aa){e(Z,function(ac,ab){if(j(ac)){if(!L){L={x:ab,y:aa}}D={x:ab,y:aa}}})});P=L.x;O=L.y;X=D.x;W=D.y}T=z(P,O);M=z(X,W);if(T&&M&&T.part==M.part){C();t();T=z(P,O).elm;s(T,"colSpan",(X-P)+1);s(T,"rowSpan",(W-O)+1);for(R=O;R<=W;R++){for(U=P;U<=X;U++){if(!g[R]||!g[R][U]){continue}V=g[R][U].elm;if(V!=T){N=d.grep(V.childNodes);e(N,function(Z){T.appendChild(Z)});if(N.length){N=d.grep(T.childNodes);Q=0;e(N,function(Z){if(Z.nodeName=="BR"&&G.getAttrib(Z,"data-mce-bogus")&&Q++<N.length-1){T.removeChild(Z)}})}G.remove(V)}}}q()}}function l(Q){var M,S,P,R,T,U,N,V,O;e(g,function(W,X){e(W,function(Z,Y){if(j(Z)){Z=Z.elm;T=Z.parentNode;U=A(T,false);M=X;if(Q){return false}}});if(Q){return !M}});for(R=0;R<g[0].length;R++){if(!g[M][R]){continue}S=g[M][R].elm;if(S!=P){if(!Q){O=a(S,"rowspan");if(O>1){s(S,"rowSpan",O+1);continue}}else{if(M>0&&g[M-1][R]){V=g[M-1][R].elm;O=a(V,"rowSpan");if(O>1){s(V,"rowSpan",O+1);continue}}}N=f(S);s(N,"colSpan",S.colSpan);U.appendChild(N);P=S}}if(U.hasChildNodes()){if(!Q){G.insertAfter(U,T)}else{T.parentNode.insertBefore(U,T)}}}function h(N){var O,M;e(g,function(P,Q){e(P,function(S,R){if(j(S)){O=R;if(N){return false}}});if(N){return !O}});e(g,function(S,T){var P,Q,R;if(!S[O]){return}P=S[O].elm;if(P!=M){R=a(P,"colspan");Q=a(P,"rowspan");if(R==1){if(!N){G.insertAfter(f(P),P);u(O,T,Q-1,R)}else{P.parentNode.insertBefore(f(P),P);u(O,T,Q-1,R)}}else{s(P,"colSpan",P.colSpan+1)}M=P}})}function n(){var M=[];e(g,function(N,O){e(N,function(Q,P){if(j(Q)&&d.inArray(M,P)===-1){e(g,function(T){var R=T[P].elm,S;S=a(R,"colSpan");if(S>1){s(R,"colSpan",S-1)}else{G.remove(R)}});M.push(P)}})});q()}function m(){var N;function M(Q){var P,R,O;P=G.getNext(Q,"tr");e(Q.cells,function(S){var T=a(S,"rowSpan");if(T>1){s(S,"rowSpan",T-1);R=F(S);u(R.x,R.y,1,1)}});R=F(Q.cells[0]);e(g[R.y],function(S){var T;S=S.elm;if(S!=O){T=a(S,"rowSpan");if(T<=1){G.remove(S)}else{s(S,"rowSpan",T-1)}O=S}})}N=k();e(N.reverse(),function(O){M(O)});q()}function E(){var M=k();G.remove(M);q();return M}function J(){var M=k();e(M,function(O,N){M[N]=A(O,true)});return M}function B(O,N){if(!O){return}var P=k(),M=P[N?0:P.length-1],Q=M.cells.length;e(g,function(S){var R;Q=0;e(S,function(U,T){if(U.real){Q+=U.colspan}if(U.elm.parentNode==M){R=1}});if(R){return false}});if(!N){O.reverse()}e(O,function(T){var S=T.cells.length,R;for(i=0;i<S;i++){R=T.cells[i];s(R,"colSpan",1);s(R,"rowSpan",1)}for(i=S;i<Q;i++){T.appendChild(f(T.cells[S-1]))}for(i=Q;i<S;i++){G.remove(T.cells[i])}if(N){M.parentNode.insertBefore(T,M)}else{G.insertAfter(T,M)}});G.removeClass(G.select("td.mceSelected,th.mceSelected"),"mceSelected")}function F(M){var N;e(g,function(O,P){e(O,function(R,Q){if(R.elm==M){N={x:Q,y:P};return false}});return !N});return N}function w(M){L=F(M)}function I(){var O,N,M;N=M=0;e(g,function(P,Q){e(P,function(S,R){var U,T;if(j(S)){S=g[Q][R];if(R>N){N=R}if(Q>M){M=Q}if(S.real){U=S.colspan-1;T=S.rowspan-1;if(U){if(R+U>N){N=R+U}}if(T){if(Q+T>M){M=Q+T}}}}})});return{x:N,y:M}}function v(S){var P,O,U,T,N,M,Q,R;D=F(S);if(L&&D){P=Math.min(L.x,D.x);O=Math.min(L.y,D.y);U=Math.max(L.x,D.x);T=Math.max(L.y,D.y);N=U;M=T;for(y=O;y<=M;y++){S=g[y][P];if(!S.real){if(P-(S.colspan-1)<P){P-=S.colspan-1}}}for(x=P;x<=N;x++){S=g[O][x];if(!S.real){if(O-(S.rowspan-1)<O){O-=S.rowspan-1}}}for(y=O;y<=T;y++){for(x=P;x<=U;x++){S=g[y][x];if(S.real){Q=S.colspan-1;R=S.rowspan-1;if(Q){if(x+Q>N){N=x+Q}}if(R){if(y+R>M){M=y+R}}}}}G.removeClass(G.select("td.mceSelected,th.mceSelected"),"mceSelected");for(y=O;y<=M;y++){for(x=P;x<=N;x++){if(g[y][x]){G.addClass(g[y][x].elm,"mceSelected")}}}}}d.extend(this,{deleteTable:r,split:C,merge:p,insertRow:l,insertCol:h,deleteCols:n,deleteRows:m,cutRows:E,copyRows:J,pasteRows:B,getPos:F,setStartCell:w,setEndCell:v})}d.create("tinymce.plugins.TablePlugin",{init:function(g,h){var f,m,j=true;function l(p){var o=g.selection,n=g.dom.getParent(p||o.getNode(),"table");if(n){return new b(n,g.dom,o)}}function k(){g.getBody().style.webkitUserSelect="";if(j){g.dom.removeClass(g.dom.select("td.mceSelected,th.mceSelected"),"mceSelected");j=false}}e([["table","table.desc","mceInsertTable",true],["delete_table","table.del","mceTableDelete"],["delete_col","table.delete_col_desc","mceTableDeleteCol"],["delete_row","table.delete_row_desc","mceTableDeleteRow"],["col_after","table.col_after_desc","mceTableInsertColAfter"],["col_before","table.col_before_desc","mceTableInsertColBefore"],["row_after","table.row_after_desc","mceTableInsertRowAfter"],["row_before","table.row_before_desc","mceTableInsertRowBefore"],["row_props","table.row_desc","mceTableRowProps",true],["cell_props","table.cell_desc","mceTableCellProps",true],["split_cells","table.split_cells_desc","mceTableSplitCells",true],["merge_cells","table.merge_cells_desc","mceTableMergeCells",true]],function(n){g.addButton(n[0],{title:n[1],cmd:n[2],ui:n[3]})});if(!d.isIE){g.onClick.add(function(n,o){o=o.target;if(o.nodeName==="TABLE"){n.selection.select(o);n.nodeChanged()}})}g.onPreProcess.add(function(o,p){var n,q,r,t=o.dom,s;n=t.select("table",p.node);q=n.length;while(q--){r=n[q];t.setAttrib(r,"data-mce-style","");if((s=t.getAttrib(r,"width"))){t.setStyle(r,"width",s);t.setAttrib(r,"width","")}if((s=t.getAttrib(r,"height"))){t.setStyle(r,"height",s);t.setAttrib(r,"height","")}}});g.onNodeChange.add(function(q,o,s){var r;s=q.selection.getStart();r=q.dom.getParent(s,"td,th,caption");o.setActive("table",s.nodeName==="TABLE"||!!r);if(r&&r.nodeName==="CAPTION"){r=0}o.setDisabled("delete_table",!r);o.setDisabled("delete_col",!r);o.setDisabled("delete_table",!r);o.setDisabled("delete_row",!r);o.setDisabled("col_after",!r);o.setDisabled("col_before",!r);o.setDisabled("row_after",!r);o.setDisabled("row_before",!r);o.setDisabled("row_props",!r);o.setDisabled("cell_props",!r);o.setDisabled("split_cells",!r);o.setDisabled("merge_cells",!r)});g.onInit.add(function(r){var p,t,q=r.dom,u;f=r.windowManager;r.onMouseDown.add(function(w,z){if(z.button!=2){k();t=q.getParent(z.target,"td,th");p=q.getParent(t,"table")}});q.bind(r.getDoc(),"mouseover",function(C){var A,z,B=C.target;if(t&&(u||B!=t)&&(B.nodeName=="TD"||B.nodeName=="TH")){z=q.getParent(B,"table");if(z==p){if(!u){u=l(z);u.setStartCell(t);r.getBody().style.webkitUserSelect="none"}u.setEndCell(B);j=true}A=r.selection.getSel();try{if(A.removeAllRanges){A.removeAllRanges()}else{A.empty()}}catch(w){}C.preventDefault()}});r.onMouseUp.add(function(F,G){var z,B=F.selection,H,I=B.getSel(),w,C,A,E;if(t){if(u){F.getBody().style.webkitUserSelect=""}function D(J,L){var K=new d.dom.TreeWalker(J,J);do{if(J.nodeType==3&&d.trim(J.nodeValue).length!=0){if(L){z.setStart(J,0)}else{z.setEnd(J,J.nodeValue.length)}return}if(J.nodeName=="BR"){if(L){z.setStartBefore(J)}else{z.setEndBefore(J)}return}}while(J=(L?K.next():K.prev()))}H=q.select("td.mceSelected,th.mceSelected");if(H.length>0){z=q.createRng();C=H[0];E=H[H.length-1];z.setStartBefore(C);z.setEndAfter(C);D(C,1);w=new d.dom.TreeWalker(C,q.getParent(H[0],"table"));do{if(C.nodeName=="TD"||C.nodeName=="TH"){if(!q.hasClass(C,"mceSelected")){break}A=C}}while(C=w.next());D(A);B.setRng(z)}F.nodeChanged();t=u=p=null}});r.onKeyUp.add(function(w,z){k()});r.onKeyDown.add(function(w,z){n(w)});r.onMouseDown.add(function(w,z){if(z.button!=2){n(w)}});function o(D,z,A,F){var B=3,G=D.dom.getParent(z.startContainer,"TABLE"),C,w,E;if(G){C=G.parentNode}w=z.startContainer.nodeType==B&&z.startOffset==0&&z.endOffset==0&&F&&(A.nodeName=="TR"||A==C);E=(A.nodeName=="TD"||A.nodeName=="TH")&&!F;return w||E}function n(A){if(!d.isWebKit){return}var z=A.selection.getRng();var C=A.selection.getNode();var B=A.dom.getParent(z.startContainer,"TD,TH");if(!o(A,z,C,B)){return}if(!B){B=C}var w=B.lastChild;while(w.lastChild){w=w.lastChild}z.setEnd(w,w.nodeValue.length);A.selection.setRng(z)}r.plugins.table.fixTableCellSelection=n;if(r&&r.plugins.contextmenu){r.plugins.contextmenu.onContextMenu.add(function(A,w,C){var D,B=r.selection,z=B.getNode()||r.getBody();if(r.dom.getParent(C,"td")||r.dom.getParent(C,"th")||r.dom.select("td.mceSelected,th.mceSelected").length){w.removeAll();if(z.nodeName=="A"&&!r.dom.getAttrib(z,"name")){w.add({title:"advanced.link_desc",icon:"link",cmd:r.plugins.advlink?"mceAdvLink":"mceLink",ui:true});w.add({title:"advanced.unlink_desc",icon:"unlink",cmd:"UnLink"});w.addSeparator()}if(z.nodeName=="IMG"&&z.className.indexOf("mceItem")==-1){w.add({title:"advanced.image_desc",icon:"image",cmd:r.plugins.advimage?"mceAdvImage":"mceImage",ui:true});w.addSeparator()}w.add({title:"table.desc",icon:"table",cmd:"mceInsertTable",value:{action:"insert"}});w.add({title:"table.props_desc",icon:"table_props",cmd:"mceInsertTable"});w.add({title:"table.del",icon:"delete_table",cmd:"mceTableDelete"});w.addSeparator();D=w.addMenu({title:"table.cell"});D.add({title:"table.cell_desc",icon:"cell_props",cmd:"mceTableCellProps"});D.add({title:"table.split_cells_desc",icon:"split_cells",cmd:"mceTableSplitCells"});D.add({title:"table.merge_cells_desc",icon:"merge_cells",cmd:"mceTableMergeCells"});D=w.addMenu({title:"table.row"});D.add({title:"table.row_desc",icon:"row_props",cmd:"mceTableRowProps"});D.add({title:"table.row_before_desc",icon:"row_before",cmd:"mceTableInsertRowBefore"});D.add({title:"table.row_after_desc",icon:"row_after",cmd:"mceTableInsertRowAfter"});D.add({title:"table.delete_row_desc",icon:"delete_row",cmd:"mceTableDeleteRow"});D.addSeparator();D.add({title:"table.cut_row_desc",icon:"cut",cmd:"mceTableCutRow"});D.add({title:"table.copy_row_desc",icon:"copy",cmd:"mceTableCopyRow"});D.add({title:"table.paste_row_before_desc",icon:"paste",cmd:"mceTablePasteRowBefore"}).setDisabled(!m);D.add({title:"table.paste_row_after_desc",icon:"paste",cmd:"mceTablePasteRowAfter"}).setDisabled(!m);D=w.addMenu({title:"table.col"});D.add({title:"table.col_before_desc",icon:"col_before",cmd:"mceTableInsertColBefore"});D.add({title:"table.col_after_desc",icon:"col_after",cmd:"mceTableInsertColAfter"});D.add({title:"table.delete_col_desc",icon:"delete_col",cmd:"mceTableDeleteCol"})}else{w.add({title:"table.desc",icon:"table",cmd:"mceInsertTable"})}})}if(d.isWebKit){function v(C,N){var L=d.VK;var Q=N.keyCode;function O(Y,U,S){var T=Y?"previousSibling":"nextSibling";var Z=C.dom.getParent(U,"tr");var X=Z[T];if(X){z(C,U,X,Y);d.dom.Event.cancel(S);return true}else{var aa=C.dom.getParent(Z,"table");var W=Z.parentNode;var R=W.nodeName.toLowerCase();if(R==="tbody"||R===(Y?"tfoot":"thead")){var V=w(Y,aa,W,"tbody");if(V!==null){return K(Y,V,U,S)}}return M(Y,Z,T,aa,S)}}function w(V,T,U,X){var S=C.dom.select(">"+X,T);var R=S.indexOf(U);if(V&&R===0||!V&&R===S.length-1){return B(V,T)}else{if(R===-1){var W=U.tagName.toLowerCase()==="thead"?0:S.length-1;return S[W]}else{return S[R+(V?-1:1)]}}}function B(U,T){var S=U?"thead":"tfoot";var R=C.dom.select(">"+S,T);return R.length!==0?R[0]:null}function K(V,T,S,U){var R=J(T,V);R&&z(C,S,R,V);d.dom.Event.cancel(U);return true}function M(Y,U,R,X,W){var S=X[R];if(S){F(S);return true}else{var V=C.dom.getParent(X,"td,th");if(V){return O(Y,V,W)}else{var T=J(U,!Y);F(T);return d.dom.Event.cancel(W)}}}function J(S,R){var T=S&&S[R?"lastChild":"firstChild"];return T&&T.nodeName==="BR"?C.dom.getParent(T,"td,th"):T}function F(R){C.selection.setCursorLocation(R,0)}function A(){return Q==L.UP||Q==L.DOWN}function D(R){var T=R.selection.getNode();var S=R.dom.getParent(T,"tr");return S!==null}function P(S){var R=0;var T=S;while(T.previousSibling){T=T.previousSibling;R=R+a(T,"colspan")}return R}function E(T,R){var U=0;var S=0;e(T.children,function(V,W){U=U+a(V,"colspan");S=W;if(U>R){return false}});return S}function z(T,W,Y,V){var X=P(T.dom.getParent(W,"td,th"));var S=E(Y,X);var R=Y.childNodes[S];var U=J(R,V);F(U||R)}function H(R){var T=C.selection.getNode();var U=C.dom.getParent(T,"td,th");var S=C.dom.getParent(R,"td,th");return U&&U!==S&&I(U,S)}function I(S,R){return C.dom.getParent(S,"TABLE")===C.dom.getParent(R,"TABLE")}if(A()&&D(C)){var G=C.selection.getNode();setTimeout(function(){if(H(G)){O(!N.shiftKey&&Q===L.UP,G,N)}},0)}}r.onKeyDown.add(v)}function s(){var w;for(w=r.getBody().lastChild;w&&w.nodeType==3&&!w.nodeValue.length;w=w.previousSibling){}if(w&&w.nodeName=="TABLE"){if(r.settings.forced_root_block){r.dom.add(r.getBody(),r.settings.forced_root_block,null,d.isIE&&!d.isIE11?" ":'<br data-mce-bogus="1" />')}else{r.dom.add(r.getBody(),"br",{"data-mce-bogus":"1"})}}}if(d.isGecko){r.onKeyDown.add(function(z,B){var w,A,C=z.dom;if(B.keyCode==37||B.keyCode==38){w=z.selection.getRng();A=C.getParent(w.startContainer,"table");if(A&&z.getBody().firstChild==A){if(c(w,A)){w=C.createRng();w.setStartBefore(A);w.setEndBefore(A);z.selection.setRng(w);B.preventDefault()}}}})}r.onKeyUp.add(s);r.onSetContent.add(s);r.onVisualAid.add(s);r.onPreProcess.add(function(w,A){var z=A.node.lastChild;if(z&&(z.nodeName=="BR"||(z.childNodes.length==1&&(z.firstChild.nodeName=="BR"||z.firstChild.nodeValue=="\u00a0")))&&z.previousSibling&&z.previousSibling.nodeName=="TABLE"){w.dom.remove(z)}});s();r.startContent=r.getContent({format:"raw"})});e({mceTableSplitCells:function(n){n.split()},mceTableMergeCells:function(o){var p,q,n;n=g.dom.getParent(g.selection.getNode(),"th,td");if(n){p=n.rowSpan;q=n.colSpan}if(!g.dom.select("td.mceSelected,th.mceSelected").length){f.open({url:h+"/merge_cells.htm",width:240+parseInt(g.getLang("table.merge_cells_delta_width",0)),height:110+parseInt(g.getLang("table.merge_cells_delta_height",0)),inline:1},{rows:p,cols:q,onaction:function(r){o.merge(n,r.cols,r.rows)},plugin_url:h})}else{o.merge()}},mceTableInsertRowBefore:function(n){n.insertRow(true)},mceTableInsertRowAfter:function(n){n.insertRow()},mceTableInsertColBefore:function(n){n.insertCol(true)},mceTableInsertColAfter:function(n){n.insertCol()},mceTableDeleteCol:function(n){n.deleteCols()},mceTableDeleteRow:function(n){n.deleteRows()},mceTableCutRow:function(n){m=n.cutRows()},mceTableCopyRow:function(n){m=n.copyRows()},mceTablePasteRowBefore:function(n){n.pasteRows(m,true)},mceTablePasteRowAfter:function(n){n.pasteRows(m)},mceTableDelete:function(n){n.deleteTable()}},function(o,n){g.addCommand(n,function(){var p=l();if(p){o(p);g.execCommand("mceRepaint");k()}})});e({mceInsertTable:function(n){f.open({url:h+"/table.htm",width:400+parseInt(g.getLang("table.table_delta_width",0)),height:320+parseInt(g.getLang("table.table_delta_height",0)),inline:1},{plugin_url:h,action:n?n.action:0})},mceTableRowProps:function(){f.open({url:h+"/row.htm",width:400+parseInt(g.getLang("table.rowprops_delta_width",0)),height:295+parseInt(g.getLang("table.rowprops_delta_height",0)),inline:1},{plugin_url:h})},mceTableCellProps:function(){f.open({url:h+"/cell.htm",width:400+parseInt(g.getLang("table.cellprops_delta_width",0)),height:295+parseInt(g.getLang("table.cellprops_delta_height",0)),inline:1},{plugin_url:h})}},function(o,n){g.addCommand(n,function(p,q){o(q)})})}});d.PluginManager.add("table",d.plugins.TablePlugin)})(tinymce);
|
mce/table/js/cell.js
CHANGED
@@ -1,319 +1,319 @@
|
|
1 |
-
tinyMCEPopup.requireLangPack();
|
2 |
-
|
3 |
-
var ed;
|
4 |
-
|
5 |
-
function init() {
|
6 |
-
ed = tinyMCEPopup.editor;
|
7 |
-
tinyMCEPopup.resizeToInnerSize();
|
8 |
-
|
9 |
-
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
|
10 |
-
document.getElementById('bordercolor_pickcontainer').innerHTML = getColorPickerHTML('bordercolor_pick','bordercolor');
|
11 |
-
document.getElementById('bgcolor_pickcontainer').innerHTML = getColorPickerHTML('bgcolor_pick','bgcolor')
|
12 |
-
|
13 |
-
var inst = ed;
|
14 |
-
var tdElm = ed.dom.getParent(ed.selection.getStart(), "td,th");
|
15 |
-
var formObj = document.forms[0];
|
16 |
-
var st = ed.dom.parseStyle(ed.dom.getAttrib(tdElm, "style"));
|
17 |
-
|
18 |
-
// Get table cell data
|
19 |
-
var celltype = tdElm.nodeName.toLowerCase();
|
20 |
-
var align = ed.dom.getAttrib(tdElm, 'align');
|
21 |
-
var valign = ed.dom.getAttrib(tdElm, 'valign');
|
22 |
-
var width = trimSize(getStyle(tdElm, 'width', 'width'));
|
23 |
-
var height = trimSize(getStyle(tdElm, 'height', 'height'));
|
24 |
-
var bordercolor = convertRGBToHex(getStyle(tdElm, 'bordercolor', 'borderLeftColor'));
|
25 |
-
var bgcolor = convertRGBToHex(getStyle(tdElm, 'bgcolor', 'backgroundColor'));
|
26 |
-
var className = ed.dom.getAttrib(tdElm, 'class');
|
27 |
-
var backgroundimage = getStyle(tdElm, 'background', 'backgroundImage').replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
|
28 |
-
var id = ed.dom.getAttrib(tdElm, 'id');
|
29 |
-
var lang = ed.dom.getAttrib(tdElm, 'lang');
|
30 |
-
var dir = ed.dom.getAttrib(tdElm, 'dir');
|
31 |
-
var scope = ed.dom.getAttrib(tdElm, 'scope');
|
32 |
-
|
33 |
-
// Setup form
|
34 |
-
addClassesToList('class', 'table_cell_styles');
|
35 |
-
TinyMCE_EditableSelects.init();
|
36 |
-
|
37 |
-
if (!ed.dom.hasClass(tdElm, 'mceSelected')) {
|
38 |
-
formObj.bordercolor.value = bordercolor;
|
39 |
-
formObj.bgcolor.value = bgcolor;
|
40 |
-
formObj.backgroundimage.value = backgroundimage;
|
41 |
-
formObj.width.value = width;
|
42 |
-
formObj.height.value = height;
|
43 |
-
formObj.id.value = id;
|
44 |
-
formObj.lang.value = lang;
|
45 |
-
formObj.style.value = ed.dom.serializeStyle(st);
|
46 |
-
selectByValue(formObj, 'align', align);
|
47 |
-
selectByValue(formObj, 'valign', valign);
|
48 |
-
selectByValue(formObj, 'class', className, true, true);
|
49 |
-
selectByValue(formObj, 'celltype', celltype);
|
50 |
-
selectByValue(formObj, 'dir', dir);
|
51 |
-
selectByValue(formObj, 'scope', scope);
|
52 |
-
|
53 |
-
// Resize some elements
|
54 |
-
if (isVisible('backgroundimagebrowser'))
|
55 |
-
document.getElementById('backgroundimage').style.width = '180px';
|
56 |
-
|
57 |
-
updateColor('bordercolor_pick', 'bordercolor');
|
58 |
-
updateColor('bgcolor_pick', 'bgcolor');
|
59 |
-
} else
|
60 |
-
tinyMCEPopup.dom.hide('action');
|
61 |
-
}
|
62 |
-
|
63 |
-
function updateAction() {
|
64 |
-
var el, inst = ed, tdElm, trElm, tableElm, formObj = document.forms[0];
|
65 |
-
|
66 |
-
if (!AutoValidator.validate(formObj)) {
|
67 |
-
tinyMCEPopup.alert(AutoValidator.getErrorMessages(formObj).join('. ') + '.');
|
68 |
-
return false;
|
69 |
-
}
|
70 |
-
|
71 |
-
tinyMCEPopup.restoreSelection();
|
72 |
-
el = ed.selection.getStart();
|
73 |
-
tdElm = ed.dom.getParent(el, "td,th");
|
74 |
-
trElm = ed.dom.getParent(el, "tr");
|
75 |
-
tableElm = ed.dom.getParent(el, "table");
|
76 |
-
|
77 |
-
// Cell is selected
|
78 |
-
if (ed.dom.hasClass(tdElm, 'mceSelected')) {
|
79 |
-
// Update all selected sells
|
80 |
-
tinymce.each(ed.dom.select('td.mceSelected,th.mceSelected'), function(td) {
|
81 |
-
updateCell(td);
|
82 |
-
});
|
83 |
-
|
84 |
-
ed.addVisual();
|
85 |
-
ed.nodeChanged();
|
86 |
-
inst.execCommand('mceEndUndoLevel');
|
87 |
-
tinyMCEPopup.close();
|
88 |
-
return;
|
89 |
-
}
|
90 |
-
|
91 |
-
switch (getSelectValue(formObj, 'action')) {
|
92 |
-
case "cell":
|
93 |
-
var celltype = getSelectValue(formObj, 'celltype');
|
94 |
-
var scope = getSelectValue(formObj, 'scope');
|
95 |
-
|
96 |
-
function doUpdate(s) {
|
97 |
-
if (s) {
|
98 |
-
updateCell(tdElm);
|
99 |
-
|
100 |
-
ed.addVisual();
|
101 |
-
ed.nodeChanged();
|
102 |
-
inst.execCommand('mceEndUndoLevel');
|
103 |
-
tinyMCEPopup.close();
|
104 |
-
}
|
105 |
-
};
|
106 |
-
|
107 |
-
if (ed.getParam("accessibility_warnings", 1)) {
|
108 |
-
if (celltype == "th" && scope == "")
|
109 |
-
tinyMCEPopup.confirm(ed.getLang('table_dlg.missing_scope', '', true), doUpdate);
|
110 |
-
else
|
111 |
-
doUpdate(1);
|
112 |
-
|
113 |
-
return;
|
114 |
-
}
|
115 |
-
|
116 |
-
updateCell(tdElm);
|
117 |
-
break;
|
118 |
-
|
119 |
-
case "row":
|
120 |
-
var cell = trElm.firstChild;
|
121 |
-
|
122 |
-
if (cell.nodeName != "TD" && cell.nodeName != "TH")
|
123 |
-
cell = nextCell(cell);
|
124 |
-
|
125 |
-
do {
|
126 |
-
cell = updateCell(cell, true);
|
127 |
-
} while ((cell = nextCell(cell)) != null);
|
128 |
-
|
129 |
-
break;
|
130 |
-
|
131 |
-
case "col":
|
132 |
-
var curr, col = 0, cell = trElm.firstChild, rows = tableElm.getElementsByTagName("tr");
|
133 |
-
|
134 |
-
if (cell.nodeName != "TD" && cell.nodeName != "TH")
|
135 |
-
cell = nextCell(cell);
|
136 |
-
|
137 |
-
do {
|
138 |
-
if (cell == tdElm)
|
139 |
-
break;
|
140 |
-
col += cell.getAttribute("colspan")?cell.getAttribute("colspan"):1;
|
141 |
-
} while ((cell = nextCell(cell)) != null);
|
142 |
-
|
143 |
-
for (var i=0; i<rows.length; i++) {
|
144 |
-
cell = rows[i].firstChild;
|
145 |
-
|
146 |
-
if (cell.nodeName != "TD" && cell.nodeName != "TH")
|
147 |
-
cell = nextCell(cell);
|
148 |
-
|
149 |
-
curr = 0;
|
150 |
-
do {
|
151 |
-
if (curr == col) {
|
152 |
-
cell = updateCell(cell, true);
|
153 |
-
break;
|
154 |
-
}
|
155 |
-
curr += cell.getAttribute("colspan")?cell.getAttribute("colspan"):1;
|
156 |
-
} while ((cell = nextCell(cell)) != null);
|
157 |
-
}
|
158 |
-
|
159 |
-
break;
|
160 |
-
|
161 |
-
case "all":
|
162 |
-
var rows = tableElm.getElementsByTagName("tr");
|
163 |
-
|
164 |
-
for (var i=0; i<rows.length; i++) {
|
165 |
-
var cell = rows[i].firstChild;
|
166 |
-
|
167 |
-
if (cell.nodeName != "TD" && cell.nodeName != "TH")
|
168 |
-
cell = nextCell(cell);
|
169 |
-
|
170 |
-
do {
|
171 |
-
cell = updateCell(cell, true);
|
172 |
-
} while ((cell = nextCell(cell)) != null);
|
173 |
-
}
|
174 |
-
|
175 |
-
break;
|
176 |
-
}
|
177 |
-
|
178 |
-
ed.addVisual();
|
179 |
-
ed.nodeChanged();
|
180 |
-
inst.execCommand('mceEndUndoLevel');
|
181 |
-
tinyMCEPopup.close();
|
182 |
-
}
|
183 |
-
|
184 |
-
function nextCell(elm) {
|
185 |
-
while ((elm = elm.nextSibling) != null) {
|
186 |
-
if (elm.nodeName == "TD" || elm.nodeName == "TH")
|
187 |
-
return elm;
|
188 |
-
}
|
189 |
-
|
190 |
-
return null;
|
191 |
-
}
|
192 |
-
|
193 |
-
function updateCell(td, skip_id) {
|
194 |
-
var inst = ed;
|
195 |
-
var formObj = document.forms[0];
|
196 |
-
var curCellType = td.nodeName.toLowerCase();
|
197 |
-
var celltype = getSelectValue(formObj, 'celltype');
|
198 |
-
var doc = inst.getDoc();
|
199 |
-
var dom = ed.dom;
|
200 |
-
|
201 |
-
if (!skip_id)
|
202 |
-
dom.setAttrib(td, 'id', formObj.id.value);
|
203 |
-
|
204 |
-
dom.setAttrib(td, 'align', formObj.align.value);
|
205 |
-
dom.setAttrib(td, 'vAlign', formObj.valign.value);
|
206 |
-
dom.setAttrib(td, 'lang', formObj.lang.value);
|
207 |
-
dom.setAttrib(td, 'dir', getSelectValue(formObj, 'dir'));
|
208 |
-
dom.setAttrib(td, 'style', ed.dom.serializeStyle(ed.dom.parseStyle(formObj.style.value)));
|
209 |
-
dom.setAttrib(td, 'scope', formObj.scope.value);
|
210 |
-
dom.setAttrib(td, 'class', getSelectValue(formObj, 'class'));
|
211 |
-
|
212 |
-
// Clear deprecated attributes
|
213 |
-
ed.dom.setAttrib(td, 'width', '');
|
214 |
-
ed.dom.setAttrib(td, 'height', '');
|
215 |
-
ed.dom.setAttrib(td, 'bgColor', '');
|
216 |
-
ed.dom.setAttrib(td, 'borderColor', '');
|
217 |
-
ed.dom.setAttrib(td, 'background', '');
|
218 |
-
|
219 |
-
// Set styles
|
220 |
-
td.style.width = getCSSSize(formObj.width.value);
|
221 |
-
td.style.height = getCSSSize(formObj.height.value);
|
222 |
-
if (formObj.bordercolor.value != "") {
|
223 |
-
td.style.borderColor = formObj.bordercolor.value;
|
224 |
-
td.style.borderStyle = td.style.borderStyle == "" ? "solid" : td.style.borderStyle;
|
225 |
-
td.style.borderWidth = td.style.borderWidth == "" ? "1px" : td.style.borderWidth;
|
226 |
-
} else
|
227 |
-
td.style.borderColor = '';
|
228 |
-
|
229 |
-
td.style.backgroundColor = formObj.bgcolor.value;
|
230 |
-
|
231 |
-
if (formObj.backgroundimage.value != "")
|
232 |
-
td.style.backgroundImage = "url('" + formObj.backgroundimage.value + "')";
|
233 |
-
else
|
234 |
-
td.style.backgroundImage = '';
|
235 |
-
|
236 |
-
if (curCellType != celltype) {
|
237 |
-
// changing to a different node type
|
238 |
-
var newCell = doc.createElement(celltype);
|
239 |
-
|
240 |
-
for (var c=0; c<td.childNodes.length; c++)
|
241 |
-
newCell.appendChild(td.childNodes[c].cloneNode(1));
|
242 |
-
|
243 |
-
for (var a=0; a<td.attributes.length; a++)
|
244 |
-
ed.dom.setAttrib(newCell, td.attributes[a].name, ed.dom.getAttrib(td, td.attributes[a].name));
|
245 |
-
|
246 |
-
td.parentNode.replaceChild(newCell, td);
|
247 |
-
td = newCell;
|
248 |
-
}
|
249 |
-
|
250 |
-
dom.setAttrib(td, 'style', dom.serializeStyle(dom.parseStyle(td.style.cssText)));
|
251 |
-
|
252 |
-
return td;
|
253 |
-
}
|
254 |
-
|
255 |
-
function changedBackgroundImage() {
|
256 |
-
var formObj = document.forms[0];
|
257 |
-
var st = ed.dom.parseStyle(formObj.style.value);
|
258 |
-
|
259 |
-
st['background-image'] = "url('" + formObj.backgroundimage.value + "')";
|
260 |
-
|
261 |
-
formObj.style.value = ed.dom.serializeStyle(st);
|
262 |
-
}
|
263 |
-
|
264 |
-
function changedSize() {
|
265 |
-
var formObj = document.forms[0];
|
266 |
-
var st = ed.dom.parseStyle(formObj.style.value);
|
267 |
-
|
268 |
-
var width = formObj.width.value;
|
269 |
-
if (width != "")
|
270 |
-
st['width'] = getCSSSize(width);
|
271 |
-
else
|
272 |
-
st['width'] = "";
|
273 |
-
|
274 |
-
var height = formObj.height.value;
|
275 |
-
if (height != "")
|
276 |
-
st['height'] = getCSSSize(height);
|
277 |
-
else
|
278 |
-
st['height'] = "";
|
279 |
-
|
280 |
-
formObj.style.value = ed.dom.serializeStyle(st);
|
281 |
-
}
|
282 |
-
|
283 |
-
function changedColor() {
|
284 |
-
var formObj = document.forms[0];
|
285 |
-
var st = ed.dom.parseStyle(formObj.style.value);
|
286 |
-
|
287 |
-
st['background-color'] = formObj.bgcolor.value;
|
288 |
-
st['border-color'] = formObj.bordercolor.value;
|
289 |
-
|
290 |
-
formObj.style.value = ed.dom.serializeStyle(st);
|
291 |
-
}
|
292 |
-
|
293 |
-
function changedStyle() {
|
294 |
-
var formObj = document.forms[0];
|
295 |
-
var st = ed.dom.parseStyle(formObj.style.value);
|
296 |
-
|
297 |
-
if (st['background-image'])
|
298 |
-
formObj.backgroundimage.value = st['background-image'].replace(new RegExp("url\\('?([^']*)'?\\)", 'gi'), "$1");
|
299 |
-
else
|
300 |
-
formObj.backgroundimage.value = '';
|
301 |
-
|
302 |
-
if (st['width'])
|
303 |
-
formObj.width.value = trimSize(st['width']);
|
304 |
-
|
305 |
-
if (st['height'])
|
306 |
-
formObj.height.value = trimSize(st['height']);
|
307 |
-
|
308 |
-
if (st['background-color']) {
|
309 |
-
formObj.bgcolor.value = st['background-color'];
|
310 |
-
updateColor('bgcolor_pick','bgcolor');
|
311 |
-
}
|
312 |
-
|
313 |
-
if (st['border-color']) {
|
314 |
-
formObj.bordercolor.value = st['border-color'];
|
315 |
-
updateColor('bordercolor_pick','bordercolor');
|
316 |
-
}
|
317 |
-
}
|
318 |
-
|
319 |
-
tinyMCEPopup.onInit.add(init);
|
1 |
+
tinyMCEPopup.requireLangPack();
|
2 |
+
|
3 |
+
var ed;
|
4 |
+
|
5 |
+
function init() {
|
6 |
+
ed = tinyMCEPopup.editor;
|
7 |
+
tinyMCEPopup.resizeToInnerSize();
|
8 |
+
|
9 |
+
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
|
10 |
+
document.getElementById('bordercolor_pickcontainer').innerHTML = getColorPickerHTML('bordercolor_pick','bordercolor');
|
11 |
+
document.getElementById('bgcolor_pickcontainer').innerHTML = getColorPickerHTML('bgcolor_pick','bgcolor')
|
12 |
+
|
13 |
+
var inst = ed;
|
14 |
+
var tdElm = ed.dom.getParent(ed.selection.getStart(), "td,th");
|
15 |
+
var formObj = document.forms[0];
|
16 |
+
var st = ed.dom.parseStyle(ed.dom.getAttrib(tdElm, "style"));
|
17 |
+
|
18 |
+
// Get table cell data
|
19 |
+
var celltype = tdElm.nodeName.toLowerCase();
|
20 |
+
var align = ed.dom.getAttrib(tdElm, 'align');
|
21 |
+
var valign = ed.dom.getAttrib(tdElm, 'valign');
|
22 |
+
var width = trimSize(getStyle(tdElm, 'width', 'width'));
|
23 |
+
var height = trimSize(getStyle(tdElm, 'height', 'height'));
|
24 |
+
var bordercolor = convertRGBToHex(getStyle(tdElm, 'bordercolor', 'borderLeftColor'));
|
25 |
+
var bgcolor = convertRGBToHex(getStyle(tdElm, 'bgcolor', 'backgroundColor'));
|
26 |
+
var className = ed.dom.getAttrib(tdElm, 'class');
|
27 |
+
var backgroundimage = getStyle(tdElm, 'background', 'backgroundImage').replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
|
28 |
+
var id = ed.dom.getAttrib(tdElm, 'id');
|
29 |
+
var lang = ed.dom.getAttrib(tdElm, 'lang');
|
30 |
+
var dir = ed.dom.getAttrib(tdElm, 'dir');
|
31 |
+
var scope = ed.dom.getAttrib(tdElm, 'scope');
|
32 |
+
|
33 |
+
// Setup form
|
34 |
+
addClassesToList('class', 'table_cell_styles');
|
35 |
+
TinyMCE_EditableSelects.init();
|
36 |
+
|
37 |
+
if (!ed.dom.hasClass(tdElm, 'mceSelected')) {
|
38 |
+
formObj.bordercolor.value = bordercolor;
|
39 |
+
formObj.bgcolor.value = bgcolor;
|
40 |
+
formObj.backgroundimage.value = backgroundimage;
|
41 |
+
formObj.width.value = width;
|
42 |
+
formObj.height.value = height;
|
43 |
+
formObj.id.value = id;
|
44 |
+
formObj.lang.value = lang;
|
45 |
+
formObj.style.value = ed.dom.serializeStyle(st);
|
46 |
+
selectByValue(formObj, 'align', align);
|
47 |
+
selectByValue(formObj, 'valign', valign);
|
48 |
+
selectByValue(formObj, 'class', className, true, true);
|
49 |
+
selectByValue(formObj, 'celltype', celltype);
|
50 |
+
selectByValue(formObj, 'dir', dir);
|
51 |
+
selectByValue(formObj, 'scope', scope);
|
52 |
+
|
53 |
+
// Resize some elements
|
54 |
+
if (isVisible('backgroundimagebrowser'))
|
55 |
+
document.getElementById('backgroundimage').style.width = '180px';
|
56 |
+
|
57 |
+
updateColor('bordercolor_pick', 'bordercolor');
|
58 |
+
updateColor('bgcolor_pick', 'bgcolor');
|
59 |
+
} else
|
60 |
+
tinyMCEPopup.dom.hide('action');
|
61 |
+
}
|
62 |
+
|
63 |
+
function updateAction() {
|
64 |
+
var el, inst = ed, tdElm, trElm, tableElm, formObj = document.forms[0];
|
65 |
+
|
66 |
+
if (!AutoValidator.validate(formObj)) {
|
67 |
+
tinyMCEPopup.alert(AutoValidator.getErrorMessages(formObj).join('. ') + '.');
|
68 |
+
return false;
|
69 |
+
}
|
70 |
+
|
71 |
+
tinyMCEPopup.restoreSelection();
|
72 |
+
el = ed.selection.getStart();
|
73 |
+
tdElm = ed.dom.getParent(el, "td,th");
|
74 |
+
trElm = ed.dom.getParent(el, "tr");
|
75 |
+
tableElm = ed.dom.getParent(el, "table");
|
76 |
+
|
77 |
+
// Cell is selected
|
78 |
+
if (ed.dom.hasClass(tdElm, 'mceSelected')) {
|
79 |
+
// Update all selected sells
|
80 |
+
tinymce.each(ed.dom.select('td.mceSelected,th.mceSelected'), function(td) {
|
81 |
+
updateCell(td);
|
82 |
+
});
|
83 |
+
|
84 |
+
ed.addVisual();
|
85 |
+
ed.nodeChanged();
|
86 |
+
inst.execCommand('mceEndUndoLevel');
|
87 |
+
tinyMCEPopup.close();
|
88 |
+
return;
|
89 |
+
}
|
90 |
+
|
91 |
+
switch (getSelectValue(formObj, 'action')) {
|
92 |
+
case "cell":
|
93 |
+
var celltype = getSelectValue(formObj, 'celltype');
|
94 |
+
var scope = getSelectValue(formObj, 'scope');
|
95 |
+
|
96 |
+
function doUpdate(s) {
|
97 |
+
if (s) {
|
98 |
+
updateCell(tdElm);
|
99 |
+
|
100 |
+
ed.addVisual();
|
101 |
+
ed.nodeChanged();
|
102 |
+
inst.execCommand('mceEndUndoLevel');
|
103 |
+
tinyMCEPopup.close();
|
104 |
+
}
|
105 |
+
};
|
106 |
+
|
107 |
+
if (ed.getParam("accessibility_warnings", 1)) {
|
108 |
+
if (celltype == "th" && scope == "")
|
109 |
+
tinyMCEPopup.confirm(ed.getLang('table_dlg.missing_scope', '', true), doUpdate);
|
110 |
+
else
|
111 |
+
doUpdate(1);
|
112 |
+
|
113 |
+
return;
|
114 |
+
}
|
115 |
+
|
116 |
+
updateCell(tdElm);
|
117 |
+
break;
|
118 |
+
|
119 |
+
case "row":
|
120 |
+
var cell = trElm.firstChild;
|
121 |
+
|
122 |
+
if (cell.nodeName != "TD" && cell.nodeName != "TH")
|
123 |
+
cell = nextCell(cell);
|
124 |
+
|
125 |
+
do {
|
126 |
+
cell = updateCell(cell, true);
|
127 |
+
} while ((cell = nextCell(cell)) != null);
|
128 |
+
|
129 |
+
break;
|
130 |
+
|
131 |
+
case "col":
|
132 |
+
var curr, col = 0, cell = trElm.firstChild, rows = tableElm.getElementsByTagName("tr");
|
133 |
+
|
134 |
+
if (cell.nodeName != "TD" && cell.nodeName != "TH")
|
135 |
+
cell = nextCell(cell);
|
136 |
+
|
137 |
+
do {
|
138 |
+
if (cell == tdElm)
|
139 |
+
break;
|
140 |
+
col += cell.getAttribute("colspan")?cell.getAttribute("colspan"):1;
|
141 |
+
} while ((cell = nextCell(cell)) != null);
|
142 |
+
|
143 |
+
for (var i=0; i<rows.length; i++) {
|
144 |
+
cell = rows[i].firstChild;
|
145 |
+
|
146 |
+
if (cell.nodeName != "TD" && cell.nodeName != "TH")
|
147 |
+
cell = nextCell(cell);
|
148 |
+
|
149 |
+
curr = 0;
|
150 |
+
do {
|
151 |
+
if (curr == col) {
|
152 |
+
cell = updateCell(cell, true);
|
153 |
+
break;
|
154 |
+
}
|
155 |
+
curr += cell.getAttribute("colspan")?cell.getAttribute("colspan"):1;
|
156 |
+
} while ((cell = nextCell(cell)) != null);
|
157 |
+
}
|
158 |
+
|
159 |
+
break;
|
160 |
+
|
161 |
+
case "all":
|
162 |
+
var rows = tableElm.getElementsByTagName("tr");
|
163 |
+
|
164 |
+
for (var i=0; i<rows.length; i++) {
|
165 |
+
var cell = rows[i].firstChild;
|
166 |
+
|
167 |
+
if (cell.nodeName != "TD" && cell.nodeName != "TH")
|
168 |
+
cell = nextCell(cell);
|
169 |
+
|
170 |
+
do {
|
171 |
+
cell = updateCell(cell, true);
|
172 |
+
} while ((cell = nextCell(cell)) != null);
|
173 |
+
}
|
174 |
+
|
175 |
+
break;
|
176 |
+
}
|
177 |
+
|
178 |
+
ed.addVisual();
|
179 |
+
ed.nodeChanged();
|
180 |
+
inst.execCommand('mceEndUndoLevel');
|
181 |
+
tinyMCEPopup.close();
|
182 |
+
}
|
183 |
+
|
184 |
+
function nextCell(elm) {
|
185 |
+
while ((elm = elm.nextSibling) != null) {
|
186 |
+
if (elm.nodeName == "TD" || elm.nodeName == "TH")
|
187 |
+
return elm;
|
188 |
+
}
|
189 |
+
|
190 |
+
return null;
|
191 |
+
}
|
192 |
+
|
193 |
+
function updateCell(td, skip_id) {
|
194 |
+
var inst = ed;
|
195 |
+
var formObj = document.forms[0];
|
196 |
+
var curCellType = td.nodeName.toLowerCase();
|
197 |
+
var celltype = getSelectValue(formObj, 'celltype');
|
198 |
+
var doc = inst.getDoc();
|
199 |
+
var dom = ed.dom;
|
200 |
+
|
201 |
+
if (!skip_id)
|
202 |
+
dom.setAttrib(td, 'id', formObj.id.value);
|
203 |
+
|
204 |
+
dom.setAttrib(td, 'align', formObj.align.value);
|
205 |
+
dom.setAttrib(td, 'vAlign', formObj.valign.value);
|
206 |
+
dom.setAttrib(td, 'lang', formObj.lang.value);
|
207 |
+
dom.setAttrib(td, 'dir', getSelectValue(formObj, 'dir'));
|
208 |
+
dom.setAttrib(td, 'style', ed.dom.serializeStyle(ed.dom.parseStyle(formObj.style.value)));
|
209 |
+
dom.setAttrib(td, 'scope', formObj.scope.value);
|
210 |
+
dom.setAttrib(td, 'class', getSelectValue(formObj, 'class'));
|
211 |
+
|
212 |
+
// Clear deprecated attributes
|
213 |
+
ed.dom.setAttrib(td, 'width', '');
|
214 |
+
ed.dom.setAttrib(td, 'height', '');
|
215 |
+
ed.dom.setAttrib(td, 'bgColor', '');
|
216 |
+
ed.dom.setAttrib(td, 'borderColor', '');
|
217 |
+
ed.dom.setAttrib(td, 'background', '');
|
218 |
+
|
219 |
+
// Set styles
|
220 |
+
td.style.width = getCSSSize(formObj.width.value);
|
221 |
+
td.style.height = getCSSSize(formObj.height.value);
|
222 |
+
if (formObj.bordercolor.value != "") {
|
223 |
+
td.style.borderColor = formObj.bordercolor.value;
|
224 |
+
td.style.borderStyle = td.style.borderStyle == "" ? "solid" : td.style.borderStyle;
|
225 |
+
td.style.borderWidth = td.style.borderWidth == "" ? "1px" : td.style.borderWidth;
|
226 |
+
} else
|
227 |
+
td.style.borderColor = '';
|
228 |
+
|
229 |
+
td.style.backgroundColor = formObj.bgcolor.value;
|
230 |
+
|
231 |
+
if (formObj.backgroundimage.value != "")
|
232 |
+
td.style.backgroundImage = "url('" + formObj.backgroundimage.value + "')";
|
233 |
+
else
|
234 |
+
td.style.backgroundImage = '';
|
235 |
+
|
236 |
+
if (curCellType != celltype) {
|
237 |
+
// changing to a different node type
|
238 |
+
var newCell = doc.createElement(celltype);
|
239 |
+
|
240 |
+
for (var c=0; c<td.childNodes.length; c++)
|
241 |
+
newCell.appendChild(td.childNodes[c].cloneNode(1));
|
242 |
+
|
243 |
+
for (var a=0; a<td.attributes.length; a++)
|
244 |
+
ed.dom.setAttrib(newCell, td.attributes[a].name, ed.dom.getAttrib(td, td.attributes[a].name));
|
245 |
+
|
246 |
+
td.parentNode.replaceChild(newCell, td);
|
247 |
+
td = newCell;
|
248 |
+
}
|
249 |
+
|
250 |
+
dom.setAttrib(td, 'style', dom.serializeStyle(dom.parseStyle(td.style.cssText)));
|
251 |
+
|
252 |
+
return td;
|
253 |
+
}
|
254 |
+
|
255 |
+
function changedBackgroundImage() {
|
256 |
+
var formObj = document.forms[0];
|
257 |
+
var st = ed.dom.parseStyle(formObj.style.value);
|
258 |
+
|
259 |
+
st['background-image'] = "url('" + formObj.backgroundimage.value + "')";
|
260 |
+
|
261 |
+
formObj.style.value = ed.dom.serializeStyle(st);
|
262 |
+
}
|
263 |
+
|
264 |
+
function changedSize() {
|
265 |
+
var formObj = document.forms[0];
|
266 |
+
var st = ed.dom.parseStyle(formObj.style.value);
|
267 |
+
|
268 |
+
var width = formObj.width.value;
|
269 |
+
if (width != "")
|
270 |
+
st['width'] = getCSSSize(width);
|
271 |
+
else
|
272 |
+
st['width'] = "";
|
273 |
+
|
274 |
+
var height = formObj.height.value;
|
275 |
+
if (height != "")
|
276 |
+
st['height'] = getCSSSize(height);
|
277 |
+
else
|
278 |
+
st['height'] = "";
|
279 |
+
|
280 |
+
formObj.style.value = ed.dom.serializeStyle(st);
|
281 |
+
}
|
282 |
+
|
283 |
+
function changedColor() {
|
284 |
+
var formObj = document.forms[0];
|
285 |
+
var st = ed.dom.parseStyle(formObj.style.value);
|
286 |
+
|
287 |
+
st['background-color'] = formObj.bgcolor.value;
|
288 |
+
st['border-color'] = formObj.bordercolor.value;
|
289 |
+
|
290 |
+
formObj.style.value = ed.dom.serializeStyle(st);
|
291 |
+
}
|
292 |
+
|
293 |
+
function changedStyle() {
|
294 |
+
var formObj = document.forms[0];
|
295 |
+
var st = ed.dom.parseStyle(formObj.style.value);
|
296 |
+
|
297 |
+
if (st['background-image'])
|
298 |
+
formObj.backgroundimage.value = st['background-image'].replace(new RegExp("url\\('?([^']*)'?\\)", 'gi'), "$1");
|
299 |
+
else
|
300 |
+
formObj.backgroundimage.value = '';
|
301 |
+
|
302 |
+
if (st['width'])
|
303 |
+
formObj.width.value = trimSize(st['width']);
|
304 |
+
|
305 |
+
if (st['height'])
|
306 |
+
formObj.height.value = trimSize(st['height']);
|
307 |
+
|
308 |
+
if (st['background-color']) {
|
309 |
+
formObj.bgcolor.value = st['background-color'];
|
310 |
+
updateColor('bgcolor_pick','bgcolor');
|
311 |
+
}
|
312 |
+
|
313 |
+
if (st['border-color']) {
|
314 |
+
formObj.bordercolor.value = st['border-color'];
|
315 |
+
updateColor('bordercolor_pick','bordercolor');
|
316 |
+
}
|
317 |
+
}
|
318 |
+
|
319 |
+
tinyMCEPopup.onInit.add(init);
|
mce/table/js/merge_cells.js
CHANGED
@@ -1,27 +1,27 @@
|
|
1 |
-
tinyMCEPopup.requireLangPack();
|
2 |
-
|
3 |
-
var MergeCellsDialog = {
|
4 |
-
init : function() {
|
5 |
-
var f = document.forms[0];
|
6 |
-
|
7 |
-
f.numcols.value = tinyMCEPopup.getWindowArg('cols', 1);
|
8 |
-
f.numrows.value = tinyMCEPopup.getWindowArg('rows', 1);
|
9 |
-
},
|
10 |
-
|
11 |
-
merge : function() {
|
12 |
-
var func, f = document.forms[0];
|
13 |
-
|
14 |
-
tinyMCEPopup.restoreSelection();
|
15 |
-
|
16 |
-
func = tinyMCEPopup.getWindowArg('onaction');
|
17 |
-
|
18 |
-
func({
|
19 |
-
cols : f.numcols.value,
|
20 |
-
rows : f.numrows.value
|
21 |
-
});
|
22 |
-
|
23 |
-
tinyMCEPopup.close();
|
24 |
-
}
|
25 |
-
};
|
26 |
-
|
27 |
-
tinyMCEPopup.onInit.add(MergeCellsDialog.init, MergeCellsDialog);
|
1 |
+
tinyMCEPopup.requireLangPack();
|
2 |
+
|
3 |
+
var MergeCellsDialog = {
|
4 |
+
init : function() {
|
5 |
+
var f = document.forms[0];
|
6 |
+
|
7 |
+
f.numcols.value = tinyMCEPopup.getWindowArg('cols', 1);
|
8 |
+
f.numrows.value = tinyMCEPopup.getWindowArg('rows', 1);
|
9 |
+
},
|
10 |
+
|
11 |
+
merge : function() {
|
12 |
+
var func, f = document.forms[0];
|
13 |
+
|
14 |
+
tinyMCEPopup.restoreSelection();
|
15 |
+
|
16 |
+
func = tinyMCEPopup.getWindowArg('onaction');
|
17 |
+
|
18 |
+
func({
|
19 |
+
cols : f.numcols.value,
|
20 |
+
rows : f.numrows.value
|
21 |
+
});
|
22 |
+
|
23 |
+
tinyMCEPopup.close();
|
24 |
+
}
|
25 |
+
};
|
26 |
+
|
27 |
+
tinyMCEPopup.onInit.add(MergeCellsDialog.init, MergeCellsDialog);
|
mce/table/js/row.js
CHANGED
@@ -1,254 +1,254 @@
|
|
1 |
-
tinyMCEPopup.requireLangPack();
|
2 |
-
|
3 |
-
function init() {
|
4 |
-
tinyMCEPopup.resizeToInnerSize();
|
5 |
-
|
6 |
-
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
|
7 |
-
document.getElementById('bgcolor_pickcontainer').innerHTML = getColorPickerHTML('bgcolor_pick','bgcolor');
|
8 |
-
|
9 |
-
var inst = tinyMCEPopup.editor;
|
10 |
-
var dom = inst.dom;
|
11 |
-
var trElm = dom.getParent(inst.selection.getStart(), "tr");
|
12 |
-
var formObj = document.forms[0];
|
13 |
-
var st = dom.parseStyle(dom.getAttrib(trElm, "style"));
|
14 |
-
|
15 |
-
// Get table row data
|
16 |
-
var rowtype = trElm.parentNode.nodeName.toLowerCase();
|
17 |
-
var align = dom.getAttrib(trElm, 'align');
|
18 |
-
var valign = dom.getAttrib(trElm, 'valign');
|
19 |
-
var height = trimSize(getStyle(trElm, 'height', 'height'));
|
20 |
-
var className = dom.getAttrib(trElm, 'class');
|
21 |
-
var bgcolor = convertRGBToHex(getStyle(trElm, 'bgcolor', 'backgroundColor'));
|
22 |
-
var backgroundimage = getStyle(trElm, 'background', 'backgroundImage').replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
|
23 |
-
var id = dom.getAttrib(trElm, 'id');
|
24 |
-
var lang = dom.getAttrib(trElm, 'lang');
|
25 |
-
var dir = dom.getAttrib(trElm, 'dir');
|
26 |
-
|
27 |
-
selectByValue(formObj, 'rowtype', rowtype);
|
28 |
-
setActionforRowType(formObj, rowtype);
|
29 |
-
|
30 |
-
// Any cells selected
|
31 |
-
if (dom.select('td.mceSelected,th.mceSelected', trElm).length == 0) {
|
32 |
-
// Setup form
|
33 |
-
addClassesToList('class', 'table_row_styles');
|
34 |
-
TinyMCE_EditableSelects.init();
|
35 |
-
|
36 |
-
formObj.bgcolor.value = bgcolor;
|
37 |
-
formObj.backgroundimage.value = backgroundimage;
|
38 |
-
formObj.height.value = height;
|
39 |
-
formObj.id.value = id;
|
40 |
-
formObj.lang.value = lang;
|
41 |
-
formObj.style.value = dom.serializeStyle(st);
|
42 |
-
selectByValue(formObj, 'align', align);
|
43 |
-
selectByValue(formObj, 'valign', valign);
|
44 |
-
selectByValue(formObj, 'class', className, true, true);
|
45 |
-
selectByValue(formObj, 'dir', dir);
|
46 |
-
|
47 |
-
// Resize some elements
|
48 |
-
if (isVisible('backgroundimagebrowser'))
|
49 |
-
document.getElementById('backgroundimage').style.width = '180px';
|
50 |
-
|
51 |
-
updateColor('bgcolor_pick', 'bgcolor');
|
52 |
-
} else
|
53 |
-
tinyMCEPopup.dom.hide('action');
|
54 |
-
}
|
55 |
-
|
56 |
-
function updateAction() {
|
57 |
-
var inst = tinyMCEPopup.editor, dom = inst.dom, trElm, tableElm, formObj = document.forms[0];
|
58 |
-
var action = getSelectValue(formObj, 'action');
|
59 |
-
|
60 |
-
if (!AutoValidator.validate(formObj)) {
|
61 |
-
tinyMCEPopup.alert(AutoValidator.getErrorMessages(formObj).join('. ') + '.');
|
62 |
-
return false;
|
63 |
-
}
|
64 |
-
|
65 |
-
tinyMCEPopup.restoreSelection();
|
66 |
-
trElm = dom.getParent(inst.selection.getStart(), "tr");
|
67 |
-
tableElm = dom.getParent(inst.selection.getStart(), "table");
|
68 |
-
|
69 |
-
// Update all selected rows
|
70 |
-
if (dom.select('td.mceSelected,th.mceSelected', trElm).length > 0) {
|
71 |
-
tinymce.each(tableElm.rows, function(tr) {
|
72 |
-
var i;
|
73 |
-
|
74 |
-
for (i = 0; i < tr.cells.length; i++) {
|
75 |
-
if (dom.hasClass(tr.cells[i], 'mceSelected')) {
|
76 |
-
updateRow(tr, true);
|
77 |
-
return;
|
78 |
-
}
|
79 |
-
}
|
80 |
-
});
|
81 |
-
|
82 |
-
inst.addVisual();
|
83 |
-
inst.nodeChanged();
|
84 |
-
inst.execCommand('mceEndUndoLevel');
|
85 |
-
tinyMCEPopup.close();
|
86 |
-
return;
|
87 |
-
}
|
88 |
-
|
89 |
-
switch (action) {
|
90 |
-
case "row":
|
91 |
-
updateRow(trElm);
|
92 |
-
break;
|
93 |
-
|
94 |
-
case "all":
|
95 |
-
var rows = tableElm.getElementsByTagName("tr");
|
96 |
-
|
97 |
-
for (var i=0; i<rows.length; i++)
|
98 |
-
updateRow(rows[i], true);
|
99 |
-
|
100 |
-
break;
|
101 |
-
|
102 |
-
case "odd":
|
103 |
-
case "even":
|
104 |
-
var rows = tableElm.getElementsByTagName("tr");
|
105 |
-
|
106 |
-
for (var i=0; i<rows.length; i++) {
|
107 |
-
if ((i % 2 == 0 && action == "odd") || (i % 2 != 0 && action == "even"))
|
108 |
-
updateRow(rows[i], true, true);
|
109 |
-
}
|
110 |
-
|
111 |
-
break;
|
112 |
-
}
|
113 |
-
|
114 |
-
inst.addVisual();
|
115 |
-
inst.nodeChanged();
|
116 |
-
inst.execCommand('mceEndUndoLevel');
|
117 |
-
tinyMCEPopup.close();
|
118 |
-
}
|
119 |
-
|
120 |
-
function updateRow(tr_elm, skip_id, skip_parent) {
|
121 |
-
var inst = tinyMCEPopup.editor;
|
122 |
-
var formObj = document.forms[0];
|
123 |
-
var dom = inst.dom;
|
124 |
-
var curRowType = tr_elm.parentNode.nodeName.toLowerCase();
|
125 |
-
var rowtype = getSelectValue(formObj, 'rowtype');
|
126 |
-
var doc = inst.getDoc();
|
127 |
-
|
128 |
-
// Update row element
|
129 |
-
if (!skip_id)
|
130 |
-
dom.setAttrib(tr_elm, 'id', formObj.id.value);
|
131 |
-
|
132 |
-
dom.setAttrib(tr_elm, 'align', getSelectValue(formObj, 'align'));
|
133 |
-
dom.setAttrib(tr_elm, 'vAlign', getSelectValue(formObj, 'valign'));
|
134 |
-
dom.setAttrib(tr_elm, 'lang', formObj.lang.value);
|
135 |
-
dom.setAttrib(tr_elm, 'dir', getSelectValue(formObj, 'dir'));
|
136 |
-
dom.setAttrib(tr_elm, 'style', dom.serializeStyle(dom.parseStyle(formObj.style.value)));
|
137 |
-
dom.setAttrib(tr_elm, 'class', getSelectValue(formObj, 'class'));
|
138 |
-
|
139 |
-
// Clear deprecated attributes
|
140 |
-
dom.setAttrib(tr_elm, 'background', '');
|
141 |
-
dom.setAttrib(tr_elm, 'bgColor', '');
|
142 |
-
dom.setAttrib(tr_elm, 'height', '');
|
143 |
-
|
144 |
-
// Set styles
|
145 |
-
tr_elm.style.height = getCSSSize(formObj.height.value);
|
146 |
-
tr_elm.style.backgroundColor = formObj.bgcolor.value;
|
147 |
-
|
148 |
-
if (formObj.backgroundimage.value != "")
|
149 |
-
tr_elm.style.backgroundImage = "url('" + formObj.backgroundimage.value + "')";
|
150 |
-
else
|
151 |
-
tr_elm.style.backgroundImage = '';
|
152 |
-
|
153 |
-
// Setup new rowtype
|
154 |
-
if (curRowType != rowtype && !skip_parent) {
|
155 |
-
// first, clone the node we are working on
|
156 |
-
var newRow = tr_elm.cloneNode(1);
|
157 |
-
|
158 |
-
// next, find the parent of its new destination (creating it if necessary)
|
159 |
-
var theTable = dom.getParent(tr_elm, "table");
|
160 |
-
var dest = rowtype;
|
161 |
-
var newParent = null;
|
162 |
-
for (var i = 0; i < theTable.childNodes.length; i++) {
|
163 |
-
if (theTable.childNodes[i].nodeName.toLowerCase() == dest)
|
164 |
-
newParent = theTable.childNodes[i];
|
165 |
-
}
|
166 |
-
|
167 |
-
if (newParent == null) {
|
168 |
-
newParent = doc.createElement(dest);
|
169 |
-
|
170 |
-
if (theTable.firstChild.nodeName == 'CAPTION')
|
171 |
-
inst.dom.insertAfter(newParent, theTable.firstChild);
|
172 |
-
else
|
173 |
-
theTable.insertBefore(newParent, theTable.firstChild);
|
174 |
-
}
|
175 |
-
|
176 |
-
// append the row to the new parent
|
177 |
-
newParent.appendChild(newRow);
|
178 |
-
|
179 |
-
// remove the original
|
180 |
-
tr_elm.parentNode.removeChild(tr_elm);
|
181 |
-
|
182 |
-
// set tr_elm to the new node
|
183 |
-
tr_elm = newRow;
|
184 |
-
}
|
185 |
-
|
186 |
-
dom.setAttrib(tr_elm, 'style', dom.serializeStyle(dom.parseStyle(tr_elm.style.cssText)));
|
187 |
-
}
|
188 |
-
|
189 |
-
function changedBackgroundImage() {
|
190 |
-
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
|
191 |
-
var st = dom.parseStyle(formObj.style.value);
|
192 |
-
|
193 |
-
st['background-image'] = "url('" + formObj.backgroundimage.value + "')";
|
194 |
-
|
195 |
-
formObj.style.value = dom.serializeStyle(st);
|
196 |
-
}
|
197 |
-
|
198 |
-
function changedStyle() {
|
199 |
-
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
|
200 |
-
var st = dom.parseStyle(formObj.style.value);
|
201 |
-
|
202 |
-
if (st['background-image'])
|
203 |
-
formObj.backgroundimage.value = st['background-image'].replace(new RegExp("url\\('?([^']*)'?\\)", 'gi'), "$1");
|
204 |
-
else
|
205 |
-
formObj.backgroundimage.value = '';
|
206 |
-
|
207 |
-
if (st['height'])
|
208 |
-
formObj.height.value = trimSize(st['height']);
|
209 |
-
|
210 |
-
if (st['background-color']) {
|
211 |
-
formObj.bgcolor.value = st['background-color'];
|
212 |
-
updateColor('bgcolor_pick','bgcolor');
|
213 |
-
}
|
214 |
-
}
|
215 |
-
|
216 |
-
function changedSize() {
|
217 |
-
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
|
218 |
-
var st = dom.parseStyle(formObj.style.value);
|
219 |
-
|
220 |
-
var height = formObj.height.value;
|
221 |
-
if (height != "")
|
222 |
-
st['height'] = getCSSSize(height);
|
223 |
-
else
|
224 |
-
st['height'] = "";
|
225 |
-
|
226 |
-
formObj.style.value = dom.serializeStyle(st);
|
227 |
-
}
|
228 |
-
|
229 |
-
function changedColor() {
|
230 |
-
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
|
231 |
-
var st = dom.parseStyle(formObj.style.value);
|
232 |
-
|
233 |
-
st['background-color'] = formObj.bgcolor.value;
|
234 |
-
|
235 |
-
formObj.style.value = dom.serializeStyle(st);
|
236 |
-
}
|
237 |
-
|
238 |
-
function changedRowType() {
|
239 |
-
var formObj = document.forms[0];
|
240 |
-
var rowtype = getSelectValue(formObj, 'rowtype');
|
241 |
-
|
242 |
-
setActionforRowType(formObj, rowtype);
|
243 |
-
|
244 |
-
}
|
245 |
-
|
246 |
-
function setActionforRowType(formObj, rowtype) {
|
247 |
-
if (rowtype === "tbody") {
|
248 |
-
formObj.action.disabled = false;
|
249 |
-
} else {
|
250 |
-
selectByValue(formObj, 'action', "row");
|
251 |
-
formObj.action.disabled = true;
|
252 |
-
}
|
253 |
-
}
|
254 |
-
tinyMCEPopup.onInit.add(init);
|
1 |
+
tinyMCEPopup.requireLangPack();
|
2 |
+
|
3 |
+
function init() {
|
4 |
+
tinyMCEPopup.resizeToInnerSize();
|
5 |
+
|
6 |
+
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
|
7 |
+
document.getElementById('bgcolor_pickcontainer').innerHTML = getColorPickerHTML('bgcolor_pick','bgcolor');
|
8 |
+
|
9 |
+
var inst = tinyMCEPopup.editor;
|
10 |
+
var dom = inst.dom;
|
11 |
+
var trElm = dom.getParent(inst.selection.getStart(), "tr");
|
12 |
+
var formObj = document.forms[0];
|
13 |
+
var st = dom.parseStyle(dom.getAttrib(trElm, "style"));
|
14 |
+
|
15 |
+
// Get table row data
|
16 |
+
var rowtype = trElm.parentNode.nodeName.toLowerCase();
|
17 |
+
var align = dom.getAttrib(trElm, 'align');
|
18 |
+
var valign = dom.getAttrib(trElm, 'valign');
|
19 |
+
var height = trimSize(getStyle(trElm, 'height', 'height'));
|
20 |
+
var className = dom.getAttrib(trElm, 'class');
|
21 |
+
var bgcolor = convertRGBToHex(getStyle(trElm, 'bgcolor', 'backgroundColor'));
|
22 |
+
var backgroundimage = getStyle(trElm, 'background', 'backgroundImage').replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
|
23 |
+
var id = dom.getAttrib(trElm, 'id');
|
24 |
+
var lang = dom.getAttrib(trElm, 'lang');
|
25 |
+
var dir = dom.getAttrib(trElm, 'dir');
|
26 |
+
|
27 |
+
selectByValue(formObj, 'rowtype', rowtype);
|
28 |
+
setActionforRowType(formObj, rowtype);
|
29 |
+
|
30 |
+
// Any cells selected
|
31 |
+
if (dom.select('td.mceSelected,th.mceSelected', trElm).length == 0) {
|
32 |
+
// Setup form
|
33 |
+
addClassesToList('class', 'table_row_styles');
|
34 |
+
TinyMCE_EditableSelects.init();
|
35 |
+
|
36 |
+
formObj.bgcolor.value = bgcolor;
|
37 |
+
formObj.backgroundimage.value = backgroundimage;
|
38 |
+
formObj.height.value = height;
|
39 |
+
formObj.id.value = id;
|
40 |
+
formObj.lang.value = lang;
|
41 |
+
formObj.style.value = dom.serializeStyle(st);
|
42 |
+
selectByValue(formObj, 'align', align);
|
43 |
+
selectByValue(formObj, 'valign', valign);
|
44 |
+
selectByValue(formObj, 'class', className, true, true);
|
45 |
+
selectByValue(formObj, 'dir', dir);
|
46 |
+
|
47 |
+
// Resize some elements
|
48 |
+
if (isVisible('backgroundimagebrowser'))
|
49 |
+
document.getElementById('backgroundimage').style.width = '180px';
|
50 |
+
|
51 |
+
updateColor('bgcolor_pick', 'bgcolor');
|
52 |
+
} else
|
53 |
+
tinyMCEPopup.dom.hide('action');
|
54 |
+
}
|
55 |
+
|
56 |
+
function updateAction() {
|
57 |
+
var inst = tinyMCEPopup.editor, dom = inst.dom, trElm, tableElm, formObj = document.forms[0];
|
58 |
+
var action = getSelectValue(formObj, 'action');
|
59 |
+
|
60 |
+
if (!AutoValidator.validate(formObj)) {
|
61 |
+
tinyMCEPopup.alert(AutoValidator.getErrorMessages(formObj).join('. ') + '.');
|
62 |
+
return false;
|
63 |
+
}
|
64 |
+
|
65 |
+
tinyMCEPopup.restoreSelection();
|
66 |
+
trElm = dom.getParent(inst.selection.getStart(), "tr");
|
67 |
+
tableElm = dom.getParent(inst.selection.getStart(), "table");
|
68 |
+
|
69 |
+
// Update all selected rows
|
70 |
+
if (dom.select('td.mceSelected,th.mceSelected', trElm).length > 0) {
|
71 |
+
tinymce.each(tableElm.rows, function(tr) {
|
72 |
+
var i;
|
73 |
+
|
74 |
+
for (i = 0; i < tr.cells.length; i++) {
|
75 |
+
if (dom.hasClass(tr.cells[i], 'mceSelected')) {
|
76 |
+
updateRow(tr, true);
|
77 |
+
return;
|
78 |
+
}
|
79 |
+
}
|
80 |
+
});
|
81 |
+
|
82 |
+
inst.addVisual();
|
83 |
+
inst.nodeChanged();
|
84 |
+
inst.execCommand('mceEndUndoLevel');
|
85 |
+
tinyMCEPopup.close();
|
86 |
+
return;
|
87 |
+
}
|
88 |
+
|
89 |
+
switch (action) {
|
90 |
+
case "row":
|
91 |
+
updateRow(trElm);
|
92 |
+
break;
|
93 |
+
|
94 |
+
case "all":
|
95 |
+
var rows = tableElm.getElementsByTagName("tr");
|
96 |
+
|
97 |
+
for (var i=0; i<rows.length; i++)
|
98 |
+
updateRow(rows[i], true);
|
99 |
+
|
100 |
+
break;
|
101 |
+
|
102 |
+
case "odd":
|
103 |
+
case "even":
|
104 |
+
var rows = tableElm.getElementsByTagName("tr");
|
105 |
+
|
106 |
+
for (var i=0; i<rows.length; i++) {
|
107 |
+
if ((i % 2 == 0 && action == "odd") || (i % 2 != 0 && action == "even"))
|
108 |
+
updateRow(rows[i], true, true);
|
109 |
+
}
|
110 |
+
|
111 |
+
break;
|
112 |
+
}
|
113 |
+
|
114 |
+
inst.addVisual();
|
115 |
+
inst.nodeChanged();
|
116 |
+
inst.execCommand('mceEndUndoLevel');
|
117 |
+
tinyMCEPopup.close();
|
118 |
+
}
|
119 |
+
|
120 |
+
function updateRow(tr_elm, skip_id, skip_parent) {
|
121 |
+
var inst = tinyMCEPopup.editor;
|
122 |
+
var formObj = document.forms[0];
|
123 |
+
var dom = inst.dom;
|
124 |
+
var curRowType = tr_elm.parentNode.nodeName.toLowerCase();
|
125 |
+
var rowtype = getSelectValue(formObj, 'rowtype');
|
126 |
+
var doc = inst.getDoc();
|
127 |
+
|
128 |
+
// Update row element
|
129 |
+
if (!skip_id)
|
130 |
+
dom.setAttrib(tr_elm, 'id', formObj.id.value);
|
131 |
+
|
132 |
+
dom.setAttrib(tr_elm, 'align', getSelectValue(formObj, 'align'));
|
133 |
+
dom.setAttrib(tr_elm, 'vAlign', getSelectValue(formObj, 'valign'));
|
134 |
+
dom.setAttrib(tr_elm, 'lang', formObj.lang.value);
|
135 |
+
dom.setAttrib(tr_elm, 'dir', getSelectValue(formObj, 'dir'));
|
136 |
+
dom.setAttrib(tr_elm, 'style', dom.serializeStyle(dom.parseStyle(formObj.style.value)));
|
137 |
+
dom.setAttrib(tr_elm, 'class', getSelectValue(formObj, 'class'));
|
138 |
+
|
139 |
+
// Clear deprecated attributes
|
140 |
+
dom.setAttrib(tr_elm, 'background', '');
|
141 |
+
dom.setAttrib(tr_elm, 'bgColor', '');
|
142 |
+
dom.setAttrib(tr_elm, 'height', '');
|
143 |
+
|
144 |
+
// Set styles
|
145 |
+
tr_elm.style.height = getCSSSize(formObj.height.value);
|
146 |
+
tr_elm.style.backgroundColor = formObj.bgcolor.value;
|
147 |
+
|
148 |
+
if (formObj.backgroundimage.value != "")
|
149 |
+
tr_elm.style.backgroundImage = "url('" + formObj.backgroundimage.value + "')";
|
150 |
+
else
|
151 |
+
tr_elm.style.backgroundImage = '';
|
152 |
+
|
153 |
+
// Setup new rowtype
|
154 |
+
if (curRowType != rowtype && !skip_parent) {
|
155 |
+
// first, clone the node we are working on
|
156 |
+
var newRow = tr_elm.cloneNode(1);
|
157 |
+
|
158 |
+
// next, find the parent of its new destination (creating it if necessary)
|
159 |
+
var theTable = dom.getParent(tr_elm, "table");
|
160 |
+
var dest = rowtype;
|
161 |
+
var newParent = null;
|
162 |
+
for (var i = 0; i < theTable.childNodes.length; i++) {
|
163 |
+
if (theTable.childNodes[i].nodeName.toLowerCase() == dest)
|
164 |
+
newParent = theTable.childNodes[i];
|
165 |
+
}
|
166 |
+
|
167 |
+
if (newParent == null) {
|
168 |
+
newParent = doc.createElement(dest);
|
169 |
+
|
170 |
+
if (theTable.firstChild.nodeName == 'CAPTION')
|
171 |
+
inst.dom.insertAfter(newParent, theTable.firstChild);
|
172 |
+
else
|
173 |
+
theTable.insertBefore(newParent, theTable.firstChild);
|
174 |
+
}
|
175 |
+
|
176 |
+
// append the row to the new parent
|
177 |
+
newParent.appendChild(newRow);
|
178 |
+
|
179 |
+
// remove the original
|
180 |
+
tr_elm.parentNode.removeChild(tr_elm);
|
181 |
+
|
182 |
+
// set tr_elm to the new node
|
183 |
+
tr_elm = newRow;
|
184 |
+
}
|
185 |
+
|
186 |
+
dom.setAttrib(tr_elm, 'style', dom.serializeStyle(dom.parseStyle(tr_elm.style.cssText)));
|
187 |
+
}
|
188 |
+
|
189 |
+
function changedBackgroundImage() {
|
190 |
+
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
|
191 |
+
var st = dom.parseStyle(formObj.style.value);
|
192 |
+
|
193 |
+
st['background-image'] = "url('" + formObj.backgroundimage.value + "')";
|
194 |
+
|
195 |
+
formObj.style.value = dom.serializeStyle(st);
|
196 |
+
}
|
197 |
+
|
198 |
+
function changedStyle() {
|
199 |
+
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
|
200 |
+
var st = dom.parseStyle(formObj.style.value);
|
201 |
+
|
202 |
+
if (st['background-image'])
|
203 |
+
formObj.backgroundimage.value = st['background-image'].replace(new RegExp("url\\('?([^']*)'?\\)", 'gi'), "$1");
|
204 |
+
else
|
205 |
+
formObj.backgroundimage.value = '';
|
206 |
+
|
207 |
+
if (st['height'])
|
208 |
+
formObj.height.value = trimSize(st['height']);
|
209 |
+
|
210 |
+
if (st['background-color']) {
|
211 |
+
formObj.bgcolor.value = st['background-color'];
|
212 |
+
updateColor('bgcolor_pick','bgcolor');
|
213 |
+
}
|
214 |
+
}
|
215 |
+
|
216 |
+
function changedSize() {
|
217 |
+
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
|
218 |
+
var st = dom.parseStyle(formObj.style.value);
|
219 |
+
|
220 |
+
var height = formObj.height.value;
|
221 |
+
if (height != "")
|
222 |
+
st['height'] = getCSSSize(height);
|
223 |
+
else
|
224 |
+
st['height'] = "";
|
225 |
+
|
226 |
+
formObj.style.value = dom.serializeStyle(st);
|
227 |
+
}
|
228 |
+
|
229 |
+
function changedColor() {
|
230 |
+
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
|
231 |
+
var st = dom.parseStyle(formObj.style.value);
|
232 |
+
|
233 |
+
st['background-color'] = formObj.bgcolor.value;
|
234 |
+
|
235 |
+
formObj.style.value = dom.serializeStyle(st);
|
236 |
+
}
|
237 |
+
|
238 |
+
function changedRowType() {
|
239 |
+
var formObj = document.forms[0];
|
240 |
+
var rowtype = getSelectValue(formObj, 'rowtype');
|
241 |
+
|
242 |
+
setActionforRowType(formObj, rowtype);
|
243 |
+
|
244 |
+
}
|
245 |
+
|
246 |
+
function setActionforRowType(formObj, rowtype) {
|
247 |
+
if (rowtype === "tbody") {
|
248 |
+
formObj.action.disabled = false;
|
249 |
+
} else {
|
250 |
+
selectByValue(formObj, 'action', "row");
|
251 |
+
formObj.action.disabled = true;
|
252 |
+
}
|
253 |
+
}
|
254 |
+
tinyMCEPopup.onInit.add(init);
|
mce/table/js/table.js
CHANGED
@@ -1,501 +1,501 @@
|
|
1 |
-
tinyMCEPopup.requireLangPack();
|
2 |
-
|
3 |
-
var action, orgTableWidth, orgTableHeight, dom = tinyMCEPopup.editor.dom;
|
4 |
-
|
5 |
-
function insertTable() {
|
6 |
-
var formObj = document.forms[0];
|
7 |
-
var inst = tinyMCEPopup.editor, dom = inst.dom;
|
8 |
-
var cols = 2, rows = 2, border = 0, cellpadding = -1, cellspacing = -1, align, width, height, className, caption, frame, rules;
|
9 |
-
var html = '', capEl, elm;
|
10 |
-
var cellLimit, rowLimit, colLimit;
|
11 |
-
|
12 |
-
tinyMCEPopup.restoreSelection();
|
13 |
-
|
14 |
-
if (!AutoValidator.validate(formObj)) {
|
15 |
-
tinyMCEPopup.alert(AutoValidator.getErrorMessages(formObj).join('. ') + '.');
|
16 |
-
return false;
|
17 |
-
}
|
18 |
-
|
19 |
-
elm = dom.getParent(inst.selection.getNode(), 'table');
|
20 |
-
|
21 |
-
// Get form data
|
22 |
-
cols = formObj.elements['cols'].value;
|
23 |
-
rows = formObj.elements['rows'].value;
|
24 |
-
border = formObj.elements['border'].value != "" ? formObj.elements['border'].value : 0;
|
25 |
-
cellpadding = formObj.elements['cellpadding'].value != "" ? formObj.elements['cellpadding'].value : "";
|
26 |
-
cellspacing = formObj.elements['cellspacing'].value != "" ? formObj.elements['cellspacing'].value : "";
|
27 |
-
align = getSelectValue(formObj, "align");
|
28 |
-
frame = getSelectValue(formObj, "tframe");
|
29 |
-
rules = getSelectValue(formObj, "rules");
|
30 |
-
width = formObj.elements['width'].value;
|
31 |
-
height = formObj.elements['height'].value;
|
32 |
-
bordercolor = formObj.elements['bordercolor'].value;
|
33 |
-
bgcolor = formObj.elements['bgcolor'].value;
|
34 |
-
className = getSelectValue(formObj, "class");
|
35 |
-
id = formObj.elements['id'].value;
|
36 |
-
summary = formObj.elements['summary'].value;
|
37 |
-
style = formObj.elements['style'].value;
|
38 |
-
dir = formObj.elements['dir'].value;
|
39 |
-
lang = formObj.elements['lang'].value;
|
40 |
-
background = formObj.elements['backgroundimage'].value;
|
41 |
-
caption = formObj.elements['caption'].checked;
|
42 |
-
|
43 |
-
cellLimit = tinyMCEPopup.getParam('table_cell_limit', false);
|
44 |
-
rowLimit = tinyMCEPopup.getParam('table_row_limit', false);
|
45 |
-
colLimit = tinyMCEPopup.getParam('table_col_limit', false);
|
46 |
-
|
47 |
-
// Validate table size
|
48 |
-
if (colLimit && cols > colLimit) {
|
49 |
-
tinyMCEPopup.alert(inst.getLang('table_dlg.col_limit').replace(/\{\$cols\}/g, colLimit));
|
50 |
-
return false;
|
51 |
-
} else if (rowLimit && rows > rowLimit) {
|
52 |
-
tinyMCEPopup.alert(inst.getLang('table_dlg.row_limit').replace(/\{\$rows\}/g, rowLimit));
|
53 |
-
return false;
|
54 |
-
} else if (cellLimit && cols * rows > cellLimit) {
|
55 |
-
tinyMCEPopup.alert(inst.getLang('table_dlg.cell_limit').replace(/\{\$cells\}/g, cellLimit));
|
56 |
-
return false;
|
57 |
-
}
|
58 |
-
|
59 |
-
// Update table
|
60 |
-
if (action == "update") {
|
61 |
-
dom.setAttrib(elm, 'cellPadding', cellpadding, true);
|
62 |
-
dom.setAttrib(elm, 'cellSpacing', cellspacing, true);
|
63 |
-
|
64 |
-
if (!isCssSize(border)) {
|
65 |
-
dom.setAttrib(elm, 'border', border);
|
66 |
-
} else {
|
67 |
-
dom.setAttrib(elm, 'border', '');
|
68 |
-
}
|
69 |
-
|
70 |
-
if (border == '') {
|
71 |
-
dom.setStyle(elm, 'border-width', '');
|
72 |
-
dom.setStyle(elm, 'border', '');
|
73 |
-
dom.setAttrib(elm, 'border', '');
|
74 |
-
}
|
75 |
-
|
76 |
-
dom.setAttrib(elm, 'align', align);
|
77 |
-
dom.setAttrib(elm, 'frame', frame);
|
78 |
-
dom.setAttrib(elm, 'rules', rules);
|
79 |
-
dom.setAttrib(elm, 'class', className);
|
80 |
-
dom.setAttrib(elm, 'style', style);
|
81 |
-
dom.setAttrib(elm, 'id', id);
|
82 |
-
dom.setAttrib(elm, 'summary', summary);
|
83 |
-
dom.setAttrib(elm, 'dir', dir);
|
84 |
-
dom.setAttrib(elm, 'lang', lang);
|
85 |
-
|
86 |
-
capEl = inst.dom.select('caption', elm)[0];
|
87 |
-
|
88 |
-
if (capEl && !caption)
|
89 |
-
capEl.parentNode.removeChild(capEl);
|
90 |
-
|
91 |
-
if (!capEl && caption) {
|
92 |
-
capEl = elm.ownerDocument.createElement('caption');
|
93 |
-
|
94 |
-
if (!tinymce.isIE)
|
95 |
-
capEl.innerHTML = '<br data-mce-bogus="1"/>';
|
96 |
-
|
97 |
-
elm.insertBefore(capEl, elm.firstChild);
|
98 |
-
}
|
99 |
-
|
100 |
-
if (width && inst.settings.inline_styles) {
|
101 |
-
dom.setStyle(elm, 'width', width);
|
102 |
-
dom.setAttrib(elm, 'width', '');
|
103 |
-
} else {
|
104 |
-
dom.setAttrib(elm, 'width', width, true);
|
105 |
-
dom.setStyle(elm, 'width', '');
|
106 |
-
}
|
107 |
-
|
108 |
-
// Remove these since they are not valid XHTML
|
109 |
-
dom.setAttrib(elm, 'borderColor', '');
|
110 |
-
dom.setAttrib(elm, 'bgColor', '');
|
111 |
-
dom.setAttrib(elm, 'background', '');
|
112 |
-
|
113 |
-
if (height && inst.settings.inline_styles) {
|
114 |
-
dom.setStyle(elm, 'height', height);
|
115 |
-
dom.setAttrib(elm, 'height', '');
|
116 |
-
} else {
|
117 |
-
dom.setAttrib(elm, 'height', height, true);
|
118 |
-
dom.setStyle(elm, 'height', '');
|
119 |
-
}
|
120 |
-
|
121 |
-
if (background != '')
|
122 |
-
elm.style.backgroundImage = "url('" + background + "')";
|
123 |
-
else
|
124 |
-
elm.style.backgroundImage = '';
|
125 |
-
|
126 |
-
/* if (tinyMCEPopup.getParam("inline_styles")) {
|
127 |
-
if (width != '')
|
128 |
-
elm.style.width = getCSSSize(width);
|
129 |
-
}*/
|
130 |
-
|
131 |
-
if (bordercolor != "") {
|
132 |
-
elm.style.borderColor = bordercolor;
|
133 |
-
elm.style.borderStyle = elm.style.borderStyle == "" ? "solid" : elm.style.borderStyle;
|
134 |
-
elm.style.borderWidth = cssSize(border);
|
135 |
-
} else
|
136 |
-
elm.style.borderColor = '';
|
137 |
-
|
138 |
-
elm.style.backgroundColor = bgcolor;
|
139 |
-
elm.style.height = getCSSSize(height);
|
140 |
-
|
141 |
-
inst.addVisual();
|
142 |
-
|
143 |
-
// Fix for stange MSIE align bug
|
144 |
-
//elm.outerHTML = elm.outerHTML;
|
145 |
-
|
146 |
-
inst.nodeChanged();
|
147 |
-
inst.execCommand('mceEndUndoLevel', false, {}, {skip_undo: true});
|
148 |
-
|
149 |
-
// Repaint if dimensions changed
|
150 |
-
if (formObj.width.value != orgTableWidth || formObj.height.value != orgTableHeight)
|
151 |
-
inst.execCommand('mceRepaint');
|
152 |
-
|
153 |
-
tinyMCEPopup.close();
|
154 |
-
return true;
|
155 |
-
}
|
156 |
-
|
157 |
-
// Create new table
|
158 |
-
html += '<table';
|
159 |
-
|
160 |
-
html += makeAttrib('id', id);
|
161 |
-
if (!isCssSize(border)) {
|
162 |
-
html += makeAttrib('border', border);
|
163 |
-
}
|
164 |
-
|
165 |
-
html += makeAttrib('cellpadding', cellpadding);
|
166 |
-
html += makeAttrib('cellspacing', cellspacing);
|
167 |
-
html += makeAttrib('data-mce-new', '1');
|
168 |
-
|
169 |
-
if (width && inst.settings.inline_styles) {
|
170 |
-
if (style)
|
171 |
-
style += '; ';
|
172 |
-
|
173 |
-
// Force px
|
174 |
-
if (/^[0-9\.]+$/.test(width))
|
175 |
-
width += 'px';
|
176 |
-
|
177 |
-
style += 'width: ' + width;
|
178 |
-
} else
|
179 |
-
html += makeAttrib('width', width);
|
180 |
-
|
181 |
-
/* if (height) {
|
182 |
-
if (style)
|
183 |
-
style += '; ';
|
184 |
-
|
185 |
-
style += 'height: ' + height;
|
186 |
-
}*/
|
187 |
-
|
188 |
-
//html += makeAttrib('height', height);
|
189 |
-
//html += makeAttrib('bordercolor', bordercolor);
|
190 |
-
//html += makeAttrib('bgcolor', bgcolor);
|
191 |
-
html += makeAttrib('align', align);
|
192 |
-
html += makeAttrib('frame', frame);
|
193 |
-
html += makeAttrib('rules', rules);
|
194 |
-
html += makeAttrib('class', className);
|
195 |
-
html += makeAttrib('style', style);
|
196 |
-
html += makeAttrib('summary', summary);
|
197 |
-
html += makeAttrib('dir', dir);
|
198 |
-
html += makeAttrib('lang', lang);
|
199 |
-
html += '>';
|
200 |
-
|
201 |
-
if (caption) {
|
202 |
-
if (!tinymce.isIE)
|
203 |
-
html += '<caption><br data-mce-bogus="1"/></caption>';
|
204 |
-
else
|
205 |
-
html += '<caption></caption>';
|
206 |
-
}
|
207 |
-
|
208 |
-
for (var y=0; y<rows; y++) {
|
209 |
-
html += "<tr>";
|
210 |
-
|
211 |
-
for (var x=0; x<cols; x++) {
|
212 |
-
if (!tinymce.isIE)
|
213 |
-
html += '<td><br data-mce-bogus="1"/></td>';
|
214 |
-
else
|
215 |
-
html += '<td></td>';
|
216 |
-
}
|
217 |
-
|
218 |
-
html += "</tr>";
|
219 |
-
}
|
220 |
-
|
221 |
-
html += "</table>";
|
222 |
-
|
223 |
-
// Move table
|
224 |
-
if (inst.settings.fix_table_elements) {
|
225 |
-
var patt = '';
|
226 |
-
|
227 |
-
inst.focus();
|
228 |
-
inst.selection.setContent('<br class="_mce_marker" />');
|
229 |
-
|
230 |
-
tinymce.each('h1,h2,h3,h4,h5,h6,p'.split(','), function(n) {
|
231 |
-
if (patt)
|
232 |
-
patt += ',';
|
233 |
-
|
234 |
-
patt += n + ' ._mce_marker';
|
235 |
-
});
|
236 |
-
|
237 |
-
tinymce.each(inst.dom.select(patt), function(n) {
|
238 |
-
inst.dom.split(inst.dom.getParent(n, 'h1,h2,h3,h4,h5,h6,p'), n);
|
239 |
-
});
|
240 |
-
|
241 |
-
dom.setOuterHTML(dom.select('br._mce_marker')[0], html);
|
242 |
-
} else
|
243 |
-
inst.execCommand('mceInsertContent', false, html);
|
244 |
-
|
245 |
tinymce.each(dom.select('table[data-mce-new]'), function(node) {
|
246 |
-
var tdorth = dom.select('td,th', node);
|
247 |
-
|
248 |
-
// Fixes a bug in IE where the caret cannot be placed after the table if the table is at the end of the document
|
249 |
-
if (tinymce.isIE && node.nextSibling == null) {
|
250 |
-
if (inst.settings.forced_root_block)
|
251 |
-
dom.insertAfter(dom.create(inst.settings.forced_root_block), node);
|
252 |
-
else
|
253 |
-
dom.insertAfter(dom.create('br', {'data-mce-bogus': '1'}), node);
|
254 |
}
|
255 |
-
|
256 |
-
try {
|
257 |
-
// IE9 might fail to do this selection
|
258 |
-
inst.selection.setCursorLocation(tdorth[0], 0);
|
259 |
-
} catch (ex) {
|
260 |
-
// Ignore
|
261 |
-
}
|
262 |
-
|
263 |
-
dom.setAttrib(node, 'data-mce-new', '');
|
264 |
-
});
|
265 |
-
|
266 |
-
inst.addVisual();
|
267 |
-
inst.execCommand('mceEndUndoLevel', false, {}, {skip_undo: true});
|
268 |
-
|
269 |
-
tinyMCEPopup.close();
|
270 |
-
}
|
271 |
-
|
272 |
-
function makeAttrib(attrib, value) {
|
273 |
-
var formObj = document.forms[0];
|
274 |
-
var valueElm = formObj.elements[attrib];
|
275 |
-
|
276 |
-
if (typeof(value) == "undefined" || value == null) {
|
277 |
-
value = "";
|
278 |
-
|
279 |
-
if (valueElm)
|
280 |
-
value = valueElm.value;
|
281 |
-
}
|
282 |
-
|
283 |
-
if (value == "")
|
284 |
-
return "";
|
285 |
-
|
286 |
-
// XML encode it
|
287 |
-
value = value.replace(/&/g, '&');
|
288 |
-
value = value.replace(/\"/g, '"');
|
289 |
-
value = value.replace(/</g, '<');
|
290 |
-
value = value.replace(/>/g, '>');
|
291 |
-
|
292 |
-
return ' ' + attrib + '="' + value + '"';
|
293 |
-
}
|
294 |
-
|
295 |
-
function init() {
|
296 |
-
tinyMCEPopup.resizeToInnerSize();
|
297 |
-
|
298 |
-
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
|
299 |
-
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
|
300 |
-
document.getElementById('bordercolor_pickcontainer').innerHTML = getColorPickerHTML('bordercolor_pick','bordercolor');
|
301 |
-
document.getElementById('bgcolor_pickcontainer').innerHTML = getColorPickerHTML('bgcolor_pick','bgcolor');
|
302 |
-
|
303 |
-
var cols = 2, rows = 2, border = tinyMCEPopup.getParam('table_default_border', '0'), cellpadding = tinyMCEPopup.getParam('table_default_cellpadding', ''), cellspacing = tinyMCEPopup.getParam('table_default_cellspacing', '');
|
304 |
-
var align = "", width = "", height = "", bordercolor = "", bgcolor = "", className = "";
|
305 |
-
var id = "", summary = "", style = "", dir = "", lang = "", background = "", bgcolor = "", bordercolor = "", rules = "", frame = "";
|
306 |
-
var inst = tinyMCEPopup.editor, dom = inst.dom;
|
307 |
-
var formObj = document.forms[0];
|
308 |
-
var elm = dom.getParent(inst.selection.getNode(), "table");
|
309 |
-
|
310 |
-
// Hide advanced fields that isn't available in the schema
|
311 |
-
tinymce.each("summary id rules dir style frame".split(" "), function(name) {
|
312 |
-
var tr = tinyMCEPopup.dom.getParent(name, "tr") || tinyMCEPopup.dom.getParent("t" + name, "tr");
|
313 |
-
|
314 |
-
if (tr && !tinyMCEPopup.editor.schema.isValid("table", name)) {
|
315 |
-
tr.style.display = 'none';
|
316 |
-
}
|
317 |
-
});
|
318 |
-
|
319 |
-
action = tinyMCEPopup.getWindowArg('action');
|
320 |
-
|
321 |
-
if (!action)
|
322 |
-
action = elm ? "update" : "insert";
|
323 |
-
|
324 |
-
if (elm && action != "insert") {
|
325 |
-
var rowsAr = elm.rows;
|
326 |
-
var cols = 0;
|
327 |
-
for (var i=0; i<rowsAr.length; i++)
|
328 |
-
if (rowsAr[i].cells.length > cols)
|
329 |
-
cols = rowsAr[i].cells.length;
|
330 |
-
|
331 |
-
cols = cols;
|
332 |
-
rows = rowsAr.length;
|
333 |
-
|
334 |
-
st = dom.parseStyle(dom.getAttrib(elm, "style"));
|
335 |
-
border = trimSize(getStyle(elm, 'border', 'borderWidth'));
|
336 |
-
cellpadding = dom.getAttrib(elm, 'cellpadding', "");
|
337 |
-
cellspacing = dom.getAttrib(elm, 'cellspacing', "");
|
338 |
-
width = trimSize(getStyle(elm, 'width', 'width'));
|
339 |
-
height = trimSize(getStyle(elm, 'height', 'height'));
|
340 |
-
bordercolor = convertRGBToHex(getStyle(elm, 'bordercolor', 'borderLeftColor'));
|
341 |
-
bgcolor = convertRGBToHex(getStyle(elm, 'bgcolor', 'backgroundColor'));
|
342 |
-
align = dom.getAttrib(elm, 'align', align);
|
343 |
-
frame = dom.getAttrib(elm, 'frame');
|
344 |
-
rules = dom.getAttrib(elm, 'rules');
|
345 |
-
className = tinymce.trim(dom.getAttrib(elm, 'class').replace(/mceItem.+/g, ''));
|
346 |
-
id = dom.getAttrib(elm, 'id');
|
347 |
-
summary = dom.getAttrib(elm, 'summary');
|
348 |
-
style = dom.serializeStyle(st);
|
349 |
-
dir = dom.getAttrib(elm, 'dir');
|
350 |
-
lang = dom.getAttrib(elm, 'lang');
|
351 |
-
background = getStyle(elm, 'background', 'backgroundImage').replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
|
352 |
-
formObj.caption.checked = elm.getElementsByTagName('caption').length > 0;
|
353 |
-
|
354 |
-
orgTableWidth = width;
|
355 |
-
orgTableHeight = height;
|
356 |
-
|
357 |
-
action = "update";
|
358 |
-
formObj.insert.value = inst.getLang('update');
|
359 |
-
}
|
360 |
-
|
361 |
-
addClassesToList('class', "table_styles");
|
362 |
-
TinyMCE_EditableSelects.init();
|
363 |
-
|
364 |
-
// Update form
|
365 |
-
selectByValue(formObj, 'align', align);
|
366 |
-
selectByValue(formObj, 'tframe', frame);
|
367 |
-
selectByValue(formObj, 'rules', rules);
|
368 |
-
selectByValue(formObj, 'class', className, true, true);
|
369 |
-
formObj.cols.value = cols;
|
370 |
-
formObj.rows.value = rows;
|
371 |
-
formObj.border.value = border;
|
372 |
-
formObj.cellpadding.value = cellpadding;
|
373 |
-
formObj.cellspacing.value = cellspacing;
|
374 |
-
formObj.width.value = width;
|
375 |
-
formObj.height.value = height;
|
376 |
-
formObj.bordercolor.value = bordercolor;
|
377 |
-
formObj.bgcolor.value = bgcolor;
|
378 |
-
formObj.id.value = id;
|
379 |
-
formObj.summary.value = summary;
|
380 |
-
formObj.style.value = style;
|
381 |
-
formObj.dir.value = dir;
|
382 |
-
formObj.lang.value = lang;
|
383 |
-
formObj.backgroundimage.value = background;
|
384 |
-
|
385 |
-
updateColor('bordercolor_pick', 'bordercolor');
|
386 |
-
updateColor('bgcolor_pick', 'bgcolor');
|
387 |
-
|
388 |
-
// Resize some elements
|
389 |
-
if (isVisible('backgroundimagebrowser'))
|
390 |
-
document.getElementById('backgroundimage').style.width = '180px';
|
391 |
-
|
392 |
-
// Disable some fields in update mode
|
393 |
-
if (action == "update") {
|
394 |
-
formObj.cols.disabled = true;
|
395 |
-
formObj.rows.disabled = true;
|
396 |
-
}
|
397 |
-
}
|
398 |
-
|
399 |
-
function changedSize() {
|
400 |
-
var formObj = document.forms[0];
|
401 |
-
var st = dom.parseStyle(formObj.style.value);
|
402 |
-
|
403 |
-
/* var width = formObj.width.value;
|
404 |
-
if (width != "")
|
405 |
-
st['width'] = tinyMCEPopup.getParam("inline_styles") ? getCSSSize(width) : "";
|
406 |
-
else
|
407 |
-
st['width'] = "";*/
|
408 |
-
|
409 |
-
var height = formObj.height.value;
|
410 |
-
if (height != "")
|
411 |
-
st['height'] = getCSSSize(height);
|
412 |
-
else
|
413 |
-
st['height'] = "";
|
414 |
-
|
415 |
-
formObj.style.value = dom.serializeStyle(st);
|
416 |
-
}
|
417 |
-
|
418 |
-
function isCssSize(value) {
|
419 |
-
return /^[0-9.]+(%|in|cm|mm|em|ex|pt|pc|px)$/.test(value);
|
420 |
-
}
|
421 |
-
|
422 |
-
function cssSize(value, def) {
|
423 |
-
value = tinymce.trim(value || def);
|
424 |
-
|
425 |
-
if (!isCssSize(value)) {
|
426 |
-
return parseInt(value, 10) + 'px';
|
427 |
-
}
|
428 |
-
|
429 |
-
return value;
|
430 |
-
}
|
431 |
-
|
432 |
-
function changedBackgroundImage() {
|
433 |
-
var formObj = document.forms[0];
|
434 |
-
var st = dom.parseStyle(formObj.style.value);
|
435 |
-
|
436 |
-
st['background-image'] = "url('" + formObj.backgroundimage.value + "')";
|
437 |
-
|
438 |
-
formObj.style.value = dom.serializeStyle(st);
|
439 |
-
}
|
440 |
-
|
441 |
-
function changedBorder() {
|
442 |
-
var formObj = document.forms[0];
|
443 |
-
var st = dom.parseStyle(formObj.style.value);
|
444 |
-
|
445 |
-
// Update border width if the element has a color
|
446 |
-
if (formObj.border.value != "" && (isCssSize(formObj.border.value) || formObj.bordercolor.value != ""))
|
447 |
-
st['border-width'] = cssSize(formObj.border.value);
|
448 |
-
else {
|
449 |
-
if (!formObj.border.value) {
|
450 |
-
st['border'] = '';
|
451 |
-
st['border-width'] = '';
|
452 |
-
}
|
453 |
-
}
|
454 |
-
|
455 |
-
formObj.style.value = dom.serializeStyle(st);
|
456 |
-
}
|
457 |
-
|
458 |
-
function changedColor() {
|
459 |
-
var formObj = document.forms[0];
|
460 |
-
var st = dom.parseStyle(formObj.style.value);
|
461 |
-
|
462 |
-
st['background-color'] = formObj.bgcolor.value;
|
463 |
-
|
464 |
-
if (formObj.bordercolor.value != "") {
|
465 |
-
st['border-color'] = formObj.bordercolor.value;
|
466 |
-
|
467 |
-
// Add border-width if it's missing
|
468 |
-
if (!st['border-width'])
|
469 |
-
st['border-width'] = cssSize(formObj.border.value, 1);
|
470 |
-
}
|
471 |
-
|
472 |
-
formObj.style.value = dom.serializeStyle(st);
|
473 |
-
}
|
474 |
-
|
475 |
-
function changedStyle() {
|
476 |
-
var formObj = document.forms[0];
|
477 |
-
var st = dom.parseStyle(formObj.style.value);
|
478 |
-
|
479 |
-
if (st['background-image'])
|
480 |
-
formObj.backgroundimage.value = st['background-image'].replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
|
481 |
-
else
|
482 |
-
formObj.backgroundimage.value = '';
|
483 |
-
|
484 |
-
if (st['width'])
|
485 |
-
formObj.width.value = trimSize(st['width']);
|
486 |
-
|
487 |
-
if (st['height'])
|
488 |
-
formObj.height.value = trimSize(st['height']);
|
489 |
-
|
490 |
-
if (st['background-color']) {
|
491 |
-
formObj.bgcolor.value = st['background-color'];
|
492 |
-
updateColor('bgcolor_pick','bgcolor');
|
493 |
-
}
|
494 |
-
|
495 |
-
if (st['border-color']) {
|
496 |
-
formObj.bordercolor.value = st['border-color'];
|
497 |
-
updateColor('bordercolor_pick','bordercolor');
|
498 |
-
}
|
499 |
-
}
|
500 |
-
|
501 |
-
tinyMCEPopup.onInit.add(init);
|
1 |
+
tinyMCEPopup.requireLangPack();
|
2 |
+
|
3 |
+
var action, orgTableWidth, orgTableHeight, dom = tinyMCEPopup.editor.dom;
|
4 |
+
|
5 |
+
function insertTable() {
|
6 |
+
var formObj = document.forms[0];
|
7 |
+
var inst = tinyMCEPopup.editor, dom = inst.dom;
|
8 |
+
var cols = 2, rows = 2, border = 0, cellpadding = -1, cellspacing = -1, align, width, height, className, caption, frame, rules;
|
9 |
+
var html = '', capEl, elm;
|
10 |
+
var cellLimit, rowLimit, colLimit;
|
11 |
+
|
12 |
+
tinyMCEPopup.restoreSelection();
|
13 |
+
|
14 |
+
if (!AutoValidator.validate(formObj)) {
|
15 |
+
tinyMCEPopup.alert(AutoValidator.getErrorMessages(formObj).join('. ') + '.');
|
16 |
+
return false;
|
17 |
+
}
|
18 |
+
|
19 |
+
elm = dom.getParent(inst.selection.getNode(), 'table');
|
20 |
+
|
21 |
+
// Get form data
|
22 |
+
cols = formObj.elements['cols'].value;
|
23 |
+
rows = formObj.elements['rows'].value;
|
24 |
+
border = formObj.elements['border'].value != "" ? formObj.elements['border'].value : 0;
|
25 |
+
cellpadding = formObj.elements['cellpadding'].value != "" ? formObj.elements['cellpadding'].value : "";
|
26 |
+
cellspacing = formObj.elements['cellspacing'].value != "" ? formObj.elements['cellspacing'].value : "";
|
27 |
+
align = getSelectValue(formObj, "align");
|
28 |
+
frame = getSelectValue(formObj, "tframe");
|
29 |
+
rules = getSelectValue(formObj, "rules");
|
30 |
+
width = formObj.elements['width'].value;
|
31 |
+
height = formObj.elements['height'].value;
|
32 |
+
bordercolor = formObj.elements['bordercolor'].value;
|
33 |
+
bgcolor = formObj.elements['bgcolor'].value;
|
34 |
+
className = getSelectValue(formObj, "class");
|
35 |
+
id = formObj.elements['id'].value;
|
36 |
+
summary = formObj.elements['summary'].value;
|
37 |
+
style = formObj.elements['style'].value;
|
38 |
+
dir = formObj.elements['dir'].value;
|
39 |
+
lang = formObj.elements['lang'].value;
|
40 |
+
background = formObj.elements['backgroundimage'].value;
|
41 |
+
caption = formObj.elements['caption'].checked;
|
42 |
+
|
43 |
+
cellLimit = tinyMCEPopup.getParam('table_cell_limit', false);
|
44 |
+
rowLimit = tinyMCEPopup.getParam('table_row_limit', false);
|
45 |
+
colLimit = tinyMCEPopup.getParam('table_col_limit', false);
|
46 |
+
|
47 |
+
// Validate table size
|
48 |
+
if (colLimit && cols > colLimit) {
|
49 |
+
tinyMCEPopup.alert(inst.getLang('table_dlg.col_limit').replace(/\{\$cols\}/g, colLimit));
|
50 |
+
return false;
|
51 |
+
} else if (rowLimit && rows > rowLimit) {
|
52 |
+
tinyMCEPopup.alert(inst.getLang('table_dlg.row_limit').replace(/\{\$rows\}/g, rowLimit));
|
53 |
+
return false;
|
54 |
+
} else if (cellLimit && cols * rows > cellLimit) {
|
55 |
+
tinyMCEPopup.alert(inst.getLang('table_dlg.cell_limit').replace(/\{\$cells\}/g, cellLimit));
|
56 |
+
return false;
|
57 |
+
}
|
58 |
+
|
59 |
+
// Update table
|
60 |
+
if (action == "update") {
|
61 |
+
dom.setAttrib(elm, 'cellPadding', cellpadding, true);
|
62 |
+
dom.setAttrib(elm, 'cellSpacing', cellspacing, true);
|
63 |
+
|
64 |
+
if (!isCssSize(border)) {
|
65 |
+
dom.setAttrib(elm, 'border', border);
|
66 |
+
} else {
|
67 |
+
dom.setAttrib(elm, 'border', '');
|
68 |
+
}
|
69 |
+
|
70 |
+
if (border == '') {
|
71 |
+
dom.setStyle(elm, 'border-width', '');
|
72 |
+
dom.setStyle(elm, 'border', '');
|
73 |
+
dom.setAttrib(elm, 'border', '');
|
74 |
+
}
|
75 |
+
|
76 |
+
dom.setAttrib(elm, 'align', align);
|
77 |
+
dom.setAttrib(elm, 'frame', frame);
|
78 |
+
dom.setAttrib(elm, 'rules', rules);
|
79 |
+
dom.setAttrib(elm, 'class', className);
|
80 |
+
dom.setAttrib(elm, 'style', style);
|
81 |
+
dom.setAttrib(elm, 'id', id);
|
82 |
+
dom.setAttrib(elm, 'summary', summary);
|
83 |
+
dom.setAttrib(elm, 'dir', dir);
|
84 |
+
dom.setAttrib(elm, 'lang', lang);
|
85 |
+
|
86 |
+
capEl = inst.dom.select('caption', elm)[0];
|
87 |
+
|
88 |
+
if (capEl && !caption)
|
89 |
+
capEl.parentNode.removeChild(capEl);
|
90 |
+
|
91 |
+
if (!capEl && caption) {
|
92 |
+
capEl = elm.ownerDocument.createElement('caption');
|
93 |
+
|
94 |
+
if (!tinymce.isIE || tinymce.isIE11)
|
95 |
+
capEl.innerHTML = '<br data-mce-bogus="1"/>';
|
96 |
+
|
97 |
+
elm.insertBefore(capEl, elm.firstChild);
|
98 |
+
}
|
99 |
+
|
100 |
+
if (width && inst.settings.inline_styles) {
|
101 |
+
dom.setStyle(elm, 'width', width);
|
102 |
+
dom.setAttrib(elm, 'width', '');
|
103 |
+
} else {
|
104 |
+
dom.setAttrib(elm, 'width', width, true);
|
105 |
+
dom.setStyle(elm, 'width', '');
|
106 |
+
}
|
107 |
+
|
108 |
+
// Remove these since they are not valid XHTML
|
109 |
+
dom.setAttrib(elm, 'borderColor', '');
|
110 |
+
dom.setAttrib(elm, 'bgColor', '');
|
111 |
+
dom.setAttrib(elm, 'background', '');
|
112 |
+
|
113 |
+
if (height && inst.settings.inline_styles) {
|
114 |
+
dom.setStyle(elm, 'height', height);
|
115 |
+
dom.setAttrib(elm, 'height', '');
|
116 |
+
} else {
|
117 |
+
dom.setAttrib(elm, 'height', height, true);
|
118 |
+
dom.setStyle(elm, 'height', '');
|
119 |
+
}
|
120 |
+
|
121 |
+
if (background != '')
|
122 |
+
elm.style.backgroundImage = "url('" + background + "')";
|
123 |
+
else
|
124 |
+
elm.style.backgroundImage = '';
|
125 |
+
|
126 |
+
/* if (tinyMCEPopup.getParam("inline_styles")) {
|
127 |
+
if (width != '')
|
128 |
+
elm.style.width = getCSSSize(width);
|
129 |
+
}*/
|
130 |
+
|
131 |
+
if (bordercolor != "") {
|
132 |
+
elm.style.borderColor = bordercolor;
|
133 |
+
elm.style.borderStyle = elm.style.borderStyle == "" ? "solid" : elm.style.borderStyle;
|
134 |
+
elm.style.borderWidth = cssSize(border);
|
135 |
+
} else
|
136 |
+
elm.style.borderColor = '';
|
137 |
+
|
138 |
+
elm.style.backgroundColor = bgcolor;
|
139 |
+
elm.style.height = getCSSSize(height);
|
140 |
+
|
141 |
+
inst.addVisual();
|
142 |
+
|
143 |
+
// Fix for stange MSIE align bug
|
144 |
+
//elm.outerHTML = elm.outerHTML;
|
145 |
+
|
146 |
+
inst.nodeChanged();
|
147 |
+
inst.execCommand('mceEndUndoLevel', false, {}, {skip_undo: true});
|
148 |
+
|
149 |
+
// Repaint if dimensions changed
|
150 |
+
if (formObj.width.value != orgTableWidth || formObj.height.value != orgTableHeight)
|
151 |
+
inst.execCommand('mceRepaint');
|
152 |
+
|
153 |
+
tinyMCEPopup.close();
|
154 |
+
return true;
|
155 |
+
}
|
156 |
+
|
157 |
+
// Create new table
|
158 |
+
html += '<table';
|
159 |
+
|
160 |
+
html += makeAttrib('id', id);
|
161 |
+
if (!isCssSize(border)) {
|
162 |
+
html += makeAttrib('border', border);
|
163 |
+
}
|
164 |
+
|
165 |
+
html += makeAttrib('cellpadding', cellpadding);
|
166 |
+
html += makeAttrib('cellspacing', cellspacing);
|
167 |
+
html += makeAttrib('data-mce-new', '1');
|
168 |
+
|
169 |
+
if (width && inst.settings.inline_styles) {
|
170 |
+
if (style)
|
171 |
+
style += '; ';
|
172 |
+
|
173 |
+
// Force px
|
174 |
+
if (/^[0-9\.]+$/.test(width))
|
175 |
+
width += 'px';
|
176 |
+
|
177 |
+
style += 'width: ' + width;
|
178 |
+
} else
|
179 |
+
html += makeAttrib('width', width);
|
180 |
+
|
181 |
+
/* if (height) {
|
182 |
+
if (style)
|
183 |
+
style += '; ';
|
184 |
+
|
185 |
+
style += 'height: ' + height;
|
186 |
+
}*/
|
187 |
+
|
188 |
+
//html += makeAttrib('height', height);
|
189 |
+
//html += makeAttrib('bordercolor', bordercolor);
|
190 |
+
//html += makeAttrib('bgcolor', bgcolor);
|
191 |
+
html += makeAttrib('align', align);
|
192 |
+
html += makeAttrib('frame', frame);
|
193 |
+
html += makeAttrib('rules', rules);
|
194 |
+
html += makeAttrib('class', className);
|
195 |
+
html += makeAttrib('style', style);
|
196 |
+
html += makeAttrib('summary', summary);
|
197 |
+
html += makeAttrib('dir', dir);
|
198 |
+
html += makeAttrib('lang', lang);
|
199 |
+
html += '>';
|
200 |
+
|
201 |
+
if (caption) {
|
202 |
+
if (!tinymce.isIE || tinymce.isIE11)
|
203 |
+
html += '<caption><br data-mce-bogus="1"/></caption>';
|
204 |
+
else
|
205 |
+
html += '<caption></caption>';
|
206 |
+
}
|
207 |
+
|
208 |
+
for (var y=0; y<rows; y++) {
|
209 |
+
html += "<tr>";
|
210 |
+
|
211 |
+
for (var x=0; x<cols; x++) {
|
212 |
+
if (!tinymce.isIE || tinymce.isIE11)
|
213 |
+
html += '<td><br data-mce-bogus="1"/></td>';
|
214 |
+
else
|
215 |
+
html += '<td></td>';
|
216 |
+
}
|
217 |
+
|
218 |
+
html += "</tr>";
|
219 |
+
}
|
220 |
+
|
221 |
+
html += "</table>";
|
222 |
+
|
223 |
+
// Move table
|
224 |
+
if (inst.settings.fix_table_elements) {
|
225 |
+
var patt = '';
|
226 |
+
|
227 |
+
inst.focus();
|
228 |
+
inst.selection.setContent('<br class="_mce_marker" />');
|
229 |
+
|
230 |
+
tinymce.each('h1,h2,h3,h4,h5,h6,p'.split(','), function(n) {
|
231 |
+
if (patt)
|
232 |
+
patt += ',';
|
233 |
+
|
234 |
+
patt += n + ' ._mce_marker';
|
235 |
+
});
|
236 |
+
|
237 |
+
tinymce.each(inst.dom.select(patt), function(n) {
|
238 |
+
inst.dom.split(inst.dom.getParent(n, 'h1,h2,h3,h4,h5,h6,p'), n);
|
239 |
+
});
|
240 |
+
|
241 |
+
dom.setOuterHTML(dom.select('br._mce_marker')[0], html);
|
242 |
+
} else
|
243 |
+
inst.execCommand('mceInsertContent', false, html);
|
244 |
+
|
245 |
tinymce.each(dom.select('table[data-mce-new]'), function(node) {
|
246 |
+
var tdorth = dom.select('td,th', node);
|
247 |
+
|
248 |
+
// Fixes a bug in IE where the caret cannot be placed after the table if the table is at the end of the document
|
249 |
+
if (tinymce.isIE && !tinymce.isIE11 && node.nextSibling == null) {
|
250 |
+
if (inst.settings.forced_root_block)
|
251 |
+
dom.insertAfter(dom.create(inst.settings.forced_root_block), node);
|
252 |
+
else
|
253 |
+
dom.insertAfter(dom.create('br', {'data-mce-bogus': '1'}), node);
|
254 |
}
|
255 |
+
|
256 |
+
try {
|
257 |
+
// IE9 might fail to do this selection
|
258 |
+
inst.selection.setCursorLocation(tdorth[0], 0);
|
259 |
+
} catch (ex) {
|
260 |
+
// Ignore
|
261 |
+
}
|
262 |
+
|
263 |
+
dom.setAttrib(node, 'data-mce-new', '');
|
264 |
+
});
|
265 |
+
|
266 |
+
inst.addVisual();
|
267 |
+
inst.execCommand('mceEndUndoLevel', false, {}, {skip_undo: true});
|
268 |
+
|
269 |
+
tinyMCEPopup.close();
|
270 |
+
}
|
271 |
+
|
272 |
+
function makeAttrib(attrib, value) {
|
273 |
+
var formObj = document.forms[0];
|
274 |
+
var valueElm = formObj.elements[attrib];
|
275 |
+
|
276 |
+
if (typeof(value) == "undefined" || value == null) {
|
277 |
+
value = "";
|
278 |
+
|
279 |
+
if (valueElm)
|
280 |
+
value = valueElm.value;
|
281 |
+
}
|
282 |
+
|
283 |
+
if (value == "")
|
284 |
+
return "";
|
285 |
+
|
286 |
+
// XML encode it
|
287 |
+
value = value.replace(/&/g, '&');
|
288 |
+
value = value.replace(/\"/g, '"');
|
289 |
+
value = value.replace(/</g, '<');
|
290 |
+
value = value.replace(/>/g, '>');
|
291 |
+
|
292 |
+
return ' ' + attrib + '="' + value + '"';
|
293 |
+
}
|
294 |
+
|
295 |
+
function init() {
|
296 |
+
tinyMCEPopup.resizeToInnerSize();
|
297 |
+
|
298 |
+
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
|
299 |
+
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
|
300 |
+
document.getElementById('bordercolor_pickcontainer').innerHTML = getColorPickerHTML('bordercolor_pick','bordercolor');
|
301 |
+
document.getElementById('bgcolor_pickcontainer').innerHTML = getColorPickerHTML('bgcolor_pick','bgcolor');
|
302 |
+
|
303 |
+
var cols = 2, rows = 2, border = tinyMCEPopup.getParam('table_default_border', '0'), cellpadding = tinyMCEPopup.getParam('table_default_cellpadding', ''), cellspacing = tinyMCEPopup.getParam('table_default_cellspacing', '');
|
304 |
+
var align = "", width = "", height = "", bordercolor = "", bgcolor = "", className = "";
|
305 |
+
var id = "", summary = "", style = "", dir = "", lang = "", background = "", bgcolor = "", bordercolor = "", rules = "", frame = "";
|
306 |
+
var inst = tinyMCEPopup.editor, dom = inst.dom;
|
307 |
+
var formObj = document.forms[0];
|
308 |
+
var elm = dom.getParent(inst.selection.getNode(), "table");
|
309 |
+
|
310 |
+
// Hide advanced fields that isn't available in the schema
|
311 |
+
tinymce.each("summary id rules dir style frame".split(" "), function(name) {
|
312 |
+
var tr = tinyMCEPopup.dom.getParent(name, "tr") || tinyMCEPopup.dom.getParent("t" + name, "tr");
|
313 |
+
|
314 |
+
if (tr && !tinyMCEPopup.editor.schema.isValid("table", name)) {
|
315 |
+
tr.style.display = 'none';
|
316 |
+
}
|
317 |
+
});
|
318 |
+
|
319 |
+
action = tinyMCEPopup.getWindowArg('action');
|
320 |
+
|
321 |
+
if (!action)
|
322 |
+
action = elm ? "update" : "insert";
|
323 |
+
|
324 |
+
if (elm && action != "insert") {
|
325 |
+
var rowsAr = elm.rows;
|
326 |
+
var cols = 0;
|
327 |
+
for (var i=0; i<rowsAr.length; i++)
|
328 |
+
if (rowsAr[i].cells.length > cols)
|
329 |
+
cols = rowsAr[i].cells.length;
|
330 |
+
|
331 |
+
cols = cols;
|
332 |
+
rows = rowsAr.length;
|
333 |
+
|
334 |
+
st = dom.parseStyle(dom.getAttrib(elm, "style"));
|
335 |
+
border = trimSize(getStyle(elm, 'border', 'borderWidth'));
|
336 |
+
cellpadding = dom.getAttrib(elm, 'cellpadding', "");
|
337 |
+
cellspacing = dom.getAttrib(elm, 'cellspacing', "");
|
338 |
+
width = trimSize(getStyle(elm, 'width', 'width'));
|
339 |
+
height = trimSize(getStyle(elm, 'height', 'height'));
|
340 |
+
bordercolor = convertRGBToHex(getStyle(elm, 'bordercolor', 'borderLeftColor'));
|
341 |
+
bgcolor = convertRGBToHex(getStyle(elm, 'bgcolor', 'backgroundColor'));
|
342 |
+
align = dom.getAttrib(elm, 'align', align);
|
343 |
+
frame = dom.getAttrib(elm, 'frame');
|
344 |
+
rules = dom.getAttrib(elm, 'rules');
|
345 |
+
className = tinymce.trim(dom.getAttrib(elm, 'class').replace(/mceItem.+/g, ''));
|
346 |
+
id = dom.getAttrib(elm, 'id');
|
347 |
+
summary = dom.getAttrib(elm, 'summary');
|
348 |
+
style = dom.serializeStyle(st);
|
349 |
+
dir = dom.getAttrib(elm, 'dir');
|
350 |
+
lang = dom.getAttrib(elm, 'lang');
|
351 |
+
background = getStyle(elm, 'background', 'backgroundImage').replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
|
352 |
+
formObj.caption.checked = elm.getElementsByTagName('caption').length > 0;
|
353 |
+
|
354 |
+
orgTableWidth = width;
|
355 |
+
orgTableHeight = height;
|
356 |
+
|
357 |
+
action = "update";
|
358 |
+
formObj.insert.value = inst.getLang('update');
|
359 |
+
}
|
360 |
+
|
361 |
+
addClassesToList('class', "table_styles");
|
362 |
+
TinyMCE_EditableSelects.init();
|
363 |
+
|
364 |
+
// Update form
|
365 |
+
selectByValue(formObj, 'align', align);
|
366 |
+
selectByValue(formObj, 'tframe', frame);
|
367 |
+
selectByValue(formObj, 'rules', rules);
|
368 |
+
selectByValue(formObj, 'class', className, true, true);
|
369 |
+
formObj.cols.value = cols;
|
370 |
+
formObj.rows.value = rows;
|
371 |
+
formObj.border.value = border;
|
372 |
+
formObj.cellpadding.value = cellpadding;
|
373 |
+
formObj.cellspacing.value = cellspacing;
|
374 |
+
formObj.width.value = width;
|
375 |
+
formObj.height.value = height;
|
376 |
+
formObj.bordercolor.value = bordercolor;
|
377 |
+
formObj.bgcolor.value = bgcolor;
|
378 |
+
formObj.id.value = id;
|
379 |
+
formObj.summary.value = summary;
|
380 |
+
formObj.style.value = style;
|
381 |
+
formObj.dir.value = dir;
|
382 |
+
formObj.lang.value = lang;
|
383 |
+
formObj.backgroundimage.value = background;
|
384 |
+
|
385 |
+
updateColor('bordercolor_pick', 'bordercolor');
|
386 |
+
updateColor('bgcolor_pick', 'bgcolor');
|
387 |
+
|
388 |
+
// Resize some elements
|
389 |
+
if (isVisible('backgroundimagebrowser'))
|
390 |
+
document.getElementById('backgroundimage').style.width = '180px';
|
391 |
+
|
392 |
+
// Disable some fields in update mode
|
393 |
+
if (action == "update") {
|
394 |
+
formObj.cols.disabled = true;
|
395 |
+
formObj.rows.disabled = true;
|
396 |
+
}
|
397 |
+
}
|
398 |
+
|
399 |
+
function changedSize() {
|
400 |
+
var formObj = document.forms[0];
|
401 |
+
var st = dom.parseStyle(formObj.style.value);
|
402 |
+
|
403 |
+
/* var width = formObj.width.value;
|
404 |
+
if (width != "")
|
405 |
+
st['width'] = tinyMCEPopup.getParam("inline_styles") ? getCSSSize(width) : "";
|
406 |
+
else
|
407 |
+
st['width'] = "";*/
|
408 |
+
|
409 |
+
var height = formObj.height.value;
|
410 |
+
if (height != "")
|
411 |
+
st['height'] = getCSSSize(height);
|
412 |
+
else
|
413 |
+
st['height'] = "";
|
414 |
+
|
415 |
+
formObj.style.value = dom.serializeStyle(st);
|
416 |
+
}
|
417 |
+
|
418 |
+
function isCssSize(value) {
|
419 |
+
return /^[0-9.]+(%|in|cm|mm|em|ex|pt|pc|px)$/.test(value);
|
420 |
+
}
|
421 |
+
|
422 |
+
function cssSize(value, def) {
|
423 |
+
value = tinymce.trim(value || def);
|
424 |
+
|
425 |
+
if (!isCssSize(value)) {
|
426 |
+
return parseInt(value, 10) + 'px';
|
427 |
+
}
|
428 |
+
|
429 |
+
return value;
|
430 |
+
}
|
431 |
+
|
432 |
+
function changedBackgroundImage() {
|
433 |
+
var formObj = document.forms[0];
|
434 |
+
var st = dom.parseStyle(formObj.style.value);
|
435 |
+
|
436 |
+
st['background-image'] = "url('" + formObj.backgroundimage.value + "')";
|
437 |
+
|
438 |
+
formObj.style.value = dom.serializeStyle(st);
|
439 |
+
}
|
440 |
+
|
441 |
+
function changedBorder() {
|
442 |
+
var formObj = document.forms[0];
|
443 |
+
var st = dom.parseStyle(formObj.style.value);
|
444 |
+
|
445 |
+
// Update border width if the element has a color
|
446 |
+
if (formObj.border.value != "" && (isCssSize(formObj.border.value) || formObj.bordercolor.value != ""))
|
447 |
+
st['border-width'] = cssSize(formObj.border.value);
|
448 |
+
else {
|
449 |
+
if (!formObj.border.value) {
|
450 |
+
st['border'] = '';
|
451 |
+
st['border-width'] = '';
|
452 |
+
}
|
453 |
+
}
|
454 |
+
|
455 |
+
formObj.style.value = dom.serializeStyle(st);
|
456 |
+
}
|
457 |
+
|
458 |
+
function changedColor() {
|
459 |
+
var formObj = document.forms[0];
|
460 |
+
var st = dom.parseStyle(formObj.style.value);
|
461 |
+
|
462 |
+
st['background-color'] = formObj.bgcolor.value;
|
463 |
+
|
464 |
+
if (formObj.bordercolor.value != "") {
|
465 |
+
st['border-color'] = formObj.bordercolor.value;
|
466 |
+
|
467 |
+
// Add border-width if it's missing
|
468 |
+
if (!st['border-width'])
|
469 |
+
st['border-width'] = cssSize(formObj.border.value, 1);
|
470 |
+
}
|
471 |
+
|
472 |
+
formObj.style.value = dom.serializeStyle(st);
|
473 |
+
}
|
474 |
+
|
475 |
+
function changedStyle() {
|
476 |
+
var formObj = document.forms[0];
|
477 |
+
var st = dom.parseStyle(formObj.style.value);
|
478 |
+
|
479 |
+
if (st['background-image'])
|
480 |
+
formObj.backgroundimage.value = st['background-image'].replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
|
481 |
+
else
|
482 |
+
formObj.backgroundimage.value = '';
|
483 |
+
|
484 |
+
if (st['width'])
|
485 |
+
formObj.width.value = trimSize(st['width']);
|
486 |
+
|
487 |
+
if (st['height'])
|
488 |
+
formObj.height.value = trimSize(st['height']);
|
489 |
+
|
490 |
+
if (st['background-color']) {
|
491 |
+
formObj.bgcolor.value = st['background-color'];
|
492 |
+
updateColor('bgcolor_pick','bgcolor');
|
493 |
+
}
|
494 |
+
|
495 |
+
if (st['border-color']) {
|
496 |
+
formObj.bordercolor.value = st['border-color'];
|
497 |
+
updateColor('bordercolor_pick','bordercolor');
|
498 |
+
}
|
499 |
+
}
|
500 |
+
|
501 |
+
tinyMCEPopup.onInit.add(init);
|
mce/table/langs/de_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('de.table_dlg',{"rules_border":"alle 4 Seiten (Border)","rules_box":"alle 4 Seiten (Box)","rules_vsides":"links und rechts","rules_rhs":"nur rechts","rules_lhs":"nur links","rules_hsides":"oben und unten","rules_below":"nur unten","rules_above":"nur oben","rules_void":"keins",rules:"Gitter","frame_all":"zwischen allen Zellen","frame_cols":"zwischen Spalten","frame_rows":"zwischen Zeilen","frame_groups":"zwischen Gruppen","frame_none":"keine",frame:"Rahmen",caption:"Beschriftung der Tabelle","missing_scope":"
|
1 |
+
tinyMCE.addI18n('de.table_dlg',{"rules_border":"alle 4 Seiten (Border)","rules_box":"alle 4 Seiten (Box)","rules_vsides":"links und rechts","rules_rhs":"nur rechts","rules_lhs":"nur links","rules_hsides":"oben und unten","rules_below":"nur unten","rules_above":"nur oben","rules_void":"keins",rules:"Gitter","frame_all":"zwischen allen Zellen","frame_cols":"zwischen Spalten","frame_rows":"zwischen Zeilen","frame_groups":"zwischen Gruppen","frame_none":"keine",frame:"Rahmen",caption:"Beschriftung der Tabelle","missing_scope":"Soll f\u00fcr diese \u00dcberschrift wirklich kein Bereich angegeben werden? Benutzer mit k\u00f6rperlichen Einschr\u00e4nkungen k\u00f6nnten Schwierigkeiten haben, den Inhalt der Tabelle zu verstehen.","cell_limit":"Die maximale Zellenzahl von {$cells} wurde \u00fcberschritten.","row_limit":"Die maximale Zeilenzahl von {$rows} wurde \u00fcberschritten.","col_limit":"Die maximale Spaltenzahl von {$cols} wurde \u00fcberschritten.",colgroup:"Horizontal gruppieren",rowgroup:"Vertikal gruppieren",scope:"Bezug",tfoot:"Tabellenfu\u00df",tbody:"Tabelleninhalt",thead:"Tabellenkopf","row_all":"Alle Zeilen ver\u00e4ndern","row_even":"Gerade Zeilen ver\u00e4ndern","row_odd":"Ungerade Zeilen ver\u00e4ndern","row_row":"Diese Zeile ver\u00e4ndern","cell_all":"Alle Zellen der Tabelle ver\u00e4ndern","cell_row":"Alle Zellen in dieser Zeile ver\u00e4ndern","cell_cell":"Diese Zelle ver\u00e4ndern",th:"\u00dcberschrift",td:"Textzelle",summary:"Zusammenfassung",bgimage:"Hintergrundbild",rtl:"Rechts nach links",ltr:"Links nach rechts",mime:"MIME-Type des Inhalts",langcode:"Sprachcode",langdir:"Schriftrichtung",style:"Format",id:"ID","merge_cells_title":"Zellen vereinen",bgcolor:"Hintergrundfarbe",bordercolor:"Rahmenfarbe","align_bottom":"Unten","align_top":"Oben",valign:"Vertikale Ausrichtung","cell_type":"Zellentyp","cell_title":"Eigenschaften der Zelle","row_title":"Eigenschaften der Zeile","align_middle":"Mittig","align_right":"Rechts","align_left":"Links","align_default":"Standard",align:"Ausrichtung",border:"Rahmen",cellpadding:"Abstand innerhalb der Zellen",cellspacing:"Zellenabstand",rows:"Zeilen",cols:"Spalten",height:"H\u00f6he",width:"Breite",title:"Tabelle einf\u00fcgen/bearbeiten",rowtype:"Gruppierung","advanced_props":"Erweiterte Einstellungen","general_props":"Allgemeine Einstellungen","advanced_tab":"Erweitert","general_tab":"Allgemein","cell_col":"Alle Zellen in dieser Spalte aktualisieren"});
|
mce/table/langs/langs.php
CHANGED
@@ -1,9 +1,12 @@
|
|
1 |
-
<?php
|
2 |
-
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
-
|
4 |
-
if ( is_file($lang_file) &&
|
5 |
-
$
|
6 |
-
|
7 |
-
|
8 |
-
$strings =
|
9 |
-
}
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
+
|
4 |
+
if ( ! is_file( $lang_file ) && defined( 'TINYMCE_ADVANCED_LANGUAGES_PATH' ) )
|
5 |
+
$lang_file = TINYMCE_ADVANCED_LANGUAGES_PATH . 'table/langs/' . $mce_locale . '_dlg.js';
|
6 |
+
|
7 |
+
if ( is_file( $lang_file ) && is_readable( $lang_file ) ) {
|
8 |
+
$strings = tdav_get_file( $lang_file );
|
9 |
+
} else {
|
10 |
+
$strings = tdav_get_file( dirname(__FILE__) . '/en_dlg.js' );
|
11 |
+
$strings = preg_replace( '/([\'"])en\./', '$1' . $mce_locale . '.', $strings, 1 );
|
12 |
+
}
|
mce/table/langs/zh_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('zh.table_dlg',{"rules_border":"\
|
1 |
+
tinyMCE.addI18n('zh.table_dlg',{"rules_border":"\u8fb9\u6846","rules_box":"\u65b9\u76d2","rules_vsides":"\u5782\u76f4","rules_rhs":"\u53f3\u8fb9","rules_lhs":"\u5de6\u8fb9","rules_hsides":"\u6c34\u5e73","rules_below":"\u4e0b","rules_above":"\u4e0a","rules_void":"\u7a7a",rules:"\u89c4\u5219","frame_all":"\u5168\u90e8","frame_cols":"\u5217\u8868\u5934","frame_rows":"\u884c\u8868\u5934","frame_groups":"\u7fa4\u7ec4","frame_none":"\u65e0",frame:"\u6846\u67b6",caption:"\u8868\u683c\u6807\u9898","missing_scope":"\u60a8\u786e\u5b9a\u4e0d\u4e3a\u8868\u5934\u5355\u5143\u683c\u6307\u5b9a\u4e00\u4e2a\u8303\u56f4\u5417\uff1f\u5982\u679c\u4e0d\u6307\u5b9a\uff0c\u5bf9\u4f7f\u7528\u975e\u53ef\u89c6\u6d4f\u89c8\u5668\u7684\u4f7f\u7528\u8005\u5c06\u66f4\u96be\u9605\u8bfb\u6216\u7406\u89e3\u8868\u683c\u5185\u5bb9\u3002","cell_limit":"\u5df2\u8fbe\u5230\u6700\u591a {$cells} \u4e2a\u5355\u5143\u683c\u7684\u4e0a\u9650\u3002","row_limit":"\u5df2\u8fbe\u5230\u6700\u591a {$rows} \u884c\u5355\u5143\u683c\u7684\u4e0a\u9650\u3002","col_limit":"\u5df2\u8fbe\u5230\u6700\u591a {$cols} \u5217\u5355\u5143\u683c\u7684\u4e0a\u9650\u3002",colgroup:"\u5217\u7ec4\u8868\u5934",rowgroup:"\u884c\u7ec4\u8868\u5934",scope:"\u8868\u5934\u8303\u56f4",tfoot:"\u8868\u5c3e",tbody:"\u8868\u683c\u4e3b\u4f53",thead:"\u8868\u5934","row_all":"\u66f4\u65b0\u6240\u6709\u884c","row_even":"\u66f4\u65b0\u5076\u6570\u884c","row_odd":"\u66f4\u65b0\u5947\u6570\u884c","row_row":"\u66f4\u65b0\u5f53\u524d\u884c","cell_all":"\u66f4\u65b0\u6240\u6709\u5355\u5143\u683c","cell_row":"\u66f4\u65b0\u884c\u4e2d\u6240\u6709\u5355\u5143\u683c","cell_cell":"\u66f4\u65b0\u5f53\u524d\u5355\u5143\u683c",th:"\u8868\u5934",td:"\u8868\u683c\u5185\u5bb9",summary:"\u8868\u683c\u6458\u8981",bgimage:"\u80cc\u666f\u56fe\u7247",rtl:"\u4ece\u53f3\u5230\u5de6",ltr:"\u4ece\u5de6\u5230\u53f3",mime:"\u76ee\u6807MIME\u7c7b\u578b",langcode:"\u8bed\u8a00\u4ee3\u7801",langdir:"\u8bed\u8a00\u4e66\u5199\u65b9\u5411",style:"\u6837\u5f0f",id:"ID","merge_cells_title":"\u5408\u5e76\u5355\u5143\u683c",bgcolor:"\u80cc\u666f\u989c\u8272",bordercolor:"\u8fb9\u6846\u989c\u8272","align_bottom":"\u9760\u4e0b","align_top":"\u9760\u4e0a",valign:"\u5782\u76f4\u5bf9\u9f50","cell_type":"\u5355\u5143\u683c\u7c7b\u578b","cell_title":"\u5355\u5143\u683c\u5c5e\u6027","row_title":"\u884c\u5c5e\u6027","align_middle":"\u5c45\u4e2d\u5bf9\u9f50","align_right":"\u9760\u53f3\u5bf9\u9f50","align_left":"\u9760\u5de6\u5bf9\u9f50","align_default":"\u9ed8\u8ba4",align:"\u5bf9\u9f50\u65b9\u5411",border:"\u8fb9\u6846",cellpadding:"\u5355\u5143\u683c\u8fb9\u8ddd",cellspacing:"\u5355\u5143\u683c\u95f4\u8ddd",rows:"\u884c\u6570",cols:"\u5217\u6570",height:"\u9ad8",width:"\u5bbd",title:"\u63d2\u5165/\u7f16\u8f91\u5355\u5143\u683c",rowtype:"\u884c\u7c7b\u578b","advanced_props":"\u9ad8\u7ea7\u5c5e\u6027","general_props":"\u666e\u901a\u5c5e\u6027","advanced_tab":"\u9ad8\u7ea7","general_tab":"\u666e\u901a","cell_col":"\u66f4\u65b0\u5217\u4e2d\u6240\u6709\u5355\u5143\u683c"});
|
mce/table/merge_cells.htm
CHANGED
@@ -1,32 +1,32 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#table_dlg.merge_cells_title}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/validate.js?ver=
|
8 |
-
<script type="text/javascript" src="js/merge_cells.js?ver=
|
9 |
-
</head>
|
10 |
-
<body style="margin: 8px" role="application">
|
11 |
-
<form onsubmit="MergeCellsDialog.merge();return false;" action="#">
|
12 |
-
<fieldset>
|
13 |
-
<legend>{#table_dlg.merge_cells_title}</legend>
|
14 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="3" width="100%">
|
15 |
-
<tr>
|
16 |
-
<td><label for="numcols">{#table_dlg.cols}</label>:</td>
|
17 |
-
<td align="right"><input type="text" id="numcols" name="numcols" value="" class="number min1 mceFocus" style="width: 30px" aria-required="true" /></td>
|
18 |
-
</tr>
|
19 |
-
<tr>
|
20 |
-
<td><label for="numrows">{#table_dlg.rows}</label>:</td>
|
21 |
-
<td align="right"><input type="text" id="numrows" name="numrows" value="" class="number min1" style="width: 30px" aria-required="true" /></td>
|
22 |
-
</tr>
|
23 |
-
</table>
|
24 |
-
</fieldset>
|
25 |
-
|
26 |
-
<div class="mceActionPanel">
|
27 |
-
<input type="submit" id="insert" name="insert" value="{#update}" />
|
28 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
29 |
-
</div>
|
30 |
-
</form>
|
31 |
-
</body>
|
32 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#table_dlg.merge_cells_title}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/validate.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="js/merge_cells.js?ver=359"></script>
|
9 |
+
</head>
|
10 |
+
<body style="margin: 8px" role="application">
|
11 |
+
<form onsubmit="MergeCellsDialog.merge();return false;" action="#">
|
12 |
+
<fieldset>
|
13 |
+
<legend>{#table_dlg.merge_cells_title}</legend>
|
14 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="3" width="100%">
|
15 |
+
<tr>
|
16 |
+
<td><label for="numcols">{#table_dlg.cols}</label>:</td>
|
17 |
+
<td align="right"><input type="text" id="numcols" name="numcols" value="" class="number min1 mceFocus" style="width: 30px" aria-required="true" /></td>
|
18 |
+
</tr>
|
19 |
+
<tr>
|
20 |
+
<td><label for="numrows">{#table_dlg.rows}</label>:</td>
|
21 |
+
<td align="right"><input type="text" id="numrows" name="numrows" value="" class="number min1" style="width: 30px" aria-required="true" /></td>
|
22 |
+
</tr>
|
23 |
+
</table>
|
24 |
+
</fieldset>
|
25 |
+
|
26 |
+
<div class="mceActionPanel">
|
27 |
+
<input type="submit" id="insert" name="insert" value="{#update}" />
|
28 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
29 |
+
</div>
|
30 |
+
</form>
|
31 |
+
</body>
|
32 |
+
</html>
|
mce/table/row.htm
CHANGED
@@ -1,158 +1,158 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#table_dlg.row_title}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/validate.js?ver=
|
9 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
10 |
-
<script type="text/javascript" src="js/row.js?ver=
|
11 |
-
<link href="css/row.css?ver=
|
12 |
-
</head>
|
13 |
-
<body id="tablerow" style="display: none" role="application">
|
14 |
-
<form onsubmit="updateAction();return false;" action="#">
|
15 |
-
<div class="tabs">
|
16 |
-
<ul>
|
17 |
-
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#table_dlg.general_tab}</a></span></li>
|
18 |
-
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#table_dlg.advanced_tab}</a></span></li>
|
19 |
-
</ul>
|
20 |
-
</div>
|
21 |
-
|
22 |
-
<div class="panel_wrapper">
|
23 |
-
<div id="general_panel" class="panel current">
|
24 |
-
<fieldset>
|
25 |
-
<legend>{#table_dlg.general_props}</legend>
|
26 |
-
|
27 |
-
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
|
28 |
-
<tr>
|
29 |
-
<td><label for="rowtype">{#table_dlg.rowtype}</label></td>
|
30 |
-
<td class="col2">
|
31 |
-
<select id="rowtype" name="rowtype" class="mceFocus" onChange="changedRowType();">
|
32 |
-
<option value="thead">{#table_dlg.thead}</option>
|
33 |
-
<option value="tbody">{#table_dlg.tbody}</option>
|
34 |
-
<option value="tfoot">{#table_dlg.tfoot}</option>
|
35 |
-
</select>
|
36 |
-
</td>
|
37 |
-
</tr>
|
38 |
-
|
39 |
-
<tr>
|
40 |
-
<td><label for="align">{#table_dlg.align}</label></td>
|
41 |
-
<td class="col2">
|
42 |
-
<select id="align" name="align">
|
43 |
-
<option value="">{#not_set}</option>
|
44 |
-
<option value="center">{#table_dlg.align_middle}</option>
|
45 |
-
<option value="left">{#table_dlg.align_left}</option>
|
46 |
-
<option value="right">{#table_dlg.align_right}</option>
|
47 |
-
</select>
|
48 |
-
</td>
|
49 |
-
</tr>
|
50 |
-
|
51 |
-
<tr>
|
52 |
-
<td><label for="valign">{#table_dlg.valign}</label></td>
|
53 |
-
<td class="col2">
|
54 |
-
<select id="valign" name="valign">
|
55 |
-
<option value="">{#not_set}</option>
|
56 |
-
<option value="top">{#table_dlg.align_top}</option>
|
57 |
-
<option value="middle">{#table_dlg.align_middle}</option>
|
58 |
-
<option value="bottom">{#table_dlg.align_bottom}</option>
|
59 |
-
</select>
|
60 |
-
</td>
|
61 |
-
</tr>
|
62 |
-
|
63 |
-
<tr id="styleSelectRow">
|
64 |
-
<td><label for="class">{#class_name}</label></td>
|
65 |
-
<td class="col2">
|
66 |
-
<select id="class" name="class" class="mceEditableSelect">
|
67 |
-
<option value="" selected="selected">{#not_set}</option>
|
68 |
-
</select>
|
69 |
-
</td>
|
70 |
-
</tr>
|
71 |
-
|
72 |
-
<tr>
|
73 |
-
<td><label for="height">{#table_dlg.height}</label></td>
|
74 |
-
<td class="col2"><input name="height" type="text" id="height" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
|
75 |
-
</tr>
|
76 |
-
</table>
|
77 |
-
</fieldset>
|
78 |
-
</div>
|
79 |
-
|
80 |
-
<div id="advanced_panel" class="panel">
|
81 |
-
<fieldset>
|
82 |
-
<legend>{#table_dlg.advanced_props}</legend>
|
83 |
-
|
84 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
85 |
-
<tr>
|
86 |
-
<td class="column1"><label for="id">{#table_dlg.id}</label></td>
|
87 |
-
<td><input id="id" name="id" type="text" value="" style="width: 200px" /></td>
|
88 |
-
</tr>
|
89 |
-
|
90 |
-
<tr>
|
91 |
-
<td><label for="style">{#table_dlg.style}</label></td>
|
92 |
-
<td><input type="text" id="style" name="style" value="" style="width: 200px;" onchange="changedStyle();" /></td>
|
93 |
-
</tr>
|
94 |
-
|
95 |
-
<tr>
|
96 |
-
<td class="column1"><label for="dir">{#table_dlg.langdir}</label></td>
|
97 |
-
<td>
|
98 |
-
<select id="dir" name="dir" style="width: 200px">
|
99 |
-
<option value="">{#not_set}</option>
|
100 |
-
<option value="ltr">{#table_dlg.ltr}</option>
|
101 |
-
<option value="rtl">{#table_dlg.rtl}</option>
|
102 |
-
</select>
|
103 |
-
</td>
|
104 |
-
</tr>
|
105 |
-
|
106 |
-
<tr>
|
107 |
-
<td class="column1"><label for="lang">{#table_dlg.langcode}</label></td>
|
108 |
-
<td>
|
109 |
-
<input id="lang" name="lang" type="text" value="" style="width: 200px" />
|
110 |
-
</td>
|
111 |
-
</tr>
|
112 |
-
|
113 |
-
<tr>
|
114 |
-
<td class="column1"><label for="backgroundimage">{#table_dlg.bgimage}</label></td>
|
115 |
-
<td>
|
116 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
117 |
-
<tr>
|
118 |
-
<td><input id="backgroundimage" name="backgroundimage" type="text" value="" style="width: 200px" onchange="changedBackgroundImage();" /></td>
|
119 |
-
<td id="backgroundimagebrowsercontainer"> </td>
|
120 |
-
</tr>
|
121 |
-
</table>
|
122 |
-
</td>
|
123 |
-
</tr>
|
124 |
-
|
125 |
-
<tr>
|
126 |
-
<td class="column1"><label for="bgcolor" id="bgcolor_label">{#table_dlg.bgcolor}</label></td>
|
127 |
-
<td>
|
128 |
-
<span role="group" aria-labelledby="bgcolor_label">
|
129 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
130 |
-
<tr>
|
131 |
-
<td><input id="bgcolor" name="bgcolor" type="text" value="" size="9" onchange="updateColor('bgcolor_pick','bgcolor');changedColor();" /></td>
|
132 |
-
<td id="bgcolor_pickcontainer"> </td>
|
133 |
-
</tr>
|
134 |
-
</table>
|
135 |
-
</span>
|
136 |
-
</td>
|
137 |
-
</tr>
|
138 |
-
</table>
|
139 |
-
</fieldset>
|
140 |
-
</div>
|
141 |
-
</div>
|
142 |
-
|
143 |
-
<div class="mceActionPanel">
|
144 |
-
<div>
|
145 |
-
<select id="action" name="action">
|
146 |
-
<option value="row">{#table_dlg.row_row}</option>
|
147 |
-
<option value="odd">{#table_dlg.row_odd}</option>
|
148 |
-
<option value="even">{#table_dlg.row_even}</option>
|
149 |
-
<option value="all">{#table_dlg.row_all}</option>
|
150 |
-
</select>
|
151 |
-
</div>
|
152 |
-
|
153 |
-
<input type="submit" id="insert" name="insert" value="{#update}" />
|
154 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
155 |
-
</div>
|
156 |
-
</form>
|
157 |
-
</body>
|
158 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#table_dlg.row_title}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/validate.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
10 |
+
<script type="text/javascript" src="js/row.js?ver=359"></script>
|
11 |
+
<link href="css/row.css?ver=359" rel="stylesheet" type="text/css" />
|
12 |
+
</head>
|
13 |
+
<body id="tablerow" style="display: none" role="application">
|
14 |
+
<form onsubmit="updateAction();return false;" action="#">
|
15 |
+
<div class="tabs">
|
16 |
+
<ul>
|
17 |
+
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#table_dlg.general_tab}</a></span></li>
|
18 |
+
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#table_dlg.advanced_tab}</a></span></li>
|
19 |
+
</ul>
|
20 |
+
</div>
|
21 |
+
|
22 |
+
<div class="panel_wrapper">
|
23 |
+
<div id="general_panel" class="panel current">
|
24 |
+
<fieldset>
|
25 |
+
<legend>{#table_dlg.general_props}</legend>
|
26 |
+
|
27 |
+
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
|
28 |
+
<tr>
|
29 |
+
<td><label for="rowtype">{#table_dlg.rowtype}</label></td>
|
30 |
+
<td class="col2">
|
31 |
+
<select id="rowtype" name="rowtype" class="mceFocus" onChange="changedRowType();">
|
32 |
+
<option value="thead">{#table_dlg.thead}</option>
|
33 |
+
<option value="tbody">{#table_dlg.tbody}</option>
|
34 |
+
<option value="tfoot">{#table_dlg.tfoot}</option>
|
35 |
+
</select>
|
36 |
+
</td>
|
37 |
+
</tr>
|
38 |
+
|
39 |
+
<tr>
|
40 |
+
<td><label for="align">{#table_dlg.align}</label></td>
|
41 |
+
<td class="col2">
|
42 |
+
<select id="align" name="align">
|
43 |
+
<option value="">{#not_set}</option>
|
44 |
+
<option value="center">{#table_dlg.align_middle}</option>
|
45 |
+
<option value="left">{#table_dlg.align_left}</option>
|
46 |
+
<option value="right">{#table_dlg.align_right}</option>
|
47 |
+
</select>
|
48 |
+
</td>
|
49 |
+
</tr>
|
50 |
+
|
51 |
+
<tr>
|
52 |
+
<td><label for="valign">{#table_dlg.valign}</label></td>
|
53 |
+
<td class="col2">
|
54 |
+
<select id="valign" name="valign">
|
55 |
+
<option value="">{#not_set}</option>
|
56 |
+
<option value="top">{#table_dlg.align_top}</option>
|
57 |
+
<option value="middle">{#table_dlg.align_middle}</option>
|
58 |
+
<option value="bottom">{#table_dlg.align_bottom}</option>
|
59 |
+
</select>
|
60 |
+
</td>
|
61 |
+
</tr>
|
62 |
+
|
63 |
+
<tr id="styleSelectRow">
|
64 |
+
<td><label for="class">{#class_name}</label></td>
|
65 |
+
<td class="col2">
|
66 |
+
<select id="class" name="class" class="mceEditableSelect">
|
67 |
+
<option value="" selected="selected">{#not_set}</option>
|
68 |
+
</select>
|
69 |
+
</td>
|
70 |
+
</tr>
|
71 |
+
|
72 |
+
<tr>
|
73 |
+
<td><label for="height">{#table_dlg.height}</label></td>
|
74 |
+
<td class="col2"><input name="height" type="text" id="height" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
|
75 |
+
</tr>
|
76 |
+
</table>
|
77 |
+
</fieldset>
|
78 |
+
</div>
|
79 |
+
|
80 |
+
<div id="advanced_panel" class="panel">
|
81 |
+
<fieldset>
|
82 |
+
<legend>{#table_dlg.advanced_props}</legend>
|
83 |
+
|
84 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
85 |
+
<tr>
|
86 |
+
<td class="column1"><label for="id">{#table_dlg.id}</label></td>
|
87 |
+
<td><input id="id" name="id" type="text" value="" style="width: 200px" /></td>
|
88 |
+
</tr>
|
89 |
+
|
90 |
+
<tr>
|
91 |
+
<td><label for="style">{#table_dlg.style}</label></td>
|
92 |
+
<td><input type="text" id="style" name="style" value="" style="width: 200px;" onchange="changedStyle();" /></td>
|
93 |
+
</tr>
|
94 |
+
|
95 |
+
<tr>
|
96 |
+
<td class="column1"><label for="dir">{#table_dlg.langdir}</label></td>
|
97 |
+
<td>
|
98 |
+
<select id="dir" name="dir" style="width: 200px">
|
99 |
+
<option value="">{#not_set}</option>
|
100 |
+
<option value="ltr">{#table_dlg.ltr}</option>
|
101 |
+
<option value="rtl">{#table_dlg.rtl}</option>
|
102 |
+
</select>
|
103 |
+
</td>
|
104 |
+
</tr>
|
105 |
+
|
106 |
+
<tr>
|
107 |
+
<td class="column1"><label for="lang">{#table_dlg.langcode}</label></td>
|
108 |
+
<td>
|
109 |
+
<input id="lang" name="lang" type="text" value="" style="width: 200px" />
|
110 |
+
</td>
|
111 |
+
</tr>
|
112 |
+
|
113 |
+
<tr>
|
114 |
+
<td class="column1"><label for="backgroundimage">{#table_dlg.bgimage}</label></td>
|
115 |
+
<td>
|
116 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
117 |
+
<tr>
|
118 |
+
<td><input id="backgroundimage" name="backgroundimage" type="text" value="" style="width: 200px" onchange="changedBackgroundImage();" /></td>
|
119 |
+
<td id="backgroundimagebrowsercontainer"> </td>
|
120 |
+
</tr>
|
121 |
+
</table>
|
122 |
+
</td>
|
123 |
+
</tr>
|
124 |
+
|
125 |
+
<tr>
|
126 |
+
<td class="column1"><label for="bgcolor" id="bgcolor_label">{#table_dlg.bgcolor}</label></td>
|
127 |
+
<td>
|
128 |
+
<span role="group" aria-labelledby="bgcolor_label">
|
129 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
130 |
+
<tr>
|
131 |
+
<td><input id="bgcolor" name="bgcolor" type="text" value="" size="9" onchange="updateColor('bgcolor_pick','bgcolor');changedColor();" /></td>
|
132 |
+
<td id="bgcolor_pickcontainer"> </td>
|
133 |
+
</tr>
|
134 |
+
</table>
|
135 |
+
</span>
|
136 |
+
</td>
|
137 |
+
</tr>
|
138 |
+
</table>
|
139 |
+
</fieldset>
|
140 |
+
</div>
|
141 |
+
</div>
|
142 |
+
|
143 |
+
<div class="mceActionPanel">
|
144 |
+
<div>
|
145 |
+
<select id="action" name="action">
|
146 |
+
<option value="row">{#table_dlg.row_row}</option>
|
147 |
+
<option value="odd">{#table_dlg.row_odd}</option>
|
148 |
+
<option value="even">{#table_dlg.row_even}</option>
|
149 |
+
<option value="all">{#table_dlg.row_all}</option>
|
150 |
+
</select>
|
151 |
+
</div>
|
152 |
+
|
153 |
+
<input type="submit" id="insert" name="insert" value="{#update}" />
|
154 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
155 |
+
</div>
|
156 |
+
</form>
|
157 |
+
</body>
|
158 |
+
</html>
|
mce/table/table.htm
CHANGED
@@ -1,188 +1,188 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#table_dlg.title}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/validate.js?ver=
|
9 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
10 |
-
<script type="text/javascript" src="js/table.js?ver=
|
11 |
-
<link href="css/table.css?ver=
|
12 |
-
</head>
|
13 |
-
<body id="table" style="display: none" role="application" aria-labelledby="app_title">
|
14 |
-
<span style="display:none;" id="app_title">{#table_dlg.title}</span>
|
15 |
-
<form onsubmit="insertTable();return false;" action="#">
|
16 |
-
<div class="tabs">
|
17 |
-
<ul>
|
18 |
-
<li id="general_tab" aria-controls="general_panel" class="current"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#table_dlg.general_tab}</a></span></li>
|
19 |
-
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#table_dlg.advanced_tab}</a></span></li>
|
20 |
-
</ul>
|
21 |
-
</div>
|
22 |
-
|
23 |
-
<div class="panel_wrapper">
|
24 |
-
<div id="general_panel" class="panel current">
|
25 |
-
<fieldset>
|
26 |
-
<legend>{#table_dlg.general_props}</legend>
|
27 |
-
<table role="presentation" border="0" cellpadding="4" cellspacing="0" width="100%">
|
28 |
-
<tr>
|
29 |
-
<td><label id="colslabel" for="cols">{#table_dlg.cols}</label></td>
|
30 |
-
<td><input id="cols" name="cols" type="text" value="" size="3" maxlength="3" class="required number min1 mceFocus" aria-required="true" /></td>
|
31 |
-
<td><label id="rowslabel" for="rows">{#table_dlg.rows}</label></td>
|
32 |
-
<td><input id="rows" name="rows" type="text" value="" size="3" maxlength="3" class="required number min1" aria-required="true" /></td>
|
33 |
-
</tr>
|
34 |
-
<tr>
|
35 |
-
<td><label id="cellpaddinglabel" for="cellpadding">{#table_dlg.cellpadding}</label></td>
|
36 |
-
<td><input id="cellpadding" name="cellpadding" type="text" value="" size="3" maxlength="3" class="number" /></td>
|
37 |
-
<td><label id="cellspacinglabel" for="cellspacing">{#table_dlg.cellspacing}</label></td>
|
38 |
-
<td><input id="cellspacing" name="cellspacing" type="text" value="" size="3" maxlength="3" class="number" /></td>
|
39 |
-
</tr>
|
40 |
-
<tr>
|
41 |
-
<td><label id="alignlabel" for="align">{#table_dlg.align}</label></td>
|
42 |
-
<td><select id="align" name="align">
|
43 |
-
<option value="">{#not_set}</option>
|
44 |
-
<option value="center">{#table_dlg.align_middle}</option>
|
45 |
-
<option value="left">{#table_dlg.align_left}</option>
|
46 |
-
<option value="right">{#table_dlg.align_right}</option>
|
47 |
-
</select></td>
|
48 |
-
<td><label id="borderlabel" for="border">{#table_dlg.border}</label></td>
|
49 |
-
<td><input id="border" name="border" type="text" value="" size="3" maxlength="5" onchange="changedBorder();" class="size" /></td>
|
50 |
-
</tr>
|
51 |
-
<tr id="width_row">
|
52 |
-
<td><label id="widthlabel" for="width">{#table_dlg.width}</label></td>
|
53 |
-
<td><input name="width" type="text" id="width" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
|
54 |
-
<td><label id="heightlabel" for="height">{#table_dlg.height}</label></td>
|
55 |
-
<td><input name="height" type="text" id="height" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
|
56 |
-
</tr>
|
57 |
-
<tr id="styleSelectRow" >
|
58 |
-
<td><label id="classlabel" for="class">{#class_name}</label></td>
|
59 |
-
<td colspan="3" >
|
60 |
-
<select id="class" name="class" class="mceEditableSelect">
|
61 |
-
<option value="" selected="selected">{#not_set}</option>
|
62 |
-
</select></td>
|
63 |
-
</tr>
|
64 |
-
<tr>
|
65 |
-
<td class="column1" ><label for="caption">{#table_dlg.caption}</label></td>
|
66 |
-
<td><input id="caption" name="caption" type="checkbox" class="checkbox" value="true" /></td>
|
67 |
-
</tr>
|
68 |
-
</table>
|
69 |
-
</fieldset>
|
70 |
-
</div>
|
71 |
-
|
72 |
-
<div id="advanced_panel" class="panel">
|
73 |
-
<fieldset>
|
74 |
-
<legend>{#table_dlg.advanced_props}</legend>
|
75 |
-
|
76 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
77 |
-
<tr>
|
78 |
-
<td class="column1"><label for="id">{#table_dlg.id}</label></td>
|
79 |
-
<td><input id="id" name="id" type="text" value="" class="advfield" /></td>
|
80 |
-
</tr>
|
81 |
-
|
82 |
-
<tr>
|
83 |
-
<td class="column1"><label for="summary">{#table_dlg.summary}</label></td>
|
84 |
-
<td><input id="summary" name="summary" type="text" value="" class="advfield" /></td>
|
85 |
-
</tr>
|
86 |
-
|
87 |
-
<tr>
|
88 |
-
<td><label for="style">{#table_dlg.style}</label></td>
|
89 |
-
<td><input type="text" id="style" name="style" value="" class="advfield" onchange="changedStyle();" /></td>
|
90 |
-
</tr>
|
91 |
-
|
92 |
-
<tr>
|
93 |
-
<td class="column1"><label id="langlabel" for="lang">{#table_dlg.langcode}</label></td>
|
94 |
-
<td>
|
95 |
-
<input id="lang" name="lang" type="text" value="" class="advfield" />
|
96 |
-
</td>
|
97 |
-
</tr>
|
98 |
-
|
99 |
-
<tr>
|
100 |
-
<td class="column1"><label for="backgroundimage">{#table_dlg.bgimage}</label></td>
|
101 |
-
<td>
|
102 |
-
<table role="presentation" aria-labelledby="backgroundimage_label" border="0" cellpadding="0" cellspacing="0">
|
103 |
-
<tr>
|
104 |
-
<td><input id="backgroundimage" name="backgroundimage" type="text" value="" class="advfield" onchange="changedBackgroundImage();" /></td>
|
105 |
-
<td id="backgroundimagebrowsercontainer"> </td>
|
106 |
-
</tr>
|
107 |
-
</table>
|
108 |
-
</td>
|
109 |
-
</tr>
|
110 |
-
|
111 |
-
<tr>
|
112 |
-
<td class="column1"><label for="tframe">{#table_dlg.frame}</label></td>
|
113 |
-
<td>
|
114 |
-
<select id="tframe" name="tframe" class="advfield">
|
115 |
-
<option value="">{#not_set}</option>
|
116 |
-
<option value="void">{#table_dlg.rules_void}</option>
|
117 |
-
<option value="above">{#table_dlg.rules_above}</option>
|
118 |
-
<option value="below">{#table_dlg.rules_below}</option>
|
119 |
-
<option value="hsides">{#table_dlg.rules_hsides}</option>
|
120 |
-
<option value="lhs">{#table_dlg.rules_lhs}</option>
|
121 |
-
<option value="rhs">{#table_dlg.rules_rhs}</option>
|
122 |
-
<option value="vsides">{#table_dlg.rules_vsides}</option>
|
123 |
-
<option value="box">{#table_dlg.rules_box}</option>
|
124 |
-
<option value="border">{#table_dlg.rules_border}</option>
|
125 |
-
</select>
|
126 |
-
</td>
|
127 |
-
</tr>
|
128 |
-
|
129 |
-
<tr>
|
130 |
-
<td class="column1"><label for="rules">{#table_dlg.rules}</label></td>
|
131 |
-
<td>
|
132 |
-
<select id="rules" name="rules" class="advfield">
|
133 |
-
<option value="">{#not_set}</option>
|
134 |
-
<option value="none">{#table_dlg.frame_none}</option>
|
135 |
-
<option value="groups">{#table_dlg.frame_groups}</option>
|
136 |
-
<option value="rows">{#table_dlg.frame_rows}</option>
|
137 |
-
<option value="cols">{#table_dlg.frame_cols}</option>
|
138 |
-
<option value="all">{#table_dlg.frame_all}</option>
|
139 |
-
</select>
|
140 |
-
</td>
|
141 |
-
</tr>
|
142 |
-
|
143 |
-
<tr>
|
144 |
-
<td class="column1"><label for="dir">{#table_dlg.langdir}</label></td>
|
145 |
-
<td>
|
146 |
-
<select id="dir" name="dir" class="advfield">
|
147 |
-
<option value="">{#not_set}</option>
|
148 |
-
<option value="ltr">{#table_dlg.ltr}</option>
|
149 |
-
<option value="rtl">{#table_dlg.rtl}</option>
|
150 |
-
</select>
|
151 |
-
</td>
|
152 |
-
</tr>
|
153 |
-
|
154 |
-
<tr role="group" aria-labelledby="bordercolor_label">
|
155 |
-
<td class="column1"><label id="bordercolor_label" for="bordercolor">{#table_dlg.bordercolor}</label></td>
|
156 |
-
<td>
|
157 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
158 |
-
<tr>
|
159 |
-
<td><input id="bordercolor" name="bordercolor" type="text" value="" size="9" onchange="updateColor('bordercolor_pick','bordercolor');changedColor();" /></td>
|
160 |
-
<td id="bordercolor_pickcontainer"> </td>
|
161 |
-
</tr>
|
162 |
-
</table>
|
163 |
-
</td>
|
164 |
-
</tr>
|
165 |
-
|
166 |
-
<tr role="group" aria-labelledby="bgcolor_label">
|
167 |
-
<td class="column1"><label id="bgcolor_label" for="bgcolor">{#table_dlg.bgcolor}</label></td>
|
168 |
-
<td>
|
169 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
170 |
-
<tr>
|
171 |
-
<td><input id="bgcolor" name="bgcolor" type="text" value="" size="9" onchange="updateColor('bgcolor_pick','bgcolor');changedColor();" /></td>
|
172 |
-
<td id="bgcolor_pickcontainer"> </td>
|
173 |
-
</tr>
|
174 |
-
</table>
|
175 |
-
</td>
|
176 |
-
</tr>
|
177 |
-
</table>
|
178 |
-
</fieldset>
|
179 |
-
</div>
|
180 |
-
</div>
|
181 |
-
|
182 |
-
<div class="mceActionPanel">
|
183 |
-
<input type="submit" id="insert" name="insert" value="{#insert}" />
|
184 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
185 |
-
</div>
|
186 |
-
</form>
|
187 |
-
</body>
|
188 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#table_dlg.title}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/validate.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
10 |
+
<script type="text/javascript" src="js/table.js?ver=359"></script>
|
11 |
+
<link href="css/table.css?ver=359" rel="stylesheet" type="text/css" />
|
12 |
+
</head>
|
13 |
+
<body id="table" style="display: none" role="application" aria-labelledby="app_title">
|
14 |
+
<span style="display:none;" id="app_title">{#table_dlg.title}</span>
|
15 |
+
<form onsubmit="insertTable();return false;" action="#">
|
16 |
+
<div class="tabs">
|
17 |
+
<ul>
|
18 |
+
<li id="general_tab" aria-controls="general_panel" class="current"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#table_dlg.general_tab}</a></span></li>
|
19 |
+
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#table_dlg.advanced_tab}</a></span></li>
|
20 |
+
</ul>
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<div class="panel_wrapper">
|
24 |
+
<div id="general_panel" class="panel current">
|
25 |
+
<fieldset>
|
26 |
+
<legend>{#table_dlg.general_props}</legend>
|
27 |
+
<table role="presentation" border="0" cellpadding="4" cellspacing="0" width="100%">
|
28 |
+
<tr>
|
29 |
+
<td><label id="colslabel" for="cols">{#table_dlg.cols}</label></td>
|
30 |
+
<td><input id="cols" name="cols" type="text" value="" size="3" maxlength="3" class="required number min1 mceFocus" aria-required="true" /></td>
|
31 |
+
<td><label id="rowslabel" for="rows">{#table_dlg.rows}</label></td>
|
32 |
+
<td><input id="rows" name="rows" type="text" value="" size="3" maxlength="3" class="required number min1" aria-required="true" /></td>
|
33 |
+
</tr>
|
34 |
+
<tr>
|
35 |
+
<td><label id="cellpaddinglabel" for="cellpadding">{#table_dlg.cellpadding}</label></td>
|
36 |
+
<td><input id="cellpadding" name="cellpadding" type="text" value="" size="3" maxlength="3" class="number" /></td>
|
37 |
+
<td><label id="cellspacinglabel" for="cellspacing">{#table_dlg.cellspacing}</label></td>
|
38 |
+
<td><input id="cellspacing" name="cellspacing" type="text" value="" size="3" maxlength="3" class="number" /></td>
|
39 |
+
</tr>
|
40 |
+
<tr>
|
41 |
+
<td><label id="alignlabel" for="align">{#table_dlg.align}</label></td>
|
42 |
+
<td><select id="align" name="align">
|
43 |
+
<option value="">{#not_set}</option>
|
44 |
+
<option value="center">{#table_dlg.align_middle}</option>
|
45 |
+
<option value="left">{#table_dlg.align_left}</option>
|
46 |
+
<option value="right">{#table_dlg.align_right}</option>
|
47 |
+
</select></td>
|
48 |
+
<td><label id="borderlabel" for="border">{#table_dlg.border}</label></td>
|
49 |
+
<td><input id="border" name="border" type="text" value="" size="3" maxlength="5" onchange="changedBorder();" class="size" /></td>
|
50 |
+
</tr>
|
51 |
+
<tr id="width_row">
|
52 |
+
<td><label id="widthlabel" for="width">{#table_dlg.width}</label></td>
|
53 |
+
<td><input name="width" type="text" id="width" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
|
54 |
+
<td><label id="heightlabel" for="height">{#table_dlg.height}</label></td>
|
55 |
+
<td><input name="height" type="text" id="height" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
|
56 |
+
</tr>
|
57 |
+
<tr id="styleSelectRow" >
|
58 |
+
<td><label id="classlabel" for="class">{#class_name}</label></td>
|
59 |
+
<td colspan="3" >
|
60 |
+
<select id="class" name="class" class="mceEditableSelect">
|
61 |
+
<option value="" selected="selected">{#not_set}</option>
|
62 |
+
</select></td>
|
63 |
+
</tr>
|
64 |
+
<tr>
|
65 |
+
<td class="column1" ><label for="caption">{#table_dlg.caption}</label></td>
|
66 |
+
<td><input id="caption" name="caption" type="checkbox" class="checkbox" value="true" /></td>
|
67 |
+
</tr>
|
68 |
+
</table>
|
69 |
+
</fieldset>
|
70 |
+
</div>
|
71 |
+
|
72 |
+
<div id="advanced_panel" class="panel">
|
73 |
+
<fieldset>
|
74 |
+
<legend>{#table_dlg.advanced_props}</legend>
|
75 |
+
|
76 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
77 |
+
<tr>
|
78 |
+
<td class="column1"><label for="id">{#table_dlg.id}</label></td>
|
79 |
+
<td><input id="id" name="id" type="text" value="" class="advfield" /></td>
|
80 |
+
</tr>
|
81 |
+
|
82 |
+
<tr>
|
83 |
+
<td class="column1"><label for="summary">{#table_dlg.summary}</label></td>
|
84 |
+
<td><input id="summary" name="summary" type="text" value="" class="advfield" /></td>
|
85 |
+
</tr>
|
86 |
+
|
87 |
+
<tr>
|
88 |
+
<td><label for="style">{#table_dlg.style}</label></td>
|
89 |
+
<td><input type="text" id="style" name="style" value="" class="advfield" onchange="changedStyle();" /></td>
|
90 |
+
</tr>
|
91 |
+
|
92 |
+
<tr>
|
93 |
+
<td class="column1"><label id="langlabel" for="lang">{#table_dlg.langcode}</label></td>
|
94 |
+
<td>
|
95 |
+
<input id="lang" name="lang" type="text" value="" class="advfield" />
|
96 |
+
</td>
|
97 |
+
</tr>
|
98 |
+
|
99 |
+
<tr>
|
100 |
+
<td class="column1"><label for="backgroundimage">{#table_dlg.bgimage}</label></td>
|
101 |
+
<td>
|
102 |
+
<table role="presentation" aria-labelledby="backgroundimage_label" border="0" cellpadding="0" cellspacing="0">
|
103 |
+
<tr>
|
104 |
+
<td><input id="backgroundimage" name="backgroundimage" type="text" value="" class="advfield" onchange="changedBackgroundImage();" /></td>
|
105 |
+
<td id="backgroundimagebrowsercontainer"> </td>
|
106 |
+
</tr>
|
107 |
+
</table>
|
108 |
+
</td>
|
109 |
+
</tr>
|
110 |
+
|
111 |
+
<tr>
|
112 |
+
<td class="column1"><label for="tframe">{#table_dlg.frame}</label></td>
|
113 |
+
<td>
|
114 |
+
<select id="tframe" name="tframe" class="advfield">
|
115 |
+
<option value="">{#not_set}</option>
|
116 |
+
<option value="void">{#table_dlg.rules_void}</option>
|
117 |
+
<option value="above">{#table_dlg.rules_above}</option>
|
118 |
+
<option value="below">{#table_dlg.rules_below}</option>
|
119 |
+
<option value="hsides">{#table_dlg.rules_hsides}</option>
|
120 |
+
<option value="lhs">{#table_dlg.rules_lhs}</option>
|
121 |
+
<option value="rhs">{#table_dlg.rules_rhs}</option>
|
122 |
+
<option value="vsides">{#table_dlg.rules_vsides}</option>
|
123 |
+
<option value="box">{#table_dlg.rules_box}</option>
|
124 |
+
<option value="border">{#table_dlg.rules_border}</option>
|
125 |
+
</select>
|
126 |
+
</td>
|
127 |
+
</tr>
|
128 |
+
|
129 |
+
<tr>
|
130 |
+
<td class="column1"><label for="rules">{#table_dlg.rules}</label></td>
|
131 |
+
<td>
|
132 |
+
<select id="rules" name="rules" class="advfield">
|
133 |
+
<option value="">{#not_set}</option>
|
134 |
+
<option value="none">{#table_dlg.frame_none}</option>
|
135 |
+
<option value="groups">{#table_dlg.frame_groups}</option>
|
136 |
+
<option value="rows">{#table_dlg.frame_rows}</option>
|
137 |
+
<option value="cols">{#table_dlg.frame_cols}</option>
|
138 |
+
<option value="all">{#table_dlg.frame_all}</option>
|
139 |
+
</select>
|
140 |
+
</td>
|
141 |
+
</tr>
|
142 |
+
|
143 |
+
<tr>
|
144 |
+
<td class="column1"><label for="dir">{#table_dlg.langdir}</label></td>
|
145 |
+
<td>
|
146 |
+
<select id="dir" name="dir" class="advfield">
|
147 |
+
<option value="">{#not_set}</option>
|
148 |
+
<option value="ltr">{#table_dlg.ltr}</option>
|
149 |
+
<option value="rtl">{#table_dlg.rtl}</option>
|
150 |
+
</select>
|
151 |
+
</td>
|
152 |
+
</tr>
|
153 |
+
|
154 |
+
<tr role="group" aria-labelledby="bordercolor_label">
|
155 |
+
<td class="column1"><label id="bordercolor_label" for="bordercolor">{#table_dlg.bordercolor}</label></td>
|
156 |
+
<td>
|
157 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
158 |
+
<tr>
|
159 |
+
<td><input id="bordercolor" name="bordercolor" type="text" value="" size="9" onchange="updateColor('bordercolor_pick','bordercolor');changedColor();" /></td>
|
160 |
+
<td id="bordercolor_pickcontainer"> </td>
|
161 |
+
</tr>
|
162 |
+
</table>
|
163 |
+
</td>
|
164 |
+
</tr>
|
165 |
+
|
166 |
+
<tr role="group" aria-labelledby="bgcolor_label">
|
167 |
+
<td class="column1"><label id="bgcolor_label" for="bgcolor">{#table_dlg.bgcolor}</label></td>
|
168 |
+
<td>
|
169 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
|
170 |
+
<tr>
|
171 |
+
<td><input id="bgcolor" name="bgcolor" type="text" value="" size="9" onchange="updateColor('bgcolor_pick','bgcolor');changedColor();" /></td>
|
172 |
+
<td id="bgcolor_pickcontainer"> </td>
|
173 |
+
</tr>
|
174 |
+
</table>
|
175 |
+
</td>
|
176 |
+
</tr>
|
177 |
+
</table>
|
178 |
+
</fieldset>
|
179 |
+
</div>
|
180 |
+
</div>
|
181 |
+
|
182 |
+
<div class="mceActionPanel">
|
183 |
+
<input type="submit" id="insert" name="insert" value="{#insert}" />
|
184 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
185 |
+
</div>
|
186 |
+
</form>
|
187 |
+
</body>
|
188 |
+
</html>
|
mce/xhtmlxtras/abbr.htm
CHANGED
@@ -1,142 +1,142 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#xhtmlxtras_dlg.title_abbr_element}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
9 |
-
<script type="text/javascript" src="js/element_common.js?ver=
|
10 |
-
<script type="text/javascript" src="js/abbr.js?ver=
|
11 |
-
<link rel="stylesheet" type="text/css" href="css/popup.css?ver=
|
12 |
-
</head>
|
13 |
-
<body style="display: none" role="application" aria-labelledby="app_title">
|
14 |
-
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.title_abbr_element}</span>
|
15 |
-
<form onsubmit="insertAbbr();return false;" action="#">
|
16 |
-
<div class="tabs">
|
17 |
-
<ul>
|
18 |
-
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.general_tab}</a></span></li>
|
19 |
-
<!-- <li id="events_tab"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.events_tab}</a></span></li> -->
|
20 |
-
</ul>
|
21 |
-
</div>
|
22 |
-
|
23 |
-
<div class="panel_wrapper">
|
24 |
-
<div id="general_panel" class="panel current">
|
25 |
-
<fieldset>
|
26 |
-
<legend>{#xhtmlxtras_dlg.fieldset_attrib_tab}</legend>
|
27 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
28 |
-
<tr>
|
29 |
-
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
30 |
-
<td><input id="title" name="title" type="text" value="" class="field mceFocus" /></td>
|
31 |
-
</tr>
|
32 |
-
<tr>
|
33 |
-
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
34 |
-
<td><input id="id" name="id" type="text" value="" class="field" /></td>
|
35 |
-
</tr>
|
36 |
-
<tr>
|
37 |
-
<td class="label"><label id="classlabel" for="class">{#xhtmlxtras_dlg.attribute_label_class}</label>:</td>
|
38 |
-
<td>
|
39 |
-
<select id="class" name="class" class="field mceEditableSelect">
|
40 |
-
<option value="">{#not_set}</option>
|
41 |
-
</select>
|
42 |
-
</td>
|
43 |
-
</tr>
|
44 |
-
<tr>
|
45 |
-
<td class="label"><label id="stylelabel" for="style">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
46 |
-
<td><input id="style" name="style" type="text" value="" class="field" /></td>
|
47 |
-
</tr>
|
48 |
-
<tr>
|
49 |
-
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
50 |
-
<td>
|
51 |
-
<select id="dir" name="dir" class="field">
|
52 |
-
<option value="">{#not_set}</option>
|
53 |
-
<option value="ltr">{#xhtmlxtras_dlg.attribute_option_ltr}</option>
|
54 |
-
<option value="rtl">{#xhtmlxtras_dlg.attribute_option_rtl}</option>
|
55 |
-
</select>
|
56 |
-
</td>
|
57 |
-
</tr>
|
58 |
-
<tr>
|
59 |
-
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
60 |
-
<td>
|
61 |
-
<input id="lang" name="lang" type="text" value="" class="field" />
|
62 |
-
</td>
|
63 |
-
</tr>
|
64 |
-
</table>
|
65 |
-
</fieldset>
|
66 |
-
</div>
|
67 |
-
<div id="events_panel" class="panel">
|
68 |
-
<fieldset>
|
69 |
-
<legend>{#xhtmlxtras_dlg.fieldset_events_tab}</legend>
|
70 |
-
|
71 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
72 |
-
<tr>
|
73 |
-
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
74 |
-
<td><input id="onfocus" name="onfocus" type="text" value="" class="field" /></td>
|
75 |
-
</tr>
|
76 |
-
|
77 |
-
<tr>
|
78 |
-
<td class="label"><label for="onblur">onblur</label>:</td>
|
79 |
-
<td><input id="onblur" name="onblur" type="text" value="" class="field" /></td>
|
80 |
-
</tr>
|
81 |
-
|
82 |
-
<tr>
|
83 |
-
<td class="label"><label for="onclick">onclick</label>:</td>
|
84 |
-
<td><input id="onclick" name="onclick" type="text" value="" class="field" /></td>
|
85 |
-
</tr>
|
86 |
-
|
87 |
-
<tr>
|
88 |
-
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
89 |
-
<td><input id="ondblclick" name="ondblclick" type="text" value="" class="field" /></td>
|
90 |
-
</tr>
|
91 |
-
|
92 |
-
<tr>
|
93 |
-
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
94 |
-
<td><input id="onmousedown" name="onmousedown" type="text" value="" class="field" /></td>
|
95 |
-
</tr>
|
96 |
-
|
97 |
-
<tr>
|
98 |
-
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
99 |
-
<td><input id="onmouseup" name="onmouseup" type="text" value="" class="field" /></td>
|
100 |
-
</tr>
|
101 |
-
|
102 |
-
<tr>
|
103 |
-
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
104 |
-
<td><input id="onmouseover" name="onmouseover" type="text" value="" class="field" /></td>
|
105 |
-
</tr>
|
106 |
-
|
107 |
-
<tr>
|
108 |
-
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
109 |
-
<td><input id="onmousemove" name="onmousemove" type="text" value="" class="field" /></td>
|
110 |
-
</tr>
|
111 |
-
|
112 |
-
<tr>
|
113 |
-
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
114 |
-
<td><input id="onmouseout" name="onmouseout" type="text" value="" class="field" /></td>
|
115 |
-
</tr>
|
116 |
-
|
117 |
-
<tr>
|
118 |
-
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
119 |
-
<td><input id="onkeypress" name="onkeypress" type="text" value="" class="field" /></td>
|
120 |
-
</tr>
|
121 |
-
|
122 |
-
<tr>
|
123 |
-
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
124 |
-
<td><input id="onkeydown" name="onkeydown" type="text" value="" class="field" /></td>
|
125 |
-
</tr>
|
126 |
-
|
127 |
-
<tr>
|
128 |
-
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
129 |
-
<td><input id="onkeyup" name="onkeyup" type="text" value="" class="field" /></td>
|
130 |
-
</tr>
|
131 |
-
</table>
|
132 |
-
</fieldset>
|
133 |
-
</div>
|
134 |
-
</div>
|
135 |
-
<div class="mceActionPanel">
|
136 |
-
<input type="submit" id="insert" name="insert" value="{#update}" />
|
137 |
-
<input type="button" id="remove" name="remove" class="button" value="{#xhtmlxtras_dlg.remove}" onclick="removeAbbr();" style="display: none;" />
|
138 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
139 |
-
</div>
|
140 |
-
</form>
|
141 |
-
</body>
|
142 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#xhtmlxtras_dlg.title_abbr_element}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="js/element_common.js?ver=359"></script>
|
10 |
+
<script type="text/javascript" src="js/abbr.js?ver=359"></script>
|
11 |
+
<link rel="stylesheet" type="text/css" href="css/popup.css?ver=359" />
|
12 |
+
</head>
|
13 |
+
<body style="display: none" role="application" aria-labelledby="app_title">
|
14 |
+
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.title_abbr_element}</span>
|
15 |
+
<form onsubmit="insertAbbr();return false;" action="#">
|
16 |
+
<div class="tabs">
|
17 |
+
<ul>
|
18 |
+
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.general_tab}</a></span></li>
|
19 |
+
<!-- <li id="events_tab"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.events_tab}</a></span></li> -->
|
20 |
+
</ul>
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<div class="panel_wrapper">
|
24 |
+
<div id="general_panel" class="panel current">
|
25 |
+
<fieldset>
|
26 |
+
<legend>{#xhtmlxtras_dlg.fieldset_attrib_tab}</legend>
|
27 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
28 |
+
<tr>
|
29 |
+
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
30 |
+
<td><input id="title" name="title" type="text" value="" class="field mceFocus" /></td>
|
31 |
+
</tr>
|
32 |
+
<tr>
|
33 |
+
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
34 |
+
<td><input id="id" name="id" type="text" value="" class="field" /></td>
|
35 |
+
</tr>
|
36 |
+
<tr>
|
37 |
+
<td class="label"><label id="classlabel" for="class">{#xhtmlxtras_dlg.attribute_label_class}</label>:</td>
|
38 |
+
<td>
|
39 |
+
<select id="class" name="class" class="field mceEditableSelect">
|
40 |
+
<option value="">{#not_set}</option>
|
41 |
+
</select>
|
42 |
+
</td>
|
43 |
+
</tr>
|
44 |
+
<tr>
|
45 |
+
<td class="label"><label id="stylelabel" for="style">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
46 |
+
<td><input id="style" name="style" type="text" value="" class="field" /></td>
|
47 |
+
</tr>
|
48 |
+
<tr>
|
49 |
+
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
50 |
+
<td>
|
51 |
+
<select id="dir" name="dir" class="field">
|
52 |
+
<option value="">{#not_set}</option>
|
53 |
+
<option value="ltr">{#xhtmlxtras_dlg.attribute_option_ltr}</option>
|
54 |
+
<option value="rtl">{#xhtmlxtras_dlg.attribute_option_rtl}</option>
|
55 |
+
</select>
|
56 |
+
</td>
|
57 |
+
</tr>
|
58 |
+
<tr>
|
59 |
+
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
60 |
+
<td>
|
61 |
+
<input id="lang" name="lang" type="text" value="" class="field" />
|
62 |
+
</td>
|
63 |
+
</tr>
|
64 |
+
</table>
|
65 |
+
</fieldset>
|
66 |
+
</div>
|
67 |
+
<div id="events_panel" class="panel">
|
68 |
+
<fieldset>
|
69 |
+
<legend>{#xhtmlxtras_dlg.fieldset_events_tab}</legend>
|
70 |
+
|
71 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
72 |
+
<tr>
|
73 |
+
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
74 |
+
<td><input id="onfocus" name="onfocus" type="text" value="" class="field" /></td>
|
75 |
+
</tr>
|
76 |
+
|
77 |
+
<tr>
|
78 |
+
<td class="label"><label for="onblur">onblur</label>:</td>
|
79 |
+
<td><input id="onblur" name="onblur" type="text" value="" class="field" /></td>
|
80 |
+
</tr>
|
81 |
+
|
82 |
+
<tr>
|
83 |
+
<td class="label"><label for="onclick">onclick</label>:</td>
|
84 |
+
<td><input id="onclick" name="onclick" type="text" value="" class="field" /></td>
|
85 |
+
</tr>
|
86 |
+
|
87 |
+
<tr>
|
88 |
+
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
89 |
+
<td><input id="ondblclick" name="ondblclick" type="text" value="" class="field" /></td>
|
90 |
+
</tr>
|
91 |
+
|
92 |
+
<tr>
|
93 |
+
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
94 |
+
<td><input id="onmousedown" name="onmousedown" type="text" value="" class="field" /></td>
|
95 |
+
</tr>
|
96 |
+
|
97 |
+
<tr>
|
98 |
+
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
99 |
+
<td><input id="onmouseup" name="onmouseup" type="text" value="" class="field" /></td>
|
100 |
+
</tr>
|
101 |
+
|
102 |
+
<tr>
|
103 |
+
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
104 |
+
<td><input id="onmouseover" name="onmouseover" type="text" value="" class="field" /></td>
|
105 |
+
</tr>
|
106 |
+
|
107 |
+
<tr>
|
108 |
+
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
109 |
+
<td><input id="onmousemove" name="onmousemove" type="text" value="" class="field" /></td>
|
110 |
+
</tr>
|
111 |
+
|
112 |
+
<tr>
|
113 |
+
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
114 |
+
<td><input id="onmouseout" name="onmouseout" type="text" value="" class="field" /></td>
|
115 |
+
</tr>
|
116 |
+
|
117 |
+
<tr>
|
118 |
+
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
119 |
+
<td><input id="onkeypress" name="onkeypress" type="text" value="" class="field" /></td>
|
120 |
+
</tr>
|
121 |
+
|
122 |
+
<tr>
|
123 |
+
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
124 |
+
<td><input id="onkeydown" name="onkeydown" type="text" value="" class="field" /></td>
|
125 |
+
</tr>
|
126 |
+
|
127 |
+
<tr>
|
128 |
+
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
129 |
+
<td><input id="onkeyup" name="onkeyup" type="text" value="" class="field" /></td>
|
130 |
+
</tr>
|
131 |
+
</table>
|
132 |
+
</fieldset>
|
133 |
+
</div>
|
134 |
+
</div>
|
135 |
+
<div class="mceActionPanel">
|
136 |
+
<input type="submit" id="insert" name="insert" value="{#update}" />
|
137 |
+
<input type="button" id="remove" name="remove" class="button" value="{#xhtmlxtras_dlg.remove}" onclick="removeAbbr();" style="display: none;" />
|
138 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
139 |
+
</div>
|
140 |
+
</form>
|
141 |
+
</body>
|
142 |
+
</html>
|
mce/xhtmlxtras/acronym.htm
CHANGED
@@ -1,142 +1,142 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#xhtmlxtras_dlg.title_acronym_element}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
9 |
-
<script type="text/javascript" src="js/element_common.js?ver=
|
10 |
-
<script type="text/javascript" src="js/acronym.js?ver=
|
11 |
-
<link rel="stylesheet" type="text/css" href="css/popup.css?ver=
|
12 |
-
</head>
|
13 |
-
<body style="display: none" role="application" aria-labelledby="app_title">
|
14 |
-
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.title_acronym_element}</span>
|
15 |
-
<form onsubmit="insertAcronym();return false;" action="#">
|
16 |
-
<div class="tabs">
|
17 |
-
<ul>
|
18 |
-
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.general_tab}</a></span></li>
|
19 |
-
<!-- <li id="events_tab"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.events_tab}</a></span></li> -->
|
20 |
-
</ul>
|
21 |
-
</div>
|
22 |
-
|
23 |
-
<div class="panel_wrapper">
|
24 |
-
<div id="general_panel" class="panel current">
|
25 |
-
<fieldset>
|
26 |
-
<legend>{#xhtmlxtras_dlg.fieldset_attrib_tab}</legend>
|
27 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
28 |
-
<tr>
|
29 |
-
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
30 |
-
<td><input id="title" name="title" type="text" value="" class="field mceFocus" /></td>
|
31 |
-
</tr>
|
32 |
-
<tr>
|
33 |
-
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
34 |
-
<td><input id="id" name="id" type="text" value="" class="field" /></td>
|
35 |
-
</tr>
|
36 |
-
<tr>
|
37 |
-
<td class="label"><label id="classlabel" for="class">{#xhtmlxtras_dlg.attribute_label_class}</label>:</td>
|
38 |
-
<td>
|
39 |
-
<select id="class" name="class" class="field mceEditableSelect">
|
40 |
-
<option value="">{#not_set}</option>
|
41 |
-
</select>
|
42 |
-
</td>
|
43 |
-
</tr>
|
44 |
-
<tr>
|
45 |
-
<td class="label"><label id="stylelabel" for="style">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
46 |
-
<td><input id="style" name="style" type="text" value="" class="field" /></td>
|
47 |
-
</tr>
|
48 |
-
<tr>
|
49 |
-
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
50 |
-
<td>
|
51 |
-
<select id="dir" name="dir" class="field">
|
52 |
-
<option value="">{#not_set}</option>
|
53 |
-
<option value="ltr">{#xhtmlxtras_dlg.attribute_option_ltr}</option>
|
54 |
-
<option value="rtl">{#xhtmlxtras_dlg.attribute_option_rtl}</option>
|
55 |
-
</select>
|
56 |
-
</td>
|
57 |
-
</tr>
|
58 |
-
<tr>
|
59 |
-
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
60 |
-
<td>
|
61 |
-
<input id="lang" name="lang" type="text" value="" class="field" />
|
62 |
-
</td>
|
63 |
-
</tr>
|
64 |
-
</table>
|
65 |
-
</fieldset>
|
66 |
-
</div>
|
67 |
-
<div id="events_panel" class="panel">
|
68 |
-
<fieldset>
|
69 |
-
<legend>{#xhtmlxtras_dlg.fieldset_events_tab}</legend>
|
70 |
-
|
71 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
72 |
-
<tr>
|
73 |
-
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
74 |
-
<td><input id="onfocus" name="onfocus" type="text" value="" class="field" /></td>
|
75 |
-
</tr>
|
76 |
-
|
77 |
-
<tr>
|
78 |
-
<td class="label"><label for="onblur">onblur</label>:</td>
|
79 |
-
<td><input id="onblur" name="onblur" type="text" value="" class="field" /></td>
|
80 |
-
</tr>
|
81 |
-
|
82 |
-
<tr>
|
83 |
-
<td class="label"><label for="onclick">onclick</label>:</td>
|
84 |
-
<td><input id="onclick" name="onclick" type="text" value="" class="field" /></td>
|
85 |
-
</tr>
|
86 |
-
|
87 |
-
<tr>
|
88 |
-
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
89 |
-
<td><input id="ondblclick" name="ondblclick" type="text" value="" class="field" /></td>
|
90 |
-
</tr>
|
91 |
-
|
92 |
-
<tr>
|
93 |
-
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
94 |
-
<td><input id="onmousedown" name="onmousedown" type="text" value="" class="field" /></td>
|
95 |
-
</tr>
|
96 |
-
|
97 |
-
<tr>
|
98 |
-
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
99 |
-
<td><input id="onmouseup" name="onmouseup" type="text" value="" class="field" /></td>
|
100 |
-
</tr>
|
101 |
-
|
102 |
-
<tr>
|
103 |
-
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
104 |
-
<td><input id="onmouseover" name="onmouseover" type="text" value="" class="field" /></td>
|
105 |
-
</tr>
|
106 |
-
|
107 |
-
<tr>
|
108 |
-
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
109 |
-
<td><input id="onmousemove" name="onmousemove" type="text" value="" class="field" /></td>
|
110 |
-
</tr>
|
111 |
-
|
112 |
-
<tr>
|
113 |
-
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
114 |
-
<td><input id="onmouseout" name="onmouseout" type="text" value="" class="field" /></td>
|
115 |
-
</tr>
|
116 |
-
|
117 |
-
<tr>
|
118 |
-
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
119 |
-
<td><input id="onkeypress" name="onkeypress" type="text" value="" class="field" /></td>
|
120 |
-
</tr>
|
121 |
-
|
122 |
-
<tr>
|
123 |
-
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
124 |
-
<td><input id="onkeydown" name="onkeydown" type="text" value="" class="field" /></td>
|
125 |
-
</tr>
|
126 |
-
|
127 |
-
<tr>
|
128 |
-
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
129 |
-
<td><input id="onkeyup" name="onkeyup" type="text" value="" class="field" /></td>
|
130 |
-
</tr>
|
131 |
-
</table>
|
132 |
-
</fieldset>
|
133 |
-
</div>
|
134 |
-
</div>
|
135 |
-
<div class="mceActionPanel">
|
136 |
-
<input type="submit" id="insert" name="insert" value="{#update}" />
|
137 |
-
<input type="button" id="remove" name="remove" class="button" value="{#xhtmlxtras_dlg.remove}" onclick="removeAcronym();" style="display: none;" />
|
138 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
139 |
-
</div>
|
140 |
-
</form>
|
141 |
-
</body>
|
142 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#xhtmlxtras_dlg.title_acronym_element}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="js/element_common.js?ver=359"></script>
|
10 |
+
<script type="text/javascript" src="js/acronym.js?ver=359"></script>
|
11 |
+
<link rel="stylesheet" type="text/css" href="css/popup.css?ver=359" />
|
12 |
+
</head>
|
13 |
+
<body style="display: none" role="application" aria-labelledby="app_title">
|
14 |
+
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.title_acronym_element}</span>
|
15 |
+
<form onsubmit="insertAcronym();return false;" action="#">
|
16 |
+
<div class="tabs">
|
17 |
+
<ul>
|
18 |
+
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.general_tab}</a></span></li>
|
19 |
+
<!-- <li id="events_tab"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.events_tab}</a></span></li> -->
|
20 |
+
</ul>
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<div class="panel_wrapper">
|
24 |
+
<div id="general_panel" class="panel current">
|
25 |
+
<fieldset>
|
26 |
+
<legend>{#xhtmlxtras_dlg.fieldset_attrib_tab}</legend>
|
27 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
28 |
+
<tr>
|
29 |
+
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
30 |
+
<td><input id="title" name="title" type="text" value="" class="field mceFocus" /></td>
|
31 |
+
</tr>
|
32 |
+
<tr>
|
33 |
+
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
34 |
+
<td><input id="id" name="id" type="text" value="" class="field" /></td>
|
35 |
+
</tr>
|
36 |
+
<tr>
|
37 |
+
<td class="label"><label id="classlabel" for="class">{#xhtmlxtras_dlg.attribute_label_class}</label>:</td>
|
38 |
+
<td>
|
39 |
+
<select id="class" name="class" class="field mceEditableSelect">
|
40 |
+
<option value="">{#not_set}</option>
|
41 |
+
</select>
|
42 |
+
</td>
|
43 |
+
</tr>
|
44 |
+
<tr>
|
45 |
+
<td class="label"><label id="stylelabel" for="style">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
46 |
+
<td><input id="style" name="style" type="text" value="" class="field" /></td>
|
47 |
+
</tr>
|
48 |
+
<tr>
|
49 |
+
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
50 |
+
<td>
|
51 |
+
<select id="dir" name="dir" class="field">
|
52 |
+
<option value="">{#not_set}</option>
|
53 |
+
<option value="ltr">{#xhtmlxtras_dlg.attribute_option_ltr}</option>
|
54 |
+
<option value="rtl">{#xhtmlxtras_dlg.attribute_option_rtl}</option>
|
55 |
+
</select>
|
56 |
+
</td>
|
57 |
+
</tr>
|
58 |
+
<tr>
|
59 |
+
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
60 |
+
<td>
|
61 |
+
<input id="lang" name="lang" type="text" value="" class="field" />
|
62 |
+
</td>
|
63 |
+
</tr>
|
64 |
+
</table>
|
65 |
+
</fieldset>
|
66 |
+
</div>
|
67 |
+
<div id="events_panel" class="panel">
|
68 |
+
<fieldset>
|
69 |
+
<legend>{#xhtmlxtras_dlg.fieldset_events_tab}</legend>
|
70 |
+
|
71 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
72 |
+
<tr>
|
73 |
+
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
74 |
+
<td><input id="onfocus" name="onfocus" type="text" value="" class="field" /></td>
|
75 |
+
</tr>
|
76 |
+
|
77 |
+
<tr>
|
78 |
+
<td class="label"><label for="onblur">onblur</label>:</td>
|
79 |
+
<td><input id="onblur" name="onblur" type="text" value="" class="field" /></td>
|
80 |
+
</tr>
|
81 |
+
|
82 |
+
<tr>
|
83 |
+
<td class="label"><label for="onclick">onclick</label>:</td>
|
84 |
+
<td><input id="onclick" name="onclick" type="text" value="" class="field" /></td>
|
85 |
+
</tr>
|
86 |
+
|
87 |
+
<tr>
|
88 |
+
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
89 |
+
<td><input id="ondblclick" name="ondblclick" type="text" value="" class="field" /></td>
|
90 |
+
</tr>
|
91 |
+
|
92 |
+
<tr>
|
93 |
+
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
94 |
+
<td><input id="onmousedown" name="onmousedown" type="text" value="" class="field" /></td>
|
95 |
+
</tr>
|
96 |
+
|
97 |
+
<tr>
|
98 |
+
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
99 |
+
<td><input id="onmouseup" name="onmouseup" type="text" value="" class="field" /></td>
|
100 |
+
</tr>
|
101 |
+
|
102 |
+
<tr>
|
103 |
+
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
104 |
+
<td><input id="onmouseover" name="onmouseover" type="text" value="" class="field" /></td>
|
105 |
+
</tr>
|
106 |
+
|
107 |
+
<tr>
|
108 |
+
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
109 |
+
<td><input id="onmousemove" name="onmousemove" type="text" value="" class="field" /></td>
|
110 |
+
</tr>
|
111 |
+
|
112 |
+
<tr>
|
113 |
+
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
114 |
+
<td><input id="onmouseout" name="onmouseout" type="text" value="" class="field" /></td>
|
115 |
+
</tr>
|
116 |
+
|
117 |
+
<tr>
|
118 |
+
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
119 |
+
<td><input id="onkeypress" name="onkeypress" type="text" value="" class="field" /></td>
|
120 |
+
</tr>
|
121 |
+
|
122 |
+
<tr>
|
123 |
+
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
124 |
+
<td><input id="onkeydown" name="onkeydown" type="text" value="" class="field" /></td>
|
125 |
+
</tr>
|
126 |
+
|
127 |
+
<tr>
|
128 |
+
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
129 |
+
<td><input id="onkeyup" name="onkeyup" type="text" value="" class="field" /></td>
|
130 |
+
</tr>
|
131 |
+
</table>
|
132 |
+
</fieldset>
|
133 |
+
</div>
|
134 |
+
</div>
|
135 |
+
<div class="mceActionPanel">
|
136 |
+
<input type="submit" id="insert" name="insert" value="{#update}" />
|
137 |
+
<input type="button" id="remove" name="remove" class="button" value="{#xhtmlxtras_dlg.remove}" onclick="removeAcronym();" style="display: none;" />
|
138 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
139 |
+
</div>
|
140 |
+
</form>
|
141 |
+
</body>
|
142 |
+
</html>
|
mce/xhtmlxtras/attributes.htm
CHANGED
@@ -1,149 +1,149 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#xhtmlxtras_dlg.attribs_title}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
9 |
-
<script type="text/javascript" src="js/attributes.js?ver=
|
10 |
-
<link rel="stylesheet" type="text/css" href="css/attributes.css?ver=
|
11 |
-
</head>
|
12 |
-
<body style="display: none" role="application" aria-labelledby="app_title">
|
13 |
-
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.attribs_title}</span>
|
14 |
-
<form onsubmit="insertAction();return false;" action="#">
|
15 |
-
<div class="tabs">
|
16 |
-
<ul>
|
17 |
-
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.attribute_attrib_tab}</a></span></li>
|
18 |
-
<li id="events_tab" aria-controls="events_panel"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.attribute_events_tab}</a></span></li>
|
19 |
-
</ul>
|
20 |
-
</div>
|
21 |
-
|
22 |
-
<div class="panel_wrapper">
|
23 |
-
<div id="general_panel" class="panel current">
|
24 |
-
<fieldset>
|
25 |
-
<legend>{#xhtmlxtras_dlg.attribute_attrib_tab}</legend>
|
26 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
27 |
-
<tr>
|
28 |
-
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
29 |
-
<td><input id="title" name="title" type="text" value="" class="mceFocus" /></td>
|
30 |
-
</tr>
|
31 |
-
<tr>
|
32 |
-
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
33 |
-
<td><input id="id" name="id" type="text" value="" /></td>
|
34 |
-
</tr>
|
35 |
-
<tr>
|
36 |
-
<td><label id="classlabel" for="classlist">{#class_name}</label></td>
|
37 |
-
<td>
|
38 |
-
<select id="classlist" name="classlist" class="mceEditableSelect">
|
39 |
-
<option value="" selected="selected">{#not_set}</option>
|
40 |
-
</select>
|
41 |
-
</td>
|
42 |
-
</tr>
|
43 |
-
<tr>
|
44 |
-
<td class="label"><label id="stylelabel" for="style">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
45 |
-
<td><input id="style" name="style" type="text" value="" /></td>
|
46 |
-
</tr>
|
47 |
-
<tr>
|
48 |
-
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
49 |
-
<td>
|
50 |
-
<select id="dir" name="dir">
|
51 |
-
<option value="">{#not_set}</option>
|
52 |
-
<option value="ltr">{#xhtmlxtras_dlg.option_ltr}</option>
|
53 |
-
<option value="rtl">{#xhtmlxtras_dlg.option_rtl}</option>
|
54 |
-
</select>
|
55 |
-
</td>
|
56 |
-
</tr>
|
57 |
-
<tr>
|
58 |
-
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
59 |
-
<td>
|
60 |
-
<input id="lang" name="lang" type="text" value="" />
|
61 |
-
</td>
|
62 |
-
</tr>
|
63 |
-
<tr>
|
64 |
-
<td><label id="tabindexlabel" for="tabindex">{#xhtmlxtras_dlg.attribute_label_tabindex}</label></td>
|
65 |
-
<td><input type="text" id="tabindex" name="tabindex" value="" /></td>
|
66 |
-
</tr>
|
67 |
-
|
68 |
-
<tr>
|
69 |
-
<td><label id="accesskeylabel" for="accesskey">{#xhtmlxtras_dlg.attribute_label_accesskey}</label></td>
|
70 |
-
<td><input type="text" id="accesskey" name="accesskey" value="" /></td>
|
71 |
-
</tr>
|
72 |
-
</table>
|
73 |
-
</fieldset>
|
74 |
-
</div>
|
75 |
-
<div id="events_panel" class="panel">
|
76 |
-
<fieldset>
|
77 |
-
<legend>{#xhtmlxtras_dlg.attribute_events_tab}</legend>
|
78 |
-
|
79 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
80 |
-
<tr>
|
81 |
-
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
82 |
-
<td><input id="onfocus" name="onfocus" type="text" value="" /></td>
|
83 |
-
</tr>
|
84 |
-
|
85 |
-
<tr>
|
86 |
-
<td class="label"><label for="onblur">onblur</label>:</td>
|
87 |
-
<td><input id="onblur" name="onblur" type="text" value="" /></td>
|
88 |
-
</tr>
|
89 |
-
|
90 |
-
<tr>
|
91 |
-
<td class="label"><label for="onclick">onclick</label>:</td>
|
92 |
-
<td><input id="onclick" name="onclick" type="text" value="" /></td>
|
93 |
-
</tr>
|
94 |
-
|
95 |
-
<tr>
|
96 |
-
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
97 |
-
<td><input id="ondblclick" name="ondblclick" type="text" value="" /></td>
|
98 |
-
</tr>
|
99 |
-
|
100 |
-
<tr>
|
101 |
-
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
102 |
-
<td><input id="onmousedown" name="onmousedown" type="text" value="" /></td>
|
103 |
-
</tr>
|
104 |
-
|
105 |
-
<tr>
|
106 |
-
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
107 |
-
<td><input id="onmouseup" name="onmouseup" type="text" value="" /></td>
|
108 |
-
</tr>
|
109 |
-
|
110 |
-
<tr>
|
111 |
-
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
112 |
-
<td><input id="onmouseover" name="onmouseover" type="text" value="" /></td>
|
113 |
-
</tr>
|
114 |
-
|
115 |
-
<tr>
|
116 |
-
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
117 |
-
<td><input id="onmousemove" name="onmousemove" type="text" value="" /></td>
|
118 |
-
</tr>
|
119 |
-
|
120 |
-
<tr>
|
121 |
-
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
122 |
-
<td><input id="onmouseout" name="onmouseout" type="text" value="" /></td>
|
123 |
-
</tr>
|
124 |
-
|
125 |
-
<tr>
|
126 |
-
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
127 |
-
<td><input id="onkeypress" name="onkeypress" type="text" value="" /></td>
|
128 |
-
</tr>
|
129 |
-
|
130 |
-
<tr>
|
131 |
-
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
132 |
-
<td><input id="onkeydown" name="onkeydown" type="text" value="" /></td>
|
133 |
-
</tr>
|
134 |
-
|
135 |
-
<tr>
|
136 |
-
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
137 |
-
<td><input id="onkeyup" name="onkeyup" type="text" value="" /></td>
|
138 |
-
</tr>
|
139 |
-
</table>
|
140 |
-
</fieldset>
|
141 |
-
</div>
|
142 |
-
</div>
|
143 |
-
<div class="mceActionPanel">
|
144 |
-
<input type="submit" id="insert" name="insert" value="{#insert}" />
|
145 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
146 |
-
</div>
|
147 |
-
</form>
|
148 |
-
</body>
|
149 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#xhtmlxtras_dlg.attribs_title}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="js/attributes.js?ver=359"></script>
|
10 |
+
<link rel="stylesheet" type="text/css" href="css/attributes.css?ver=359" />
|
11 |
+
</head>
|
12 |
+
<body style="display: none" role="application" aria-labelledby="app_title">
|
13 |
+
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.attribs_title}</span>
|
14 |
+
<form onsubmit="insertAction();return false;" action="#">
|
15 |
+
<div class="tabs">
|
16 |
+
<ul>
|
17 |
+
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.attribute_attrib_tab}</a></span></li>
|
18 |
+
<li id="events_tab" aria-controls="events_panel"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.attribute_events_tab}</a></span></li>
|
19 |
+
</ul>
|
20 |
+
</div>
|
21 |
+
|
22 |
+
<div class="panel_wrapper">
|
23 |
+
<div id="general_panel" class="panel current">
|
24 |
+
<fieldset>
|
25 |
+
<legend>{#xhtmlxtras_dlg.attribute_attrib_tab}</legend>
|
26 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
27 |
+
<tr>
|
28 |
+
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
29 |
+
<td><input id="title" name="title" type="text" value="" class="mceFocus" /></td>
|
30 |
+
</tr>
|
31 |
+
<tr>
|
32 |
+
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
33 |
+
<td><input id="id" name="id" type="text" value="" /></td>
|
34 |
+
</tr>
|
35 |
+
<tr>
|
36 |
+
<td><label id="classlabel" for="classlist">{#class_name}</label></td>
|
37 |
+
<td>
|
38 |
+
<select id="classlist" name="classlist" class="mceEditableSelect">
|
39 |
+
<option value="" selected="selected">{#not_set}</option>
|
40 |
+
</select>
|
41 |
+
</td>
|
42 |
+
</tr>
|
43 |
+
<tr>
|
44 |
+
<td class="label"><label id="stylelabel" for="style">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
45 |
+
<td><input id="style" name="style" type="text" value="" /></td>
|
46 |
+
</tr>
|
47 |
+
<tr>
|
48 |
+
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
49 |
+
<td>
|
50 |
+
<select id="dir" name="dir">
|
51 |
+
<option value="">{#not_set}</option>
|
52 |
+
<option value="ltr">{#xhtmlxtras_dlg.option_ltr}</option>
|
53 |
+
<option value="rtl">{#xhtmlxtras_dlg.option_rtl}</option>
|
54 |
+
</select>
|
55 |
+
</td>
|
56 |
+
</tr>
|
57 |
+
<tr>
|
58 |
+
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
59 |
+
<td>
|
60 |
+
<input id="lang" name="lang" type="text" value="" />
|
61 |
+
</td>
|
62 |
+
</tr>
|
63 |
+
<tr>
|
64 |
+
<td><label id="tabindexlabel" for="tabindex">{#xhtmlxtras_dlg.attribute_label_tabindex}</label></td>
|
65 |
+
<td><input type="text" id="tabindex" name="tabindex" value="" /></td>
|
66 |
+
</tr>
|
67 |
+
|
68 |
+
<tr>
|
69 |
+
<td><label id="accesskeylabel" for="accesskey">{#xhtmlxtras_dlg.attribute_label_accesskey}</label></td>
|
70 |
+
<td><input type="text" id="accesskey" name="accesskey" value="" /></td>
|
71 |
+
</tr>
|
72 |
+
</table>
|
73 |
+
</fieldset>
|
74 |
+
</div>
|
75 |
+
<div id="events_panel" class="panel">
|
76 |
+
<fieldset>
|
77 |
+
<legend>{#xhtmlxtras_dlg.attribute_events_tab}</legend>
|
78 |
+
|
79 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
80 |
+
<tr>
|
81 |
+
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
82 |
+
<td><input id="onfocus" name="onfocus" type="text" value="" /></td>
|
83 |
+
</tr>
|
84 |
+
|
85 |
+
<tr>
|
86 |
+
<td class="label"><label for="onblur">onblur</label>:</td>
|
87 |
+
<td><input id="onblur" name="onblur" type="text" value="" /></td>
|
88 |
+
</tr>
|
89 |
+
|
90 |
+
<tr>
|
91 |
+
<td class="label"><label for="onclick">onclick</label>:</td>
|
92 |
+
<td><input id="onclick" name="onclick" type="text" value="" /></td>
|
93 |
+
</tr>
|
94 |
+
|
95 |
+
<tr>
|
96 |
+
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
97 |
+
<td><input id="ondblclick" name="ondblclick" type="text" value="" /></td>
|
98 |
+
</tr>
|
99 |
+
|
100 |
+
<tr>
|
101 |
+
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
102 |
+
<td><input id="onmousedown" name="onmousedown" type="text" value="" /></td>
|
103 |
+
</tr>
|
104 |
+
|
105 |
+
<tr>
|
106 |
+
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
107 |
+
<td><input id="onmouseup" name="onmouseup" type="text" value="" /></td>
|
108 |
+
</tr>
|
109 |
+
|
110 |
+
<tr>
|
111 |
+
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
112 |
+
<td><input id="onmouseover" name="onmouseover" type="text" value="" /></td>
|
113 |
+
</tr>
|
114 |
+
|
115 |
+
<tr>
|
116 |
+
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
117 |
+
<td><input id="onmousemove" name="onmousemove" type="text" value="" /></td>
|
118 |
+
</tr>
|
119 |
+
|
120 |
+
<tr>
|
121 |
+
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
122 |
+
<td><input id="onmouseout" name="onmouseout" type="text" value="" /></td>
|
123 |
+
</tr>
|
124 |
+
|
125 |
+
<tr>
|
126 |
+
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
127 |
+
<td><input id="onkeypress" name="onkeypress" type="text" value="" /></td>
|
128 |
+
</tr>
|
129 |
+
|
130 |
+
<tr>
|
131 |
+
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
132 |
+
<td><input id="onkeydown" name="onkeydown" type="text" value="" /></td>
|
133 |
+
</tr>
|
134 |
+
|
135 |
+
<tr>
|
136 |
+
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
137 |
+
<td><input id="onkeyup" name="onkeyup" type="text" value="" /></td>
|
138 |
+
</tr>
|
139 |
+
</table>
|
140 |
+
</fieldset>
|
141 |
+
</div>
|
142 |
+
</div>
|
143 |
+
<div class="mceActionPanel">
|
144 |
+
<input type="submit" id="insert" name="insert" value="{#insert}" />
|
145 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
146 |
+
</div>
|
147 |
+
</form>
|
148 |
+
</body>
|
149 |
+
</html>
|
mce/xhtmlxtras/cite.htm
CHANGED
@@ -1,142 +1,142 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#xhtmlxtras_dlg.title_cite_element}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
9 |
-
<script type="text/javascript" src="js/element_common.js?ver=
|
10 |
-
<script type="text/javascript" src="js/cite.js?ver=
|
11 |
-
<link rel="stylesheet" type="text/css" href="css/popup.css?ver=
|
12 |
-
</head>
|
13 |
-
<body style="display: none" role="application" aria-labelledby="app_title">
|
14 |
-
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.title_cite_element}</span>
|
15 |
-
<form onsubmit="insertCite();return false;" action="#">
|
16 |
-
<div class="tabs">
|
17 |
-
<ul>
|
18 |
-
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.general_tab}</a></span></li>
|
19 |
-
<!-- <li id="events_tab"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.events_tab}</a></span></li> -->
|
20 |
-
</ul>
|
21 |
-
</div>
|
22 |
-
|
23 |
-
<div class="panel_wrapper">
|
24 |
-
<div id="general_panel" class="panel current">
|
25 |
-
<fieldset>
|
26 |
-
<legend>{#xhtmlxtras_dlg.fieldset_attrib_tab}</legend>
|
27 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
28 |
-
<tr>
|
29 |
-
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
30 |
-
<td><input id="title" name="title" type="text" value="" class="field mceFocus" /></td>
|
31 |
-
</tr>
|
32 |
-
<tr>
|
33 |
-
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
34 |
-
<td><input id="id" name="id" type="text" value="" class="field" /></td>
|
35 |
-
</tr>
|
36 |
-
<tr>
|
37 |
-
<td class="label"><label id="classlabel" for="class">{#xhtmlxtras_dlg.attribute_label_class}</label>:</td>
|
38 |
-
<td>
|
39 |
-
<select id="class" name="class" class="field mceEditableSelect">
|
40 |
-
<option value="">{#not_set}</option>
|
41 |
-
</select>
|
42 |
-
</td>
|
43 |
-
</tr>
|
44 |
-
<tr>
|
45 |
-
<td class="label"><label id="stylelabel" for="class">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
46 |
-
<td><input id="style" name="style" type="text" value="" class="field" /></td>
|
47 |
-
</tr>
|
48 |
-
<tr>
|
49 |
-
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
50 |
-
<td>
|
51 |
-
<select id="dir" name="dir" class="field">
|
52 |
-
<option value="">{#not_set}</option>
|
53 |
-
<option value="ltr">{#xhtmlxtras_dlg.attribute_option_ltr}</option>
|
54 |
-
<option value="rtl">{#xhtmlxtras_dlg.attribute_option_rtl}</option>
|
55 |
-
</select>
|
56 |
-
</td>
|
57 |
-
</tr>
|
58 |
-
<tr>
|
59 |
-
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
60 |
-
<td>
|
61 |
-
<input id="lang" name="lang" type="text" value="" class="field" />
|
62 |
-
</td>
|
63 |
-
</tr>
|
64 |
-
</table>
|
65 |
-
</fieldset>
|
66 |
-
</div>
|
67 |
-
<div id="events_panel" class="panel">
|
68 |
-
<fieldset>
|
69 |
-
<legend>{#xhtmlxtras_dlg.fieldset_events_tab}</legend>
|
70 |
-
|
71 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
72 |
-
<tr>
|
73 |
-
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
74 |
-
<td><input id="onfocus" name="onfocus" type="text" value="" class="field" /></td>
|
75 |
-
</tr>
|
76 |
-
|
77 |
-
<tr>
|
78 |
-
<td class="label"><label for="onblur">onblur</label>:</td>
|
79 |
-
<td><input id="onblur" name="onblur" type="text" value="" class="field" /></td>
|
80 |
-
</tr>
|
81 |
-
|
82 |
-
<tr>
|
83 |
-
<td class="label"><label for="onclick">onclick</label>:</td>
|
84 |
-
<td><input id="onclick" name="onclick" type="text" value="" class="field" /></td>
|
85 |
-
</tr>
|
86 |
-
|
87 |
-
<tr>
|
88 |
-
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
89 |
-
<td><input id="ondblclick" name="ondblclick" type="text" value="" class="field" /></td>
|
90 |
-
</tr>
|
91 |
-
|
92 |
-
<tr>
|
93 |
-
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
94 |
-
<td><input id="onmousedown" name="onmousedown" type="text" value="" class="field" /></td>
|
95 |
-
</tr>
|
96 |
-
|
97 |
-
<tr>
|
98 |
-
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
99 |
-
<td><input id="onmouseup" name="onmouseup" type="text" value="" class="field" /></td>
|
100 |
-
</tr>
|
101 |
-
|
102 |
-
<tr>
|
103 |
-
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
104 |
-
<td><input id="onmouseover" name="onmouseover" type="text" value="" class="field" /></td>
|
105 |
-
</tr>
|
106 |
-
|
107 |
-
<tr>
|
108 |
-
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
109 |
-
<td><input id="onmousemove" name="onmousemove" type="text" value="" class="field" /></td>
|
110 |
-
</tr>
|
111 |
-
|
112 |
-
<tr>
|
113 |
-
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
114 |
-
<td><input id="onmouseout" name="onmouseout" type="text" value="" class="field" /></td>
|
115 |
-
</tr>
|
116 |
-
|
117 |
-
<tr>
|
118 |
-
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
119 |
-
<td><input id="onkeypress" name="onkeypress" type="text" value="" class="field" /></td>
|
120 |
-
</tr>
|
121 |
-
|
122 |
-
<tr>
|
123 |
-
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
124 |
-
<td><input id="onkeydown" name="onkeydown" type="text" value="" class="field" /></td>
|
125 |
-
</tr>
|
126 |
-
|
127 |
-
<tr>
|
128 |
-
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
129 |
-
<td><input id="onkeyup" name="onkeyup" type="text" value="" class="field" /></td>
|
130 |
-
</tr>
|
131 |
-
</table>
|
132 |
-
</fieldset>
|
133 |
-
</div>
|
134 |
-
</div>
|
135 |
-
<div class="mceActionPanel">
|
136 |
-
<input type="submit" id="insert" name="insert" value="{#update}" />
|
137 |
-
<input type="button" id="remove" name="remove" class="button" value="{#xhtmlxtras_dlg.remove}" onclick="removeCite();" style="display: none;" />
|
138 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
139 |
-
</div>
|
140 |
-
</form>
|
141 |
-
</body>
|
142 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#xhtmlxtras_dlg.title_cite_element}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="js/element_common.js?ver=359"></script>
|
10 |
+
<script type="text/javascript" src="js/cite.js?ver=359"></script>
|
11 |
+
<link rel="stylesheet" type="text/css" href="css/popup.css?ver=359" />
|
12 |
+
</head>
|
13 |
+
<body style="display: none" role="application" aria-labelledby="app_title">
|
14 |
+
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.title_cite_element}</span>
|
15 |
+
<form onsubmit="insertCite();return false;" action="#">
|
16 |
+
<div class="tabs">
|
17 |
+
<ul>
|
18 |
+
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.general_tab}</a></span></li>
|
19 |
+
<!-- <li id="events_tab"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.events_tab}</a></span></li> -->
|
20 |
+
</ul>
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<div class="panel_wrapper">
|
24 |
+
<div id="general_panel" class="panel current">
|
25 |
+
<fieldset>
|
26 |
+
<legend>{#xhtmlxtras_dlg.fieldset_attrib_tab}</legend>
|
27 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
28 |
+
<tr>
|
29 |
+
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
30 |
+
<td><input id="title" name="title" type="text" value="" class="field mceFocus" /></td>
|
31 |
+
</tr>
|
32 |
+
<tr>
|
33 |
+
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
34 |
+
<td><input id="id" name="id" type="text" value="" class="field" /></td>
|
35 |
+
</tr>
|
36 |
+
<tr>
|
37 |
+
<td class="label"><label id="classlabel" for="class">{#xhtmlxtras_dlg.attribute_label_class}</label>:</td>
|
38 |
+
<td>
|
39 |
+
<select id="class" name="class" class="field mceEditableSelect">
|
40 |
+
<option value="">{#not_set}</option>
|
41 |
+
</select>
|
42 |
+
</td>
|
43 |
+
</tr>
|
44 |
+
<tr>
|
45 |
+
<td class="label"><label id="stylelabel" for="class">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
46 |
+
<td><input id="style" name="style" type="text" value="" class="field" /></td>
|
47 |
+
</tr>
|
48 |
+
<tr>
|
49 |
+
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
50 |
+
<td>
|
51 |
+
<select id="dir" name="dir" class="field">
|
52 |
+
<option value="">{#not_set}</option>
|
53 |
+
<option value="ltr">{#xhtmlxtras_dlg.attribute_option_ltr}</option>
|
54 |
+
<option value="rtl">{#xhtmlxtras_dlg.attribute_option_rtl}</option>
|
55 |
+
</select>
|
56 |
+
</td>
|
57 |
+
</tr>
|
58 |
+
<tr>
|
59 |
+
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
60 |
+
<td>
|
61 |
+
<input id="lang" name="lang" type="text" value="" class="field" />
|
62 |
+
</td>
|
63 |
+
</tr>
|
64 |
+
</table>
|
65 |
+
</fieldset>
|
66 |
+
</div>
|
67 |
+
<div id="events_panel" class="panel">
|
68 |
+
<fieldset>
|
69 |
+
<legend>{#xhtmlxtras_dlg.fieldset_events_tab}</legend>
|
70 |
+
|
71 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
72 |
+
<tr>
|
73 |
+
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
74 |
+
<td><input id="onfocus" name="onfocus" type="text" value="" class="field" /></td>
|
75 |
+
</tr>
|
76 |
+
|
77 |
+
<tr>
|
78 |
+
<td class="label"><label for="onblur">onblur</label>:</td>
|
79 |
+
<td><input id="onblur" name="onblur" type="text" value="" class="field" /></td>
|
80 |
+
</tr>
|
81 |
+
|
82 |
+
<tr>
|
83 |
+
<td class="label"><label for="onclick">onclick</label>:</td>
|
84 |
+
<td><input id="onclick" name="onclick" type="text" value="" class="field" /></td>
|
85 |
+
</tr>
|
86 |
+
|
87 |
+
<tr>
|
88 |
+
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
89 |
+
<td><input id="ondblclick" name="ondblclick" type="text" value="" class="field" /></td>
|
90 |
+
</tr>
|
91 |
+
|
92 |
+
<tr>
|
93 |
+
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
94 |
+
<td><input id="onmousedown" name="onmousedown" type="text" value="" class="field" /></td>
|
95 |
+
</tr>
|
96 |
+
|
97 |
+
<tr>
|
98 |
+
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
99 |
+
<td><input id="onmouseup" name="onmouseup" type="text" value="" class="field" /></td>
|
100 |
+
</tr>
|
101 |
+
|
102 |
+
<tr>
|
103 |
+
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
104 |
+
<td><input id="onmouseover" name="onmouseover" type="text" value="" class="field" /></td>
|
105 |
+
</tr>
|
106 |
+
|
107 |
+
<tr>
|
108 |
+
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
109 |
+
<td><input id="onmousemove" name="onmousemove" type="text" value="" class="field" /></td>
|
110 |
+
</tr>
|
111 |
+
|
112 |
+
<tr>
|
113 |
+
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
114 |
+
<td><input id="onmouseout" name="onmouseout" type="text" value="" class="field" /></td>
|
115 |
+
</tr>
|
116 |
+
|
117 |
+
<tr>
|
118 |
+
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
119 |
+
<td><input id="onkeypress" name="onkeypress" type="text" value="" class="field" /></td>
|
120 |
+
</tr>
|
121 |
+
|
122 |
+
<tr>
|
123 |
+
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
124 |
+
<td><input id="onkeydown" name="onkeydown" type="text" value="" class="field" /></td>
|
125 |
+
</tr>
|
126 |
+
|
127 |
+
<tr>
|
128 |
+
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
129 |
+
<td><input id="onkeyup" name="onkeyup" type="text" value="" class="field" /></td>
|
130 |
+
</tr>
|
131 |
+
</table>
|
132 |
+
</fieldset>
|
133 |
+
</div>
|
134 |
+
</div>
|
135 |
+
<div class="mceActionPanel">
|
136 |
+
<input type="submit" id="insert" name="insert" value="{#update}" />
|
137 |
+
<input type="button" id="remove" name="remove" class="button" value="{#xhtmlxtras_dlg.remove}" onclick="removeCite();" style="display: none;" />
|
138 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
139 |
+
</div>
|
140 |
+
</form>
|
141 |
+
</body>
|
142 |
+
</html>
|
mce/xhtmlxtras/css/attributes.css
CHANGED
@@ -1,11 +1,13 @@
|
|
1 |
-
.panel_wrapper div.current {
|
2 |
-
height: 290px;
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
|
|
|
1 |
+
.panel_wrapper div.current {
|
2 |
+
min-height: 290px;
|
3 |
+
height: auto;
|
4 |
+
}
|
5 |
+
|
6 |
+
#events_panel input,
|
7 |
+
#id, #style, #title, #dir, #hreflang, #lang, #classlist, #tabindex, #accesskey {
|
8 |
+
width: 200px;
|
9 |
+
}
|
10 |
+
|
11 |
+
.mceActionPanel {
|
12 |
+
margin: 5px 0;
|
13 |
+
}
|
mce/xhtmlxtras/css/popup.css
CHANGED
@@ -1,9 +1,9 @@
|
|
1 |
-
input.field, select.field {width:200px;}
|
2 |
-
input.picker {width:179px; margin-left: 5px;}
|
3 |
-
input.disabled {border-color:#F2F2F2;}
|
4 |
-
img.picker {vertical-align:text-bottom; cursor:pointer;}
|
5 |
-
h1 {padding: 0 0 5px 0;}
|
6 |
-
.panel_wrapper div.current {height:160px;}
|
7 |
-
#xhtmlxtrasdel .panel_wrapper div.current, #xhtmlxtrasins .panel_wrapper div.current {height: 230px;}
|
8 |
-
a.browse span {display:block; width:20px; height:20px; background:url('../../../themes/advanced/img/icons.gif') -140px -20px;}
|
9 |
-
#datetime {width:180px;}
|
1 |
+
input.field, select.field {width:200px;}
|
2 |
+
input.picker {width:179px; margin-left: 5px;}
|
3 |
+
input.disabled {border-color:#F2F2F2;}
|
4 |
+
img.picker {vertical-align:text-bottom; cursor:pointer;}
|
5 |
+
h1 {padding: 0 0 5px 0;}
|
6 |
+
.panel_wrapper div.current {min-height:160px;height:auto;}
|
7 |
+
#xhtmlxtrasdel .panel_wrapper div.current, #xhtmlxtrasins .panel_wrapper div.current {height: 230px;}
|
8 |
+
a.browse span {display:block; width:20px; height:20px; background:url('../../../themes/advanced/img/icons.gif') -140px -20px;}
|
9 |
+
#datetime {width:180px;}
|
mce/xhtmlxtras/css/xhtmlxtras.css
CHANGED
@@ -1,24 +1,24 @@
|
|
1 |
-
ins {
|
2 |
-
border-bottom: 1px solid green;
|
3 |
-
text-decoration: none;
|
4 |
-
color: green;
|
5 |
-
}
|
6 |
-
|
7 |
-
del {
|
8 |
-
color: Red;
|
9 |
-
text-decoration: line-through;
|
10 |
-
}
|
11 |
-
|
12 |
-
cite {
|
13 |
-
border-bottom: 1px dashed blue;
|
14 |
-
}
|
15 |
-
|
16 |
-
acronym {
|
17 |
-
border-bottom: 1px dotted #CCC;
|
18 |
-
cursor: help;
|
19 |
-
}
|
20 |
-
|
21 |
-
abbr, html\:abbr {
|
22 |
-
border-bottom: 1px dashed #CCC;
|
23 |
-
cursor: help;
|
24 |
-
}
|
1 |
+
ins {
|
2 |
+
border-bottom: 1px solid green;
|
3 |
+
text-decoration: none;
|
4 |
+
color: green;
|
5 |
+
}
|
6 |
+
|
7 |
+
del {
|
8 |
+
color: Red;
|
9 |
+
text-decoration: line-through;
|
10 |
+
}
|
11 |
+
|
12 |
+
cite {
|
13 |
+
border-bottom: 1px dashed blue;
|
14 |
+
}
|
15 |
+
|
16 |
+
acronym {
|
17 |
+
border-bottom: 1px dotted #CCC;
|
18 |
+
cursor: help;
|
19 |
+
}
|
20 |
+
|
21 |
+
abbr, html\:abbr {
|
22 |
+
border-bottom: 1px dashed #CCC;
|
23 |
+
cursor: help;
|
24 |
+
}
|
mce/xhtmlxtras/del.htm
CHANGED
@@ -1,162 +1,162 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#xhtmlxtras_dlg.title_del_element}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
9 |
-
<script type="text/javascript" src="js/element_common.js?ver=
|
10 |
-
<script type="text/javascript" src="js/del.js?ver=
|
11 |
-
<link rel="stylesheet" type="text/css" href="css/popup.css?ver=
|
12 |
-
</head>
|
13 |
-
<body id="xhtmlxtrasins" style="display: none" role="application" aria-labelledby="app_title">
|
14 |
-
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.title_del_element}</span>
|
15 |
-
<form onsubmit="insertDel();return false;" action="#">
|
16 |
-
<div class="tabs">
|
17 |
-
<ul>
|
18 |
-
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.general_tab}</a></span></li>
|
19 |
-
<!-- <li id="events_tab"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.events_tab}</a></span></li> -->
|
20 |
-
</ul>
|
21 |
-
</div>
|
22 |
-
|
23 |
-
<div class="panel_wrapper">
|
24 |
-
<div id="general_panel" class="panel current">
|
25 |
-
<fieldset>
|
26 |
-
<legend>{#xhtmlxtras_dlg.fieldset_general_tab}</legend>
|
27 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
28 |
-
<tr>
|
29 |
-
<td class="label"><label id="datetimelabel" for="datetime">{#xhtmlxtras_dlg.attribute_label_datetime}</label>:</td>
|
30 |
-
<td>
|
31 |
-
<table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
32 |
-
<tr>
|
33 |
-
<td><input id="datetime" name="datetime" type="text" value="" maxlength="19" class="field mceFocus" /></td>
|
34 |
-
<td><a href="javascript:insertDateTime('datetime');" onmousedown="return false;" class="browse" role="button" aria-labelledby="datetimelabel"><span class="datetime" title="{#xhtmlxtras_dlg.insert_date}"></span></a></td>
|
35 |
-
</tr>
|
36 |
-
</table>
|
37 |
-
</td>
|
38 |
-
</tr>
|
39 |
-
<tr>
|
40 |
-
<td class="label"><label id="citelabel" for="cite">{#xhtmlxtras_dlg.attribute_label_cite}</label>:</td>
|
41 |
-
<td><input id="cite" name="cite" type="text" value="" class="field" /></td>
|
42 |
-
</tr>
|
43 |
-
</table>
|
44 |
-
</fieldset>
|
45 |
-
<fieldset>
|
46 |
-
<legend>{#xhtmlxtras_dlg.fieldset_attrib_tab}</legend>
|
47 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
48 |
-
<tr>
|
49 |
-
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
50 |
-
<td><input id="title" name="title" type="text" value="" class="field" /></td>
|
51 |
-
</tr>
|
52 |
-
<tr>
|
53 |
-
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
54 |
-
<td><input id="id" name="id" type="text" value="" class="field" /></td>
|
55 |
-
</tr>
|
56 |
-
<tr>
|
57 |
-
<td class="label"><label id="classlabel" for="class">{#xhtmlxtras_dlg.attribute_label_class}</label>:</td>
|
58 |
-
<td>
|
59 |
-
<select id="class" name="class" class="field mceEditableSelect">
|
60 |
-
<option value="">{#not_set}</option>
|
61 |
-
</select>
|
62 |
-
</td>
|
63 |
-
</tr>
|
64 |
-
<tr>
|
65 |
-
<td class="label"><label id="stylelabel" for="style">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
66 |
-
<td><input id="style" name="style" type="text" value="" class="field" /></td>
|
67 |
-
</tr>
|
68 |
-
<tr>
|
69 |
-
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
70 |
-
<td>
|
71 |
-
<select id="dir" name="dir" class="field">
|
72 |
-
<option value="">{#not_set}</option>
|
73 |
-
<option value="ltr">{#xhtmlxtras_dlg.attribute_option_ltr}</option>
|
74 |
-
<option value="rtl">{#xhtmlxtras_dlg.attribute_option_rtl}</option>
|
75 |
-
</select>
|
76 |
-
</td>
|
77 |
-
</tr>
|
78 |
-
<tr>
|
79 |
-
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
80 |
-
<td>
|
81 |
-
<input id="lang" name="lang" type="text" value="" class="field" />
|
82 |
-
</td>
|
83 |
-
</tr>
|
84 |
-
</table>
|
85 |
-
</fieldset>
|
86 |
-
</div>
|
87 |
-
<div id="events_panel" class="panel">
|
88 |
-
<fieldset>
|
89 |
-
<legend>{#xhtmlxtras_dlg.fieldset_events_tab}</legend>
|
90 |
-
|
91 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
92 |
-
<tr>
|
93 |
-
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
94 |
-
<td><input id="onfocus" name="onfocus" type="text" value="" class="field" /></td>
|
95 |
-
</tr>
|
96 |
-
|
97 |
-
<tr>
|
98 |
-
<td class="label"><label for="onblur">onblur</label>:</td>
|
99 |
-
<td><input id="onblur" name="onblur" type="text" value="" class="field" /></td>
|
100 |
-
</tr>
|
101 |
-
|
102 |
-
<tr>
|
103 |
-
<td class="label"><label for="onclick">onclick</label>:</td>
|
104 |
-
<td><input id="onclick" name="onclick" type="text" value="" class="field" /></td>
|
105 |
-
</tr>
|
106 |
-
|
107 |
-
<tr>
|
108 |
-
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
109 |
-
<td><input id="ondblclick" name="ondblclick" type="text" value="" class="field" /></td>
|
110 |
-
</tr>
|
111 |
-
|
112 |
-
<tr>
|
113 |
-
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
114 |
-
<td><input id="onmousedown" name="onmousedown" type="text" value="" class="field" /></td>
|
115 |
-
</tr>
|
116 |
-
|
117 |
-
<tr>
|
118 |
-
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
119 |
-
<td><input id="onmouseup" name="onmouseup" type="text" value="" class="field" /></td>
|
120 |
-
</tr>
|
121 |
-
|
122 |
-
<tr>
|
123 |
-
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
124 |
-
<td><input id="onmouseover" name="onmouseover" type="text" value="" class="field" /></td>
|
125 |
-
</tr>
|
126 |
-
|
127 |
-
<tr>
|
128 |
-
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
129 |
-
<td><input id="onmousemove" name="onmousemove" type="text" value="" class="field" /></td>
|
130 |
-
</tr>
|
131 |
-
|
132 |
-
<tr>
|
133 |
-
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
134 |
-
<td><input id="onmouseout" name="onmouseout" type="text" value="" class="field" /></td>
|
135 |
-
</tr>
|
136 |
-
|
137 |
-
<tr>
|
138 |
-
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
139 |
-
<td><input id="onkeypress" name="onkeypress" type="text" value="" class="field" /></td>
|
140 |
-
</tr>
|
141 |
-
|
142 |
-
<tr>
|
143 |
-
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
144 |
-
<td><input id="onkeydown" name="onkeydown" type="text" value="" class="field" /></td>
|
145 |
-
</tr>
|
146 |
-
|
147 |
-
<tr>
|
148 |
-
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
149 |
-
<td><input id="onkeyup" name="onkeyup" type="text" value="" class="field" /></td>
|
150 |
-
</tr>
|
151 |
-
</table>
|
152 |
-
</fieldset>
|
153 |
-
</div>
|
154 |
-
</div>
|
155 |
-
<div class="mceActionPanel">
|
156 |
-
<input type="submit" id="insert" name="insert" value="{#update}" />
|
157 |
-
<input type="button" id="remove" name="remove" class="button" value="{#xhtmlxtras_dlg.remove}" onclick="removeDel();" style="display: none;" />
|
158 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
159 |
-
</div>
|
160 |
-
</form>
|
161 |
-
</body>
|
162 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#xhtmlxtras_dlg.title_del_element}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="js/element_common.js?ver=359"></script>
|
10 |
+
<script type="text/javascript" src="js/del.js?ver=359"></script>
|
11 |
+
<link rel="stylesheet" type="text/css" href="css/popup.css?ver=359" />
|
12 |
+
</head>
|
13 |
+
<body id="xhtmlxtrasins" style="display: none" role="application" aria-labelledby="app_title">
|
14 |
+
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.title_del_element}</span>
|
15 |
+
<form onsubmit="insertDel();return false;" action="#">
|
16 |
+
<div class="tabs">
|
17 |
+
<ul>
|
18 |
+
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.general_tab}</a></span></li>
|
19 |
+
<!-- <li id="events_tab"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.events_tab}</a></span></li> -->
|
20 |
+
</ul>
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<div class="panel_wrapper">
|
24 |
+
<div id="general_panel" class="panel current">
|
25 |
+
<fieldset>
|
26 |
+
<legend>{#xhtmlxtras_dlg.fieldset_general_tab}</legend>
|
27 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
28 |
+
<tr>
|
29 |
+
<td class="label"><label id="datetimelabel" for="datetime">{#xhtmlxtras_dlg.attribute_label_datetime}</label>:</td>
|
30 |
+
<td>
|
31 |
+
<table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
32 |
+
<tr>
|
33 |
+
<td><input id="datetime" name="datetime" type="text" value="" maxlength="19" class="field mceFocus" /></td>
|
34 |
+
<td><a href="javascript:insertDateTime('datetime');" onmousedown="return false;" class="browse" role="button" aria-labelledby="datetimelabel"><span class="datetime" title="{#xhtmlxtras_dlg.insert_date}"></span></a></td>
|
35 |
+
</tr>
|
36 |
+
</table>
|
37 |
+
</td>
|
38 |
+
</tr>
|
39 |
+
<tr>
|
40 |
+
<td class="label"><label id="citelabel" for="cite">{#xhtmlxtras_dlg.attribute_label_cite}</label>:</td>
|
41 |
+
<td><input id="cite" name="cite" type="text" value="" class="field" /></td>
|
42 |
+
</tr>
|
43 |
+
</table>
|
44 |
+
</fieldset>
|
45 |
+
<fieldset>
|
46 |
+
<legend>{#xhtmlxtras_dlg.fieldset_attrib_tab}</legend>
|
47 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
48 |
+
<tr>
|
49 |
+
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
50 |
+
<td><input id="title" name="title" type="text" value="" class="field" /></td>
|
51 |
+
</tr>
|
52 |
+
<tr>
|
53 |
+
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
54 |
+
<td><input id="id" name="id" type="text" value="" class="field" /></td>
|
55 |
+
</tr>
|
56 |
+
<tr>
|
57 |
+
<td class="label"><label id="classlabel" for="class">{#xhtmlxtras_dlg.attribute_label_class}</label>:</td>
|
58 |
+
<td>
|
59 |
+
<select id="class" name="class" class="field mceEditableSelect">
|
60 |
+
<option value="">{#not_set}</option>
|
61 |
+
</select>
|
62 |
+
</td>
|
63 |
+
</tr>
|
64 |
+
<tr>
|
65 |
+
<td class="label"><label id="stylelabel" for="style">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
66 |
+
<td><input id="style" name="style" type="text" value="" class="field" /></td>
|
67 |
+
</tr>
|
68 |
+
<tr>
|
69 |
+
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
70 |
+
<td>
|
71 |
+
<select id="dir" name="dir" class="field">
|
72 |
+
<option value="">{#not_set}</option>
|
73 |
+
<option value="ltr">{#xhtmlxtras_dlg.attribute_option_ltr}</option>
|
74 |
+
<option value="rtl">{#xhtmlxtras_dlg.attribute_option_rtl}</option>
|
75 |
+
</select>
|
76 |
+
</td>
|
77 |
+
</tr>
|
78 |
+
<tr>
|
79 |
+
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
80 |
+
<td>
|
81 |
+
<input id="lang" name="lang" type="text" value="" class="field" />
|
82 |
+
</td>
|
83 |
+
</tr>
|
84 |
+
</table>
|
85 |
+
</fieldset>
|
86 |
+
</div>
|
87 |
+
<div id="events_panel" class="panel">
|
88 |
+
<fieldset>
|
89 |
+
<legend>{#xhtmlxtras_dlg.fieldset_events_tab}</legend>
|
90 |
+
|
91 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
92 |
+
<tr>
|
93 |
+
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
94 |
+
<td><input id="onfocus" name="onfocus" type="text" value="" class="field" /></td>
|
95 |
+
</tr>
|
96 |
+
|
97 |
+
<tr>
|
98 |
+
<td class="label"><label for="onblur">onblur</label>:</td>
|
99 |
+
<td><input id="onblur" name="onblur" type="text" value="" class="field" /></td>
|
100 |
+
</tr>
|
101 |
+
|
102 |
+
<tr>
|
103 |
+
<td class="label"><label for="onclick">onclick</label>:</td>
|
104 |
+
<td><input id="onclick" name="onclick" type="text" value="" class="field" /></td>
|
105 |
+
</tr>
|
106 |
+
|
107 |
+
<tr>
|
108 |
+
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
109 |
+
<td><input id="ondblclick" name="ondblclick" type="text" value="" class="field" /></td>
|
110 |
+
</tr>
|
111 |
+
|
112 |
+
<tr>
|
113 |
+
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
114 |
+
<td><input id="onmousedown" name="onmousedown" type="text" value="" class="field" /></td>
|
115 |
+
</tr>
|
116 |
+
|
117 |
+
<tr>
|
118 |
+
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
119 |
+
<td><input id="onmouseup" name="onmouseup" type="text" value="" class="field" /></td>
|
120 |
+
</tr>
|
121 |
+
|
122 |
+
<tr>
|
123 |
+
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
124 |
+
<td><input id="onmouseover" name="onmouseover" type="text" value="" class="field" /></td>
|
125 |
+
</tr>
|
126 |
+
|
127 |
+
<tr>
|
128 |
+
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
129 |
+
<td><input id="onmousemove" name="onmousemove" type="text" value="" class="field" /></td>
|
130 |
+
</tr>
|
131 |
+
|
132 |
+
<tr>
|
133 |
+
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
134 |
+
<td><input id="onmouseout" name="onmouseout" type="text" value="" class="field" /></td>
|
135 |
+
</tr>
|
136 |
+
|
137 |
+
<tr>
|
138 |
+
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
139 |
+
<td><input id="onkeypress" name="onkeypress" type="text" value="" class="field" /></td>
|
140 |
+
</tr>
|
141 |
+
|
142 |
+
<tr>
|
143 |
+
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
144 |
+
<td><input id="onkeydown" name="onkeydown" type="text" value="" class="field" /></td>
|
145 |
+
</tr>
|
146 |
+
|
147 |
+
<tr>
|
148 |
+
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
149 |
+
<td><input id="onkeyup" name="onkeyup" type="text" value="" class="field" /></td>
|
150 |
+
</tr>
|
151 |
+
</table>
|
152 |
+
</fieldset>
|
153 |
+
</div>
|
154 |
+
</div>
|
155 |
+
<div class="mceActionPanel">
|
156 |
+
<input type="submit" id="insert" name="insert" value="{#update}" />
|
157 |
+
<input type="button" id="remove" name="remove" class="button" value="{#xhtmlxtras_dlg.remove}" onclick="removeDel();" style="display: none;" />
|
158 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
159 |
+
</div>
|
160 |
+
</form>
|
161 |
+
</body>
|
162 |
+
</html>
|
mce/xhtmlxtras/ins.htm
CHANGED
@@ -1,162 +1,162 @@
|
|
1 |
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
-
<head>
|
4 |
-
<title>{#xhtmlxtras_dlg.title_ins_element}</title>
|
5 |
-
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=
|
6 |
-
<script type="text/javascript" src="../../utils/mctabs.js?ver=
|
7 |
-
<script type="text/javascript" src="../../utils/form_utils.js?ver=
|
8 |
-
<script type="text/javascript" src="../../utils/editable_selects.js?ver=
|
9 |
-
<script type="text/javascript" src="js/element_common.js?ver=
|
10 |
-
<script type="text/javascript" src="js/ins.js?ver=
|
11 |
-
<link rel="stylesheet" type="text/css" href="css/popup.css?ver=
|
12 |
-
</head>
|
13 |
-
<body id="xhtmlxtrasins" style="display: none" role="application" aria-labelledby="app_title">
|
14 |
-
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.title_ins_element}</span>
|
15 |
-
<form onsubmit="insertIns();return false;" action="#">
|
16 |
-
<div class="tabs">
|
17 |
-
<ul>
|
18 |
-
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.general_tab}</a></span></li>
|
19 |
-
<!-- <li id="events_tab"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.events_tab}</a></span></li> -->
|
20 |
-
</ul>
|
21 |
-
</div>
|
22 |
-
|
23 |
-
<div class="panel_wrapper">
|
24 |
-
<div id="general_panel" class="panel current">
|
25 |
-
<fieldset>
|
26 |
-
<legend>{#xhtmlxtras_dlg.fieldset_general_tab}</legend>
|
27 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
28 |
-
<tr>
|
29 |
-
<td class="label"><label id="datetimelabel" for="datetime">{#xhtmlxtras_dlg.attribute_label_datetime}</label>:</td>
|
30 |
-
<td>
|
31 |
-
<table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
32 |
-
<tr>
|
33 |
-
<td><input id="datetime" name="datetime" type="text" value="" maxlength="19" class="field mceFocus" /></td>
|
34 |
-
<td ><a href="javascript:insertDateTime('datetime');" onmousedown="return false;" class="browse" role="button" aria-labelledby="datetimelabel"><span class="datetime" title="{#xhtmlxtras_dlg.insert_date}"></span></a></td>
|
35 |
-
</tr>
|
36 |
-
</table>
|
37 |
-
</td>
|
38 |
-
</tr>
|
39 |
-
<tr >
|
40 |
-
<td class="label"><label id="citelabel" for="cite">{#xhtmlxtras_dlg.attribute_label_cite}</label>:</td>
|
41 |
-
<td><input id="cite" name="cite" type="text" value="" class="field" /></td>
|
42 |
-
</tr>
|
43 |
-
</table>
|
44 |
-
</fieldset>
|
45 |
-
<fieldset>
|
46 |
-
<legend>{#xhtmlxtras_dlg.fieldset_attrib_tab}</legend>
|
47 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
48 |
-
<tr>
|
49 |
-
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
50 |
-
<td><input id="title" name="title" type="text" value="" class="field" /></td>
|
51 |
-
</tr>
|
52 |
-
<tr>
|
53 |
-
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
54 |
-
<td><input id="id" name="id" type="text" value="" class="field" /></td>
|
55 |
-
</tr>
|
56 |
-
<tr>
|
57 |
-
<td class="label"><label id="classlabel" for="class">{#xhtmlxtras_dlg.attribute_label_class}</label>:</td>
|
58 |
-
<td>
|
59 |
-
<select id="class" name="class" class="field mceEditableSelect">
|
60 |
-
<option value="">{#not_set}</option>
|
61 |
-
</select>
|
62 |
-
</td>
|
63 |
-
</tr>
|
64 |
-
<tr>
|
65 |
-
<td class="label"><label id="stylelabel" for="style">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
66 |
-
<td><input id="style" name="style" type="text" value="" class="field" /></td>
|
67 |
-
</tr>
|
68 |
-
<tr>
|
69 |
-
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
70 |
-
<td>
|
71 |
-
<select id="dir" name="dir" class="field">
|
72 |
-
<option value="">{#not_set}</option>
|
73 |
-
<option value="ltr">{#xhtmlxtras_dlg.attribute_option_ltr}</option>
|
74 |
-
<option value="rtl">{#xhtmlxtras_dlg.attribute_option_rtl}</option>
|
75 |
-
</select>
|
76 |
-
</td>
|
77 |
-
</tr>
|
78 |
-
<tr>
|
79 |
-
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
80 |
-
<td>
|
81 |
-
<input id="lang" name="lang" type="text" value="" class="field" />
|
82 |
-
</td>
|
83 |
-
</tr>
|
84 |
-
</table>
|
85 |
-
</fieldset>
|
86 |
-
</div>
|
87 |
-
<div id="events_panel" class="panel">
|
88 |
-
<fieldset>
|
89 |
-
<legend>{#xhtmlxtras_dlg.fieldset_events_tab}</legend>
|
90 |
-
|
91 |
-
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
92 |
-
<tr>
|
93 |
-
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
94 |
-
<td><input id="onfocus" name="onfocus" type="text" value="" class="field" /></td>
|
95 |
-
</tr>
|
96 |
-
|
97 |
-
<tr>
|
98 |
-
<td class="label"><label for="onblur">onblur</label>:</td>
|
99 |
-
<td><input id="onblur" name="onblur" type="text" value="" class="field" /></td>
|
100 |
-
</tr>
|
101 |
-
|
102 |
-
<tr>
|
103 |
-
<td class="label"><label for="onclick">onclick</label>:</td>
|
104 |
-
<td><input id="onclick" name="onclick" type="text" value="" class="field" /></td>
|
105 |
-
</tr>
|
106 |
-
|
107 |
-
<tr>
|
108 |
-
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
109 |
-
<td><input id="ondblclick" name="ondblclick" type="text" value="" class="field" /></td>
|
110 |
-
</tr>
|
111 |
-
|
112 |
-
<tr>
|
113 |
-
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
114 |
-
<td><input id="onmousedown" name="onmousedown" type="text" value="" class="field" /></td>
|
115 |
-
</tr>
|
116 |
-
|
117 |
-
<tr>
|
118 |
-
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
119 |
-
<td><input id="onmouseup" name="onmouseup" type="text" value="" class="field" /></td>
|
120 |
-
</tr>
|
121 |
-
|
122 |
-
<tr>
|
123 |
-
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
124 |
-
<td><input id="onmouseover" name="onmouseover" type="text" value="" class="field" /></td>
|
125 |
-
</tr>
|
126 |
-
|
127 |
-
<tr>
|
128 |
-
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
129 |
-
<td><input id="onmousemove" name="onmousemove" type="text" value="" class="field" /></td>
|
130 |
-
</tr>
|
131 |
-
|
132 |
-
<tr>
|
133 |
-
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
134 |
-
<td><input id="onmouseout" name="onmouseout" type="text" value="" class="field" /></td>
|
135 |
-
</tr>
|
136 |
-
|
137 |
-
<tr>
|
138 |
-
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
139 |
-
<td><input id="onkeypress" name="onkeypress" type="text" value="" class="field" /></td>
|
140 |
-
</tr>
|
141 |
-
|
142 |
-
<tr>
|
143 |
-
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
144 |
-
<td><input id="onkeydown" name="onkeydown" type="text" value="" class="field" /></td>
|
145 |
-
</tr>
|
146 |
-
|
147 |
-
<tr>
|
148 |
-
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
149 |
-
<td><input id="onkeyup" name="onkeyup" type="text" value="" class="field" /></td>
|
150 |
-
</tr>
|
151 |
-
</table>
|
152 |
-
</fieldset>
|
153 |
-
</div>
|
154 |
-
</div>
|
155 |
-
<div class="mceActionPanel">
|
156 |
-
<input type="submit" id="insert" name="insert" value="{#update}" />
|
157 |
-
<input type="button" id="remove" name="remove" class="button" value="{#xhtmlxtras_dlg.remove}" onclick="removeIns();" style="display: none;" />
|
158 |
-
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
159 |
-
</div>
|
160 |
-
</form>
|
161 |
-
</body>
|
162 |
-
</html>
|
1 |
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2 |
+
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
+
<head>
|
4 |
+
<title>{#xhtmlxtras_dlg.title_ins_element}</title>
|
5 |
+
<script type="text/javascript" src="../../tiny_mce_popup.js?ver=359"></script>
|
6 |
+
<script type="text/javascript" src="../../utils/mctabs.js?ver=359"></script>
|
7 |
+
<script type="text/javascript" src="../../utils/form_utils.js?ver=359"></script>
|
8 |
+
<script type="text/javascript" src="../../utils/editable_selects.js?ver=359"></script>
|
9 |
+
<script type="text/javascript" src="js/element_common.js?ver=359"></script>
|
10 |
+
<script type="text/javascript" src="js/ins.js?ver=359"></script>
|
11 |
+
<link rel="stylesheet" type="text/css" href="css/popup.css?ver=359" />
|
12 |
+
</head>
|
13 |
+
<body id="xhtmlxtrasins" style="display: none" role="application" aria-labelledby="app_title">
|
14 |
+
<span style="display:none;" id="app_title">{#xhtmlxtras_dlg.title_ins_element}</span>
|
15 |
+
<form onsubmit="insertIns();return false;" action="#">
|
16 |
+
<div class="tabs">
|
17 |
+
<ul>
|
18 |
+
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.general_tab}</a></span></li>
|
19 |
+
<!-- <li id="events_tab"><span><a href="javascript:mcTabs.displayTab('events_tab','events_panel');" onmousedown="return false;">{#xhtmlxtras_dlg.events_tab}</a></span></li> -->
|
20 |
+
</ul>
|
21 |
+
</div>
|
22 |
+
|
23 |
+
<div class="panel_wrapper">
|
24 |
+
<div id="general_panel" class="panel current">
|
25 |
+
<fieldset>
|
26 |
+
<legend>{#xhtmlxtras_dlg.fieldset_general_tab}</legend>
|
27 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
28 |
+
<tr>
|
29 |
+
<td class="label"><label id="datetimelabel" for="datetime">{#xhtmlxtras_dlg.attribute_label_datetime}</label>:</td>
|
30 |
+
<td>
|
31 |
+
<table role="presentation" border="0" cellspacing="0" cellpadding="0">
|
32 |
+
<tr>
|
33 |
+
<td><input id="datetime" name="datetime" type="text" value="" maxlength="19" class="field mceFocus" /></td>
|
34 |
+
<td ><a href="javascript:insertDateTime('datetime');" onmousedown="return false;" class="browse" role="button" aria-labelledby="datetimelabel"><span class="datetime" title="{#xhtmlxtras_dlg.insert_date}"></span></a></td>
|
35 |
+
</tr>
|
36 |
+
</table>
|
37 |
+
</td>
|
38 |
+
</tr>
|
39 |
+
<tr >
|
40 |
+
<td class="label"><label id="citelabel" for="cite">{#xhtmlxtras_dlg.attribute_label_cite}</label>:</td>
|
41 |
+
<td><input id="cite" name="cite" type="text" value="" class="field" /></td>
|
42 |
+
</tr>
|
43 |
+
</table>
|
44 |
+
</fieldset>
|
45 |
+
<fieldset>
|
46 |
+
<legend>{#xhtmlxtras_dlg.fieldset_attrib_tab}</legend>
|
47 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
48 |
+
<tr>
|
49 |
+
<td class="label"><label id="titlelabel" for="title">{#xhtmlxtras_dlg.attribute_label_title}</label>:</td>
|
50 |
+
<td><input id="title" name="title" type="text" value="" class="field" /></td>
|
51 |
+
</tr>
|
52 |
+
<tr>
|
53 |
+
<td class="label"><label id="idlabel" for="id">{#xhtmlxtras_dlg.attribute_label_id}</label>:</td>
|
54 |
+
<td><input id="id" name="id" type="text" value="" class="field" /></td>
|
55 |
+
</tr>
|
56 |
+
<tr>
|
57 |
+
<td class="label"><label id="classlabel" for="class">{#xhtmlxtras_dlg.attribute_label_class}</label>:</td>
|
58 |
+
<td>
|
59 |
+
<select id="class" name="class" class="field mceEditableSelect">
|
60 |
+
<option value="">{#not_set}</option>
|
61 |
+
</select>
|
62 |
+
</td>
|
63 |
+
</tr>
|
64 |
+
<tr>
|
65 |
+
<td class="label"><label id="stylelabel" for="style">{#xhtmlxtras_dlg.attribute_label_style}</label>:</td>
|
66 |
+
<td><input id="style" name="style" type="text" value="" class="field" /></td>
|
67 |
+
</tr>
|
68 |
+
<tr>
|
69 |
+
<td class="label"><label id="dirlabel" for="dir">{#xhtmlxtras_dlg.attribute_label_langdir}</label>:</td>
|
70 |
+
<td>
|
71 |
+
<select id="dir" name="dir" class="field">
|
72 |
+
<option value="">{#not_set}</option>
|
73 |
+
<option value="ltr">{#xhtmlxtras_dlg.attribute_option_ltr}</option>
|
74 |
+
<option value="rtl">{#xhtmlxtras_dlg.attribute_option_rtl}</option>
|
75 |
+
</select>
|
76 |
+
</td>
|
77 |
+
</tr>
|
78 |
+
<tr>
|
79 |
+
<td class="label"><label id="langlabel" for="lang">{#xhtmlxtras_dlg.attribute_label_langcode}</label>:</td>
|
80 |
+
<td>
|
81 |
+
<input id="lang" name="lang" type="text" value="" class="field" />
|
82 |
+
</td>
|
83 |
+
</tr>
|
84 |
+
</table>
|
85 |
+
</fieldset>
|
86 |
+
</div>
|
87 |
+
<div id="events_panel" class="panel">
|
88 |
+
<fieldset>
|
89 |
+
<legend>{#xhtmlxtras_dlg.fieldset_events_tab}</legend>
|
90 |
+
|
91 |
+
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
|
92 |
+
<tr>
|
93 |
+
<td class="label"><label for="onfocus">onfocus</label>:</td>
|
94 |
+
<td><input id="onfocus" name="onfocus" type="text" value="" class="field" /></td>
|
95 |
+
</tr>
|
96 |
+
|
97 |
+
<tr>
|
98 |
+
<td class="label"><label for="onblur">onblur</label>:</td>
|
99 |
+
<td><input id="onblur" name="onblur" type="text" value="" class="field" /></td>
|
100 |
+
</tr>
|
101 |
+
|
102 |
+
<tr>
|
103 |
+
<td class="label"><label for="onclick">onclick</label>:</td>
|
104 |
+
<td><input id="onclick" name="onclick" type="text" value="" class="field" /></td>
|
105 |
+
</tr>
|
106 |
+
|
107 |
+
<tr>
|
108 |
+
<td class="label"><label for="ondblclick">ondblclick</label>:</td>
|
109 |
+
<td><input id="ondblclick" name="ondblclick" type="text" value="" class="field" /></td>
|
110 |
+
</tr>
|
111 |
+
|
112 |
+
<tr>
|
113 |
+
<td class="label"><label for="onmousedown">onmousedown</label>:</td>
|
114 |
+
<td><input id="onmousedown" name="onmousedown" type="text" value="" class="field" /></td>
|
115 |
+
</tr>
|
116 |
+
|
117 |
+
<tr>
|
118 |
+
<td class="label"><label for="onmouseup">onmouseup</label>:</td>
|
119 |
+
<td><input id="onmouseup" name="onmouseup" type="text" value="" class="field" /></td>
|
120 |
+
</tr>
|
121 |
+
|
122 |
+
<tr>
|
123 |
+
<td class="label"><label for="onmouseover">onmouseover</label>:</td>
|
124 |
+
<td><input id="onmouseover" name="onmouseover" type="text" value="" class="field" /></td>
|
125 |
+
</tr>
|
126 |
+
|
127 |
+
<tr>
|
128 |
+
<td class="label"><label for="onmousemove">onmousemove</label>:</td>
|
129 |
+
<td><input id="onmousemove" name="onmousemove" type="text" value="" class="field" /></td>
|
130 |
+
</tr>
|
131 |
+
|
132 |
+
<tr>
|
133 |
+
<td class="label"><label for="onmouseout">onmouseout</label>:</td>
|
134 |
+
<td><input id="onmouseout" name="onmouseout" type="text" value="" class="field" /></td>
|
135 |
+
</tr>
|
136 |
+
|
137 |
+
<tr>
|
138 |
+
<td class="label"><label for="onkeypress">onkeypress</label>:</td>
|
139 |
+
<td><input id="onkeypress" name="onkeypress" type="text" value="" class="field" /></td>
|
140 |
+
</tr>
|
141 |
+
|
142 |
+
<tr>
|
143 |
+
<td class="label"><label for="onkeydown">onkeydown</label>:</td>
|
144 |
+
<td><input id="onkeydown" name="onkeydown" type="text" value="" class="field" /></td>
|
145 |
+
</tr>
|
146 |
+
|
147 |
+
<tr>
|
148 |
+
<td class="label"><label for="onkeyup">onkeyup</label>:</td>
|
149 |
+
<td><input id="onkeyup" name="onkeyup" type="text" value="" class="field" /></td>
|
150 |
+
</tr>
|
151 |
+
</table>
|
152 |
+
</fieldset>
|
153 |
+
</div>
|
154 |
+
</div>
|
155 |
+
<div class="mceActionPanel">
|
156 |
+
<input type="submit" id="insert" name="insert" value="{#update}" />
|
157 |
+
<input type="button" id="remove" name="remove" class="button" value="{#xhtmlxtras_dlg.remove}" onclick="removeIns();" style="display: none;" />
|
158 |
+
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
|
159 |
+
</div>
|
160 |
+
</form>
|
161 |
+
</body>
|
162 |
+
</html>
|
mce/xhtmlxtras/js/abbr.js
CHANGED
@@ -1,28 +1,28 @@
|
|
1 |
-
/**
|
2 |
-
* abbr.js
|
3 |
-
*
|
4 |
-
* Copyright 2009, Moxiecode Systems AB
|
5 |
-
* Released under LGPL License.
|
6 |
-
*
|
7 |
-
* License: http://tinymce.moxiecode.com/license
|
8 |
-
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
-
*/
|
10 |
-
|
11 |
-
function init() {
|
12 |
-
SXE.initElementDialog('abbr');
|
13 |
-
if (SXE.currentAction == "update") {
|
14 |
-
SXE.showRemoveButton();
|
15 |
-
}
|
16 |
-
}
|
17 |
-
|
18 |
-
function insertAbbr() {
|
19 |
-
SXE.insertElement('abbr');
|
20 |
-
tinyMCEPopup.close();
|
21 |
-
}
|
22 |
-
|
23 |
-
function removeAbbr() {
|
24 |
-
SXE.removeElement('abbr');
|
25 |
-
tinyMCEPopup.close();
|
26 |
-
}
|
27 |
-
|
28 |
-
tinyMCEPopup.onInit.add(init);
|
1 |
+
/**
|
2 |
+
* abbr.js
|
3 |
+
*
|
4 |
+
* Copyright 2009, Moxiecode Systems AB
|
5 |
+
* Released under LGPL License.
|
6 |
+
*
|
7 |
+
* License: http://tinymce.moxiecode.com/license
|
8 |
+
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
+
*/
|
10 |
+
|
11 |
+
function init() {
|
12 |
+
SXE.initElementDialog('abbr');
|
13 |
+
if (SXE.currentAction == "update") {
|
14 |
+
SXE.showRemoveButton();
|
15 |
+
}
|
16 |
+
}
|
17 |
+
|
18 |
+
function insertAbbr() {
|
19 |
+
SXE.insertElement('abbr');
|
20 |
+
tinyMCEPopup.close();
|
21 |
+
}
|
22 |
+
|
23 |
+
function removeAbbr() {
|
24 |
+
SXE.removeElement('abbr');
|
25 |
+
tinyMCEPopup.close();
|
26 |
+
}
|
27 |
+
|
28 |
+
tinyMCEPopup.onInit.add(init);
|
mce/xhtmlxtras/js/acronym.js
CHANGED
@@ -1,28 +1,28 @@
|
|
1 |
-
/**
|
2 |
-
* acronym.js
|
3 |
-
*
|
4 |
-
* Copyright 2009, Moxiecode Systems AB
|
5 |
-
* Released under LGPL License.
|
6 |
-
*
|
7 |
-
* License: http://tinymce.moxiecode.com/license
|
8 |
-
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
-
*/
|
10 |
-
|
11 |
-
function init() {
|
12 |
-
SXE.initElementDialog('acronym');
|
13 |
-
if (SXE.currentAction == "update") {
|
14 |
-
SXE.showRemoveButton();
|
15 |
-
}
|
16 |
-
}
|
17 |
-
|
18 |
-
function insertAcronym() {
|
19 |
-
SXE.insertElement('acronym');
|
20 |
-
tinyMCEPopup.close();
|
21 |
-
}
|
22 |
-
|
23 |
-
function removeAcronym() {
|
24 |
-
SXE.removeElement('acronym');
|
25 |
-
tinyMCEPopup.close();
|
26 |
-
}
|
27 |
-
|
28 |
-
tinyMCEPopup.onInit.add(init);
|
1 |
+
/**
|
2 |
+
* acronym.js
|
3 |
+
*
|
4 |
+
* Copyright 2009, Moxiecode Systems AB
|
5 |
+
* Released under LGPL License.
|
6 |
+
*
|
7 |
+
* License: http://tinymce.moxiecode.com/license
|
8 |
+
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
+
*/
|
10 |
+
|
11 |
+
function init() {
|
12 |
+
SXE.initElementDialog('acronym');
|
13 |
+
if (SXE.currentAction == "update") {
|
14 |
+
SXE.showRemoveButton();
|
15 |
+
}
|
16 |
+
}
|
17 |
+
|
18 |
+
function insertAcronym() {
|
19 |
+
SXE.insertElement('acronym');
|
20 |
+
tinyMCEPopup.close();
|
21 |
+
}
|
22 |
+
|
23 |
+
function removeAcronym() {
|
24 |
+
SXE.removeElement('acronym');
|
25 |
+
tinyMCEPopup.close();
|
26 |
+
}
|
27 |
+
|
28 |
+
tinyMCEPopup.onInit.add(init);
|
mce/xhtmlxtras/js/attributes.js
CHANGED
@@ -1,111 +1,111 @@
|
|
1 |
-
/**
|
2 |
-
* attributes.js
|
3 |
-
*
|
4 |
-
* Copyright 2009, Moxiecode Systems AB
|
5 |
-
* Released under LGPL License.
|
6 |
-
*
|
7 |
-
* License: http://tinymce.moxiecode.com/license
|
8 |
-
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
-
*/
|
10 |
-
|
11 |
-
function init() {
|
12 |
-
tinyMCEPopup.resizeToInnerSize();
|
13 |
-
var inst = tinyMCEPopup.editor;
|
14 |
-
var dom = inst.dom;
|
15 |
-
var elm = inst.selection.getNode();
|
16 |
-
var f = document.forms[0];
|
17 |
-
var onclick = dom.getAttrib(elm, 'onclick');
|
18 |
-
|
19 |
-
setFormValue('title', dom.getAttrib(elm, 'title'));
|
20 |
-
setFormValue('id', dom.getAttrib(elm, 'id'));
|
21 |
-
setFormValue('style', dom.getAttrib(elm, "style"));
|
22 |
-
setFormValue('dir', dom.getAttrib(elm, 'dir'));
|
23 |
-
setFormValue('lang', dom.getAttrib(elm, 'lang'));
|
24 |
-
setFormValue('tabindex', dom.getAttrib(elm, 'tabindex', typeof(elm.tabindex) != "undefined" ? elm.tabindex : ""));
|
25 |
-
setFormValue('accesskey', dom.getAttrib(elm, 'accesskey', typeof(elm.accesskey) != "undefined" ? elm.accesskey : ""));
|
26 |
-
setFormValue('onfocus', dom.getAttrib(elm, 'onfocus'));
|
27 |
-
setFormValue('onblur', dom.getAttrib(elm, 'onblur'));
|
28 |
-
setFormValue('onclick', onclick);
|
29 |
-
setFormValue('ondblclick', dom.getAttrib(elm, 'ondblclick'));
|
30 |
-
setFormValue('onmousedown', dom.getAttrib(elm, 'onmousedown'));
|
31 |
-
setFormValue('onmouseup', dom.getAttrib(elm, 'onmouseup'));
|
32 |
-
setFormValue('onmouseover', dom.getAttrib(elm, 'onmouseover'));
|
33 |
-
setFormValue('onmousemove', dom.getAttrib(elm, 'onmousemove'));
|
34 |
-
setFormValue('onmouseout', dom.getAttrib(elm, 'onmouseout'));
|
35 |
-
setFormValue('onkeypress', dom.getAttrib(elm, 'onkeypress'));
|
36 |
-
setFormValue('onkeydown', dom.getAttrib(elm, 'onkeydown'));
|
37 |
-
setFormValue('onkeyup', dom.getAttrib(elm, 'onkeyup'));
|
38 |
-
className = dom.getAttrib(elm, 'class');
|
39 |
-
|
40 |
-
addClassesToList('classlist', 'advlink_styles');
|
41 |
-
selectByValue(f, 'classlist', className, true);
|
42 |
-
|
43 |
-
TinyMCE_EditableSelects.init();
|
44 |
-
}
|
45 |
-
|
46 |
-
function setFormValue(name, value) {
|
47 |
-
if(value && document.forms[0].elements[name]){
|
48 |
-
document.forms[0].elements[name].value = value;
|
49 |
-
}
|
50 |
-
}
|
51 |
-
|
52 |
-
function insertAction() {
|
53 |
-
var inst = tinyMCEPopup.editor;
|
54 |
-
var elm = inst.selection.getNode();
|
55 |
-
|
56 |
-
setAllAttribs(elm);
|
57 |
-
tinyMCEPopup.execCommand("mceEndUndoLevel");
|
58 |
-
tinyMCEPopup.close();
|
59 |
-
}
|
60 |
-
|
61 |
-
function setAttrib(elm, attrib, value) {
|
62 |
-
var formObj = document.forms[0];
|
63 |
-
var valueElm = formObj.elements[attrib.toLowerCase()];
|
64 |
-
var inst = tinyMCEPopup.editor;
|
65 |
-
var dom = inst.dom;
|
66 |
-
|
67 |
-
if (typeof(value) == "undefined" || value == null) {
|
68 |
-
value = "";
|
69 |
-
|
70 |
-
if (valueElm)
|
71 |
-
value = valueElm.value;
|
72 |
-
}
|
73 |
-
|
74 |
-
dom.setAttrib(elm, attrib.toLowerCase(), value);
|
75 |
-
}
|
76 |
-
|
77 |
-
function setAllAttribs(elm) {
|
78 |
-
var f = document.forms[0];
|
79 |
-
|
80 |
-
setAttrib(elm, 'title');
|
81 |
-
setAttrib(elm, 'id');
|
82 |
-
setAttrib(elm, 'style');
|
83 |
-
setAttrib(elm, 'class', getSelectValue(f, 'classlist'));
|
84 |
-
setAttrib(elm, 'dir');
|
85 |
-
setAttrib(elm, 'lang');
|
86 |
-
setAttrib(elm, 'tabindex');
|
87 |
-
setAttrib(elm, 'accesskey');
|
88 |
-
setAttrib(elm, 'onfocus');
|
89 |
-
setAttrib(elm, 'onblur');
|
90 |
-
setAttrib(elm, 'onclick');
|
91 |
-
setAttrib(elm, 'ondblclick');
|
92 |
-
setAttrib(elm, 'onmousedown');
|
93 |
-
setAttrib(elm, 'onmouseup');
|
94 |
-
setAttrib(elm, 'onmouseover');
|
95 |
-
setAttrib(elm, 'onmousemove');
|
96 |
-
setAttrib(elm, 'onmouseout');
|
97 |
-
setAttrib(elm, 'onkeypress');
|
98 |
-
setAttrib(elm, 'onkeydown');
|
99 |
-
setAttrib(elm, 'onkeyup');
|
100 |
-
|
101 |
-
// Refresh in old MSIE
|
102 |
-
// if (tinyMCE.isMSIE5)
|
103 |
-
// elm.outerHTML = elm.outerHTML;
|
104 |
-
}
|
105 |
-
|
106 |
-
function insertAttribute() {
|
107 |
-
tinyMCEPopup.close();
|
108 |
-
}
|
109 |
-
|
110 |
-
tinyMCEPopup.onInit.add(init);
|
111 |
-
tinyMCEPopup.requireLangPack();
|
1 |
+
/**
|
2 |
+
* attributes.js
|
3 |
+
*
|
4 |
+
* Copyright 2009, Moxiecode Systems AB
|
5 |
+
* Released under LGPL License.
|
6 |
+
*
|
7 |
+
* License: http://tinymce.moxiecode.com/license
|
8 |
+
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
+
*/
|
10 |
+
|
11 |
+
function init() {
|
12 |
+
tinyMCEPopup.resizeToInnerSize();
|
13 |
+
var inst = tinyMCEPopup.editor;
|
14 |
+
var dom = inst.dom;
|
15 |
+
var elm = inst.selection.getNode();
|
16 |
+
var f = document.forms[0];
|
17 |
+
var onclick = dom.getAttrib(elm, 'onclick');
|
18 |
+
|
19 |
+
setFormValue('title', dom.getAttrib(elm, 'title'));
|
20 |
+
setFormValue('id', dom.getAttrib(elm, 'id'));
|
21 |
+
setFormValue('style', dom.getAttrib(elm, "style"));
|
22 |
+
setFormValue('dir', dom.getAttrib(elm, 'dir'));
|
23 |
+
setFormValue('lang', dom.getAttrib(elm, 'lang'));
|
24 |
+
setFormValue('tabindex', dom.getAttrib(elm, 'tabindex', typeof(elm.tabindex) != "undefined" ? elm.tabindex : ""));
|
25 |
+
setFormValue('accesskey', dom.getAttrib(elm, 'accesskey', typeof(elm.accesskey) != "undefined" ? elm.accesskey : ""));
|
26 |
+
setFormValue('onfocus', dom.getAttrib(elm, 'onfocus'));
|
27 |
+
setFormValue('onblur', dom.getAttrib(elm, 'onblur'));
|
28 |
+
setFormValue('onclick', onclick);
|
29 |
+
setFormValue('ondblclick', dom.getAttrib(elm, 'ondblclick'));
|
30 |
+
setFormValue('onmousedown', dom.getAttrib(elm, 'onmousedown'));
|
31 |
+
setFormValue('onmouseup', dom.getAttrib(elm, 'onmouseup'));
|
32 |
+
setFormValue('onmouseover', dom.getAttrib(elm, 'onmouseover'));
|
33 |
+
setFormValue('onmousemove', dom.getAttrib(elm, 'onmousemove'));
|
34 |
+
setFormValue('onmouseout', dom.getAttrib(elm, 'onmouseout'));
|
35 |
+
setFormValue('onkeypress', dom.getAttrib(elm, 'onkeypress'));
|
36 |
+
setFormValue('onkeydown', dom.getAttrib(elm, 'onkeydown'));
|
37 |
+
setFormValue('onkeyup', dom.getAttrib(elm, 'onkeyup'));
|
38 |
+
className = dom.getAttrib(elm, 'class');
|
39 |
+
|
40 |
+
addClassesToList('classlist', 'advlink_styles');
|
41 |
+
selectByValue(f, 'classlist', className, true);
|
42 |
+
|
43 |
+
TinyMCE_EditableSelects.init();
|
44 |
+
}
|
45 |
+
|
46 |
+
function setFormValue(name, value) {
|
47 |
+
if(value && document.forms[0].elements[name]){
|
48 |
+
document.forms[0].elements[name].value = value;
|
49 |
+
}
|
50 |
+
}
|
51 |
+
|
52 |
+
function insertAction() {
|
53 |
+
var inst = tinyMCEPopup.editor;
|
54 |
+
var elm = inst.selection.getNode();
|
55 |
+
|
56 |
+
setAllAttribs(elm);
|
57 |
+
tinyMCEPopup.execCommand("mceEndUndoLevel");
|
58 |
+
tinyMCEPopup.close();
|
59 |
+
}
|
60 |
+
|
61 |
+
function setAttrib(elm, attrib, value) {
|
62 |
+
var formObj = document.forms[0];
|
63 |
+
var valueElm = formObj.elements[attrib.toLowerCase()];
|
64 |
+
var inst = tinyMCEPopup.editor;
|
65 |
+
var dom = inst.dom;
|
66 |
+
|
67 |
+
if (typeof(value) == "undefined" || value == null) {
|
68 |
+
value = "";
|
69 |
+
|
70 |
+
if (valueElm)
|
71 |
+
value = valueElm.value;
|
72 |
+
}
|
73 |
+
|
74 |
+
dom.setAttrib(elm, attrib.toLowerCase(), value);
|
75 |
+
}
|
76 |
+
|
77 |
+
function setAllAttribs(elm) {
|
78 |
+
var f = document.forms[0];
|
79 |
+
|
80 |
+
setAttrib(elm, 'title');
|
81 |
+
setAttrib(elm, 'id');
|
82 |
+
setAttrib(elm, 'style');
|
83 |
+
setAttrib(elm, 'class', getSelectValue(f, 'classlist'));
|
84 |
+
setAttrib(elm, 'dir');
|
85 |
+
setAttrib(elm, 'lang');
|
86 |
+
setAttrib(elm, 'tabindex');
|
87 |
+
setAttrib(elm, 'accesskey');
|
88 |
+
setAttrib(elm, 'onfocus');
|
89 |
+
setAttrib(elm, 'onblur');
|
90 |
+
setAttrib(elm, 'onclick');
|
91 |
+
setAttrib(elm, 'ondblclick');
|
92 |
+
setAttrib(elm, 'onmousedown');
|
93 |
+
setAttrib(elm, 'onmouseup');
|
94 |
+
setAttrib(elm, 'onmouseover');
|
95 |
+
setAttrib(elm, 'onmousemove');
|
96 |
+
setAttrib(elm, 'onmouseout');
|
97 |
+
setAttrib(elm, 'onkeypress');
|
98 |
+
setAttrib(elm, 'onkeydown');
|
99 |
+
setAttrib(elm, 'onkeyup');
|
100 |
+
|
101 |
+
// Refresh in old MSIE
|
102 |
+
// if (tinyMCE.isMSIE5)
|
103 |
+
// elm.outerHTML = elm.outerHTML;
|
104 |
+
}
|
105 |
+
|
106 |
+
function insertAttribute() {
|
107 |
+
tinyMCEPopup.close();
|
108 |
+
}
|
109 |
+
|
110 |
+
tinyMCEPopup.onInit.add(init);
|
111 |
+
tinyMCEPopup.requireLangPack();
|
mce/xhtmlxtras/js/cite.js
CHANGED
@@ -1,28 +1,28 @@
|
|
1 |
-
/**
|
2 |
-
* cite.js
|
3 |
-
*
|
4 |
-
* Copyright 2009, Moxiecode Systems AB
|
5 |
-
* Released under LGPL License.
|
6 |
-
*
|
7 |
-
* License: http://tinymce.moxiecode.com/license
|
8 |
-
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
-
*/
|
10 |
-
|
11 |
-
function init() {
|
12 |
-
SXE.initElementDialog('cite');
|
13 |
-
if (SXE.currentAction == "update") {
|
14 |
-
SXE.showRemoveButton();
|
15 |
-
}
|
16 |
-
}
|
17 |
-
|
18 |
-
function insertCite() {
|
19 |
-
SXE.insertElement('cite');
|
20 |
-
tinyMCEPopup.close();
|
21 |
-
}
|
22 |
-
|
23 |
-
function removeCite() {
|
24 |
-
SXE.removeElement('cite');
|
25 |
-
tinyMCEPopup.close();
|
26 |
-
}
|
27 |
-
|
28 |
-
tinyMCEPopup.onInit.add(init);
|
1 |
+
/**
|
2 |
+
* cite.js
|
3 |
+
*
|
4 |
+
* Copyright 2009, Moxiecode Systems AB
|
5 |
+
* Released under LGPL License.
|
6 |
+
*
|
7 |
+
* License: http://tinymce.moxiecode.com/license
|
8 |
+
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
+
*/
|
10 |
+
|
11 |
+
function init() {
|
12 |
+
SXE.initElementDialog('cite');
|
13 |
+
if (SXE.currentAction == "update") {
|
14 |
+
SXE.showRemoveButton();
|
15 |
+
}
|
16 |
+
}
|
17 |
+
|
18 |
+
function insertCite() {
|
19 |
+
SXE.insertElement('cite');
|
20 |
+
tinyMCEPopup.close();
|
21 |
+
}
|
22 |
+
|
23 |
+
function removeCite() {
|
24 |
+
SXE.removeElement('cite');
|
25 |
+
tinyMCEPopup.close();
|
26 |
+
}
|
27 |
+
|
28 |
+
tinyMCEPopup.onInit.add(init);
|
mce/xhtmlxtras/js/del.js
CHANGED
@@ -1,53 +1,53 @@
|
|
1 |
-
/**
|
2 |
-
* del.js
|
3 |
-
*
|
4 |
-
* Copyright 2009, Moxiecode Systems AB
|
5 |
-
* Released under LGPL License.
|
6 |
-
*
|
7 |
-
* License: http://tinymce.moxiecode.com/license
|
8 |
-
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
-
*/
|
10 |
-
|
11 |
-
function init() {
|
12 |
-
SXE.initElementDialog('del');
|
13 |
-
if (SXE.currentAction == "update") {
|
14 |
-
setFormValue('datetime', tinyMCEPopup.editor.dom.getAttrib(SXE.updateElement, 'datetime'));
|
15 |
-
setFormValue('cite', tinyMCEPopup.editor.dom.getAttrib(SXE.updateElement, 'cite'));
|
16 |
-
SXE.showRemoveButton();
|
17 |
-
}
|
18 |
-
}
|
19 |
-
|
20 |
-
function setElementAttribs(elm) {
|
21 |
-
setAllCommonAttribs(elm);
|
22 |
-
setAttrib(elm, 'datetime');
|
23 |
-
setAttrib(elm, 'cite');
|
24 |
-
elm.removeAttribute('data-mce-new');
|
25 |
-
}
|
26 |
-
|
27 |
-
function insertDel() {
|
28 |
-
var elm = tinyMCEPopup.editor.dom.getParent(SXE.focusElement, 'DEL');
|
29 |
-
|
30 |
-
if (elm == null) {
|
31 |
-
var s = SXE.inst.selection.getContent();
|
32 |
-
if(s.length > 0) {
|
33 |
-
insertInlineElement('del');
|
34 |
-
var elementArray = SXE.inst.dom.select('del[data-mce-new]');
|
35 |
-
for (var i=0; i<elementArray.length; i++) {
|
36 |
-
var elm = elementArray[i];
|
37 |
-
setElementAttribs(elm);
|
38 |
-
}
|
39 |
-
}
|
40 |
-
} else {
|
41 |
-
setElementAttribs(elm);
|
42 |
-
}
|
43 |
-
tinyMCEPopup.editor.nodeChanged();
|
44 |
-
tinyMCEPopup.execCommand('mceEndUndoLevel');
|
45 |
-
tinyMCEPopup.close();
|
46 |
-
}
|
47 |
-
|
48 |
-
function removeDel() {
|
49 |
-
SXE.removeElement('del');
|
50 |
-
tinyMCEPopup.close();
|
51 |
-
}
|
52 |
-
|
53 |
-
tinyMCEPopup.onInit.add(init);
|
1 |
+
/**
|
2 |
+
* del.js
|
3 |
+
*
|
4 |
+
* Copyright 2009, Moxiecode Systems AB
|
5 |
+
* Released under LGPL License.
|
6 |
+
*
|
7 |
+
* License: http://tinymce.moxiecode.com/license
|
8 |
+
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
+
*/
|
10 |
+
|
11 |
+
function init() {
|
12 |
+
SXE.initElementDialog('del');
|
13 |
+
if (SXE.currentAction == "update") {
|
14 |
+
setFormValue('datetime', tinyMCEPopup.editor.dom.getAttrib(SXE.updateElement, 'datetime'));
|
15 |
+
setFormValue('cite', tinyMCEPopup.editor.dom.getAttrib(SXE.updateElement, 'cite'));
|
16 |
+
SXE.showRemoveButton();
|
17 |
+
}
|
18 |
+
}
|
19 |
+
|
20 |
+
function setElementAttribs(elm) {
|
21 |
+
setAllCommonAttribs(elm);
|
22 |
+
setAttrib(elm, 'datetime');
|
23 |
+
setAttrib(elm, 'cite');
|
24 |
+
elm.removeAttribute('data-mce-new');
|
25 |
+
}
|
26 |
+
|
27 |
+
function insertDel() {
|
28 |
+
var elm = tinyMCEPopup.editor.dom.getParent(SXE.focusElement, 'DEL');
|
29 |
+
|
30 |
+
if (elm == null) {
|
31 |
+
var s = SXE.inst.selection.getContent();
|
32 |
+
if(s.length > 0) {
|
33 |
+
insertInlineElement('del');
|
34 |
+
var elementArray = SXE.inst.dom.select('del[data-mce-new]');
|
35 |
+
for (var i=0; i<elementArray.length; i++) {
|
36 |
+
var elm = elementArray[i];
|
37 |
+
setElementAttribs(elm);
|
38 |
+
}
|
39 |
+
}
|
40 |
+
} else {
|
41 |
+
setElementAttribs(elm);
|
42 |
+
}
|
43 |
+
tinyMCEPopup.editor.nodeChanged();
|
44 |
+
tinyMCEPopup.execCommand('mceEndUndoLevel');
|
45 |
+
tinyMCEPopup.close();
|
46 |
+
}
|
47 |
+
|
48 |
+
function removeDel() {
|
49 |
+
SXE.removeElement('del');
|
50 |
+
tinyMCEPopup.close();
|
51 |
+
}
|
52 |
+
|
53 |
+
tinyMCEPopup.onInit.add(init);
|
mce/xhtmlxtras/js/element_common.js
CHANGED
@@ -1,229 +1,229 @@
|
|
1 |
-
/**
|
2 |
-
* element_common.js
|
3 |
-
*
|
4 |
-
* Copyright 2009, Moxiecode Systems AB
|
5 |
-
* Released under LGPL License.
|
6 |
-
*
|
7 |
-
* License: http://tinymce.moxiecode.com/license
|
8 |
-
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
-
*/
|
10 |
-
|
11 |
-
tinyMCEPopup.requireLangPack();
|
12 |
-
|
13 |
-
function initCommonAttributes(elm) {
|
14 |
-
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
|
15 |
-
|
16 |
-
// Setup form data for common element attributes
|
17 |
-
setFormValue('title', dom.getAttrib(elm, 'title'));
|
18 |
-
setFormValue('id', dom.getAttrib(elm, 'id'));
|
19 |
-
selectByValue(formObj, 'class', dom.getAttrib(elm, 'class'), true);
|
20 |
-
setFormValue('style', dom.getAttrib(elm, 'style'));
|
21 |
-
selectByValue(formObj, 'dir', dom.getAttrib(elm, 'dir'));
|
22 |
-
setFormValue('lang', dom.getAttrib(elm, 'lang'));
|
23 |
-
setFormValue('onfocus', dom.getAttrib(elm, 'onfocus'));
|
24 |
-
setFormValue('onblur', dom.getAttrib(elm, 'onblur'));
|
25 |
-
setFormValue('onclick', dom.getAttrib(elm, 'onclick'));
|
26 |
-
setFormValue('ondblclick', dom.getAttrib(elm, 'ondblclick'));
|
27 |
-
setFormValue('onmousedown', dom.getAttrib(elm, 'onmousedown'));
|
28 |
-
setFormValue('onmouseup', dom.getAttrib(elm, 'onmouseup'));
|
29 |
-
setFormValue('onmouseover', dom.getAttrib(elm, 'onmouseover'));
|
30 |
-
setFormValue('onmousemove', dom.getAttrib(elm, 'onmousemove'));
|
31 |
-
setFormValue('onmouseout', dom.getAttrib(elm, 'onmouseout'));
|
32 |
-
setFormValue('onkeypress', dom.getAttrib(elm, 'onkeypress'));
|
33 |
-
setFormValue('onkeydown', dom.getAttrib(elm, 'onkeydown'));
|
34 |
-
setFormValue('onkeyup', dom.getAttrib(elm, 'onkeyup'));
|
35 |
-
}
|
36 |
-
|
37 |
-
function setFormValue(name, value) {
|
38 |
-
if(document.forms[0].elements[name]) document.forms[0].elements[name].value = value;
|
39 |
-
}
|
40 |
-
|
41 |
-
function insertDateTime(id) {
|
42 |
-
document.getElementById(id).value = getDateTime(new Date(), "%Y-%m-%dT%H:%M:%S");
|
43 |
-
}
|
44 |
-
|
45 |
-
function getDateTime(d, fmt) {
|
46 |
-
fmt = fmt.replace("%D", "%m/%d/%y");
|
47 |
-
fmt = fmt.replace("%r", "%I:%M:%S %p");
|
48 |
-
fmt = fmt.replace("%Y", "" + d.getFullYear());
|
49 |
-
fmt = fmt.replace("%y", "" + d.getYear());
|
50 |
-
fmt = fmt.replace("%m", addZeros(d.getMonth()+1, 2));
|
51 |
-
fmt = fmt.replace("%d", addZeros(d.getDate(), 2));
|
52 |
-
fmt = fmt.replace("%H", "" + addZeros(d.getHours(), 2));
|
53 |
-
fmt = fmt.replace("%M", "" + addZeros(d.getMinutes(), 2));
|
54 |
-
fmt = fmt.replace("%S", "" + addZeros(d.getSeconds(), 2));
|
55 |
-
fmt = fmt.replace("%I", "" + ((d.getHours() + 11) % 12 + 1));
|
56 |
-
fmt = fmt.replace("%p", "" + (d.getHours() < 12 ? "AM" : "PM"));
|
57 |
-
fmt = fmt.replace("%%", "%");
|
58 |
-
|
59 |
-
return fmt;
|
60 |
-
}
|
61 |
-
|
62 |
-
function addZeros(value, len) {
|
63 |
-
var i;
|
64 |
-
|
65 |
-
value = "" + value;
|
66 |
-
|
67 |
-
if (value.length < len) {
|
68 |
-
for (i=0; i<(len-value.length); i++)
|
69 |
-
value = "0" + value;
|
70 |
-
}
|
71 |
-
|
72 |
-
return value;
|
73 |
-
}
|
74 |
-
|
75 |
-
function selectByValue(form_obj, field_name, value, add_custom, ignore_case) {
|
76 |
-
if (!form_obj || !form_obj.elements[field_name])
|
77 |
-
return;
|
78 |
-
|
79 |
-
var sel = form_obj.elements[field_name];
|
80 |
-
|
81 |
-
var found = false;
|
82 |
-
for (var i=0; i<sel.options.length; i++) {
|
83 |
-
var option = sel.options[i];
|
84 |
-
|
85 |
-
if (option.value == value || (ignore_case && option.value.toLowerCase() == value.toLowerCase())) {
|
86 |
-
option.selected = true;
|
87 |
-
found = true;
|
88 |
-
} else
|
89 |
-
option.selected = false;
|
90 |
-
}
|
91 |
-
|
92 |
-
if (!found && add_custom && value != '') {
|
93 |
-
var option = new Option('Value: ' + value, value);
|
94 |
-
option.selected = true;
|
95 |
-
sel.options[sel.options.length] = option;
|
96 |
-
}
|
97 |
-
|
98 |
-
return found;
|
99 |
-
}
|
100 |
-
|
101 |
-
function setAttrib(elm, attrib, value) {
|
102 |
-
var formObj = document.forms[0];
|
103 |
-
var valueElm = formObj.elements[attrib.toLowerCase()];
|
104 |
-
tinyMCEPopup.editor.dom.setAttrib(elm, attrib, value || valueElm.value);
|
105 |
-
}
|
106 |
-
|
107 |
-
function setAllCommonAttribs(elm) {
|
108 |
-
setAttrib(elm, 'title');
|
109 |
-
setAttrib(elm, 'id');
|
110 |
-
setAttrib(elm, 'class');
|
111 |
-
setAttrib(elm, 'style');
|
112 |
-
setAttrib(elm, 'dir');
|
113 |
-
setAttrib(elm, 'lang');
|
114 |
-
/*setAttrib(elm, 'onfocus');
|
115 |
-
setAttrib(elm, 'onblur');
|
116 |
-
setAttrib(elm, 'onclick');
|
117 |
-
setAttrib(elm, 'ondblclick');
|
118 |
-
setAttrib(elm, 'onmousedown');
|
119 |
-
setAttrib(elm, 'onmouseup');
|
120 |
-
setAttrib(elm, 'onmouseover');
|
121 |
-
setAttrib(elm, 'onmousemove');
|
122 |
-
setAttrib(elm, 'onmouseout');
|
123 |
-
setAttrib(elm, 'onkeypress');
|
124 |
-
setAttrib(elm, 'onkeydown');
|
125 |
-
setAttrib(elm, 'onkeyup');*/
|
126 |
-
}
|
127 |
-
|
128 |
-
SXE = {
|
129 |
-
currentAction : "insert",
|
130 |
-
inst : tinyMCEPopup.editor,
|
131 |
-
updateElement : null
|
132 |
-
}
|
133 |
-
|
134 |
-
SXE.focusElement = SXE.inst.selection.getNode();
|
135 |
-
|
136 |
-
SXE.initElementDialog = function(element_name) {
|
137 |
-
addClassesToList('class', 'xhtmlxtras_styles');
|
138 |
-
TinyMCE_EditableSelects.init();
|
139 |
-
|
140 |
-
element_name = element_name.toLowerCase();
|
141 |
-
var elm = SXE.inst.dom.getParent(SXE.focusElement, element_name.toUpperCase());
|
142 |
-
if (elm != null && elm.nodeName.toUpperCase() == element_name.toUpperCase()) {
|
143 |
-
SXE.currentAction = "update";
|
144 |
-
}
|
145 |
-
|
146 |
-
if (SXE.currentAction == "update") {
|
147 |
-
initCommonAttributes(elm);
|
148 |
-
SXE.updateElement = elm;
|
149 |
-
}
|
150 |
-
|
151 |
-
document.forms[0].insert.value = tinyMCEPopup.getLang(SXE.currentAction, 'Insert', true);
|
152 |
-
}
|
153 |
-
|
154 |
-
SXE.insertElement = function(element_name) {
|
155 |
-
var elm = SXE.inst.dom.getParent(SXE.focusElement, element_name.toUpperCase()), h, tagName;
|
156 |
-
|
157 |
-
if (elm == null) {
|
158 |
-
var s = SXE.inst.selection.getContent();
|
159 |
-
if(s.length > 0) {
|
160 |
-
tagName = element_name;
|
161 |
-
|
162 |
-
insertInlineElement(element_name);
|
163 |
-
var elementArray = tinymce.grep(SXE.inst.dom.select(element_name));
|
164 |
-
for (var i=0; i<elementArray.length; i++) {
|
165 |
-
var elm = elementArray[i];
|
166 |
-
|
167 |
-
if (SXE.inst.dom.getAttrib(elm, 'data-mce-new')) {
|
168 |
-
elm.id = '';
|
169 |
-
elm.setAttribute('id', '');
|
170 |
-
elm.removeAttribute('id');
|
171 |
-
elm.removeAttribute('data-mce-new');
|
172 |
-
|
173 |
-
setAllCommonAttribs(elm);
|
174 |
-
}
|
175 |
-
}
|
176 |
-
}
|
177 |
-
} else {
|
178 |
-
setAllCommonAttribs(elm);
|
179 |
-
}
|
180 |
-
SXE.inst.nodeChanged();
|
181 |
-
tinyMCEPopup.execCommand('mceEndUndoLevel');
|
182 |
-
}
|
183 |
-
|
184 |
-
SXE.removeElement = function(element_name){
|
185 |
-
element_name = element_name.toLowerCase();
|
186 |
-
elm = SXE.inst.dom.getParent(SXE.focusElement, element_name.toUpperCase());
|
187 |
-
if(elm && elm.nodeName.toUpperCase() == element_name.toUpperCase()){
|
188 |
-
tinyMCE.execCommand('mceRemoveNode', false, elm);
|
189 |
-
SXE.inst.nodeChanged();
|
190 |
-
tinyMCEPopup.execCommand('mceEndUndoLevel');
|
191 |
-
}
|
192 |
-
}
|
193 |
-
|
194 |
-
SXE.showRemoveButton = function() {
|
195 |
-
document.getElementById("remove").style.display = '';
|
196 |
-
}
|
197 |
-
|
198 |
-
SXE.containsClass = function(elm,cl) {
|
199 |
-
return (elm.className.indexOf(cl) > -1) ? true : false;
|
200 |
-
}
|
201 |
-
|
202 |
-
SXE.removeClass = function(elm,cl) {
|
203 |
-
if(elm.className == null || elm.className == "" || !SXE.containsClass(elm,cl)) {
|
204 |
-
return true;
|
205 |
-
}
|
206 |
-
var classNames = elm.className.split(" ");
|
207 |
-
var newClassNames = "";
|
208 |
-
for (var x = 0, cnl = classNames.length; x < cnl; x++) {
|
209 |
-
if (classNames[x] != cl) {
|
210 |
-
newClassNames += (classNames[x] + " ");
|
211 |
-
}
|
212 |
-
}
|
213 |
-
elm.className = newClassNames.substring(0,newClassNames.length-1); //removes extra space at the end
|
214 |
-
}
|
215 |
-
|
216 |
-
SXE.addClass = function(elm,cl) {
|
217 |
-
if(!SXE.containsClass(elm,cl)) elm.className ? elm.className += " " + cl : elm.className = cl;
|
218 |
-
return true;
|
219 |
-
}
|
220 |
-
|
221 |
-
function insertInlineElement(en) {
|
222 |
-
var ed = tinyMCEPopup.editor, dom = ed.dom;
|
223 |
-
|
224 |
-
ed.getDoc().execCommand('FontName', false, 'mceinline');
|
225 |
-
tinymce.each(dom.select('span,font'), function(n) {
|
226 |
-
if (n.style.fontFamily == 'mceinline' || n.face == 'mceinline')
|
227 |
-
dom.replace(dom.create(en, {'data-mce-new' : 1}), n, 1);
|
228 |
-
});
|
229 |
-
}
|
1 |
+
/**
|
2 |
+
* element_common.js
|
3 |
+
*
|
4 |
+
* Copyright 2009, Moxiecode Systems AB
|
5 |
+
* Released under LGPL License.
|
6 |
+
*
|
7 |
+
* License: http://tinymce.moxiecode.com/license
|
8 |
+
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
+
*/
|
10 |
+
|
11 |
+
tinyMCEPopup.requireLangPack();
|
12 |
+
|
13 |
+
function initCommonAttributes(elm) {
|
14 |
+
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
|
15 |
+
|
16 |
+
// Setup form data for common element attributes
|
17 |
+
setFormValue('title', dom.getAttrib(elm, 'title'));
|
18 |
+
setFormValue('id', dom.getAttrib(elm, 'id'));
|
19 |
+
selectByValue(formObj, 'class', dom.getAttrib(elm, 'class'), true);
|
20 |
+
setFormValue('style', dom.getAttrib(elm, 'style'));
|
21 |
+
selectByValue(formObj, 'dir', dom.getAttrib(elm, 'dir'));
|
22 |
+
setFormValue('lang', dom.getAttrib(elm, 'lang'));
|
23 |
+
setFormValue('onfocus', dom.getAttrib(elm, 'onfocus'));
|
24 |
+
setFormValue('onblur', dom.getAttrib(elm, 'onblur'));
|
25 |
+
setFormValue('onclick', dom.getAttrib(elm, 'onclick'));
|
26 |
+
setFormValue('ondblclick', dom.getAttrib(elm, 'ondblclick'));
|
27 |
+
setFormValue('onmousedown', dom.getAttrib(elm, 'onmousedown'));
|
28 |
+
setFormValue('onmouseup', dom.getAttrib(elm, 'onmouseup'));
|
29 |
+
setFormValue('onmouseover', dom.getAttrib(elm, 'onmouseover'));
|
30 |
+
setFormValue('onmousemove', dom.getAttrib(elm, 'onmousemove'));
|
31 |
+
setFormValue('onmouseout', dom.getAttrib(elm, 'onmouseout'));
|
32 |
+
setFormValue('onkeypress', dom.getAttrib(elm, 'onkeypress'));
|
33 |
+
setFormValue('onkeydown', dom.getAttrib(elm, 'onkeydown'));
|
34 |
+
setFormValue('onkeyup', dom.getAttrib(elm, 'onkeyup'));
|
35 |
+
}
|
36 |
+
|
37 |
+
function setFormValue(name, value) {
|
38 |
+
if(document.forms[0].elements[name]) document.forms[0].elements[name].value = value;
|
39 |
+
}
|
40 |
+
|
41 |
+
function insertDateTime(id) {
|
42 |
+
document.getElementById(id).value = getDateTime(new Date(), "%Y-%m-%dT%H:%M:%S");
|
43 |
+
}
|
44 |
+
|
45 |
+
function getDateTime(d, fmt) {
|
46 |
+
fmt = fmt.replace("%D", "%m/%d/%y");
|
47 |
+
fmt = fmt.replace("%r", "%I:%M:%S %p");
|
48 |
+
fmt = fmt.replace("%Y", "" + d.getFullYear());
|
49 |
+
fmt = fmt.replace("%y", "" + d.getYear());
|
50 |
+
fmt = fmt.replace("%m", addZeros(d.getMonth()+1, 2));
|
51 |
+
fmt = fmt.replace("%d", addZeros(d.getDate(), 2));
|
52 |
+
fmt = fmt.replace("%H", "" + addZeros(d.getHours(), 2));
|
53 |
+
fmt = fmt.replace("%M", "" + addZeros(d.getMinutes(), 2));
|
54 |
+
fmt = fmt.replace("%S", "" + addZeros(d.getSeconds(), 2));
|
55 |
+
fmt = fmt.replace("%I", "" + ((d.getHours() + 11) % 12 + 1));
|
56 |
+
fmt = fmt.replace("%p", "" + (d.getHours() < 12 ? "AM" : "PM"));
|
57 |
+
fmt = fmt.replace("%%", "%");
|
58 |
+
|
59 |
+
return fmt;
|
60 |
+
}
|
61 |
+
|
62 |
+
function addZeros(value, len) {
|
63 |
+
var i;
|
64 |
+
|
65 |
+
value = "" + value;
|
66 |
+
|
67 |
+
if (value.length < len) {
|
68 |
+
for (i=0; i<(len-value.length); i++)
|
69 |
+
value = "0" + value;
|
70 |
+
}
|
71 |
+
|
72 |
+
return value;
|
73 |
+
}
|
74 |
+
|
75 |
+
function selectByValue(form_obj, field_name, value, add_custom, ignore_case) {
|
76 |
+
if (!form_obj || !form_obj.elements[field_name])
|
77 |
+
return;
|
78 |
+
|
79 |
+
var sel = form_obj.elements[field_name];
|
80 |
+
|
81 |
+
var found = false;
|
82 |
+
for (var i=0; i<sel.options.length; i++) {
|
83 |
+
var option = sel.options[i];
|
84 |
+
|
85 |
+
if (option.value == value || (ignore_case && option.value.toLowerCase() == value.toLowerCase())) {
|
86 |
+
option.selected = true;
|
87 |
+
found = true;
|
88 |
+
} else
|
89 |
+
option.selected = false;
|
90 |
+
}
|
91 |
+
|
92 |
+
if (!found && add_custom && value != '') {
|
93 |
+
var option = new Option('Value: ' + value, value);
|
94 |
+
option.selected = true;
|
95 |
+
sel.options[sel.options.length] = option;
|
96 |
+
}
|
97 |
+
|
98 |
+
return found;
|
99 |
+
}
|
100 |
+
|
101 |
+
function setAttrib(elm, attrib, value) {
|
102 |
+
var formObj = document.forms[0];
|
103 |
+
var valueElm = formObj.elements[attrib.toLowerCase()];
|
104 |
+
tinyMCEPopup.editor.dom.setAttrib(elm, attrib, value || valueElm.value);
|
105 |
+
}
|
106 |
+
|
107 |
+
function setAllCommonAttribs(elm) {
|
108 |
+
setAttrib(elm, 'title');
|
109 |
+
setAttrib(elm, 'id');
|
110 |
+
setAttrib(elm, 'class');
|
111 |
+
setAttrib(elm, 'style');
|
112 |
+
setAttrib(elm, 'dir');
|
113 |
+
setAttrib(elm, 'lang');
|
114 |
+
/*setAttrib(elm, 'onfocus');
|
115 |
+
setAttrib(elm, 'onblur');
|
116 |
+
setAttrib(elm, 'onclick');
|
117 |
+
setAttrib(elm, 'ondblclick');
|
118 |
+
setAttrib(elm, 'onmousedown');
|
119 |
+
setAttrib(elm, 'onmouseup');
|
120 |
+
setAttrib(elm, 'onmouseover');
|
121 |
+
setAttrib(elm, 'onmousemove');
|
122 |
+
setAttrib(elm, 'onmouseout');
|
123 |
+
setAttrib(elm, 'onkeypress');
|
124 |
+
setAttrib(elm, 'onkeydown');
|
125 |
+
setAttrib(elm, 'onkeyup');*/
|
126 |
+
}
|
127 |
+
|
128 |
+
SXE = {
|
129 |
+
currentAction : "insert",
|
130 |
+
inst : tinyMCEPopup.editor,
|
131 |
+
updateElement : null
|
132 |
+
}
|
133 |
+
|
134 |
+
SXE.focusElement = SXE.inst.selection.getNode();
|
135 |
+
|
136 |
+
SXE.initElementDialog = function(element_name) {
|
137 |
+
addClassesToList('class', 'xhtmlxtras_styles');
|
138 |
+
TinyMCE_EditableSelects.init();
|
139 |
+
|
140 |
+
element_name = element_name.toLowerCase();
|
141 |
+
var elm = SXE.inst.dom.getParent(SXE.focusElement, element_name.toUpperCase());
|
142 |
+
if (elm != null && elm.nodeName.toUpperCase() == element_name.toUpperCase()) {
|
143 |
+
SXE.currentAction = "update";
|
144 |
+
}
|
145 |
+
|
146 |
+
if (SXE.currentAction == "update") {
|
147 |
+
initCommonAttributes(elm);
|
148 |
+
SXE.updateElement = elm;
|
149 |
+
}
|
150 |
+
|
151 |
+
document.forms[0].insert.value = tinyMCEPopup.getLang(SXE.currentAction, 'Insert', true);
|
152 |
+
}
|
153 |
+
|
154 |
+
SXE.insertElement = function(element_name) {
|
155 |
+
var elm = SXE.inst.dom.getParent(SXE.focusElement, element_name.toUpperCase()), h, tagName;
|
156 |
+
|
157 |
+
if (elm == null) {
|
158 |
+
var s = SXE.inst.selection.getContent();
|
159 |
+
if(s.length > 0) {
|
160 |
+
tagName = element_name;
|
161 |
+
|
162 |
+
insertInlineElement(element_name);
|
163 |
+
var elementArray = tinymce.grep(SXE.inst.dom.select(element_name));
|
164 |
+
for (var i=0; i<elementArray.length; i++) {
|
165 |
+
var elm = elementArray[i];
|
166 |
+
|
167 |
+
if (SXE.inst.dom.getAttrib(elm, 'data-mce-new')) {
|
168 |
+
elm.id = '';
|
169 |
+
elm.setAttribute('id', '');
|
170 |
+
elm.removeAttribute('id');
|
171 |
+
elm.removeAttribute('data-mce-new');
|
172 |
+
|
173 |
+
setAllCommonAttribs(elm);
|
174 |
+
}
|
175 |
+
}
|
176 |
+
}
|
177 |
+
} else {
|
178 |
+
setAllCommonAttribs(elm);
|
179 |
+
}
|
180 |
+
SXE.inst.nodeChanged();
|
181 |
+
tinyMCEPopup.execCommand('mceEndUndoLevel');
|
182 |
+
}
|
183 |
+
|
184 |
+
SXE.removeElement = function(element_name){
|
185 |
+
element_name = element_name.toLowerCase();
|
186 |
+
elm = SXE.inst.dom.getParent(SXE.focusElement, element_name.toUpperCase());
|
187 |
+
if(elm && elm.nodeName.toUpperCase() == element_name.toUpperCase()){
|
188 |
+
tinyMCE.execCommand('mceRemoveNode', false, elm);
|
189 |
+
SXE.inst.nodeChanged();
|
190 |
+
tinyMCEPopup.execCommand('mceEndUndoLevel');
|
191 |
+
}
|
192 |
+
}
|
193 |
+
|
194 |
+
SXE.showRemoveButton = function() {
|
195 |
+
document.getElementById("remove").style.display = '';
|
196 |
+
}
|
197 |
+
|
198 |
+
SXE.containsClass = function(elm,cl) {
|
199 |
+
return (elm.className.indexOf(cl) > -1) ? true : false;
|
200 |
+
}
|
201 |
+
|
202 |
+
SXE.removeClass = function(elm,cl) {
|
203 |
+
if(elm.className == null || elm.className == "" || !SXE.containsClass(elm,cl)) {
|
204 |
+
return true;
|
205 |
+
}
|
206 |
+
var classNames = elm.className.split(" ");
|
207 |
+
var newClassNames = "";
|
208 |
+
for (var x = 0, cnl = classNames.length; x < cnl; x++) {
|
209 |
+
if (classNames[x] != cl) {
|
210 |
+
newClassNames += (classNames[x] + " ");
|
211 |
+
}
|
212 |
+
}
|
213 |
+
elm.className = newClassNames.substring(0,newClassNames.length-1); //removes extra space at the end
|
214 |
+
}
|
215 |
+
|
216 |
+
SXE.addClass = function(elm,cl) {
|
217 |
+
if(!SXE.containsClass(elm,cl)) elm.className ? elm.className += " " + cl : elm.className = cl;
|
218 |
+
return true;
|
219 |
+
}
|
220 |
+
|
221 |
+
function insertInlineElement(en) {
|
222 |
+
var ed = tinyMCEPopup.editor, dom = ed.dom;
|
223 |
+
|
224 |
+
ed.getDoc().execCommand('FontName', false, 'mceinline');
|
225 |
+
tinymce.each(dom.select('span,font'), function(n) {
|
226 |
+
if (n.style.fontFamily == 'mceinline' || n.face == 'mceinline')
|
227 |
+
dom.replace(dom.create(en, {'data-mce-new' : 1}), n, 1);
|
228 |
+
});
|
229 |
+
}
|
mce/xhtmlxtras/js/ins.js
CHANGED
@@ -1,53 +1,53 @@
|
|
1 |
-
/**
|
2 |
-
* ins.js
|
3 |
-
*
|
4 |
-
* Copyright 2009, Moxiecode Systems AB
|
5 |
-
* Released under LGPL License.
|
6 |
-
*
|
7 |
-
* License: http://tinymce.moxiecode.com/license
|
8 |
-
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
-
*/
|
10 |
-
|
11 |
-
function init() {
|
12 |
-
SXE.initElementDialog('ins');
|
13 |
-
if (SXE.currentAction == "update") {
|
14 |
-
setFormValue('datetime', tinyMCEPopup.editor.dom.getAttrib(SXE.updateElement, 'datetime'));
|
15 |
-
setFormValue('cite', tinyMCEPopup.editor.dom.getAttrib(SXE.updateElement, 'cite'));
|
16 |
-
SXE.showRemoveButton();
|
17 |
-
}
|
18 |
-
}
|
19 |
-
|
20 |
-
function setElementAttribs(elm) {
|
21 |
-
setAllCommonAttribs(elm);
|
22 |
-
setAttrib(elm, 'datetime');
|
23 |
-
setAttrib(elm, 'cite');
|
24 |
-
elm.removeAttribute('data-mce-new');
|
25 |
-
}
|
26 |
-
|
27 |
-
function insertIns() {
|
28 |
-
var elm = tinyMCEPopup.editor.dom.getParent(SXE.focusElement, 'INS');
|
29 |
-
|
30 |
-
if (elm == null) {
|
31 |
-
var s = SXE.inst.selection.getContent();
|
32 |
-
if(s.length > 0) {
|
33 |
-
insertInlineElement('ins');
|
34 |
-
var elementArray = SXE.inst.dom.select('ins[data-mce-new]');
|
35 |
-
for (var i=0; i<elementArray.length; i++) {
|
36 |
-
var elm = elementArray[i];
|
37 |
-
setElementAttribs(elm);
|
38 |
-
}
|
39 |
-
}
|
40 |
-
} else {
|
41 |
-
setElementAttribs(elm);
|
42 |
-
}
|
43 |
-
tinyMCEPopup.editor.nodeChanged();
|
44 |
-
tinyMCEPopup.execCommand('mceEndUndoLevel');
|
45 |
-
tinyMCEPopup.close();
|
46 |
-
}
|
47 |
-
|
48 |
-
function removeIns() {
|
49 |
-
SXE.removeElement('ins');
|
50 |
-
tinyMCEPopup.close();
|
51 |
-
}
|
52 |
-
|
53 |
-
tinyMCEPopup.onInit.add(init);
|
1 |
+
/**
|
2 |
+
* ins.js
|
3 |
+
*
|
4 |
+
* Copyright 2009, Moxiecode Systems AB
|
5 |
+
* Released under LGPL License.
|
6 |
+
*
|
7 |
+
* License: http://tinymce.moxiecode.com/license
|
8 |
+
* Contributing: http://tinymce.moxiecode.com/contributing
|
9 |
+
*/
|
10 |
+
|
11 |
+
function init() {
|
12 |
+
SXE.initElementDialog('ins');
|
13 |
+
if (SXE.currentAction == "update") {
|
14 |
+
setFormValue('datetime', tinyMCEPopup.editor.dom.getAttrib(SXE.updateElement, 'datetime'));
|
15 |
+
setFormValue('cite', tinyMCEPopup.editor.dom.getAttrib(SXE.updateElement, 'cite'));
|
16 |
+
SXE.showRemoveButton();
|
17 |
+
}
|
18 |
+
}
|
19 |
+
|
20 |
+
function setElementAttribs(elm) {
|
21 |
+
setAllCommonAttribs(elm);
|
22 |
+
setAttrib(elm, 'datetime');
|
23 |
+
setAttrib(elm, 'cite');
|
24 |
+
elm.removeAttribute('data-mce-new');
|
25 |
+
}
|
26 |
+
|
27 |
+
function insertIns() {
|
28 |
+
var elm = tinyMCEPopup.editor.dom.getParent(SXE.focusElement, 'INS');
|
29 |
+
|
30 |
+
if (elm == null) {
|
31 |
+
var s = SXE.inst.selection.getContent();
|
32 |
+
if(s.length > 0) {
|
33 |
+
insertInlineElement('ins');
|
34 |
+
var elementArray = SXE.inst.dom.select('ins[data-mce-new]');
|
35 |
+
for (var i=0; i<elementArray.length; i++) {
|
36 |
+
var elm = elementArray[i];
|
37 |
+
setElementAttribs(elm);
|
38 |
+
}
|
39 |
+
}
|
40 |
+
} else {
|
41 |
+
setElementAttribs(elm);
|
42 |
+
}
|
43 |
+
tinyMCEPopup.editor.nodeChanged();
|
44 |
+
tinyMCEPopup.execCommand('mceEndUndoLevel');
|
45 |
+
tinyMCEPopup.close();
|
46 |
+
}
|
47 |
+
|
48 |
+
function removeIns() {
|
49 |
+
SXE.removeElement('ins');
|
50 |
+
tinyMCEPopup.close();
|
51 |
+
}
|
52 |
+
|
53 |
+
tinyMCEPopup.onInit.add(init);
|
mce/xhtmlxtras/langs/langs.php
CHANGED
@@ -1,9 +1,12 @@
|
|
1 |
-
<?php
|
2 |
-
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
-
|
4 |
-
if ( is_file($lang_file) &&
|
5 |
-
$
|
6 |
-
|
7 |
-
|
8 |
-
$strings =
|
9 |
-
}
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$lang_file = dirname(__FILE__) . '/' . $mce_locale . '_dlg.js';
|
3 |
+
|
4 |
+
if ( ! is_file( $lang_file ) && defined( 'TINYMCE_ADVANCED_LANGUAGES_PATH' ) )
|
5 |
+
$lang_file = TINYMCE_ADVANCED_LANGUAGES_PATH . 'xhtmlxtras/langs/' . $mce_locale . '_dlg.js';
|
6 |
+
|
7 |
+
if ( is_file( $lang_file ) && is_readable( $lang_file ) ) {
|
8 |
+
$strings = tdav_get_file( $lang_file );
|
9 |
+
} else {
|
10 |
+
$strings = tdav_get_file( dirname(__FILE__) . '/en_dlg.js' );
|
11 |
+
$strings = preg_replace( '/([\'"])en\./', '$1' . $mce_locale . '.', $strings, 1 );
|
12 |
+
}
|
mce/xhtmlxtras/langs/zh_dlg.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
tinyMCE.addI18n('zh.xhtmlxtras_dlg',{"attribs_title":"\u63d2\u5165/\
|
1 |
+
tinyMCE.addI18n('zh.xhtmlxtras_dlg',{"attribs_title":"\u63d2\u5165/\u7f16\u8f91\u5c5e\u6027","option_rtl":"\u4ece\u53f3\u5230\u5de6","option_ltr":"\u4ece\u5de6\u5230\u53f3","insert_date":"\u63d2\u5165\u5f53\u524d\u65e5\u671f/\u65f6\u95f4",remove:"\u79fb\u9664","title_cite_element":"\u5f15\u7528\u5143\u7d20","title_abbr_element":"\u7f29\u5199\u5143\u7d20","title_acronym_element":"\u9996\u5b57\u6bcd\u7f29\u5199\u5143\u7d20","title_del_element":"\u5220\u9664\u5143\u7d20","title_ins_element":"\u63d2\u5165\u5143\u7d20","fieldset_events_tab":"\u5143\u7d20\u4e8b\u4ef6","fieldset_attrib_tab":"\u5143\u7d20\u5c5e\u6027","fieldset_general_tab":"\u666e\u901a\u8bbe\u7f6e","events_tab":"Javascript\u4e8b\u4ef6","attrib_tab":"\u5c5e\u6027","general_tab":"\u666e\u901a","attribute_attrib_tab":"\u5c5e\u6027","attribute_events_tab":"Javascript\u4e8b\u4ef6","attribute_label_accesskey":"\u5feb\u6377\u952e","attribute_label_tabindex":"Tab\u7d22\u5f15","attribute_label_langcode":"\u8bed\u8a00","attribute_option_rtl":"\u4ece\u53f3\u5230\u5de6","attribute_option_ltr":"\u4ece\u5de6\u5230\u53f3","attribute_label_langdir":"\u6587\u5b57\u4e66\u5199\u65b9\u5411","attribute_label_datetime":"\u65e5\u671f/\u65f6\u95f4","attribute_label_cite":"\u5f15\u7528","attribute_label_style":"\u6837\u5f0f","attribute_label_class":"\u7c7b","attribute_label_id":"ID","attribute_label_title":"\u6807\u9898"});
|
readme.txt
CHANGED
@@ -1,39 +1,48 @@
|
|
1 |
=== TinyMCE Advanced ===
|
2 |
Contributors: azaozz
|
3 |
-
Donate link:
|
4 |
Tags: wysiwyg, formatting, tinymce, write, editor
|
5 |
-
|
6 |
-
|
|
|
7 |
Stable tag: 3.5.8
|
8 |
|
9 |
Enables the advanced features of TinyMCE, the WordPress WYSIWYG editor.
|
10 |
|
11 |
== Description ==
|
12 |
|
13 |
-
|
|
|
14 |
|
15 |
-
|
16 |
|
17 |
-
|
|
|
|
|
|
|
|
|
|
|
18 |
|
|
|
19 |
|
20 |
-
=
|
21 |
|
22 |
-
|
23 |
-
* Support for making and editing tables.
|
24 |
-
* Editing in-line css styles.
|
25 |
-
* Advanced list and image dialogs that offer a lot of options.
|
26 |
-
* Search and Replace in the editor.
|
27 |
-
* Support for XHTML specific tags and for (div based) layers.
|
28 |
|
|
|
29 |
|
30 |
-
== Installation ==
|
31 |
|
32 |
-
|
33 |
|
|
|
34 |
|
35 |
== Changelog ==
|
36 |
|
|
|
|
|
|
|
|
|
|
|
|
|
37 |
= 3.4.9 =
|
38 |
Updated for WordPress 3.4 and TinyMCE 3.4.9.
|
39 |
|
@@ -89,7 +98,7 @@ Includes an admin page for arranging the TinyMCE toolbar buttons, easy installat
|
|
89 |
|
90 |
= No styles are imported in the Styles drop-down menu. =
|
91 |
|
92 |
-
These styles
|
93 |
|
94 |
= I have just installed this plugin, but it does not do anything. =
|
95 |
|
@@ -109,7 +118,7 @@ Click the "Remove Settings" button on the plugin settings page and then set the
|
|
109 |
|
110 |
= Other questions? More screenshots? =
|
111 |
|
112 |
-
Please visit the homepage for [TinyMCE Advanced](http://www.laptoptips.ca/projects/tinymce-advanced/).
|
113 |
|
114 |
|
115 |
== Screenshots ==
|
1 |
=== TinyMCE Advanced ===
|
2 |
Contributors: azaozz
|
|
|
3 |
Tags: wysiwyg, formatting, tinymce, write, editor
|
4 |
+
License: GPL v2
|
5 |
+
Requires at least: 3.7
|
6 |
+
Tested up to: 3.7
|
7 |
Stable tag: 3.5.8
|
8 |
|
9 |
Enables the advanced features of TinyMCE, the WordPress WYSIWYG editor.
|
10 |
|
11 |
== Description ==
|
12 |
|
13 |
+
This plugin will let you add, remove and arrange the buttons that are shown on the Visual Editor toolbar.
|
14 |
+
It includes 16 plugins for [TinyMCE](http://tinymce.com/) that are automatically enabled or disabled depending on what buttons are chosen.
|
15 |
|
16 |
+
= Some of the features added by this plugin =
|
17 |
|
18 |
+
* Support for creating and editing tables.
|
19 |
+
* More options when inserting lists.
|
20 |
+
* Search and Replace in the editor.
|
21 |
+
* Editing in-line css styles.
|
22 |
+
* Advanced image dialog that offer a lot of options.
|
23 |
+
* Adding and removing HTML tag attributes.
|
24 |
|
25 |
+
Included TinyMCE plugins: Advanced HR, Advanced Image, Advanced Link, Advanced List, Context Menu, Emotions (Smilies), Date and Time, IESpell, Layer, Nonbreaking, Print, Search and Replace, Style, Table, Visual Characters and XHTML Extras.
|
26 |
|
27 |
+
= Language Support =
|
28 |
|
29 |
+
The plugin includes several translations for the TinyMCE components: German, French, Italian, Spanish, Portuguese, Russian, Chinese and Japanese.
|
|
|
|
|
|
|
|
|
|
|
30 |
|
31 |
+
More translations are available as a separate plugin: [TinyMCE Advanced Language Pack](http://wordpress.org/plugins/tinymce-advanced-language-pack/).
|
32 |
|
|
|
33 |
|
34 |
+
== Installation ==
|
35 |
|
36 |
+
Best is to install directly from WordPress. If manual installation is required, please make sure that the plugin files are in a folder named "tinymce-advanced" (not two nested folders) in the WordPress plugins folder, usually "wp-content/plugins".
|
37 |
|
38 |
== Changelog ==
|
39 |
|
40 |
+
= 3.5.9 =
|
41 |
+
Updated for WordPress 3.7 and TinyMCE 3.5.9.
|
42 |
+
|
43 |
+
= 3.5.8 =
|
44 |
+
Updated for WordPress 3.5 and TinyMCE 3.5.8.
|
45 |
+
|
46 |
= 3.4.9 =
|
47 |
Updated for WordPress 3.4 and TinyMCE 3.4.9.
|
48 |
|
98 |
|
99 |
= No styles are imported in the Styles drop-down menu. =
|
100 |
|
101 |
+
These styles are imported from your current theme editor-style.css file. However some themes do not have this functionality. For these themes TinyMCE Advanced has the option to let you add a customized editor-style.css and import it into the editor.
|
102 |
|
103 |
= I have just installed this plugin, but it does not do anything. =
|
104 |
|
118 |
|
119 |
= Other questions? More screenshots? =
|
120 |
|
121 |
+
Please post on the support forum or visit the homepage for [TinyMCE Advanced](http://www.laptoptips.ca/projects/tinymce-advanced/).
|
122 |
|
123 |
|
124 |
== Screenshots ==
|
screenshot-1.jpg
DELETED
Binary file
|
screenshot-1.png
ADDED
Binary file
|
tadv_admin.php
CHANGED
@@ -24,10 +24,10 @@ if ( isset( $_POST['tadv_uninstall'] ) ) {
|
|
24 |
return;
|
25 |
}
|
26 |
|
27 |
-
if ( ! isset($GLOBALS['wp_version']) || version_compare($GLOBALS['wp_version'], '3.
|
28 |
?>
|
29 |
<div class="error" style="margin-top:30px;">
|
30 |
-
<p><?php _e('This plugin requires WordPress version 3.
|
31 |
</div>
|
32 |
<?php
|
33 |
|
@@ -190,9 +190,6 @@ $tadv_allbtns = array_values($buttons);
|
|
190 |
$tadv_allbtns[] = 'separator';
|
191 |
$tadv_allbtns[] = '|';
|
192 |
|
193 |
-
for ( $i = 1; $i < 21; $i++ )
|
194 |
-
$buttons["s$i"] = "separator$i";
|
195 |
-
|
196 |
if ( isset($_POST['tadv-save']) ) {
|
197 |
update_option( 'tadv_plugins', $plugins );
|
198 |
update_option( 'tadv_btns1', $toolbar_1 );
|
@@ -205,191 +202,253 @@ if ( isset($_POST['tadv-save']) ) {
|
|
205 |
<?php } ?>
|
206 |
|
207 |
<div class="wrap" id="contain">
|
208 |
-
|
209 |
-
|
210 |
-
|
211 |
-
|
212 |
-
|
213 |
-
|
214 |
-
|
215 |
-
|
216 |
-
|
217 |
-
|
218 |
-
|
219 |
-
|
220 |
-
|
221 |
-
<div class="tadvdropzone">
|
222 |
-
<ul style="position: relative;" id="toolbar_1" class="container">
|
223 |
<?php
|
|
|
224 |
if ( is_array($tadv_toolbars['toolbar_1']) ) {
|
225 |
$tb1 = array();
|
|
|
226 |
foreach( $tadv_toolbars['toolbar_1'] as $k ) {
|
227 |
$t = array_intersect( $buttons, (array) $k );
|
228 |
$tb1 += $t;
|
229 |
}
|
230 |
|
231 |
foreach( $tb1 as $name => $btn ) {
|
232 |
-
if ( strpos( $btn, 'separator' ) !== false )
|
233 |
-
|
234 |
-
|
235 |
-
|
236 |
-
<?php
|
237 |
-
|
238 |
-
|
239 |
-
|
240 |
-
|
241 |
-
</div></li>
|
242 |
-
<?php }
|
243 |
}
|
|
|
244 |
$buttons = array_diff( $buttons, $tb1 );
|
245 |
-
}
|
246 |
-
</ul></div>
|
247 |
-
<br class="clear" />
|
248 |
|
249 |
-
|
250 |
-
|
|
|
|
|
|
|
|
|
251 |
<?php
|
|
|
252 |
if ( is_array($tadv_toolbars['toolbar_2']) ) {
|
253 |
$tb2 = array();
|
|
|
254 |
foreach( $tadv_toolbars['toolbar_2'] as $k ) {
|
255 |
$t = array_intersect( $buttons, (array) $k );
|
256 |
$tb2 = $tb2 + $t;
|
257 |
}
|
258 |
-
foreach( $tb2 as $name => $btn ) {
|
259 |
-
if ( strpos( $btn, 'separator' ) !== false ) { ?>
|
260 |
|
261 |
-
|
262 |
-
|
263 |
-
|
264 |
-
|
265 |
-
|
266 |
-
|
267 |
-
|
268 |
-
<?php
|
|
|
269 |
}
|
|
|
270 |
$buttons = array_diff( $buttons, $tb2 );
|
271 |
-
}
|
272 |
-
</ul></div>
|
273 |
-
<br class="clear" />
|
274 |
|
275 |
-
|
276 |
-
|
|
|
|
|
|
|
|
|
277 |
<?php
|
|
|
278 |
if ( is_array($tadv_toolbars['toolbar_3']) ) {
|
279 |
$tb3 = array();
|
|
|
280 |
foreach( $tadv_toolbars['toolbar_3'] as $k ) {
|
281 |
$t = array_intersect( $buttons, (array) $k );
|
282 |
$tb3 += $t;
|
283 |
}
|
284 |
-
foreach( $tb3 as $name => $btn ) {
|
285 |
-
if ( strpos( $btn, 'separator' ) !== false ) { ?>
|
286 |
-
|
287 |
-
<li class="separator" id="pre_<?php echo $btn; ?>">
|
288 |
-
<div class="tadvitem"> </div></li>
|
289 |
-
<?php } else { ?>
|
290 |
|
291 |
-
|
292 |
-
|
293 |
-
|
294 |
-
|
|
|
|
|
|
|
|
|
|
|
295 |
}
|
|
|
296 |
$buttons = array_diff( $buttons, $tb3 );
|
297 |
-
}
|
298 |
-
</ul></div>
|
299 |
-
<br class="clear" />
|
300 |
|
301 |
-
|
302 |
-
|
|
|
|
|
|
|
|
|
303 |
<?php
|
|
|
304 |
if ( is_array($tadv_toolbars['toolbar_4']) ) {
|
305 |
$tb4 = array();
|
|
|
306 |
foreach( $tadv_toolbars['toolbar_4'] as $k ) {
|
307 |
$t = array_intersect( $buttons, (array) $k );
|
308 |
$tb4 += $t;
|
309 |
}
|
310 |
-
foreach( $tb4 as $name => $btn ) {
|
311 |
-
if ( strpos( $btn, 'separator' ) !== false ) { ?>
|
312 |
|
313 |
-
|
314 |
-
|
315 |
-
|
316 |
-
|
317 |
-
|
318 |
-
|
319 |
-
|
320 |
-
<?php
|
|
|
321 |
}
|
|
|
322 |
$buttons = array_diff( $buttons, $tb4 );
|
323 |
-
}
|
324 |
-
|
325 |
-
|
326 |
-
|
|
|
|
|
327 |
|
328 |
-
|
329 |
<span id="too_long" style="display:none;"><?php _e('Adding too many buttons will make the toolbar too long and will not display correctly in TinyMCE!', 'tadv'); ?></span>
|
330 |
-
|
331 |
|
332 |
-
|
333 |
-
|
334 |
<?php
|
|
|
335 |
if ( is_array($buttons) ) {
|
336 |
foreach( $buttons as $name => $btn ) {
|
337 |
-
if ( strpos( $btn, 'separator' ) !== false )
|
338 |
-
|
339 |
-
<li class="separator" id="pre_<?php echo $btn; ?>">
|
340 |
-
<div class="tadvitem"> </div></li>
|
341 |
-
<?php } else { ?>
|
342 |
-
|
343 |
-
<li class="tadvmodule" id="pre_<?php echo $btn; ?>">
|
344 |
-
<div class="tadvitem"><div id="<?php echo $btn; ?>" title="<?php echo $name; ?>"></div>
|
345 |
-
<span class="descr"> <?php echo $name; ?></span></div></li>
|
346 |
-
<?php }
|
347 |
-
}
|
348 |
-
} ?>
|
349 |
-
</ul>
|
350 |
-
</div>
|
351 |
-
|
352 |
-
<table class="clear" style="margin:10px 0"><tr><td style="padding:2px 12px 8px;">
|
353 |
-
Also enable:
|
354 |
|
355 |
-
|
356 |
-
<
|
357 |
-
|
358 |
-
<
|
359 |
-
|
|
|
|
|
360 |
|
361 |
-
|
362 |
-
|
363 |
-
|
364 |
-
</td></tr>
|
365 |
|
366 |
-
|
367 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
368 |
|
369 |
-
|
370 |
-
|
371 |
-
<?php if ( ! current_theme_supports( 'editor-style' ) ) { ?>
|
372 |
-
<p><?php _e('It seems your theme (still) doesn\'t support customised styles for the editor. If you would like to use that, you can create a file named <i>editor-style.css</i> and add it to your theme\'s directory. You can use the editor-style.css from the Twenty Ten theme as a template.', 'tadv'); ?></p>
|
373 |
|
374 |
-
|
375 |
-
|
|
|
|
|
|
|
|
|
|
|
376 |
|
377 |
-
|
378 |
|
379 |
-
|
|
|
380 |
</td></tr>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
381 |
<?php
|
382 |
-
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
391 |
?>
|
392 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
393 |
|
394 |
<p>
|
395 |
<?php wp_nonce_field( 'tadv-save-buttons-order' ); ?>
|
24 |
return;
|
25 |
}
|
26 |
|
27 |
+
if ( ! isset( $GLOBALS['wp_version'] ) || version_compare( $GLOBALS['wp_version'], '3.6', '<' ) ) {
|
28 |
?>
|
29 |
<div class="error" style="margin-top:30px;">
|
30 |
+
<p><?php _e('This plugin requires WordPress version 3.6 or newer. Please upgrade your WordPress installation or download an', 'tadv'); ?> <a href="http://wordpress.org/extend/plugins/tinymce-advanced/download/"><?php _e('older version of the plugin.', 'tadv'); ?></a></p>
|
31 |
</div>
|
32 |
<?php
|
33 |
|
190 |
$tadv_allbtns[] = 'separator';
|
191 |
$tadv_allbtns[] = '|';
|
192 |
|
|
|
|
|
|
|
193 |
if ( isset($_POST['tadv-save']) ) {
|
194 |
update_option( 'tadv_plugins', $plugins );
|
195 |
update_option( 'tadv_btns1', $toolbar_1 );
|
202 |
<?php } ?>
|
203 |
|
204 |
<div class="wrap" id="contain">
|
205 |
+
<h2><?php _e('TinyMCE Buttons Arrangement', 'tadv'); ?></h2>
|
206 |
+
<form id="tadvadmin" method="post" action="" onsubmit="">
|
207 |
+
<p><?php _e('Drag and drop buttons onto the toolbars below.', 'tadv'); ?></p>
|
208 |
+
|
209 |
+
<div id="tadvzones">
|
210 |
+
<input id="toolbar_1order" name="toolbar_1order" value="" type="hidden" />
|
211 |
+
<input id="toolbar_2order" name="toolbar_2order" value="" type="hidden" />
|
212 |
+
<input id="toolbar_3order" name="toolbar_3order" value="" type="hidden" />
|
213 |
+
<input id="toolbar_4order" name="toolbar_4order" value="" type="hidden" />
|
214 |
+
<input name="tadv-save" value="1" type="hidden" />
|
215 |
+
|
216 |
+
<div class="tadvdropzone">
|
217 |
+
<ul style="position: relative;" id="toolbar_1" class="container">
|
|
|
|
|
218 |
<?php
|
219 |
+
|
220 |
if ( is_array($tadv_toolbars['toolbar_1']) ) {
|
221 |
$tb1 = array();
|
222 |
+
|
223 |
foreach( $tadv_toolbars['toolbar_1'] as $k ) {
|
224 |
$t = array_intersect( $buttons, (array) $k );
|
225 |
$tb1 += $t;
|
226 |
}
|
227 |
|
228 |
foreach( $tb1 as $name => $btn ) {
|
229 |
+
if ( strpos( $btn, 'separator' ) !== false )
|
230 |
+
continue;
|
231 |
+
|
232 |
+
?>
|
233 |
+
<li class="tadvmodule" id="pre_<?php echo $btn; ?>">
|
234 |
+
<div class="tadvitem"><div id="<?php echo $btn; ?>" title="<?php echo $name; ?>"></div>
|
235 |
+
<span class="descr"> <?php echo $name; ?></span>
|
236 |
+
</div></li>
|
237 |
+
<?php
|
|
|
|
|
238 |
}
|
239 |
+
|
240 |
$buttons = array_diff( $buttons, $tb1 );
|
241 |
+
}
|
|
|
|
|
242 |
|
243 |
+
?>
|
244 |
+
</ul></div>
|
245 |
+
<br class="clear" />
|
246 |
+
|
247 |
+
<div class="tadvdropzone">
|
248 |
+
<ul style="position: relative;" id="toolbar_2" class="container">
|
249 |
<?php
|
250 |
+
|
251 |
if ( is_array($tadv_toolbars['toolbar_2']) ) {
|
252 |
$tb2 = array();
|
253 |
+
|
254 |
foreach( $tadv_toolbars['toolbar_2'] as $k ) {
|
255 |
$t = array_intersect( $buttons, (array) $k );
|
256 |
$tb2 = $tb2 + $t;
|
257 |
}
|
|
|
|
|
258 |
|
259 |
+
foreach( $tb2 as $name => $btn ) {
|
260 |
+
if ( strpos( $btn, 'separator' ) !== false )
|
261 |
+
continue;
|
262 |
+
|
263 |
+
?>
|
264 |
+
<li class="tadvmodule" id="pre_<?php echo $btn; ?>">
|
265 |
+
<div class="tadvitem"><div id="<?php echo $btn; ?>" title="<?php echo $name; ?>"></div>
|
266 |
+
<span class="descr"> <?php echo $name; ?></span></div></li>
|
267 |
+
<?php
|
268 |
}
|
269 |
+
|
270 |
$buttons = array_diff( $buttons, $tb2 );
|
271 |
+
}
|
|
|
|
|
272 |
|
273 |
+
?>
|
274 |
+
</ul></div>
|
275 |
+
<br class="clear" />
|
276 |
+
|
277 |
+
<div class="tadvdropzone">
|
278 |
+
<ul style="position: relative;" id="toolbar_3" class="container">
|
279 |
<?php
|
280 |
+
|
281 |
if ( is_array($tadv_toolbars['toolbar_3']) ) {
|
282 |
$tb3 = array();
|
283 |
+
|
284 |
foreach( $tadv_toolbars['toolbar_3'] as $k ) {
|
285 |
$t = array_intersect( $buttons, (array) $k );
|
286 |
$tb3 += $t;
|
287 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
288 |
|
289 |
+
foreach( $tb3 as $name => $btn ) {
|
290 |
+
if ( strpos( $btn, 'separator' ) !== false )
|
291 |
+
continue;
|
292 |
+
|
293 |
+
?>
|
294 |
+
<li class="tadvmodule" id="pre_<?php echo $btn; ?>">
|
295 |
+
<div class="tadvitem"><div id="<?php echo $btn; ?>" title="<?php echo $name; ?>"></div>
|
296 |
+
<span class="descr"> <?php echo $name; ?></span></div></li>
|
297 |
+
<?php
|
298 |
}
|
299 |
+
|
300 |
$buttons = array_diff( $buttons, $tb3 );
|
301 |
+
}
|
|
|
|
|
302 |
|
303 |
+
?>
|
304 |
+
</ul></div>
|
305 |
+
<br class="clear" />
|
306 |
+
|
307 |
+
<div class="tadvdropzone">
|
308 |
+
<ul style="position: relative;" id="toolbar_4" class="container">
|
309 |
<?php
|
310 |
+
|
311 |
if ( is_array($tadv_toolbars['toolbar_4']) ) {
|
312 |
$tb4 = array();
|
313 |
+
|
314 |
foreach( $tadv_toolbars['toolbar_4'] as $k ) {
|
315 |
$t = array_intersect( $buttons, (array) $k );
|
316 |
$tb4 += $t;
|
317 |
}
|
|
|
|
|
318 |
|
319 |
+
foreach( $tb4 as $name => $btn ) {
|
320 |
+
if ( strpos( $btn, 'separator' ) !== false )
|
321 |
+
continue;
|
322 |
+
|
323 |
+
?>
|
324 |
+
<li class="tadvmodule" id="pre_<?php echo $btn; ?>">
|
325 |
+
<div class="tadvitem"><div id="<?php echo $btn; ?>" title="<?php echo $name; ?>"></div>
|
326 |
+
<span class="descr"> <?php echo $name; ?></span></div></li>
|
327 |
+
<?php
|
328 |
}
|
329 |
+
|
330 |
$buttons = array_diff( $buttons, $tb4 );
|
331 |
+
}
|
332 |
+
|
333 |
+
?>
|
334 |
+
</ul></div>
|
335 |
+
<br class="clear" />
|
336 |
+
</div>
|
337 |
|
338 |
+
<div id="tadvWarnmsg">
|
339 |
<span id="too_long" style="display:none;"><?php _e('Adding too many buttons will make the toolbar too long and will not display correctly in TinyMCE!', 'tadv'); ?></span>
|
340 |
+
</div>
|
341 |
|
342 |
+
<div id="tadvpalettediv">
|
343 |
+
<ul style="position: relative;" id="tadvpalette">
|
344 |
<?php
|
345 |
+
|
346 |
if ( is_array($buttons) ) {
|
347 |
foreach( $buttons as $name => $btn ) {
|
348 |
+
if ( strpos( $btn, 'separator' ) !== false )
|
349 |
+
continue;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
350 |
|
351 |
+
?>
|
352 |
+
<li class="tadvmodule" id="pre_<?php echo $btn; ?>">
|
353 |
+
<div class="tadvitem"><div id="<?php echo $btn; ?>" title="<?php echo $name; ?>"></div>
|
354 |
+
<span class="descr"> <?php echo $name; ?></span></div></li>
|
355 |
+
<?php
|
356 |
+
}
|
357 |
+
}
|
358 |
|
359 |
+
?>
|
360 |
+
</ul>
|
361 |
+
</div>
|
|
|
362 |
|
363 |
+
<table class="clear" style="margin:10px 0">
|
364 |
+
<tr><td style="padding:2px 12px 8px;">
|
365 |
+
<?php _e('Also enable:', 'tadv'); ?>
|
366 |
+
|
367 |
+
<label for="advimage" class="tadv-box">
|
368 |
+
<input type="checkbox" class="tadv-chk" name="advimage" id="advimage" <?php if ( !empty($tadv_options['advimage']) ) echo ' checked="checked"'; ?> />
|
369 |
+
<?php _e('Advanced Image', 'tadv'); ?>
|
370 |
+
</label>
|
371 |
+
|
372 |
+
<label for="advlist" class="tadv-box">
|
373 |
+
<input type="checkbox" class="tadv-chk" name="advlist" id="advlist" <?php if ( !empty($tadv_options['advlist']) ) echo ' checked="checked"'; ?> />
|
374 |
+
<?php _e('Advanced List Options', 'tadv'); ?>
|
375 |
+
</label>
|
376 |
+
|
377 |
+
<label for="contextmenu" class="tadv-box">
|
378 |
+
<input type="checkbox" class="tadv-chk" name="contextmenu" id="contextmenu" <?php if ( !empty($tadv_options['contextmenu']) ) echo ' checked="checked"'; ?> />
|
379 |
+
<?php _e('Context Menu', 'tadv'); ?>
|
380 |
+
</label>
|
381 |
+
</td></tr>
|
382 |
+
<?php
|
383 |
|
384 |
+
$mce_locale = get_locale();
|
385 |
+
$mce_locale = empty( $mce_locale ) ? 'en' : strtolower( substr( $mce_locale, 0, 2 ) );
|
|
|
|
|
386 |
|
387 |
+
if ( $mce_locale != 'en' && ! @file_exists( TADV_PATH . 'mce/advlink/langs/' . $mce_locale . '_dlg.js' ) ) {
|
388 |
+
if ( in_array( $mce_locale, array( 'ar', 'be', 'nb', 'bg', 'ca', 'cn', 'cs', 'da', 'nl', 'fa', 'fi', 'gl', 'el', 'he', 'hi', 'hu', 'id', 'km', 'ko', 'lv', 'lt', 'mk', 'no', 'pl', 'ro', 'sk', 'sl', 'sv', 'tr', 'uk', 'cy' ), true ) ) {
|
389 |
+
?>
|
390 |
+
<tr><td style="padding:2px 12px 8px;">
|
391 |
+
<p><b><?php _e('Language Options'); ?></b></p>
|
392 |
+
<p>
|
393 |
+
<?php
|
394 |
|
395 |
+
printf( __('Your WordPress language is set to <b>%1$s</b>, however there is no matching language installed for the TinyMCE components added from this plugin. You can install the <a href="%2$s">TnyMCE Advanced Language Pack</a> plugin to add it.', 'tadv'), esc_html( get_locale() ), esc_url('http://wordpress.org/plugins/tinymce-advanced-language-pack/') );
|
396 |
|
397 |
+
?>
|
398 |
+
</p>
|
399 |
</td></tr>
|
400 |
+
<?php
|
401 |
+
}
|
402 |
+
} // end mce_locale
|
403 |
+
|
404 |
+
?>
|
405 |
+
<tr><td style="border:1px solid #CD0000;padding:2px 12px 8px;">
|
406 |
+
<p style="font-weight:bold;color:#CD0000;"><?php _e('Advanced Options', 'tadv'); ?></p>
|
407 |
+
|
408 |
+
<p>
|
409 |
+
<label for="advlink1" class="tadv-box">
|
410 |
+
<input type="checkbox" class="tadv-chk" name="advlink1" id="advlink1" <?php if ( !empty($tadv_options['advlink1']) ) echo ' checked="checked"'; ?> />
|
411 |
+
<?php _e('Advanced Link', 'tadv'); ?>
|
412 |
+
</label>
|
413 |
+
<?php _e('Enabling this TinyMCE plugin will overwrite the internal links feature in WordPress 3.1 and newer. Cuttently there is no way to enable both of them at the same time.', 'tadv'); ?>
|
414 |
+
</p>
|
415 |
+
|
416 |
<?php
|
417 |
+
|
418 |
+
if ( ! current_theme_supports( 'editor-style' ) ) {
|
419 |
+
|
420 |
+
?>
|
421 |
+
<p>
|
422 |
+
<?php _e('It seems your theme (still) doesn\'t support customised styles for the editor. If you would like to use that, you can create a file named <i>editor-style.css</i> and add it to your theme\'s directory. You can use the editor-style.css from the Twenty Ten theme as a template.', 'tadv'); ?>
|
423 |
+
</p>
|
424 |
+
|
425 |
+
<p>
|
426 |
+
<label for="editorstyle" class="tadv-box"><input type="checkbox" class="tadv-chk" name="editorstyle" id="editorstyle" <?php if ( !empty($tadv_options['editorstyle']) ) echo ' checked="checked"'; ?> />
|
427 |
+
<?php _e('Import editor-style.css.', 'tadv'); ?>
|
428 |
+
</label>
|
429 |
+
<?php _e('This is only needed if you created that file. Themes that style the editor will import the stylesheet automatically.', 'tadv'); ?>
|
430 |
+
</p>
|
431 |
+
<?php
|
432 |
+
}
|
433 |
+
|
434 |
?>
|
435 |
+
<p>
|
436 |
+
<label for="hideclasses" class="tadv-box">
|
437 |
+
<input type="checkbox" class="tadv-chk" name="hideclasses" id="hideclasses" <?php if ( !empty($tadv_options['hideclasses']) ) echo ' checked="checked"'; ?> />
|
438 |
+
<?php _e('Hide all CSS classes in the editor menus.', 'tadv'); ?>
|
439 |
+
</label>
|
440 |
+
<?php _e('Note that selecting this will also disable the Styles drop-down menu.', 'tadv'); ?>
|
441 |
+
</p>
|
442 |
+
|
443 |
+
<p>
|
444 |
+
<label for="no_autop" class="tadv-box">
|
445 |
+
<input type="checkbox" class="tadv-chk" name="no_autop" id="no_autop" <?php if ( !empty($tadv_options['no_autop']) ) echo ' checked="checked"'; ?> />
|
446 |
+
<?php _e('Stop removing the <p> and <br /> tags when saving and show them in the HTML editor', 'tadv'); ?>
|
447 |
+
</label>
|
448 |
+
<?php _e('This will make it possible to use more advanced coding in the HTML editor without the back-end filtering affecting it much. However it may behave unexpectedly in rare cases, so test it thoroughly before enabling it permanently. Also line breaks in the HTML editor would still affect the output, in particular do not use empty lines, line breaks inside HTML tags or multiple <br /> tags.', 'tadv'); ?>
|
449 |
+
</p>
|
450 |
+
</td></tr>
|
451 |
+
</table>
|
452 |
|
453 |
<p>
|
454 |
<?php wp_nonce_field( 'tadv-save-buttons-order' ); ?>
|
tiny_mce_popup.js
CHANGED
@@ -2,4 +2,4 @@
|
|
2 |
// Uncomment and change this document.domain value if you are loading the script cross subdomains
|
3 |
// document.domain = 'moxiecode.com';
|
4 |
|
5 |
-
var tinymce=null,tinyMCEPopup,tinyMCE;tinyMCEPopup={init:function(){var b=this,a,c;a=b.getWin();tinymce=a.tinymce;tinyMCE=a.tinyMCE;b.editor=tinymce.EditorManager.activeEditor;b.params=b.editor.windowManager.params;b.features=b.editor.windowManager.features;b.dom=b.editor.windowManager.createInstance("tinymce.dom.DOMUtils",document,{ownEvents:true,proxy:tinyMCEPopup._eventProxy});b.dom.bind(window,"ready",b._onDOMLoaded,b);if(b.features.popup_css!==false){b.dom.loadCSS(b.features.popup_css||b.editor.settings.popup_css)}b.listeners=[];b.onInit={add:function(e,d){b.listeners.push({func:e,scope:d})}};b.isWindow=!b.getWindowArg("mce_inline");b.id=b.getWindowArg("mce_window_id");b.editor.windowManager.onOpen.dispatch(b.editor.windowManager,window)},getWin:function(){return(!window.frameElement&&window.dialogArguments)||opener||parent||top},getWindowArg:function(c,b){var a=this.params[c];return tinymce.is(a)?a:b},getParam:function(b,a){return this.editor.getParam(b,a)},getLang:function(b,a){return this.editor.getLang(b,a)},execCommand:function(d,c,e,b){b=b||{};b.skip_focus=1;this.restoreSelection();return this.editor.execCommand(d,c,e,b)},resizeToInnerSize:function(){var a=this;setTimeout(function(){var b=a.dom.getViewPort(window);a.editor.windowManager.resizeBy(a.getWindowArg("mce_width")-b.w,a.getWindowArg("mce_height")-b.h,a.id||window)},10)},executeOnLoad:function(s){this.onInit.add(function(){eval(s)})},storeSelection:function(){this.editor.windowManager.bookmark=tinyMCEPopup.editor.selection.getBookmark(1)},restoreSelection:function(){var a=tinyMCEPopup;if(!a.isWindow&&tinymce.isIE){a.editor.selection.moveToBookmark(a.editor.windowManager.bookmark)}},requireLangPack:function(){var b=this,a=b.getWindowArg("plugin_url")||b.getWindowArg("theme_url");if(a&&b.editor.settings.language&&b.features.translate_i18n!==false&&b.editor.settings.language_load!==false){a+="/langs/"+b.editor.settings.language+"_dlg.js";if(!tinymce.ScriptLoader.isDone(a)){document.write('<script type="text/javascript" src="'+tinymce._addVer(a)+'"><\/script>');tinymce.ScriptLoader.markDone(a)}}},pickColor:function(b,a){this.execCommand("mceColorPicker",true,{color:document.getElementById(a).value,func:function(e){document.getElementById(a).value=e;try{document.getElementById(a).onchange()}catch(d){}}})},openBrowser:function(a,c,b){tinyMCEPopup.restoreSelection();this.editor.execCallback("file_browser_callback",a,document.getElementById(a).value,c,window)},confirm:function(b,a,c){this.editor.windowManager.confirm(b,a,c,window)},alert:function(b,a,c){this.editor.windowManager.alert(b,a,c,window)},close:function(){var a=this;function b(){a.editor.windowManager.close(window);tinymce=tinyMCE=a.editor=a.params=a.dom=a.dom.doc=null}if(tinymce.isOpera){a.getWin().setTimeout(b,0)}else{b()}},_restoreSelection:function(){var a=window.event.srcElement;if(a.nodeName=="INPUT"&&(a.type=="submit"||a.type=="button")){tinyMCEPopup.restoreSelection()}},_onDOMLoaded:function(){var b=tinyMCEPopup,d=document.title,e,c,a;if(b.features.translate_i18n!==false){c=document.body.innerHTML;if(tinymce.isIE){c=c.replace(/ (value|title|alt)=([^"][^\s>]+)/gi,' $1="$2"')}document.dir=b.editor.getParam("directionality","");if((a=b.editor.translate(c))&&a!=c){document.body.innerHTML=a}if((a=b.editor.translate(d))&&a!=d){document.title=d=a}}if(!b.editor.getParam("browser_preferred_colors",false)||!b.isWindow){b.dom.addClass(document.body,"forceColors")}document.body.style.display="";if(tinymce.isIE){document.attachEvent("onmouseup",tinyMCEPopup._restoreSelection);b.dom.add(b.dom.select("head")[0],"base",{target:"_self"})}b.restoreSelection();b.resizeToInnerSize();if(!b.isWindow){b.editor.windowManager.setTitle(window,d)}else{window.focus()}if(!tinymce.isIE&&!b.isWindow){b.dom.bind(document,"focus",function(){b.editor.windowManager.focus(b.id)})}tinymce.each(b.dom.select("select"),function(f){f.onkeydown=tinyMCEPopup._accessHandler});tinymce.each(b.listeners,function(f){f.func.call(f.scope,b.editor)});if(b.getWindowArg("mce_auto_focus",true)){window.focus();tinymce.each(document.forms,function(g){tinymce.each(g.elements,function(f){if(b.dom.hasClass(f,"mceFocus")&&!f.disabled){f.focus();return false}})})}document.onkeyup=tinyMCEPopup._closeWinKeyHandler},_accessHandler:function(a){a=a||window.event;if(a.keyCode==13||a.keyCode==32){var b=a.target||a.srcElement;if(b.onchange){b.onchange()}return tinymce.dom.Event.cancel(a)}},_closeWinKeyHandler:function(a){a=a||window.event;if(a.keyCode==27){tinyMCEPopup.close()}},_eventProxy:function(a){return function(b){tinyMCEPopup.dom.events.callNativeHandler(a,b)}}};tinyMCEPopup.init();
|
2 |
// Uncomment and change this document.domain value if you are loading the script cross subdomains
|
3 |
// document.domain = 'moxiecode.com';
|
4 |
|
5 |
+
var tinymce=null,tinyMCEPopup,tinyMCE;tinyMCEPopup={init:function(){var b=this,a,c;a=b.getWin();tinymce=a.tinymce;tinyMCE=a.tinyMCE;b.editor=tinymce.EditorManager.activeEditor;b.params=b.editor.windowManager.params;b.features=b.editor.windowManager.features;b.dom=b.editor.windowManager.createInstance("tinymce.dom.DOMUtils",document,{ownEvents:true,proxy:tinyMCEPopup._eventProxy});b.dom.bind(window,"ready",b._onDOMLoaded,b);if(b.features.popup_css!==false){b.dom.loadCSS(b.features.popup_css||b.editor.settings.popup_css)}b.listeners=[];b.onInit={add:function(e,d){b.listeners.push({func:e,scope:d})}};b.isWindow=!b.getWindowArg("mce_inline");b.id=b.getWindowArg("mce_window_id");b.editor.windowManager.onOpen.dispatch(b.editor.windowManager,window)},getWin:function(){return(!window.frameElement&&window.dialogArguments)||opener||parent||top},getWindowArg:function(c,b){var a=this.params[c];return tinymce.is(a)?a:b},getParam:function(b,a){return this.editor.getParam(b,a)},getLang:function(b,a){return this.editor.getLang(b,a)},execCommand:function(d,c,e,b){b=b||{};b.skip_focus=1;this.restoreSelection();return this.editor.execCommand(d,c,e,b)},resizeToInnerSize:function(){var a=this;setTimeout(function(){var b=a.dom.getViewPort(window);a.editor.windowManager.resizeBy(a.getWindowArg("mce_width")-b.w,a.getWindowArg("mce_height")-b.h,a.id||window)},10)},executeOnLoad:function(s){this.onInit.add(function(){eval(s)})},storeSelection:function(){this.editor.windowManager.bookmark=tinyMCEPopup.editor.selection.getBookmark(1)},restoreSelection:function(){var a=tinyMCEPopup;if(!a.isWindow&&tinymce.isIE){a.editor.selection.moveToBookmark(a.editor.windowManager.bookmark)}},requireLangPack:function(){var b=this,a=b.getWindowArg("plugin_url")||b.getWindowArg("theme_url");if(a&&b.editor.settings.language&&b.features.translate_i18n!==false&&b.editor.settings.language_load!==false){a+="/langs/"+b.editor.settings.language+"_dlg.js";if(!tinymce.ScriptLoader.isDone(a)){document.write('<script type="text/javascript" src="'+tinymce._addVer(a)+'"><\/script>');tinymce.ScriptLoader.markDone(a)}}},pickColor:function(b,a){this.execCommand("mceColorPicker",true,{color:document.getElementById(a).value,func:function(e){document.getElementById(a).value=e;try{document.getElementById(a).onchange()}catch(d){}}})},openBrowser:function(a,c,b){tinyMCEPopup.restoreSelection();this.editor.execCallback("file_browser_callback",a,document.getElementById(a).value,c,window)},confirm:function(b,a,c){this.editor.windowManager.confirm(b,a,c,window)},alert:function(b,a,c){this.editor.windowManager.alert(b,a,c,window)},close:function(){var a=this;function b(){a.editor.windowManager.close(window);tinymce=tinyMCE=a.editor=a.params=a.dom=a.dom.doc=null}if(tinymce.isOpera){a.getWin().setTimeout(b,0)}else{b()}},_restoreSelection:function(a){var a=(a&&a.target)||window.event.srcElement;if(a.nodeName=="INPUT"&&(a.type=="submit"||a.type=="button")){tinyMCEPopup.restoreSelection()}},_onDOMLoaded:function(){var b=tinyMCEPopup,d=document.title,e,c,a;if(b.features.translate_i18n!==false){c=document.body.innerHTML;if(tinymce.isIE){c=c.replace(/ (value|title|alt)=([^"][^\s>]+)/gi,' $1="$2"')}document.dir=b.editor.getParam("directionality","");if((a=b.editor.translate(c))&&a!=c){document.body.innerHTML=a}if((a=b.editor.translate(d))&&a!=d){document.title=d=a}}if(!b.editor.getParam("browser_preferred_colors",false)||!b.isWindow){b.dom.addClass(document.body,"forceColors")}document.body.style.display="";if(tinymce.isIE&&!tinymce.isIE11){document.attachEvent("onmouseup",tinyMCEPopup._restoreSelection);b.dom.add(b.dom.select("head")[0],"base",{target:"_self"})}else{if(tinymce.isIE11){document.addEventListener("mouseup",tinyMCEPopup._restoreSelection,false)}}b.restoreSelection();b.resizeToInnerSize();if(!b.isWindow){b.editor.windowManager.setTitle(window,d)}else{window.focus()}if(!tinymce.isIE&&!b.isWindow){b.dom.bind(document,"focus",function(){b.editor.windowManager.focus(b.id)})}tinymce.each(b.dom.select("select"),function(f){f.onkeydown=tinyMCEPopup._accessHandler});tinymce.each(b.listeners,function(f){f.func.call(f.scope,b.editor)});if(b.getWindowArg("mce_auto_focus",true)){window.focus();tinymce.each(document.forms,function(g){tinymce.each(g.elements,function(f){if(b.dom.hasClass(f,"mceFocus")&&!f.disabled){f.focus();return false}})})}document.onkeyup=tinyMCEPopup._closeWinKeyHandler},_accessHandler:function(a){a=a||window.event;if(a.keyCode==13||a.keyCode==32){var b=a.target||a.srcElement;if(b.onchange){b.onchange()}return tinymce.dom.Event.cancel(a)}},_closeWinKeyHandler:function(a){a=a||window.event;if(a.keyCode==27){tinyMCEPopup.close()}},_eventProxy:function(a){return function(b){tinyMCEPopup.dom.events.callNativeHandler(a,b)}}};tinyMCEPopup.init();
|
tinymce-advanced.php
CHANGED
@@ -3,13 +3,13 @@
|
|
3 |
Plugin Name: TinyMCE Advanced
|
4 |
Plugin URI: http://www.laptoptips.ca/projects/tinymce-advanced/
|
5 |
Description: Enables advanced features and plugins in TinyMCE, the visual editor in WordPress.
|
6 |
-
Version: 3.5.
|
7 |
Author: Andrew Ozz
|
8 |
Author URI: http://www.laptoptips.ca/
|
9 |
|
10 |
Some code and ideas from WordPress (http://wordpress.org/). The options page for this plugin uses jQuery (http://jquery.com/).
|
11 |
|
12 |
-
Released under the GPL v.2, http://www.gnu.org/
|
13 |
|
14 |
This program is distributed in the hope that it will be useful,
|
15 |
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
@@ -19,9 +19,7 @@ Released under the GPL v.2, http://www.gnu.org/copyleft/gpl.html
|
|
19 |
|
20 |
|
21 |
if ( ! function_exists('tadv_paths') ) {
|
22 |
-
|
23 |
-
If using domain mapping or plugins that change the path dinamically, edit these to set the proper path and URL.
|
24 |
-
*/
|
25 |
function tadv_paths() {
|
26 |
if ( !defined('TADV_URL') )
|
27 |
define('TADV_URL', plugin_dir_url(__FILE__));
|
@@ -52,7 +50,7 @@ if ( ! function_exists('tadv_add_scripts') ) {
|
|
52 |
function tadv_add_scripts($page) {
|
53 |
if ( 'settings_page_tinymce-advanced' == $page ) {
|
54 |
wp_enqueue_script( 'tadv-js', TADV_URL . 'js/tadv.js', array('jquery-ui-sortable'), '3.4.2', true );
|
55 |
-
wp_enqueue_style( 'tadv-css', TADV_URL . 'css/tadv-styles.css', array(), '3.
|
56 |
}
|
57 |
}
|
58 |
}
|
@@ -89,19 +87,7 @@ if ( ! function_exists('tdav_get_file') ) {
|
|
89 |
if ( ! $path || ! @is_file($path) )
|
90 |
return '';
|
91 |
|
92 |
-
|
93 |
-
return @file_get_contents($path);
|
94 |
-
|
95 |
-
$content = '';
|
96 |
-
$fp = @fopen($path, 'r');
|
97 |
-
if ( ! $fp )
|
98 |
-
return '';
|
99 |
-
|
100 |
-
while ( ! feof($fp) )
|
101 |
-
$content .= fgets($fp);
|
102 |
-
|
103 |
-
fclose($fp);
|
104 |
-
return $content;
|
105 |
}
|
106 |
}
|
107 |
|
3 |
Plugin Name: TinyMCE Advanced
|
4 |
Plugin URI: http://www.laptoptips.ca/projects/tinymce-advanced/
|
5 |
Description: Enables advanced features and plugins in TinyMCE, the visual editor in WordPress.
|
6 |
+
Version: 3.5.9
|
7 |
Author: Andrew Ozz
|
8 |
Author URI: http://www.laptoptips.ca/
|
9 |
|
10 |
Some code and ideas from WordPress (http://wordpress.org/). The options page for this plugin uses jQuery (http://jquery.com/).
|
11 |
|
12 |
+
Released under the GPL v.2, http://www.gnu.org/licenses/gpl-2.0.html
|
13 |
|
14 |
This program is distributed in the hope that it will be useful,
|
15 |
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
19 |
|
20 |
|
21 |
if ( ! function_exists('tadv_paths') ) {
|
22 |
+
// If using domain mapping or plugins that change the path dinamically, edit these to set the proper path and URL.
|
|
|
|
|
23 |
function tadv_paths() {
|
24 |
if ( !defined('TADV_URL') )
|
25 |
define('TADV_URL', plugin_dir_url(__FILE__));
|
50 |
function tadv_add_scripts($page) {
|
51 |
if ( 'settings_page_tinymce-advanced' == $page ) {
|
52 |
wp_enqueue_script( 'tadv-js', TADV_URL . 'js/tadv.js', array('jquery-ui-sortable'), '3.4.2', true );
|
53 |
+
wp_enqueue_style( 'tadv-css', TADV_URL . 'css/tadv-styles.css', array(), '3.5.9' );
|
54 |
}
|
55 |
}
|
56 |
}
|
87 |
if ( ! $path || ! @is_file($path) )
|
88 |
return '';
|
89 |
|
90 |
+
return @file_get_contents($path);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
91 |
}
|
92 |
}
|
93 |
|