rem: window._content.focus(); 
add: gContentWindow.focus(); 
context: function SetDisplayMode(mode){  if (gIsHTMLEditor)  {    // Already in requested mode:    //  return false to indicate we didn't switch    if (mode == gEditorDisplayMode)      return false;    gEditorDisplayMode = mode;    // Save the last non-source mode so we can cancel source editing easily    if (mode != DisplayModeSource)      PreviousNonSourceDisplayMode = mode;    // Editorshell does the style sheet loading/unloading    editorShell.SetDisplayMode(mode);    // Set the UI states    var selectedTab = null;    if (mode == DisplayModePreview) selectedTab = gPreviewModeButton;    if (mode == DisplayModeNormal) selectedTab = gNormalModeButton;    if (mode == DisplayModeAllTags) selectedTab = gTagModeButton;    if (mode == DisplayModeSource) selectedTab = gSourceModeButton;    if (selectedTab)      document.getElementById("EditModeTabs").selectedTab = selectedTab;    if (mode == DisplayModeSource)    {      // Switch to the sourceWindow (second in the deck)      gContentWindowDeck.setAttribute("index","1");      DisableMenusForHTMLSource(true);      //Hide the formating toolbar if not already hidden      gFormatToolbarHidden = gFormatToolbar.getAttribute("hidden");      if (gFormatToolbarHidden != "true")      {        gFormatToolbar.setAttribute("hidden", "true");      }      gSourceContentWindow.focus();    }    else    {      // Switch to the normal editor (first in the deck)      gContentWindowDeck.setAttribute("index","0");      // Restore menus and toolbars      DisableMenusForHTMLSource(false);      if (gFormatToolbarHidden != "true")      {        gFormatToolbar.setAttribute("hidden", gFormatToolbarHidden);      }      window._content.focus();    }    // We must set check on menu item since toolbar may have been used    document.getElementById("viewPreviewMode").setAttribute("checked","false");    document.getElementById("viewNormalMode").setAttribute("checked","false");    document.getElementById("viewAllTagsMode").setAttribute("checked","false");    document.getElementById("viewSourceMode").setAttribute("checked","false");    var menuID;    switch(mode)    {      case DisplayModePreview:        menuID = "viewPreviewMode";        break;      case DisplayModeNormal:        menuID = "viewNormalMode";        break;      case DisplayModeAllTags:        menuID = "viewAllTagsMode";        break;      case DisplayModeSource:        menuID = "viewSourceMode";        break;    }    if (menuID)      document.getElementById(menuID).setAttribute("checked","true");    return true;  }  return false;}
meta: 8395	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/8395/5315f300306753d3e6e43aaf0e8ddd650d310502/editor.js/buggy/editor/ui/composer/content/editor.js