Changeset 6996 for trunk/gli


Ignore:
Timestamp:
2004-03-09T17:10:48+13:00 (20 years ago)
Author:
kjdon
Message:

now if you change the interface lang, it calls clearPluginCache and clearClassifierCache on the plugin and classifier managers

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gli/src/org/greenstone/gatherer/gui/Preferences.java

    r6842 r6996  
    650650        Gatherer.g_man.enrich_pane.valueChanged((TreeSelectionEvent) null); // Refresh metadata table
    651651
    652         Gatherer.config.setLocale("general.locale", Configuration.GENERAL_SETTING, ((DictionaryEntry)language_combobox.getSelectedItem()).getLocale());
    653 
     652        String current_lang = Gatherer.config.getLanguage();
     653        String new_lang = ((DictionaryEntry)language_combobox.getSelectedItem()).getLocale().getLanguage();
     654        if (!current_lang.equals(new_lang)) {
     655        Gatherer.config.setLocale("general.locale", Configuration.GENERAL_SETTING, ((DictionaryEntry)language_combobox.getSelectedItem()).getLocale());
     656        // delete the plugins and classifiers.dat files
     657        Gatherer.c_man.getCollection().cdm.plugin_manager.clearPlugInCache();
     658        Gatherer.c_man.getCollection().cdm.classifier_manager.clearClassifierCache();
     659        }
    654660        //Gatherer.config.setInt("general.max_folder_depth", Configuration.COLLECTION_SPECIFIC, ((Integer)recursion_depth_spinner.getValue()).intValue());
    655661
Note: See TracChangeset for help on using the changeset viewer.