SerialInterface and pads: Allow MAXPADS lower than 4

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1923 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
John Peterson 2009-01-19 03:45:28 +00:00
parent 5708e14a0e
commit d60fea1d99
8 changed files with 136 additions and 98 deletions

View file

@ -27,7 +27,7 @@ and stopped.
//////////////////////////////////////////////////////////////////////////////////////////
// Includes
//
// -----------
#include <string.h>
#ifdef _WIN32
#include <windows.h>
@ -79,11 +79,14 @@ std::string GetLastErrorAsString()
#endif
}
// Loading means loading the dll with LoadLibrary() to get an instance to the dll.
// This is done when Dolphin is started to determine which dlls are good, and
// before opening the Config and Debugging windows from Plugin.cpp and
// before opening the dll for running the emulation in Video_...cpp in Core.
// Since this is fairly slow, TODO: think about implementing some sort of cache.
//////////////////////////////////////////////////////////////////////////////////////////
// Includes
// -----------
/* Function: Loading means loading the dll with LoadLibrary() to get an instance to the dll.
This is done when Dolphin is started to determine which dlls are good, and before opening
the Config and Debugging windows from Plugin.cpp and before opening the dll for running
the emulation in Video_...cpp in Core. Since this is fairly slow, TODO: think about
implementing some sort of cache. */
int DynamicLibrary::Load(const char* filename)
{
if (!filename || strlen(filename) == 0)
@ -147,11 +150,12 @@ void* DynamicLibrary::Get(const char* funcname) const
PanicAlert("Can't find function %s - Library not loaded.");
return NULL;
}
#ifdef _WIN32
retval = GetProcAddress(library, funcname);
#else
retval = dlsym(library, funcname);
#endif
#ifdef _WIN32
retval = GetProcAddress(library, funcname);
#else
retval = dlsym(library, funcname);
#endif
if (!retval)
{