Changeset 192
- Timestamp:
- 03/17/07 09:49:09 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/v.mische/test/002/wymeditor/jquery.wymeditor.explorer.js
r191 r192 1 /*1 /* 2 2 * WYMeditor : what you see is What You Mean web-based editor 3 3 * Copyright (C) 2007 H.O.net - http://www.honet.be/ … … 38 38 39 39 40 var doc = iframe.contentWindow.document;40 //var doc = iframe.contentWindow.document; 41 41 this.html(this._wym._html); 42 42 … … 44 44 //handle events 45 45 var wymexp = this; 46 doc.onbeforedeactivate = function() {wymexp.saveCaret();};47 doc.onkeyup = function() {wymexp.saveCaret();};48 doc.onclick = function() {wymexp.saveCaret();};46 this._doc.onbeforedeactivate = function() {wymexp.saveCaret();}; 47 this._doc.onkeyup = function() {wymexp.saveCaret();}; 48 this._doc.onclick = function() {wymexp.saveCaret();}; 49 49 50 50 //callback can't be executed twice, so we check … … 53 53 }; 54 54 55 /* 55 56 WymClassExplorer.prototype.doc = function() { 56 57 //MSIE needs this weird function, or sometimes you get "Permission denied" if you call this._doc … … 58 59 return(doc); 59 60 }; 61 */ 60 62 61 63 WymClassExplorer.prototype._exec = function(cmd,param) { … … 75 77 WymClassExplorer.prototype.saveCaret = function () { 76 78 77 var doc = this._iframe.contentWindow.document;78 doc.caretPos =doc.selection.createRange();79 //var doc = this._iframe.contentWindow.document; 80 this._doc.caretPos = this._doc.selection.createRange(); 79 81 }; 80 82
Note: See TracChangeset
for help on using the changeset viewer.