Changeset 590


Ignore:
Timestamp:
04/16/09 11:20:39 (3 years ago)
Author:
totoro
Message:

Implemented Safari.setFocusToNode() (thanks wnielson). See #151.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wymeditor/jquery.wymeditor.safari.js

    r555 r590  
    219219}; 
    220220 
    221 //TODO 
    222221WYMeditor.WymClassSafari.prototype.setFocusToNode = function(node) { 
    223     /*var range = document.createRange(); 
     222    var range = this._iframe.contentDocument.createRange(); 
    224223    range.selectNode(node); 
    225224    var selected = this._iframe.contentWindow.getSelection(); 
    226225    selected.addRange(range); 
    227226    selected.collapse(node, node.childNodes.length); 
    228     this._iframe.contentWindow.focus();*/ 
     227    this._iframe.contentWindow.focus(); 
    229228}; 
    230229 
Note: See TracChangeset for help on using the changeset viewer.