Changeset 932


Ignore:
Timestamp:
01/13/08 18:46:26 (12 years ago)
Author:
ray
Message:

another fix for #1112 for FF3

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/modules/Gecko/Gecko.js

    r930 r932  
    696696 
    697697//Control character for retaining edit location when switching modes 
    698 Xinha.prototype.cc = String.fromCharCode(173);  
     698Xinha.prototype.cc = '|XinhaCaret|';  
    699699 
    700700Xinha.prototype.setCC = function ( target ) 
     
    752752  else 
    753753  { 
    754   try  
    755   { 
    756     var self = this; 
    757     var t = setTimeout(function(){ // Why do so many thing work only with a timeout?? 
    758       self._iframe.contentWindow.find( self.cc ); 
    759       var sel = self.getSelection(); 
     754    try 
     755    { 
     756      this._iframe.contentWindow.find( this.cc ); 
     757      var sel = this.getSelection(); 
    760758      sel.getRangeAt(0).deleteContents(); 
    761       self._iframe.contentWindow.focus(); 
    762     },50); 
    763      
    764   } catch (e) {} 
     759      this.scrollToElement(); 
     760      this._iframe.contentWindow.focus(); 
     761    } catch (e) {} 
    765762  } 
    766763}; 
Note: See TracChangeset for help on using the changeset viewer.