From 39f5ddeeb7871eee4845da8f2c1ac6079158dd4a Mon Sep 17 00:00:00 2001 From: Rajesh Taneja Date: Mon, 5 Sep 2011 14:25:13 +0800 Subject: [PATCH] MDL-28987 Forms Library: Removed onBlur validation. Now the validation will occur on form submit only --- lib/editor/tinymce/module.js | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/lib/editor/tinymce/module.js b/lib/editor/tinymce/module.js index 3978bcea59b..2754961545d 100644 --- a/lib/editor/tinymce/module.js +++ b/lib/editor/tinymce/module.js @@ -80,20 +80,11 @@ M.editor_tinymce.onblur_event = function(ed) { //have loaded contents and submitting form should not throw error. ed.save(); - //Attach blur event for tinymce to call onchange validation function of textarea. + //Attach blur event for tinymce to save contents to textarea var doc = s.content_editable ? ed.getBody() : (tinymce.isGecko ? ed.getDoc() : ed.getWin()); tinymce.dom.Event.add(doc, 'blur', function() { //save contents to textarea before calling validation script. ed.save(); - var element = document.getElementById(ed.id); - element.onchange(element); - }); - - //Add an extra event to make sure after window is blurred because of user clicking - //out of tinymce or any popup occured, then error should be cleaned on focusing back. - tinymce.dom.Event.add(doc, 'focus', function() { - var element = document.getElementById(ed.id); - qf_errorHandler(element, ''); }); }; };