mirror of
https://github.com/yawut/SDL.git
synced 2026-04-11 11:35:57 -05:00
WinRT: pseudo-implemented SDLmain for WinRT. It has to be compiled directly into apps, for now.
This commit is contained in:
parent
390acc322a
commit
2995bb36ae
14
src/main/windowsrt/SDL_winrt_main.cpp
Normal file
14
src/main/windowsrt/SDL_winrt_main.cpp
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
|
||||
//#include "pch.h"
|
||||
|
||||
// The app's C-style main will be passed into SDL.dll as a function
|
||||
// pointer, and called at the appropriate time.
|
||||
typedef int (*SDLmain_MainFunction)(int, char **);
|
||||
extern __declspec(dllimport) int SDL_WinRT_RunApplication(SDLmain_MainFunction mainFunction);
|
||||
extern "C" int SDL_main(int, char **);
|
||||
|
||||
[Platform::MTAThread]
|
||||
int main(Platform::Array<Platform::String^>^)
|
||||
{
|
||||
return SDL_WinRT_RunApplication(SDL_main);
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user