*** plugins/TinyMCEforMT/TinyMCEforMT.pl.org	Wed May  2 18:30:20 2007
--- plugins/TinyMCEforMT/TinyMCEforMT.pl	Wed May 23 05:45:05 2007
***************
*** 139,149 ****
  		// trim continuous spacing
  		html = html.replace(/\\s+</g,'<').replace(/>\\s+/g,'>');
  		// break before tag
! 		html = html.replace (/(<(?:h1|h2|h3|h4|h5|h6)[^>]*\\/?>)/ig, '\\n\$1');
  		// break after tag
! 		html = html.replace (/(<(?:br|\\/h1|\\/h2|\\/h3|\\/h4|\\/h5|\\/h6|\\/li)[^>]*>)/ig, '\$1\\n');
  		// break before and behind of tag
! 		html = html.replace (/(<\\/?(?:address|blockquote|div|dl|form|hr|iframe|img|ol|p|pre|script|table|textarea|ul)[^>]*\\/?>)/ig, '\\n\$1\\n');
  		// trim continuous line breaks
  		html = html.replace(/\\n+/g, "\\n");
  		// trim 'border="x"' in <img> tag
--- 139,149 ----
  		// trim continuous spacing
  		html = html.replace(/\\s+</g,'<').replace(/>\\s+/g,'>');
  		// break before tag
! //		html = html.replace (/(<(?:h1|h2|h3|h4|h5|h6)[^>]*\\/?>)/ig, '\\n\$1');
  		// break after tag
! //		html = html.replace (/(<(?:br|\\/h1|\\/h2|\\/h3|\\/h4|\\/h5|\\/h6|\\/li)[^>]*>)/ig, '\$1\\n');
  		// break before and behind of tag
! //		html = html.replace (/(<\\/?(?:address|blockquote|div|dl|form|hr|iframe|img|ol|p|pre|script|table|textarea|ul)[^>]*\\/?>)/ig, '\\n\$1\\n');
  		// trim continuous line breaks
  		html = html.replace(/\\n+/g, "\\n");
  		// trim 'border="x"' in <img> tag
***************
*** 180,206 ****
  tinyMCE.init({
  		content_css : "<TMPL_VAR NAME=STATIC_URI>$MYNAME/mycontent.css",
  		theme : "advanced",
! 		plugins : "table,advimage,advlink,emotions,insertdatetime,preview,youtube,contextmenu,paste,directionality,noneditable,style",
  		theme_advanced_blockformats : "p,div,pre,h1,h2,h3,h4,h5,h6",
!         theme_advanced_buttons1 : "bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,styleselect,fontselect,fontsizeselect,zoom",
!         theme_advanced_buttons2 : "bullist,numlist,|,outdent,indent,|,undo,redo,|,link,unlink,image,|,code,cleanup,removeformat,|,forecolor,backcolor,|,cut,copy,paste,pastetext,pasteword,|,help",
!         theme_advanced_buttons3 : "styleprops,|,tablecontrols,|,hr,|,sub,sup,|,charmap,nonbreaking,emotions,|,youtube,|,preview",
  		theme_advanced_toolbar_location : "top",
  		theme_advanced_toolbar_align : "left",
  		theme_advanced_path_location : "bottom",
! 		theme_advanced_resize_horizontal : true,
  		theme_advanced_resizing : true,
  		theme_advanced_resizing_use_cookie : true,
     	    extended_valid_elements : "hr[class|width|size|noshade]",
  		file_browser_callback : "fileBrowserCallBack",
! 		language : <TMPL_IF NAME=LANGUAGE_ID>'<TMPL_VAR NAME=LANGUAGE_ID>_<TMPL_VAR NAME=LANGUAGE_ENCODING>'<TMPL_ELSE>'en'</TMPL_IF>.toLowerCase (),
  		convert_urls : false,
! 		convert_fonts_to_spans : true,
! 		convert_newlines_to_brs : false,
! 		force_p_newlines : true,
! 		force_br_newlines : false,
  		relative_urls : false,
! 		apply_source_formatting : true,
          width : "569",
          height : "300",
  		cleanup_callback : "${MYNAME}_CallbackOnCleanup",
--- 180,209 ----
  tinyMCE.init({
  		content_css : "<TMPL_VAR NAME=STATIC_URI>$MYNAME/mycontent.css",
  		theme : "advanced",
! 		plugins : "table,advimage,advlink,insertdatetime,contextmenu,paste,noneditable,style",
  		theme_advanced_blockformats : "p,div,pre,h1,h2,h3,h4,h5,h6",
! 
!         theme_advanced_buttons1 : "styleprops,fontselect,fontsizeselect,zoom,|,bold,italic,underline,|,forecolor,backcolor",
!         theme_advanced_buttons2 : "justifyleft,justifycenter,justifyright,|,numlist,bullist,|,outdent,indent,|,undo,|,cut,copy,paste,|,code,cleanup,removeformat,|,help",
!         theme_advanced_buttons3 : "link,image,|,tablecontrols,|,hr,|,sub,sup,|,nonbreaking",
! 
  		theme_advanced_toolbar_location : "top",
  		theme_advanced_toolbar_align : "left",
  		theme_advanced_path_location : "bottom",
! 		theme_advanced_resize_horizontal : false,
  		theme_advanced_resizing : true,
  		theme_advanced_resizing_use_cookie : true,
     	    extended_valid_elements : "hr[class|width|size|noshade]",
  		file_browser_callback : "fileBrowserCallBack",
! 		language : <TMPL_IF NAME=LANGUAGE_ID>( '<TMPL_VAR NAME=LANGUAGE_ID>_' + '<TMPL_VAR NAME=LANGUAGE_ENCODING>'.replace(/_/,'-') ).toLowerCase ()<TMPL_ELSE>'en'</TMPL_IF>,
  		convert_urls : false,
! 		convert_fonts_to_spans : false,
! 		convert_newlines_to_brs : true,
! 		force_p_newlines : false,
! 		force_br_newlines : true,
! 		remove_linebreaks : true,
  		relative_urls : false,
! 		apply_source_formatting : false,
          width : "569",
          height : "300",
  		cleanup_callback : "${MYNAME}_CallbackOnCleanup",
***************
*** 229,238 ****
  ;#
  	my $add = <<HTML;
   id="${MYNAME}_text_wysiwyg">
! <a title="" href="#" onclick="return enableWYSIWYG('text', 0);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_off.gif" width="44" height="16" /></a>
  </div>
  <span id="${MYNAME}_text_normal"><div class="field-buttons-formatting">
! <a title="" href="#" onclick="return enableWYSIWYG('text', 1);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_on.gif" width="44" height="16" /></a
  HTML
  	chop ($old); $old = quotemeta ($old);
  	chop ($add);
--- 232,241 ----
  ;#
  	my $add = <<HTML;
   id="${MYNAME}_text_wysiwyg">
! <a title="&#12527;&#12540;&#12503;&#12525;&#12514;&#12540;&#12489;&#12434;&#27490;&#12417;HTML&#12434;&#33258;&#20998;&#12391;&#26360;&#12365;&#12414;&#12377;" href="#" onclick="return enableWYSIWYG('text', 0);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_off.gif" width="64" height="19" /></a>
  </div>
  <span id="${MYNAME}_text_normal"><div class="field-buttons-formatting">
! <a title="&#12527;&#12540;&#12503;&#12525;&#39080;&#12395;&#25991;&#31456;&#20837;&#21147;&#12391;&#12365;&#12427;&#12424;&#12358;&#12395;&#12375;&#12414;&#12377;" href="#" onclick="return enableWYSIWYG('text', 1);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_on.gif" width="64" height="19" /></a
  HTML
  	chop ($old); $old = quotemeta ($old);
  	chop ($add);
***************
*** 269,278 ****
  HTML
  	my $add = <<HTML;
   id="${MYNAME}_text_more_wysiwyg">
! <a title="" href="#" onclick="return enableWYSIWYG('text_more', 0);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_off.gif" width="44" height="16" /></a>
  </div>
  <span id="${MYNAME}_text_more_normal"><div class="field-buttons-formatting">
! <a title="" href="#" onclick="return enableWYSIWYG('text_more', 1);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_on.gif" width="44" height="16" /></a
  HTML
  	chop ($old); $old = quotemeta ($old);
  	chop ($add);
--- 272,281 ----
  HTML
  	my $add = <<HTML;
   id="${MYNAME}_text_more_wysiwyg">
! <a title="&#12527;&#12540;&#12503;&#12525;&#12514;&#12540;&#12489;&#12434;&#27490;&#12417;HTML&#12434;&#33258;&#20998;&#12391;&#26360;&#12365;&#12414;&#12377;" href="#" onclick="return enableWYSIWYG('text_more', 0);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_off.gif" width="64" height="19" /></a>
  </div>
  <span id="${MYNAME}_text_more_normal"><div class="field-buttons-formatting">
! <a title="&#12527;&#12540;&#12503;&#12525;&#39080;&#12395;&#25991;&#31456;&#20837;&#21147;&#12391;&#12365;&#12427;&#12424;&#12358;&#12395;&#12375;&#12414;&#12377;" href="#" onclick="return enableWYSIWYG('text_more', 1);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_on.gif" width="64" height="19" /></a
  HTML
  	chop ($old); $old = quotemeta ($old);
  	chop ($add);
***************
*** 291,300 ****
  HTML
  	my $add2 = <<HTML;
  <span id="${MYNAME}_excerpt_wysiwyg">
! <a title="" href="#" onclick="return enableWYSIWYG('excerpt', 0);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_off.gif" width="44" height="16" /></a>
  </span>
  <span id="${MYNAME}_excerpt_normal">
! <a title="" href="#" onclick="return enableWYSIWYG('excerpt', 1);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_on.gif" width="44" height="16" /></a>
  </span>
  HTML
  	chop ($old); $old = quotemeta ($old);
--- 294,303 ----
  HTML
  	my $add2 = <<HTML;
  <span id="${MYNAME}_excerpt_wysiwyg">
! <a title="&#12527;&#12540;&#12503;&#12525;&#12514;&#12540;&#12489;&#12434;&#27490;&#12417;HTML&#12434;&#33258;&#20998;&#12391;&#26360;&#12365;&#12414;&#12377;" href="#" onclick="return enableWYSIWYG('excerpt', 0);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_off.gif" width="64" height="19" /></a>
  </span>
  <span id="${MYNAME}_excerpt_normal">
! <a title="&#12527;&#12540;&#12503;&#12525;&#39080;&#12395;&#25991;&#31456;&#20837;&#21147;&#12391;&#12365;&#12427;&#12424;&#12358;&#12395;&#12375;&#12414;&#12377;" href="#" onclick="return enableWYSIWYG('excerpt', 1);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_on.gif" width="64" height="19" /></a>
  </span>
  HTML
  	chop ($old); $old = quotemeta ($old);
***************
*** 315,324 ****
  HTML
  	my $add2 = <<HTML;
  <span id="${MYNAME}_keywords_wysiwyg">
! <a title="" href="#" onclick="return enableWYSIWYG('keywords', 0);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_off.gif" width="44" height="16" /></a>
  </span>
  <span id="${MYNAME}_keywords_normal">
! <a title="" href="#" onclick="return enableWYSIWYG('keywords', 1);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_on.gif" width="44" height="16" /></a>
  </span>
  HTML
  	chop ($old); $old = quotemeta ($old);
--- 318,327 ----
  HTML
  	my $add2 = <<HTML;
  <span id="${MYNAME}_keywords_wysiwyg">
! <a title="&#12527;&#12540;&#12503;&#12525;&#12514;&#12540;&#12489;&#12434;&#27490;&#12417;HTML&#12434;&#33258;&#20998;&#12391;&#26360;&#12365;&#12414;&#12377;" href="#" onclick="return enableWYSIWYG('keywords', 0);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_off.gif" width="64" height="19" /></a>
  </span>
  <span id="${MYNAME}_keywords_normal">
! <a title="&#12527;&#12540;&#12503;&#12525;&#39080;&#12395;&#25991;&#31456;&#20837;&#21147;&#12391;&#12365;&#12427;&#12424;&#12358;&#12395;&#12375;&#12414;&#12377;" href="#" onclick="return enableWYSIWYG('keywords', 1);"><img src="<TMPL_VAR NAME=STATIC_URI>$MYNAME/images/wysiwyg_on.gif" width="64" height="19" /></a>
  </span>
  HTML
  	chop ($old); $old = quotemeta ($old);
