CLuaInstance: Fix commit e85f64d733

- Use return value from checkMagicMask() for color
This commit is contained in:
M. Liebmann
2016-01-01 14:41:53 +01:00
parent 6801bf215e
commit a7790ce049
4 changed files with 17 additions and 17 deletions

View File

@@ -104,9 +104,9 @@ int CLuaInstCCWindow::CCWindowNew(lua_State *L)
tableLookup(L, "btnYellow", btnYellow);
tableLookup(L, "btnBlue", btnBlue);
checkMagicMask(color_frame);
checkMagicMask(color_body);
checkMagicMask(color_shadow);
color_frame = checkMagicMask(color_frame);
color_body = checkMagicMask(color_body);
color_shadow = checkMagicMask(color_shadow);
bool show_header = true;
if (!tableLookup(L, "show_header", show_header)) {
@@ -227,15 +227,15 @@ int CLuaInstCCWindow::CCWindowSetWindowColor(lua_State *L)
lua_Unsigned color;
if (tableLookup(L, "color_frame" , color)) {
checkMagicMask(color);
color = checkMagicMask(color);
D->w->setColorFrame(color);
}
if (tableLookup(L, "color_body" , color)) {
checkMagicMask(color);
color = checkMagicMask(color);
D->w->setColorBody(color);
}
if (tableLookup(L, "color_shadow" , color)) {
checkMagicMask(color);
color = checkMagicMask(color);
D->w->setColorShadow(color);
}