@@ -29,23 +29,13 @@
|
||||
|
||||
void *SDL_LoadObject(const char *sofile)
|
||||
{
|
||||
void *handle;
|
||||
LPWSTR wstr;
|
||||
|
||||
if (!sofile) {
|
||||
SDL_InvalidParamError("sofile");
|
||||
return NULL;
|
||||
}
|
||||
wstr = WIN_UTF8ToStringW(sofile);
|
||||
#ifdef SDL_PLATFORM_WINRT
|
||||
/* WinRT only publicly supports LoadPackagedLibrary() for loading .dll
|
||||
files. LoadLibrary() is a private API, and not available for apps
|
||||
(that can be published to MS' Windows Store.)
|
||||
*/
|
||||
handle = (void *)LoadPackagedLibrary(wstr, 0);
|
||||
#else
|
||||
handle = (void *)LoadLibrary(wstr);
|
||||
#endif
|
||||
|
||||
LPWSTR wstr = WIN_UTF8ToStringW(sofile);
|
||||
void *handle = (void *)LoadLibrary(wstr);
|
||||
SDL_free(wstr);
|
||||
|
||||
// Generate an error message if all loads failed
|
||||
|
||||
Reference in New Issue
Block a user