1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Settings: pass name to callbacks by reference

Spare some copies.
This commit is contained in:
est31 2015-07-09 08:23:08 +02:00
parent 4ece2b9e32
commit cb8978fb1d
4 changed files with 5 additions and 4 deletions

View file

@ -806,7 +806,7 @@ public:
m_fogEnabled = g_settings->getBool("enable_fog");
}
static void SettingsCallback(const std::string name, void *userdata)
static void SettingsCallback(const std::string &name, void *userdata)
{
reinterpret_cast<GameGlobalShaderConstantSetter*>(userdata)->onSettingsChange(name);
}