mirror of
https://github.com/encounter/SDL.git
synced 2025-12-10 05:57:44 +00:00
WinRT: renamed SDL_winrt_main.cpp to indicate that it should only be used in non-XAML apps
This can break builds of existing SDL/WinRT apps. To fix, remove the reference to SDL_winrt_main.cpp, then add a reference to the renamed file, SDL_winrt_main_NonXAML.cpp. If you get a build error about a missing .winmd file, enable the /ZW compiler flag for that one file (at minimum).
This commit is contained in:
@@ -24,7 +24,7 @@ extern "C" int SDL_main(int, char **);
|
||||
#pragma comment(lib, "runtimeobject.lib")
|
||||
#endif
|
||||
|
||||
int CALLBACK WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
|
||||
int CALLBACK WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
|
||||
{
|
||||
if (FAILED(Windows::Foundation::Initialize(RO_INIT_MULTITHREADED))) {
|
||||
return 1;
|
||||
@@ -33,3 +33,4 @@ int CALLBACK WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
|
||||
SDL_WinRT_RunApplication(SDL_main);
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user