From 6315743251433667ed97cffca2369251cc94e4b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Branimir=20Karad=C5=BEi=C4=87?= Date: Wed, 17 Dec 2014 21:25:00 -0800 Subject: [PATCH] SDL: Added connect/disconnect gamepad events. --- examples/common/entry/entry_sdl.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/examples/common/entry/entry_sdl.cpp b/examples/common/entry/entry_sdl.cpp index 1464a298..b7f432b3 100644 --- a/examples/common/entry/entry_sdl.cpp +++ b/examples/common/entry/entry_sdl.cpp @@ -502,6 +502,7 @@ namespace entry if (isValid(handle) ) { m_gamepad[handle.idx].create(cev.which); + m_eventQueue.postGamepadEvent(defaultWindow, handle, true); } } break; @@ -520,6 +521,7 @@ namespace entry { m_gamepad[handle.idx].destroy(); m_gamepadAlloc.free(handle.idx); + m_eventQueue.postGamepadEvent(defaultWindow, handle, false); } } break;