aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2001-12-29 01:52:53 +0000
committernyamatongwe <devnull@localhost>2001-12-29 01:52:53 +0000
commitc5a692dbf8fec7248fc3f384174c4899dd5aa036 (patch)
treeabb88911d166d6ff42ef607723c2fede40de5fa2
parentb506b7d33b1f8372f6c1cdaf9490dd7338354ef1 (diff)
downloadscintilla-mirror-c5a692dbf8fec7248fc3f384174c4899dd5aa036.tar.gz
Using HINSTANCE from Scintilla_RegisterClasses to find cursor so that
static builds within DLLs will work.
-rw-r--r--win32/PlatWin.cxx2
-rw-r--r--win32/ScintillaWin.cxx5
2 files changed, 5 insertions, 2 deletions
diff --git a/win32/PlatWin.cxx b/win32/PlatWin.cxx
index 9befd3f78..c6adbf327 100644
--- a/win32/PlatWin.cxx
+++ b/win32/PlatWin.cxx
@@ -716,7 +716,7 @@ void Window::SetFont(Font &font) {
reinterpret_cast<WPARAM>(font.GetID()), 0);
}
-static HINSTANCE hinstPlatformRes = 0;
+HINSTANCE hinstPlatformRes = 0;
void Window::SetCursor(Cursor curs) {
switch (curs) {
diff --git a/win32/ScintillaWin.cxx b/win32/ScintillaWin.cxx
index 37297e0bf..1293d0737 100644
--- a/win32/ScintillaWin.cxx
+++ b/win32/ScintillaWin.cxx
@@ -1879,9 +1879,12 @@ sptr_t PASCAL ScintillaWin::SWndProc(
}
}
+extern HINSTANCE hinstPlatformRes;
+
// This function is externally visible so it can be called from container when building statically
void Scintilla_RegisterClasses(void *hInstance) {
- ScintillaWin::Register(reinterpret_cast<HINSTANCE>(hInstance));
+ hinstPlatformRes = reinterpret_cast<HINSTANCE>(hInstance);
+ ScintillaWin::Register(hinstPlatformRes);
}
#ifndef STATIC_BUILD