Changeset 810
- Timestamp:
- 04/10/07 21:35:44 (6 years ago)
- Files:
-
- 1 modified
-
trunk/plugins/CharCounter/char-counter.js (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/plugins/CharCounter/char-counter.js
r677 r810 9 9 this._Words = 0; 10 10 this._HTML = 0; 11 this.maxHTML = 1024;12 11 this.onKeyPress = this.__onKeyPress; 13 12 } … … 18 17 'showWord': true, // show the words count, 19 18 'showHtml': true, // show the exact html count 20 'separator': ' | ' // separator used to join informations 19 'separator': ' | ', // separator used to join informations 20 'maxHTML' : -1 // -1 for unlimited length, other number for limiting the length of the edited HTML 21 21 }; 22 22 23 23 CharCounter._pluginInfo = { 24 24 name : "CharCounter", 25 version : "1.3 ",25 version : "1.31", 26 26 developer : "Udo Schmal", 27 27 developer_url : "http://www.schaffrath-neuemedien.de", … … 37 37 38 38 39 CharCounter.prototype.onGenerate = function() {39 CharCounter.prototype.onGenerateOnce = function() { 40 40 var self = this; 41 41 if (this.charCount==null) { … … 66 66 CharCounter.prototype.__onKeyPress= function(ev) { 67 67 if ((ev.keyCode != 8) && (ev.keyCode !=46)) { // not backspace & delete 68 if (this. maxHTML!=-1) {68 if (this.editor.config.CharCounter.maxHTML!=-1) { 69 69 var contents = this.editor.getHTML(); 70 if (contents.length >=this.maxHTML) {70 if (contents.length >= this.editor.config.CharCounter.maxHTML) { 71 71 HTMLArea._stopEvent(ev); 72 72 return true;
