From 03dea17fe7b2be066ca8ab3451b92bb1b9fa73ae Mon Sep 17 00:00:00 2001 From: nyamatongwe Date: Tue, 12 Feb 2002 23:32:48 +0000 Subject: Moved external lexer loading from initialisation of ScintillaWin object to Scintilla_RegisterClasses to avoid possibility of thread contention. --- win32/ScintillaWin.cxx | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'win32') 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)); +#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. -- cgit v1.2.3