]> git.saurik.com Git - wxWidgets.git/commitdiff
made wxDllLoader more backwards compatible
authorVadim Zeitlin <vadim@wxwidgets.org>
Mon, 22 Jul 2002 14:42:38 +0000 (14:42 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Mon, 22 Jul 2002 14:42:38 +0000 (14:42 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16252 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/dynload.h
src/common/dynload.cpp

index 4e5c5c09fcfac80ca415ba5f5cbaf184589389f8..8aaa926807d81a31332993fb4a900c550f766be6 100644 (file)
@@ -301,7 +301,7 @@ class WXDLLEXPORT wxDllLoader
 {
 public:
 
-    static wxDllType    LoadLibrary(const wxString& name);
+    static wxDllType    LoadLibrary(const wxString& name, bool *success = NULL);
     static void         UnloadLibrary(wxDllType dll);
 
     static wxDllType GetProgramHandle() { return wxDynamicLibrary::GetProgramHandle(); }
index f330d816656a8d467458040f35fbc43b6f3c218e..daf499db9890cd5ae7b990a8c4802bda7c05d55c 100644 (file)
@@ -657,7 +657,7 @@ void wxPluginManager::Unload()
 
 #if WXWIN_COMPATIBILITY_2_2
 
-wxDllType wxDllLoader::LoadLibrary(const wxString &name)
+wxDllType wxDllLoader::LoadLibrary(const wxString &name, bool *success)
 {
     wxPluginLibrary *p = wxPluginManager::LoadLibrary
                          (
@@ -665,6 +665,9 @@ wxDllType wxDllLoader::LoadLibrary(const wxString &name)
                             wxDL_DEFAULT | wxDL_VERBATIM | wxDL_NOSHARE
                          );
 
+    if ( success )
+        *success = p != NULL;
+
     return p ? p->GetLibHandle() : 0;
 }