diff options
Diffstat (limited to 'public/javascripts/tiny_mce/plugins/fullpage')
| -rw-r--r--[-rwxr-xr-x] | public/javascripts/tiny_mce/plugins/fullpage/css/fullpage.css | 0 | ||||
| -rw-r--r--[-rwxr-xr-x] | public/javascripts/tiny_mce/plugins/fullpage/editor_plugin.js | 2 | ||||
| -rw-r--r--[-rwxr-xr-x] | public/javascripts/tiny_mce/plugins/fullpage/editor_plugin_src.js | 8 | ||||
| -rw-r--r--[-rwxr-xr-x] | public/javascripts/tiny_mce/plugins/fullpage/fullpage.htm | 19 | ||||
| -rw-r--r--[-rwxr-xr-x] | public/javascripts/tiny_mce/plugins/fullpage/js/fullpage.js | 2 | ||||
| -rw-r--r--[-rwxr-xr-x] | public/javascripts/tiny_mce/plugins/fullpage/langs/en_dlg.js | 0 |
6 files changed, 17 insertions, 14 deletions
diff --git a/public/javascripts/tiny_mce/plugins/fullpage/css/fullpage.css b/public/javascripts/tiny_mce/plugins/fullpage/css/fullpage.css index 7a3334f..7a3334f 100755..100644 --- a/public/javascripts/tiny_mce/plugins/fullpage/css/fullpage.css +++ b/public/javascripts/tiny_mce/plugins/fullpage/css/fullpage.css | |||
diff --git a/public/javascripts/tiny_mce/plugins/fullpage/editor_plugin.js b/public/javascripts/tiny_mce/plugins/fullpage/editor_plugin.js index 727beb5..8e11bfc 100755..100644 --- a/public/javascripts/tiny_mce/plugins/fullpage/editor_plugin.js +++ b/public/javascripts/tiny_mce/plugins/fullpage/editor_plugin.js | |||
| @@ -1 +1 @@ | |||
| (function(){tinymce.create('tinymce.plugins.FullPagePlugin',{init:function(ed,url){var t=this;t.editor=ed;ed.addCommand('mceFullPageProperties',function(){ed.windowManager.open({file:url+'/fullpage.htm',width:430+parseInt(ed.getLang('fullpage.delta_width',0)),height:495+parseInt(ed.getLang('fullpage.delta_height',0)),inline:1},{plugin_url:url,head_html:t.head});});ed.addButton('fullpage',{title:'fullpage.desc',cmd:'mceFullPageProperties'});ed.onBeforeSetContent.add(t._setContent,t);ed.onSetContent.add(t._setBodyAttribs,t);ed.onGetContent.add(t._getContent,t);},getInfo:function(){return{longname:'Fullpage',author:'Moxiecode Systems AB',authorurl:'http://tinymce.moxiecode.com',infourl:'http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/fullpage',version:tinymce.majorVersion+"."+tinymce.minorVersion};},_setBodyAttribs:function(ed,o){var bdattr,i,len,kv,k,v,t,attr=this.head.match(/body(.*?)>/i);if(attr&&attr[1]){bdattr=attr[1].match(/\s*(\w+\s*=\s*".*?"|\w+\s*=\s*'.*?'|\w+\s*=\s*\w+|\w+)\s*/g);if(bdattr){for(i=0,len=bdattr.length;i<len;i++){kv=bdattr[i].split('=');k=kv[0].replace(/\s/,'');v=kv[1];if(v){v=v.replace(/^\s+/,'').replace(/\s+$/,'');t=v.match(/^["'](.*)["']$/);if(t)v=t[1];}else v=k;ed.dom.setAttrib(ed.getBody(),'style',v);}}}},_createSerializer:function(){return new tinymce.dom.Serializer({dom:this.editor.dom,apply_source_formatting:true});},_setContent:function(ed,o){var t=this,sp,ep,c=o.content,v,st='';c=c.replace(/<(\/?)BODY/gi,'<$1body');sp=c.indexOf('<body');if(sp!=-1){sp=c.indexOf('>',sp);t.head=c.substring(0,sp+1);ep=c.indexOf('</body',sp);if(ep==-1)ep=c.indexOf('</body',ep);o.content=c.substring(sp+1,ep);t.foot=c.substring(ep);function low(s){return s.replace(/<\/?[A-Z]+/g,function(a){return a.toLowerCase();})};t.head=low(t.head);t.foot=low(t.foot);}else{t.head='';if(ed.getParam('fullpage_default_xml_pi'))t.head+='<?xml version="1.0" encoding="'+ed.getParam('fullpage_default_encoding','ISO-8859-1')+'" ?>\n';t.head+=ed.getParam('fullpage_default_doctype','<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">');t.head+='\n<html>\n<head>\n<title>'+ed.getParam('fullpage_default_title','Untitled document')+'</title>\n';if(v=ed.getParam('fullpage_default_encoding'))t.head+='<meta http-equiv="Content-Type" content="'+v+'" />\n';if(v=ed.getParam('fullpage_default_font_family'))st+='font-family: '+v+';';if(v=ed.getParam('fullpage_default_font_size'))st+='font-size: '+v+';';if(v=ed.getParam('fullpage_default_text_color'))st+='color: '+v+';';t.head+='</head>\n<body'+(st?' style="'+st+'"':'')+'>\n';t.foot='\n</body>\n</html>';}},_getContent:function(ed,o){var t=this;o.content=tinymce.trim(t.head)+'\n'+tinymce.trim(o.content)+'\n'+tinymce.trim(t.foot);}});tinymce.PluginManager.add('fullpage',tinymce.plugins.FullPagePlugin);})(); \ No newline at end of file | (function(){tinymce.create("tinymce.plugins.FullPagePlugin",{init:function(a,b){var c=this;c.editor=a;a.addCommand("mceFullPageProperties",function(){a.windowManager.open({file:b+"/fullpage.htm",width:430+parseInt(a.getLang("fullpage.delta_width",0)),height:495+parseInt(a.getLang("fullpage.delta_height",0)),inline:1},{plugin_url:b,head_html:c.head})});a.addButton("fullpage",{title:"fullpage.desc",cmd:"mceFullPageProperties"});a.onBeforeSetContent.add(c._setContent,c);a.onSetContent.add(c._setBodyAttribs,c);a.onGetContent.add(c._getContent,c)},getInfo:function(){return{longname:"Fullpage",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/fullpage",version:tinymce.majorVersion+"."+tinymce.minorVersion}},_setBodyAttribs:function(d,a){var l,c,e,g,b,h,j,f=this.head.match(/body(.*?)>/i);if(f&&f[1]){l=f[1].match(/\s*(\w+\s*=\s*".*?"|\w+\s*=\s*'.*?'|\w+\s*=\s*\w+|\w+)\s*/g);if(l){for(c=0,e=l.length;c<e;c++){g=l[c].split("=");b=g[0].replace(/\s/,"");h=g[1];if(h){h=h.replace(/^\s+/,"").replace(/\s+$/,"");j=h.match(/^["'](.*)["']$/);if(j){h=j[1]}}else{h=b}d.dom.setAttrib(d.getBody(),"style",h)}}}},_createSerializer:function(){return new tinymce.dom.Serializer({dom:this.editor.dom,apply_source_formatting:true})},_setContent:function(d,b){var h=this,a,j,f=b.content,g,i="";if(b.source_view&&d.getParam("fullpage_hide_in_source_view")){return}f=f.replace(/<(\/?)BODY/gi,"<$1body");a=f.indexOf("<body");if(a!=-1){a=f.indexOf(">",a);h.head=f.substring(0,a+1);j=f.indexOf("</body",a);if(j==-1){j=f.indexOf("</body",j)}b.content=f.substring(a+1,j);h.foot=f.substring(j);function e(c){return c.replace(/<\/?[A-Z]+/g,function(k){return k.toLowerCase()})}h.head=e(h.head);h.foot=e(h.foot)}else{h.head="";if(d.getParam("fullpage_default_xml_pi")){h.head+='<?xml version="1.0" encoding="'+d.getParam("fullpage_default_encoding","ISO-8859-1")+'" ?>\n'}h.head+=d.getParam("fullpage_default_doctype",'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">');h.head+="\n<html>\n<head>\n<title>"+d.getParam("fullpage_default_title","Untitled document")+"</title>\n";if(g=d.getParam("fullpage_default_encoding")){h.head+='<meta http-equiv="Content-Type" content="'+g+'" />\n'}if(g=d.getParam("fullpage_default_font_family")){i+="font-family: "+g+";"}if(g=d.getParam("fullpage_default_font_size")){i+="font-size: "+g+";"}if(g=d.getParam("fullpage_default_text_color")){i+="color: "+g+";"}h.head+="</head>\n<body"+(i?' style="'+i+'"':"")+">\n";h.foot="\n</body>\n</html>"}},_getContent:function(a,c){var b=this;if(!c.source_view||!a.getParam("fullpage_hide_in_source_view")){c.content=tinymce.trim(b.head)+"\n"+tinymce.trim(c.content)+"\n"+tinymce.trim(b.foot)}}});tinymce.PluginManager.add("fullpage",tinymce.plugins.FullPagePlugin)})(); \ No newline at end of file | ||
diff --git a/public/javascripts/tiny_mce/plugins/fullpage/editor_plugin_src.js b/public/javascripts/tiny_mce/plugins/fullpage/editor_plugin_src.js index 019682d..c7d5aca 100755..100644 --- a/public/javascripts/tiny_mce/plugins/fullpage/editor_plugin_src.js +++ b/public/javascripts/tiny_mce/plugins/fullpage/editor_plugin_src.js | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | /** | 1 | /** |
| 2 | * $Id: editor_plugin_src.js 920 2008-09-09 14:05:33Z spocke $ | 2 | * $Id: editor_plugin_src.js 1029 2009-02-24 22:32:21Z spocke $ |
| 3 | * | 3 | * |
| 4 | * @author Moxiecode | 4 | * @author Moxiecode |
| 5 | * @copyright Copyright © 2004-2008, Moxiecode Systems AB, All rights reserved. | 5 | * @copyright Copyright © 2004-2008, Moxiecode Systems AB, All rights reserved. |
| @@ -82,6 +82,9 @@ | |||
| 82 | _setContent : function(ed, o) { | 82 | _setContent : function(ed, o) { |
| 83 | var t = this, sp, ep, c = o.content, v, st = ''; | 83 | var t = this, sp, ep, c = o.content, v, st = ''; |
| 84 | 84 | ||
| 85 | if (o.source_view && ed.getParam('fullpage_hide_in_source_view')) | ||
| 86 | return; | ||
| 87 | |||
| 85 | // Parse out head, body and footer | 88 | // Parse out head, body and footer |
| 86 | c = c.replace(/<(\/?)BODY/gi, '<$1body'); | 89 | c = c.replace(/<(\/?)BODY/gi, '<$1body'); |
| 87 | sp = c.indexOf('<body'); | 90 | sp = c.indexOf('<body'); |
| @@ -133,7 +136,8 @@ | |||
| 133 | _getContent : function(ed, o) { | 136 | _getContent : function(ed, o) { |
| 134 | var t = this; | 137 | var t = this; |
| 135 | 138 | ||
| 136 | o.content = tinymce.trim(t.head) + '\n' + tinymce.trim(o.content) + '\n' + tinymce.trim(t.foot); | 139 | if (!o.source_view || !ed.getParam('fullpage_hide_in_source_view')) |
| 140 | o.content = tinymce.trim(t.head) + '\n' + tinymce.trim(o.content) + '\n' + tinymce.trim(t.foot); | ||
| 137 | } | 141 | } |
| 138 | }); | 142 | }); |
| 139 | 143 | ||
diff --git a/public/javascripts/tiny_mce/plugins/fullpage/fullpage.htm b/public/javascripts/tiny_mce/plugins/fullpage/fullpage.htm index d74da0d..3ea4081 100755..100644 --- a/public/javascripts/tiny_mce/plugins/fullpage/fullpage.htm +++ b/public/javascripts/tiny_mce/plugins/fullpage/fullpage.htm | |||
| @@ -7,7 +7,6 @@ | |||
| 7 | <script type="text/javascript" src="../../utils/form_utils.js"></script> | 7 | <script type="text/javascript" src="../../utils/form_utils.js"></script> |
| 8 | <script type="text/javascript" src="js/fullpage.js"></script> | 8 | <script type="text/javascript" src="js/fullpage.js"></script> |
| 9 | <link href="css/fullpage.css" rel="stylesheet" type="text/css" /> | 9 | <link href="css/fullpage.css" rel="stylesheet" type="text/css" /> |
| 10 | <base target="_self" /> | ||
| 11 | </head> | 10 | </head> |
| 12 | <body id="advlink" style="display: none"> | 11 | <body id="advlink" style="display: none"> |
| 13 | <form onsubmit="updateAction();return false;" name="fullpage" action="#"> | 12 | <form onsubmit="updateAction();return false;" name="fullpage" action="#"> |
| @@ -26,27 +25,27 @@ | |||
| 26 | 25 | ||
| 27 | <table border="0" cellpadding="4" cellspacing="0"> | 26 | <table border="0" cellpadding="4" cellspacing="0"> |
| 28 | <tr> | 27 | <tr> |
| 29 | <td nowrap="nowrap"><label for="metatitle">{#fullpage_dlg.meta_title}</label> </td> | 28 | <td class="nowrap"><label for="metatitle">{#fullpage_dlg.meta_title}</label> </td> |
| 30 | <td><input type="text" id="metatitle" name="metatitle" value="" class="mceFocus" /></td> | 29 | <td><input type="text" id="metatitle" name="metatitle" value="" class="mceFocus" /></td> |
| 31 | </tr> | 30 | </tr> |
| 32 | <tr> | 31 | <tr> |
| 33 | <td nowrap="nowrap"><label for="metakeywords">{#fullpage_dlg.meta_keywords}</label> </td> | 32 | <td class="nowrap"><label for="metakeywords">{#fullpage_dlg.meta_keywords}</label> </td> |
| 34 | <td><textarea id="metakeywords" name="metakeywords" rows="4"></textarea></td> | 33 | <td><textarea id="metakeywords" name="metakeywords" rows="4"></textarea></td> |
| 35 | </tr> | 34 | </tr> |
| 36 | <tr> | 35 | <tr> |
| 37 | <td nowrap="nowrap"><label for="metadescription">{#fullpage_dlg.meta_description}</label> </td> | 36 | <td class="nowrap"><label for="metadescription">{#fullpage_dlg.meta_description}</label> </td> |
| 38 | <td><textarea id="metadescription" name="metadescription" rows="4"></textarea></td> | 37 | <td><textarea id="metadescription" name="metadescription" rows="4"></textarea></td> |
| 39 | </tr> | 38 | </tr> |
| 40 | <tr> | 39 | <tr> |
| 41 | <td nowrap="nowrap"><label for="metaauthor">{#fullpage_dlg.author}</label> </td> | 40 | <td class="nowrap"><label for="metaauthor">{#fullpage_dlg.author}</label> </td> |
| 42 | <td><input type="text" id="metaauthor" name="metaauthor" value="" /></td> | 41 | <td><input type="text" id="metaauthor" name="metaauthor" value="" /></td> |
| 43 | </tr> | 42 | </tr> |
| 44 | <tr> | 43 | <tr> |
| 45 | <td nowrap="nowrap"><label for="metacopyright">{#fullpage_dlg.copyright}</label> </td> | 44 | <td class="nowrap"><label for="metacopyright">{#fullpage_dlg.copyright}</label> </td> |
| 46 | <td><input type="text" id="metacopyright" name="metacopyright" value="" /></td> | 45 | <td><input type="text" id="metacopyright" name="metacopyright" value="" /></td> |
| 47 | </tr> | 46 | </tr> |
| 48 | <tr> | 47 | <tr> |
| 49 | <td nowrap="nowrap"><label for="metarobots">{#fullpage_dlg.meta_robots}</label> </td> | 48 | <td class="nowrap"><label for="metarobots">{#fullpage_dlg.meta_robots}</label> </td> |
| 50 | <td> | 49 | <td> |
| 51 | <select id="metarobots" name="metarobots"> | 50 | <select id="metarobots" name="metarobots"> |
| 52 | <option value="">{#not_set}</option> | 51 | <option value="">{#not_set}</option> |
| @@ -73,7 +72,7 @@ | |||
| 73 | </td> | 72 | </td> |
| 74 | </tr> | 73 | </tr> |
| 75 | <tr> | 74 | <tr> |
| 76 | <td nowrap="nowrap"><label for="doctypes">{#fullpage_dlg.doctypes}</label> </td> | 75 | <td class="nowrap"><label for="doctypes">{#fullpage_dlg.doctypes}</label> </td> |
| 77 | <td> | 76 | <td> |
| 78 | <select id="doctypes" name="doctypes"> | 77 | <select id="doctypes" name="doctypes"> |
| 79 | <option value="">{#not_set}</option> | 78 | <option value="">{#not_set}</option> |
| @@ -81,7 +80,7 @@ | |||
| 81 | </td> | 80 | </td> |
| 82 | </tr> | 81 | </tr> |
| 83 | <tr> | 82 | <tr> |
| 84 | <td nowrap="nowrap"><label for="langcode">{#fullpage_dlg.langcode}</label> </td> | 83 | <td class="nowrap"><label for="langcode">{#fullpage_dlg.langcode}</label> </td> |
| 85 | <td><input type="text" id="langcode" name="langcode" value="" /></td> | 84 | <td><input type="text" id="langcode" name="langcode" value="" /></td> |
| 86 | </tr> | 85 | </tr> |
| 87 | <tr> | 86 | <tr> |
| @@ -95,7 +94,7 @@ | |||
| 95 | </td> | 94 | </td> |
| 96 | </tr> | 95 | </tr> |
| 97 | <tr> | 96 | <tr> |
| 98 | <td nowrap="nowrap"><label for="xml_pi">{#fullpage_dlg.xml_pi}</label> </td> | 97 | <td class="nowrap"><label for="xml_pi">{#fullpage_dlg.xml_pi}</label> </td> |
| 99 | <td><input type="checkbox" id="xml_pi" name="xml_pi" class="checkbox" /></td> | 98 | <td><input type="checkbox" id="xml_pi" name="xml_pi" class="checkbox" /></td> |
| 100 | </tr> | 99 | </tr> |
| 101 | </table> | 100 | </table> |
diff --git a/public/javascripts/tiny_mce/plugins/fullpage/js/fullpage.js b/public/javascripts/tiny_mce/plugins/fullpage/js/fullpage.js index 89059ef..dd3a29c 100755..100644 --- a/public/javascripts/tiny_mce/plugins/fullpage/js/fullpage.js +++ b/public/javascripts/tiny_mce/plugins/fullpage/js/fullpage.js | |||
| @@ -123,7 +123,7 @@ function init() { | |||
| 123 | // Parse xml and doctype | 123 | // Parse xml and doctype |
| 124 | xmlVer = getReItem(/<\?\s*?xml.*?version\s*?=\s*?"(.*?)".*?\?>/gi, h, 1); | 124 | xmlVer = getReItem(/<\?\s*?xml.*?version\s*?=\s*?"(.*?)".*?\?>/gi, h, 1); |
| 125 | xmlEnc = getReItem(/<\?\s*?xml.*?encoding\s*?=\s*?"(.*?)".*?\?>/gi, h, 1); | 125 | xmlEnc = getReItem(/<\?\s*?xml.*?encoding\s*?=\s*?"(.*?)".*?\?>/gi, h, 1); |
| 126 | docType = getReItem(/<\!DOCTYPE.*?>/gi, h, 0); | 126 | docType = getReItem(/<\!DOCTYPE.*?>/gi, h.replace(/\n/g, ''), 0).replace(/ +/g, ' '); |
| 127 | f.langcode.value = getReItem(/lang="(.*?)"/gi, h, 1); | 127 | f.langcode.value = getReItem(/lang="(.*?)"/gi, h, 1); |
| 128 | 128 | ||
| 129 | // Parse title | 129 | // Parse title |
diff --git a/public/javascripts/tiny_mce/plugins/fullpage/langs/en_dlg.js b/public/javascripts/tiny_mce/plugins/fullpage/langs/en_dlg.js index f5801b8..f5801b8 100755..100644 --- a/public/javascripts/tiny_mce/plugins/fullpage/langs/en_dlg.js +++ b/public/javascripts/tiny_mce/plugins/fullpage/langs/en_dlg.js | |||
