rem: tinyMCE.triggerNodeChange(false); 
context: function TinyMCE_handleEvent(e) {	//window.status = e.type + " " + e.target.nodeName + " " + (e.relatedTarget ? e.relatedTarget.nodeName : "");	switch (e.type) {		case "paste":			if (tinyMCE.settings['auto_cleanup_word'])				window.setTimeout("tinyMCE.execInstanceCommand('" + e.target.editorId + "', 'mceCleanupWord', false, null);", 1);			break;		case "beforecut":		case "beforepaste":			if (tinyMCE.selectedInstance)				tinyMCE.selectedInstance.execCommand("mceAddUndoLevel");			break;		case "keypress":			if (e.target.editorId) {				tinyMCE.selectedInstance = tinyMCE.instances[e.target.editorId];			} else {				if (e.target.ownerDocument.editorId)					tinyMCE.selectedInstance = tinyMCE.instances[e.target.ownerDocument.editorId];			}			// Mozilla custom key handling			if (!tinyMCE.isMSIE && e.ctrlKey && tinyMCE.settings['custom_undo_redo']) {				if (e.charCode == 120 || e.charCode == 118) { // Ctrl+X, Ctrl+V					tinyMCE.selectedInstance.execCommand("mceAddUndoLevel");					return;				}				if (e.charCode == 122) { // Ctrl+Z					tinyMCE.selectedInstance.execCommand("Undo");					// Cancel event					e.preventDefault();					return false;				}				if (e.charCode == 121) { // Ctrl+Y					tinyMCE.selectedInstance.execCommand("Redo");					// Cancel event					e.preventDefault();					return false;				}			}			if (tinyMCE.settings['custom_undo_redo']) {				// Check if it's a position key press				var keys = new Array(13,45,36,35,33,34,37,38,39,40);				var posKey = false;				for (var i=0; i<keys.length; i++) {					if (keys[i] == e.keyCode) {						tinyMCE.selectedInstance.typing = false;						posKey = true;						break;					}				}				// Add typing undo level				if (!tinyMCE.selectedInstance.typing && !posKey) {					tinyMCE.selectedInstance.execCommand("mceAddUndoLevel");					tinyMCE.selectedInstance.typing = true;				}			}			//window.status = e.keyCode;			//window.status = e.type + " " + e.target.nodeName;			// Return key pressed			if (tinyMCE.isMSIE && tinyMCE.settings['force_br_newlines'] && e.keyCode == 13) {				if (e.target.editorId)					tinyMCE.selectedInstance = tinyMCE.instances[e.target.editorId];				if (tinyMCE.selectedInstance) {					var sel = tinyMCE.selectedInstance.contentWindow.document.selection;					var rng = sel.createRange();					if (tinyMCE.getParentElement(rng.parentElement(), "li") != null)						return false;					if (tinyMCE.getParentElement(rng.parentElement(), "div") == null)						return false;					// Cancel event					e.returnValue = false;					e.cancelBubble = true;					// Insert BR element					rng.pasteHTML("<br>");					rng.collapse(false);					rng.select();				}			}			// Backspace or delete			if (e.keyCode == 8 || e.keyCode == 46) {				tinyMCE.selectedElement = e.target;				tinyMCE.linkElement = tinyMCE.getParentElement(e.target, "a");				tinyMCE.imgElement = tinyMCE.getParentElement(e.target, "img");				tinyMCE.triggerNodeChange(false);			}			return false;		break;		case "keyup":		case "keydown":			if (e.target.editorId)				tinyMCE.selectedInstance = tinyMCE.instances[e.target.editorId];			else				return;			tinyMCE.selectedElement = null;			var elm = tinyMCE.selectedInstance.getFocusElement();			tinyMCE.linkElement = tinyMCE.getParentElement(elm, "a");			tinyMCE.imgElement = tinyMCE.getParentElement(elm, "img");			tinyMCE.selectedElement = elm;			// MSIE custom key handling			if (tinyMCE.isMSIE && tinyMCE.settings['custom_undo_redo']) {				// Check if it's a position key press				var keys = new Array(13,45,36,35,33,34,37,38,39,40);				var posKey = false;				for (var i=0; i<keys.length; i++) {					if (keys[i] == e.keyCode) {						tinyMCE.selectedInstance.typing = false;						posKey = true;						break;					}				}				// Add typing undo level (unless pos keys or shift, alt, ctrl, capslock)				if (!tinyMCE.selectedInstance.typing && !posKey && (e.keyCode < 16 || e.keyCode > 18 && e.keyCode != 255)) {					tinyMCE.selectedInstance.execCommand("mceAddUndoLevel");					tinyMCE.selectedInstance.typing = true;					tinyMCE.triggerNodeChange(false);				}				if (posKey && e.type == "keyup")					tinyMCE.triggerNodeChange(false);				var ctrlKeys = new Array(66,73,85,86,88); // B/I/U/V/X				var keys = new Array(8,46); // Backspace,Delete				for (var i=0; i<keys.length; i++) {					if ((ctrlKeys[i] == e.keyCode && e.ctrlKey) || keys[i] == e.keyCode) {						tinyMCE.selectedInstance.execCommand("mceAddUndoLevel");						tinyMCE.triggerNodeChange(false);						return true;					}				}				if (e.keyCode == 90 && e.ctrlKey && e.type == "keydown") { // Ctrl+Z					tinyMCE.selectedInstance.execCommand("Undo");					tinyMCE.triggerNodeChange(false);					// Cancel event					e.returnValue = false;					e.cancelBubble = true;					return false;				}				if (e.keyCode == 89 && e.ctrlKey && e.type == "keydown") { // Ctrl+Y					tinyMCE.selectedInstance.execCommand("Redo");					tinyMCE.triggerNodeChange(false);					// Cancel event					e.returnValue = false;					e.cancelBubble = true;					return false;				}			}		break;		case "mousedown":		case "mouseup":		case "click":		case "focus":			// Check instance event trigged on			var targetBody = tinyMCE.getParentElement(e.target, "body");			for (var instanceName in tinyMCE.instances) {				var instance = tinyMCE.instances[instanceName];				if (instance.contentWindow.document.body == targetBody) {					tinyMCE.selectedInstance = instance;					tinyMCE.selectedElement = e.target;					tinyMCE.linkElement = tinyMCE.getParentElement(tinyMCE.selectedElement, "a");					tinyMCE.imgElement = tinyMCE.getParentElement(tinyMCE.selectedElement, "img");					// Reset typing					tinyMCE.selectedInstance.typing = false;					tinyMCE.triggerNodeChange(false);					break;				}			}			// Just in case			if (!tinyMCE.selectedInstance && e.target.editorId)				tinyMCE.selectedInstance = tinyMCE.instances[e.target.editorId];		break;	}}
meta: 5314	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/5314/873ce1c62e52365d732f67421272ae1302559b15/tiny_mce_src.js/buggy/www/extras/tinymce/jscripts/tiny_mce/tiny_mce_src.js