diff options
Diffstat (limited to 'framework/Web/Javascripts/source/prado/controls/htmlarea.js')
-rw-r--r-- | framework/Web/Javascripts/source/prado/controls/htmlarea.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/framework/Web/Javascripts/source/prado/controls/htmlarea.js b/framework/Web/Javascripts/source/prado/controls/htmlarea.js index 30bb82dd..5cba4f6c 100644 --- a/framework/Web/Javascripts/source/prado/controls/htmlarea.js +++ b/framework/Web/Javascripts/source/prado/controls/htmlarea.js @@ -124,7 +124,11 @@ Prado.WebUI.THtmlArea = Class.create(Prado.WebUI.Control, try { tinyMCE.execCommand('mceFocus', false, this.ID); + // when removed, tinyMCE restores its content to the textarea. If the textarea content has been + // updated in this same callback, it will be overwritten with the old content. Workaround this. + var curtext = $(this.ID).value; tinyMCE.execCommand('mceRemoveControl', false, this.ID); + $(this.ID).value = curtext; } catch (e) { |