aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2002-02-12 23:32:48 +0000
committernyamatongwe <devnull@localhost>2002-02-12 23:32:48 +0000
commit2b6a1d2f499826155dd023c54e5321f51f1356a0 (patch)
treee190904e92e3341e900c07ac2b306106579921f4
parent3d4ba4da35eb10950081d1079d1cb028a41b595b (diff)
downloadscintilla-mirror-2b6a1d2f499826155dd023c54e5321f51f1356a0.tar.gz
Moved external lexer loading from initialisation of ScintillaWin object
to Scintilla_RegisterClasses to avoid possibility of thread contention.
-rw-r--r--win32/ScintillaWin.cxx9
1 files changed, 4 insertions, 5 deletions
diff --git a/win32/ScintillaWin.cxx b/win32/ScintillaWin.cxx
index ddcab290b..dfb81e894 100644
--- a/win32/ScintillaWin.cxx
+++ b/win32/ScintillaWin.cxx
@@ -273,11 +273,6 @@ void ScintillaWin::Initialise() {
// no effect. If the app hasnt, we really shouldnt ask them to call
// it just so this internal feature works.
::OleInitialize(NULL);
-
-#ifdef SCI_LEXER
- LexerManager *lexMan = LexerManager::GetInstance();
- lexMan->Load();
-#endif
}
void ScintillaWin::Finalise() {
@@ -1924,6 +1919,10 @@ extern void Platform_Finalise();
void Scintilla_RegisterClasses(void *hInstance) {
Platform_Initialise(hInstance);
ScintillaWin::Register(reinterpret_cast<HINSTANCE>(hInstance));
+#ifdef SCI_LEXER
+ LexerManager *lexMan = LexerManager::GetInstance();
+ lexMan->Load();
+#endif
}
// This function is externally visible so it can be called from container when building statically.