Added wxDllLoader::UnloadLibrary()

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@2949 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Karsten Ballüder 1999-07-03 19:34:48 +00:00
parent 329e86bfde
commit 752c7d6bbd
2 changed files with 10 additions and 0 deletions

View File

@ -76,6 +76,8 @@ class wxDllLoader
@return A handle to the loaded DLL. Use success parameter to test if it is valid. @return A handle to the loaded DLL. Use success parameter to test if it is valid.
*/ */
static wxDllType LoadLibrary(const wxString & libname, bool *success); static wxDllType LoadLibrary(const wxString & libname, bool *success);
/** This function unloads the shared library. */
static void UnloadLibrary(wxDllType dll);
/** This function returns a valid handle for the main program /** This function returns a valid handle for the main program
itself. */ itself. */
static wxDllType GetProgramHandle(void); static wxDllType GetProgramHandle(void);

View File

@ -221,6 +221,14 @@ wxDllLoader::LoadLibrary(const wxString & lib_name, bool *success)
return handle; return handle;
} }
/* static */
void
wxDllLoader::UnloadLibrary(wxDllType handle)
{
wxDllClose(handle);
}
/* static */ /* static */
void * void *
wxDllLoader::GetSymbol(wxDllType dllHandle, const wxString &name) wxDllLoader::GetSymbol(wxDllType dllHandle, const wxString &name)