includes/clientside/tinymce/plugins/fullscreen/fullscreen.htm
changeset 588 20484deb89cd
parent 476 f26a69c40431
child 1193 e3b94bd055dc
--- a/includes/clientside/tinymce/plugins/fullscreen/fullscreen.htm	Thu Jun 26 18:05:42 2008 -0400
+++ b/includes/clientside/tinymce/plugins/fullscreen/fullscreen.htm	Thu Jun 26 20:55:13 2008 -0400
@@ -10,7 +10,7 @@
 				settings[key] = "window.opener." + settings[key];
 		}
 
-		var settings = {}, paSe = window.opener.tinyMCE.activeEditor.settings;
+		var settings = {}, paSe = window.opener.tinyMCE.activeEditor.settings, oeID = window.opener.tinyMCE.activeEditor.id;
 
 		// Clone array
 		for (var n in paSe)
@@ -41,13 +41,13 @@
 		settings['ask'] = false;
 		settings['document_base_url'] = window.opener.tinyMCE.activeEditor.documentBaseURI.getURI();
 		settings['fullscreen_is_enabled'] = true;
-		settings['fullscreen_editor_id'] = window.opener.tinyMCE.activeEditor.id;
+		settings['fullscreen_editor_id'] = oeID;
 		settings['theme_advanced_resizing'] = false;
 		settings['strict_loading_mode'] = true;
 
 		settings.save_onsavecallback = function() {
-			window.opener.tinyMCE.activeEditor.setContent(tinyMCE.get('fullscreenarea').getContent({format : 'raw'}), {format : 'raw'});
-			window.opener.tinyMCE.activeEditor.execCommand('mceSave');
+			window.opener.tinyMCE.get(oeID).setContent(tinyMCE.get('fullscreenarea').getContent({format : 'raw'}), {format : 'raw'});
+			window.opener.tinyMCE.get(oeID).execCommand('mceSave');
 			window.close();
 		};
 
@@ -56,7 +56,7 @@
 		}
 
 		function moveContent() {
-			window.opener.tinyMCE.activeEditor.setContent(tinyMCE.activeEditor.getContent());
+			window.opener.tinyMCE.get(oeID).setContent(tinyMCE.activeEditor.getContent());
 		}
 
 		function closeFullscreen() {
@@ -78,7 +78,7 @@
 		function render() {
 			var e = document.getElementById('fullscreenarea'), vp, ed, ow, oh, dom = tinymce.DOM;
 
-			e.value = window.opener.tinyMCE.activeEditor.getContent();
+			e.value = window.opener.tinyMCE.get(oeID).getContent();
 
 			vp = dom.getViewPort();
 			settings.width = vp.w;