Pass object by reference

Found by cppcheck.
This commit is contained in:
Ignacio R. Morelle 2015-07-06 23:42:13 -03:00
parent 926ba98d46
commit aecdbab096

View file

@ -36,7 +36,7 @@ static const int text_width = 400;
struct tooltip
{
tooltip(const SDL_Rect& r, const std::string& msg, const std::string& act = "", bool use_markup = false, const surface fg = surface())
tooltip(const SDL_Rect& r, const std::string& msg, const std::string& act = "", bool use_markup = false, const surface& fg = surface())
: rect(r), message(msg), action(act), markup(use_markup), foreground(fg)
{}
SDL_Rect rect;