Ticket #1387: fas-2009-02-08.patch

File fas-2009-02-08.patch, 5.6 KB (added by guest, 10 years ago)
  • trunk/modules/InsertImage/pluginMethods.js

     
    2828    } 
    2929    outparam = 
    3030    { 
    31       f_url    : this.stripBaseURL(image.getAttribute('src',2)), // the second parameter makes IE return the value as it is set, as opposed to an "interpolated" (as MSDN calls it) value 
     31      f_url    : editor.stripBaseURL(image.getAttribute('src',2)), // the second parameter makes IE return the value as it is set, as opposed to an "interpolated" (as MSDN calls it) value 
    3232      f_alt    : image.alt, 
    3333      f_border : image.border, 
    3434      f_align  : image.align, 
  • trunk/modules/InternetExplorer/InternetExplorer.js

     
    451451Xinha.prototype.restoreSelection = function(savedSelection) 
    452452{ 
    453453  if (!savedSelection) return; 
     454 
     455  // fas: hack to avoid problem where savedSelection does not implement parentElement(). 
     456  // This condition occurs if there was no text selection at the time saveSelection() was called.  In the case 
     457  // an image selection, the situation is confusing... the image may be selected in two different ways:  1) by 
     458  // simply clicking the image it will appear to be selected by a box with sizing handles; ro 2) by clicking and 
     459  // dragging over the image as you might click and drag over text.  In the first case, the resulting selection 
     460  // object does not implement parentElement(), leading to a crash later on in the code below.  The following 
     461  // hack avoids that problem. 
     462  if (!savedSelection.parentElement) 
     463  { 
     464        return; 
     465  } 
     466 
    454467  // In order to prevent triggering the IE bug mentioned below, we will try to 
    455468  // optimize by not restoring the selection if it happens to match the current 
    456469  // selection. 
  • trunk/plugins/ContextMenu/ContextMenu.js

     
    103103                        elmenus.push(null, 
    104104                                     [ Xinha._lc("_Image Properties...", "ContextMenu"), 
    105105                                       function() { 
    106                                                editor._insertImage(img); 
     106                                               config.btnList["insertimage"][3](img); 
    107107                                       }, 
    108108                                       Xinha._lc("Show the image properties dialog", "ContextMenu"), 
    109109                                       config.btnList["insertimage"][1] ] 
  • trunk/plugins/ContextMenu/menu.css

     
    1010  color: #000; 
    1111  cursor: default; 
    1212  z-index: 1000; 
     13  text-align: left; 
    1314} 
    1415 
    1516div.htmlarea-context-menu table { 
  • trunk/popups/editor_help.html

     
    2323</head> 
    2424 
    2525<body class="dialog" onload="Init()"> 
    26 <div class="title">Xinha Help</div> 
     26<div class="title">Editor Help</div> 
    2727<table width="100%" style="background: white none repeat scroll 0%;"> 
    2828  <thead style="border: 1px solid gray; background: silver none repeat scroll 0%;"> 
    2929  <tr> 
  • trunk/XinhaCore.js

     
    11281128    htmlmode: [ "Toggle HTML Source", ["ed_buttons_main.png",7,0], true, function(e) { e.execCommand("htmlmode"); } ], 
    11291129    toggleborders: [ "Toggle Borders", ["ed_buttons_main.png",7,2], false, function(e) { e._toggleBorders(); } ], 
    11301130    print: [ "Print document", ["ed_buttons_main.png",8,1], false, function(e) { if(Xinha.is_gecko) {e._iframe.contentWindow.print(); } else { e.focusEditor(); print(); } } ], 
    1131     saveas: [ "Save as", "ed_saveas.png", false, function(e) { e.execCommand("saveas",false,"noname.htm"); } ], 
     1131    saveas: [ "Save as", ["ed_buttons_main.png",9,1], false, function(e) { e.execCommand("saveas",false,"noname.htm"); } ], 
    11321132    about: [ "About this editor", ["ed_buttons_main.png",8,2], true, function(e) { e.getPluginInstance("AboutBox").show(); } ], 
    11331133    showhelp: [ "Help using editor", ["ed_buttons_main.png",9,2], true, function(e) { e.execCommand("showhelp"); } ], 
    11341134 
     
    32513251      if ( Xinha.is_gecko ) 
    32523252      { 
    32533253        setTimeout(function() { editor.initIframe(); }, 50); 
    3254         return false; 
     3254        return; 
    32553255      } 
    32563256      else 
    32573257      { 
     
    32623262  catch(ex) 
    32633263  { // try later 
    32643264    setTimeout(function() { editor.initIframe(); }, 50); 
     3265    return; 
    32653266  } 
    32663267   
    32673268  Xinha.freeLater(this, '_doc'); 
     
    67396740  // Opera seems to have some problems mixing HEAD requests with GET requests. 
    67406741  // The GET is slower, so it's a net slowdown for Opera, but it keeps things 
    67416742  // from breaking. 
    6742   var method = Xinha.is_opera ? "GET" : "HEAD"; 
     6743  // 
     6744  // 07 Feb 2009, fas: I found that HEAD was also causing IE7 to hangup (for about 60 seconds) when loading 
     6745  // from a remote, production server.  I could not reproduce the hangup when running on a localhost test 
     6746  // server.  Using GET requests cured the problem in all contexts. 
     6747  // 
     6748  var method = (Xinha.is_opera || Xinha.is_ie) ? "GET" : "HEAD"; 
    67436749  req.onreadystatechange = callBack; 
    67446750  req.open(method, url, true); 
    67456751  req.send(null);