From c09b5102afbef3e3121e18c56b71d1cb2ae7e9fa Mon Sep 17 00:00:00 2001 From: starfighter83 Date: Wed, 23 Feb 2011 09:26:40 -0100 Subject: [PATCH] Fixes: TinyMCE no longer defaults

tags around text Work Items: 29964 --- .../umbraco_client/tinymce3/tiny_mce_src.js | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/umbraco/presentation/umbraco_client/tinymce3/tiny_mce_src.js b/umbraco/presentation/umbraco_client/tinymce3/tiny_mce_src.js index a0f5b431b1..132db2701a 100644 --- a/umbraco/presentation/umbraco_client/tinymce3/tiny_mce_src.js +++ b/umbraco/presentation/umbraco_client/tinymce3/tiny_mce_src.js @@ -5049,16 +5049,22 @@ window.tinymce.dom.Sizzle = Sizzle; }, setContent : function(h, s) { + + var t = this, r = t.getRng(), c, d = t.win.document; s = s || {format : 'html'}; s.set = true; h = s.content = t.dom.processHTML(h); + + // Dispatch before set content event t.onBeforeSetContent.dispatch(t, s); h = s.content; + + if (r.insertNode) { // Make caret marker since insertNode places the caret in the beginning of text after insert h += '_'; @@ -9276,7 +9282,7 @@ tinymce.create('tinymce.ui.Toolbar:tinymce.ui.Container', { font_size_style_values : 'xx-small,x-small,small,medium,large,x-large,xx-large', apply_source_formatting : 1, directionality : 'ltr', - forced_root_block : false, + forced_root_block : 'p', valid_elements : '@[id|class|style|title|dir