made wxDllLoader more backwards compatible
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16252 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
f44b23b6f7
commit
3d7fa4e684
@ -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(); }
|
||||
|
@ -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;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user