Ticket #6588: 6588.patch
File 6588.patch, 1.3 KB (added by , 13 years ago) |
---|
-
_source/plugins/scayt/plugin.js
46 46 oParams.customDictionaryIds = config.scayt_customDictionaryIds || ''; 47 47 oParams.userDictionaryName = config.scayt_userDictionaryName || ''; 48 48 oParams.sLang = config.scayt_sLang || 'en_US'; 49 oParams.addClass = true; 49 50 50 51 // Introduce SCAYT onLoad callback. (#5632) 51 52 oParams.onLoad = function() … … 505 506 { 506 507 var moreSuggestions = {}, 507 508 mainSuggestions = {}; 508 509 510 // Delete span.scayt-misspell when text pasting in editor (#6588) 511 var dataProcessor = editor.dataProcessor; 512 var addDataFilterRules = { 513 elements : { 514 span : function( element ){ 515 if (element.attributes['class'] != undefined){ 516 if (element.attributes['class'].indexOf("scayt-misspell") != -1){ delete element.name } 517 if (element.attributes['class'].indexOf("scayt-ignore") != -1){ delete element.name } 518 } 519 } 520 } 521 }; 522 dataProcessor.dataFilter.addRules( addDataFilterRules ); 523 509 524 // Scayt command. 510 525 var command = editor.addCommand( commandName, commandDefinition ); 511 526