Ignore:
Timestamp:
03/05/05 07:04:04 (15 years ago)
Author:
gogo
Message:

Applied patch in ticket #51

Location:
trunk/plugins/SpellChecker
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/plugins/SpellChecker/spell-check-ui.js

    r20 r32  
    204204  var field = document.getElementById("f_content"); 
    205205  field.value = HTMLArea.getHTML(editor._doc.body, false, editor); 
    206  
     206  var dict = document.getElementById("f_dictionary"); 
     207  if(typeof editor.config.SpellChecker.defaultDictionary != "undefined" 
     208     && editor.config.SpellChecker.defaultDictionary != "") { 
     209    dict.value = editor.config.SpellChecker.defaultDictionary; 
     210  } else { 
     211    dict.value = "en_GB"; 
     212  } 
    207213  if(editor.config.SpellChecker.backend == 'php') 
    208214  { 
     
    422428      select.remove(i); 
    423429    } 
     430    var activeDictionary = document.getElementById("f_dictionary").value; 
    424431    for (var i = 0; i < dicts.length; ++i) { 
    425432      var txt = dicts[i]; 
    426433      var option = document.createElement("option"); 
    427       if (/^@(.*)$/.test(txt)) { 
     434      if(txt == activeDictionary) { 
    428435        txt = RegExp.$1; 
    429436        option.selected = true; 
  • trunk/plugins/SpellChecker/spell-checker.js

    r20 r32  
    99// $Id$ 
    1010 
    11 HTMLArea.Config.prototype.SpellChecker = { 'backend': 'php', 'personalFilesDir' : '' }; 
     11HTMLArea.Config.prototype.SpellChecker = { 'backend': 'php', 'personalFilesDir' : '', 'defaultDictionary' : 'en_GB' }; 
    1212 
    1313function SpellChecker(editor) { 
Note: See TracChangeset for help on using the changeset viewer.