Changeset 1411


Ignore:
Timestamp:
02/22/18 08:42:38 (6 months ago)
Author:
gogo
Message:

IE11 Had some issues with the selection and MootoolsFileManager?, this fixes it by having all browsers save and restore the selection when opening/closing the MootoolsFileManager?. Tested in various browsers and it seems fine (previously this was only done for the old IE browsers).

Location:
trunk/plugins/MootoolsFileManager
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/plugins/MootoolsFileManager/MootoolsFileManager.FileManager.js

    r1324 r1411  
    125125    } 
    126126 
    127     if(Xinha.is_ie) this.current_selection = this.editor.saveSelection(); 
     127    // IE11 which pretends it is "gecko" is particularly finicky  
     128    //  about losing selection other browsers not so much, but they 
     129    //   don't seem to mind saving and restoring it anyway, so we  
     130    //   will do that for everybody 
     131    if(1||Xinha.is_ie) this.current_selection = this.editor.saveSelection(); 
    128132    if(link) 
    129133    {       
     
    165169  param.f_href = path; 
    166170 
    167   if(Xinha.is_ie) this.editor.restoreSelection(this.current_selection);   
     171  // IE11 which pretends it is "gecko" is particularly finicky  
     172  //  about losing selection other browsers not so much, but they 
     173  //   don't seem to mind saving and restoring it anyway, so we  
     174  //   will do that for everybody 
     175  if(1||Xinha.is_ie) this.editor.restoreSelection(this.current_selection);   
    168176  if (!a) 
    169177  { 
  • trunk/plugins/MootoolsFileManager/MootoolsFileManager.ImageManager.js

    r1371 r1411  
    111111  } 
    112112   
    113   if(Xinha.is_ie) this.current_selection = this.editor.saveSelection(); 
     113  // IE11 which pretends it is "gecko" is particularly finicky  
     114  //  about losing selection other browsers not so much, but they 
     115  //   don't seem to mind saving and restoring it anyway, so we  
     116  //   will do that for everybody 
     117  if(1||Xinha.is_ie) this.current_selection = this.editor.saveSelection(); 
    114118   
    115119  if(self.current_image) 
     
    575579  param.f_url = path; 
    576580   
    577   if(Xinha.is_ie) this.editor.restoreSelection(this.current_selection); 
     581  // IE11 which pretends it is "gecko" is particularly finicky  
     582  //  about losing selection other browsers not so much, but they 
     583  //   don't seem to mind saving and restoring it anyway, so we  
     584  //   will do that for everybody 
     585  if(1||Xinha.is_ie) this.editor.restoreSelection(this.current_selection); 
    578586  var img = image; 
    579587  if (!img) { 
Note: See TracChangeset for help on using the changeset viewer.