summaryrefslogtreecommitdiff
path: root/plugins/SpellChecker/src
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/SpellChecker/src')
-rw-r--r--plugins/SpellChecker/src/options.cpp7
-rw-r--r--plugins/SpellChecker/src/options.h3
-rw-r--r--plugins/SpellChecker/src/spellchecker.cpp5
3 files changed, 4 insertions, 11 deletions
diff --git a/plugins/SpellChecker/src/options.cpp b/plugins/SpellChecker/src/options.cpp
index 7fafa944e8..8188bad73a 100644
--- a/plugins/SpellChecker/src/options.cpp
+++ b/plugins/SpellChecker/src/options.cpp
@@ -73,13 +73,6 @@ int InitOptionsCallback(WPARAM wParam, LPARAM)
return 0;
}
-void InitOptions()
-{
- LoadOptions();
-
- HookEvent(ME_OPT_INITIALISE, InitOptionsCallback);
-}
-
void LoadOptions()
{
LoadOpts(optionsControls, _countof(optionsControls), MODULENAME);
diff --git a/plugins/SpellChecker/src/options.h b/plugins/SpellChecker/src/options.h
index 8d699d4adf..5577c8fb3a 100644
--- a/plugins/SpellChecker/src/options.h
+++ b/plugins/SpellChecker/src/options.h
@@ -50,8 +50,7 @@ struct Options
extern Options opts;
-// Initializations needed by options
-void InitOptions();
+int InitOptionsCallback(WPARAM, LPARAM);
// Loads the options from DB
// It don't need to be called, except in some rare cases
diff --git a/plugins/SpellChecker/src/spellchecker.cpp b/plugins/SpellChecker/src/spellchecker.cpp
index f5ce69d0a7..348946325e 100644
--- a/plugins/SpellChecker/src/spellchecker.cpp
+++ b/plugins/SpellChecker/src/spellchecker.cpp
@@ -118,8 +118,6 @@ static int ModulesLoaded(WPARAM, LPARAM)
}
else flagsDllFolder = Utils_ReplaceVarsW(FLAGS_DLL_FOLDER);
- InitOptions();
-
GetAvaibleDictionaries(languages, dictionariesFolder, customDictionariesFolder);
LoadOptions();
@@ -231,6 +229,9 @@ int CMPlugin::Load()
// hooks
HookEvent(ME_SYSTEM_MODULESLOADED, ModulesLoaded);
HookEvent(ME_SYSTEM_PRESHUTDOWN, PreShutdown);
+ HookEvent(ME_OPT_INITIALISE, InitOptionsCallback);
+
+ LoadOptions();
CreateServiceFunction(MS_SPELLCHECKER_ADD_RICHEDIT, AddContactTextBoxService);
CreateServiceFunction(MS_SPELLCHECKER_REMOVE_RICHEDIT, RemoveContactTextBoxService);