diff options
author | 2015-10-20 21:34:36 +0200 | |
---|---|---|
committer | 2015-10-20 21:34:36 +0200 | |
commit | a7b8acbe3eebcf17367baa642375cfa47ae4ea85 (patch) | |
tree | 854b859d6176802c0278f4b00de3f7c774e02dda /3rdparty/bgfx/examples/common/entry/entry_sdl.cpp | |
parent | 4610935e796661874bb4ee7ec6536d9423aeb7be (diff) | |
parent | 74aae76c4e3e257f99d139c4febb5d86d1419e50 (diff) |
Merge pull request #6 from mamedev/master
Sync to base master
Diffstat (limited to '3rdparty/bgfx/examples/common/entry/entry_sdl.cpp')
-rw-r--r-- | 3rdparty/bgfx/examples/common/entry/entry_sdl.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/3rdparty/bgfx/examples/common/entry/entry_sdl.cpp b/3rdparty/bgfx/examples/common/entry/entry_sdl.cpp index 91bfef74865..a9faec69e47 100644 --- a/3rdparty/bgfx/examples/common/entry/entry_sdl.cpp +++ b/3rdparty/bgfx/examples/common/entry/entry_sdl.cpp @@ -13,7 +13,7 @@ #include <SDL2/SDL.h> #include <SDL2/SDL_syswm.h> -#include <bgfxplatform.h> +#include <bgfx/bgfxplatform.h> #include <stdio.h> #include <bx/thread.h> @@ -320,7 +320,7 @@ namespace entry initTranslateGamepadAxis(SDL_CONTROLLER_AXIS_TRIGGERRIGHT, GamepadAxis::RightZ); } - void run(int _argc, char** _argv) + int run(int _argc, char** _argv) { m_mte.m_argc = _argc; m_mte.m_argv = _argv; @@ -644,7 +644,7 @@ namespace entry Msg* msg = (Msg*)uev.data2; if (isValid(handle) ) { - SDL_SetWindowTitle(m_window[handle.idx], msg->m_title.c_str()); + SDL_SetWindowTitle(m_window[handle.idx], msg->m_title.c_str() ); } delete msg; } @@ -710,6 +710,8 @@ namespace entry SDL_DestroyWindow(m_window[0]); SDL_Quit(); + + return m_thread.getExitCode(); } WindowHandle findHandle(uint32_t _windowId) @@ -896,8 +898,7 @@ namespace entry int main(int _argc, char** _argv) { using namespace entry; - s_ctx.run(_argc, _argv); - return 0; + return s_ctx.run(_argc, _argv); } #endif // ENTRY_CONFIG_USE_SDL |