Преглед на файлове

Fix all warnings (errors) in the engine folder

Daniele Bartolini преди 12 години
родител
ревизия
70dd1849fa
променени са 5 файла, в които са добавени 7 реда и са изтрити 8 реда
  1. 2 2
      engine/lua/DeviceBinds.cpp
  2. 2 2
      engine/lua/LuaEnvironment.cpp
  3. 1 1
      engine/lua/LuaStack.cpp
  4. 1 1
      engine/lua/LuaStack.h
  5. 1 2
      engine/os/linux/OsWindow.cpp

+ 2 - 2
engine/lua/DeviceBinds.cpp

@@ -56,7 +56,7 @@ CE_EXPORT int32_t device_last_delta_time(lua_State* L)
 }
 }
 
 
 //-----------------------------------------------------------------------------
 //-----------------------------------------------------------------------------
-CE_EXPORT int32_t device_start(lua_State* L)
+CE_EXPORT int32_t device_start(lua_State* /*L*/)
 {
 {
 	device()->start();
 	device()->start();
 
 
@@ -64,7 +64,7 @@ CE_EXPORT int32_t device_start(lua_State* L)
 }
 }
 
 
 //-----------------------------------------------------------------------------
 //-----------------------------------------------------------------------------
-CE_EXPORT int32_t device_stop(lua_State* L)
+CE_EXPORT int32_t device_stop(lua_State* /*L*/)
 {
 {
 	device()->stop();
 	device()->stop();
 
 

+ 2 - 2
engine/lua/LuaEnvironment.cpp

@@ -219,14 +219,14 @@ void LuaEnvironment::load_module_function(const char* module, const char* name,
 }
 }
 
 
 //-----------------------------------------------------------
 //-----------------------------------------------------------
-void LuaEnvironment::load_module_enum(const char* module, const char* name, uint32_t value)
+void LuaEnvironment::load_module_enum(const char* /*module*/, const char* name, uint32_t value)
 {
 {
 	lua_pushinteger(m_state, value);
 	lua_pushinteger(m_state, value);
 	lua_setfield(m_state, -2, name);
 	lua_setfield(m_state, -2, name);
 }
 }
 
 
 //-----------------------------------------------------------------------------
 //-----------------------------------------------------------------------------
-CE_EXPORT int32_t luaopen_libcrown(lua_State* L)
+CE_EXPORT int32_t luaopen_libcrown(lua_State* /*L*/)
 {
 {
 	LuaEnvironment* env = device()->lua_environment();
 	LuaEnvironment* env = device()->lua_environment();
 
 

+ 1 - 1
engine/lua/LuaStack.cpp

@@ -137,7 +137,7 @@ void LuaStack::push_string(const char* str, size_t len)
 }
 }
 
 
 //-----------------------------------------------------------------------------
 //-----------------------------------------------------------------------------
-void LuaStack::push_lightdata(void* data, size_t len)
+void LuaStack::push_lightdata(void* data)
 {
 {
 	lua_pushlightuserdata(m_state, data);
 	lua_pushlightuserdata(m_state, data);
 }
 }

+ 1 - 1
engine/lua/LuaStack.h

@@ -65,7 +65,7 @@ public:
 
 
 	void 					push_string(const char* str, size_t len);
 	void 					push_string(const char* str, size_t len);
 
 
-	void					push_lightdata(void* data, size_t len);
+	void					push_lightdata(void* data);
 
 
 	void					push_vec2(Vec2* v);
 	void					push_vec2(Vec2* v);
 
 

+ 1 - 2
engine/os/linux/OsWindow.cpp

@@ -320,10 +320,9 @@ void OsWindow::frame()
 			case KeyRelease:
 			case KeyRelease:
 			{
 			{
 				char string[4] = {0, 0, 0, 0};
 				char string[4] = {0, 0, 0, 0};
-				int32_t len = -1;
 				KeySym key;
 				KeySym key;
 
 
-				len = XLookupString(&event.xkey, string, 4, &key, NULL);
+				XLookupString(&event.xkey, string, 4, &key, NULL);
 
 
 				Key kc = x11_translate_key(key);
 				Key kc = x11_translate_key(key);