mirror of
https://github.com/love2d/love.git
synced 2026-08-16 00:02:12 +02:00
Misc. fixes
This commit is contained in:
@@ -31,9 +31,6 @@
|
||||
#if defined(__APPLE__)
|
||||
# define LOVE_MACOSX 1
|
||||
#endif
|
||||
#if defined(macintosh)
|
||||
# define LOVE_MACOS 1
|
||||
#endif
|
||||
|
||||
// Endianness.
|
||||
#if defined(__i386__) || defined(__i386)
|
||||
|
||||
@@ -130,7 +130,7 @@ std::string luax_checkstring(lua_State *L, int idx)
|
||||
return std::string(str, len);
|
||||
}
|
||||
|
||||
void luax_pushstring(lua_State *L, std::string str)
|
||||
void luax_pushstring(lua_State *L, const std::string &str)
|
||||
{
|
||||
lua_pushlstring(L, str.data(), str.size());
|
||||
}
|
||||
@@ -466,11 +466,15 @@ StringMap<Type, TYPE_MAX_ENUM>::Entry typeEntries[] =
|
||||
{"ParticleSystem", GRAPHICS_PARTICLE_SYSTEM_ID},
|
||||
{"SpriteBatch", GRAPHICS_SPRITE_BATCH_ID},
|
||||
{"Canvas", GRAPHICS_CANVAS_ID},
|
||||
{"Shader", GRAPHICS_SHADER_ID},
|
||||
|
||||
// Image
|
||||
{"ImageData", IMAGE_IMAGE_DATA_ID},
|
||||
{"CompressedData", IMAGE_COMPRESSED_DATA_ID},
|
||||
|
||||
// Math
|
||||
{"RandomGenerator", MATH_RANDOM_GENERATOR_ID},
|
||||
|
||||
// Audio
|
||||
{"Source", AUDIO_SOURCE_ID},
|
||||
|
||||
|
||||
@@ -156,7 +156,7 @@ std::string luax_checkstring(lua_State *L, int idx);
|
||||
* @param L The Lua state.
|
||||
* @param str The string to push.
|
||||
**/
|
||||
void luax_pushstring(lua_State *L, std::string str);
|
||||
void luax_pushstring(lua_State *L, const std::string &str);
|
||||
|
||||
/**
|
||||
* Require at least 'min' number of items on the stack.
|
||||
|
||||
Reference in New Issue
Block a user