Changeset 5347
- Timestamp:
- 10/22/09 03:54:35 (2 years ago)
- Location:
- branches/scratch/pharvey
- Files:
-
- 4 edited
-
TinyMCEPlugin/lib/Foswiki/Plugins/TinyMCEPlugin.pm (modified) (1 diff)
-
WysiwygPlugin/lib/Foswiki/Plugins/WysiwygPlugin/TML2HTML.pm (modified) (2 diffs)
-
WysiwygPlugin/test/unit/WysiwygPlugin/TranslatorTests.pm (modified) (2 diffs)
-
WysiwygPlugin/test/unit/WysiwygPlugin/WysiwygPluginTests.pm (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/scratch/pharvey/TinyMCEPlugin/lib/Foswiki/Plugins/TinyMCEPlugin.pm
r5344 r5347 37 37 dialog_type: "modal", 38 38 extended_valid_elements : "li[type]", 39 forced_root_block : false,40 39 setupcontent_callback : FoswikiTiny.setUpContent, 41 40 urlconverter_callback : "FoswikiTiny.convertLink", -
branches/scratch/pharvey/WysiwygPlugin/lib/Foswiki/Plugins/WysiwygPlugin/TML2HTML.pm
r5240 r5347 47 47 my $TT2 = chr(2); 48 48 49 # SMELL: Item2254: Accomodates a temporary work-around, where TML2HTML 50 # needs to wrap content in <div></div> 51 my $Item2254start = '<div>'; 52 my $Item2254end = '</div>'; 53 49 54 # HTML elements that are palatable to editors. Other HTML tags will be 50 55 # rendered in 'protected' regions to prevent the WYSIWYG editor mussing … … 129 134 130 135 # This should really use a template, but what the heck... 131 return $content; 136 # SMELL: Item2254 - see var declaration up top 137 return $Item2254start . $content . $Item2254end; 138 139 #return $content; 132 140 } 133 141 -
branches/scratch/pharvey/WysiwygPlugin/test/unit/WysiwygPlugin/TranslatorTests.pm
r5310 r5347 41 41 my $CANNOTWYSIWYG = 1 << 3; # test that notWysiwygEditable returns true 42 42 # and make the ROUNDTRIP test expect failure 43 44 # SMELL: Accomodates the temporary work-around for Item2254, for when TML2HTML 45 # is wrapping content in <div></div> 46 my $Item2254start = '<div>'; 47 my $Item2254end = '</div>'; 43 48 44 49 # Note: ROUNDTRIP is *not* the same as the combination of … … 2161 2166 $this->TML_HTMLconverterOptions() 2162 2167 ); 2168 2169 # SMELL: Item2254 temporary work-around requires TML2HTML to wrap output 2170 # in <div></div>. 2171 if (($Item2254start) and ($Item2254end)) { 2172 $tx = ($tx =~ /^$Item2254start(.*)$Item2254end$/mxs)[0]; 2173 } 2163 2174 2164 2175 $this->assert_html_equals( $html, $tx ); -
branches/scratch/pharvey/WysiwygPlugin/test/unit/WysiwygPlugin/WysiwygPluginTests.pm
r4645 r5347 31 31 my $UI_FN; 32 32 33 # SMELL: Accomodates the temporary work-around for Item2254, for when TML2HTML 34 # is wrapping content in <div></div> 35 my $Item2254start = '<div>'; 36 my $Item2254end = '</div>'; 37 33 38 sub new { 34 39 my $self = shift()->SUPER::new(@_); … … 164 169 165 170 $out = Encode::decode_utf8($out); 166 171 167 172 my $id = "<!--$Foswiki::Plugins::WysiwygPlugin::SECRET_ID-->"; 168 $this->assert( $out =~ s/^\s*$id <p>\s*//s, anal($out) );169 $out =~ s/\s*<\/p> \s*$//s;173 $this->assert( $out =~ s/^\s*$id$Item2254start<p>\s*//s, anal($out) ); 174 $out =~ s/\s*<\/p>$Item2254end\s*$//s; 170 175 171 176 require Foswiki::Plugins::WysiwygPlugin::Constants;
Note: See TracChangeset
for help on using the changeset viewer.
