diff options
| author | nakeee <nakeee@gmail.com> | 2009-01-07 22:07:51 +0000 |
|---|---|---|
| committer | nakeee <nakeee@gmail.com> | 2009-01-07 22:07:51 +0000 |
| commit | 3a9eeeb1442c60ec5b15a8c35a156effa76768c4 (patch) | |
| tree | 74f7d6d09d044e0d1dbd3674d00eb6ab174e00cc /Source/Core/Common/Src/Plugin.cpp | |
| parent | c4993bf036a3ced1181b7ecb34564413c7c18a3e (diff) | |
addded the setdllglobals function to the specs
(no failure maybe warning on symbols
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1825 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core/Common/Src/Plugin.cpp')
| -rw-r--r-- | Source/Core/Common/Src/Plugin.cpp | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/Source/Core/Common/Src/Plugin.cpp b/Source/Core/Common/Src/Plugin.cpp index fb6c67e78e..4a77d9c11c 100644 --- a/Source/Core/Common/Src/Plugin.cpp +++ b/Source/Core/Common/Src/Plugin.cpp @@ -31,9 +31,10 @@ namespace Common { DynamicLibrary CPlugin::m_hInstLib; -void(__cdecl * CPlugin::m_GetDllInfo) (PLUGIN_INFO * _PluginInfo) = 0; -void(__cdecl * CPlugin::m_DllConfig) (HWND _hParent) = 0; -void(__cdecl * CPlugin::m_DllDebugger) (HWND _hParent, bool Show) = 0; +void(__cdecl * CPlugin::m_GetDllInfo) (PLUGIN_INFO * _PluginInfo) = 0; +void(__cdecl * CPlugin::m_DllConfig) (HWND _hParent) = 0; +void(__cdecl * CPlugin::m_DllDebugger) (HWND _hParent, bool Show) = 0; +void(__cdecl * CPlugin::m_SetDllGlobals) (PLUGIN_GLOBALS* _PluginGlobals) = 0; void CPlugin::Release(void) @@ -41,7 +42,8 @@ CPlugin::Release(void) m_GetDllInfo = 0; m_DllConfig = 0; m_DllDebugger = 0; - + m_SetDllGlobals = 0; + m_hInstLib.Unload(); } @@ -53,6 +55,7 @@ CPlugin::Load(const char* _szName) m_GetDllInfo = (void (__cdecl*)(PLUGIN_INFO*)) m_hInstLib.Get("GetDllInfo"); m_DllConfig = (void (__cdecl*)(HWND)) m_hInstLib.Get("DllConfig"); m_DllDebugger = (void (__cdecl*)(HWND, bool)) m_hInstLib.Get("DllDebugger"); + m_SetDllGlobals = (void (__cdecl*)(PLUGIN_GLOBALS*)) m_hInstLib.Get("SetDllGlobals"); return(true); } @@ -87,4 +90,13 @@ void CPlugin::Debug(HWND _hwnd, bool Show) m_DllDebugger(_hwnd, Show); } } + +void CPlugin::SetGlobals(PLUGIN_GLOBALS& _pluginGlobals) +{ + if (m_SetDllGlobals != 0) + { + m_SetDllGlobals(&_pluginGlobals); + } +} + } // end of namespace Common |
