Explorar el Código

clear OsEventBuffer at the end of frame()

mikymod hace 12 años
padre
commit
ae28e93aa2
Se han modificado 1 ficheros con 7 adiciones y 1 borrados
  1. 7 1
      engine/Device.cpp

+ 7 - 1
engine/Device.cpp

@@ -54,6 +54,7 @@ OTHER DEALINGS IN THE SOFTWARE.
 #include "Bundle.h"
 #include "TempAllocator.h"
 #include "ResourcePackage.h"
+#include "OsEventBuffer.h"
 
 #if defined(LINUX) || defined(WINDOWS)
 	#include "BundleCompiler.h"
@@ -172,7 +173,10 @@ bool Device::init(int argc, char** argv)
 	#endif
 
 	g_main_thread.start();
-	// g_main_thread.join();
+
+	#ifndef ANDROID
+	g_main_thread.join();
+	#endif
 
 	return true;
 }
@@ -524,6 +528,8 @@ void Device::frame()
 	}
 
 	m_frame_count++;
+
+	os_event_buffer()->clear();
 }
 
 //-----------------------------------------------------------------------------