diff --git a/src/gui/lua/lua_cc_picture.cpp b/src/gui/lua/lua_cc_picture.cpp index 23d4c6bfc..f8de9070c 100644 --- a/src/gui/lua/lua_cc_picture.cpp +++ b/src/gui/lua/lua_cc_picture.cpp @@ -108,9 +108,9 @@ int CLuaInstCCPicture::CCPictureNew(lua_State *L) tableLookup(L, "color_shadow", color_shadow); tableLookup(L, "transparency", transparency); - checkMagicMask(color_frame); - checkMagicMask(color_background); - checkMagicMask(color_shadow); + color_frame = checkMagicMask(color_frame); + color_background = checkMagicMask(color_background); + color_shadow = checkMagicMask(color_shadow); CComponentsForm* pw = (parent && parent->w) ? parent->w->getBodyObject() : NULL; diff --git a/src/gui/lua/lua_cc_text.cpp b/src/gui/lua/lua_cc_text.cpp index af488a8be..4af40c59a 100644 --- a/src/gui/lua/lua_cc_text.cpp +++ b/src/gui/lua/lua_cc_text.cpp @@ -111,10 +111,10 @@ int CLuaInstCCText::CCTextNew(lua_State *L) tableLookup(L, "color_body", color_body); tableLookup(L, "color_shadow", color_shadow); - checkMagicMask(color_text); - checkMagicMask(color_frame); - checkMagicMask(color_body); - checkMagicMask(color_shadow); + color_text = checkMagicMask(color_text); + color_frame = checkMagicMask(color_frame); + color_body = checkMagicMask(color_body); + color_shadow = checkMagicMask(color_shadow); if (!tmpMode.empty()) { table_key txt_align[] = { diff --git a/src/gui/lua/lua_cc_window.cpp b/src/gui/lua/lua_cc_window.cpp index 467a9baeb..76c753bdb 100644 --- a/src/gui/lua/lua_cc_window.cpp +++ b/src/gui/lua/lua_cc_window.cpp @@ -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); } diff --git a/src/gui/lua/luainstance.cpp b/src/gui/lua/luainstance.cpp index fe3359c45..f02cea774 100644 --- a/src/gui/lua/luainstance.cpp +++ b/src/gui/lua/luainstance.cpp @@ -768,7 +768,7 @@ int CLuaInstance::PaintBox(lua_State *L) w = W->fbwin->dx - x; if (h < 0 || y + h > W->fbwin->dy) h = W->fbwin->dy - y; - checkMagicMask(c); + c = checkMagicMask(c); W->fbwin->paintBoxRel(x, y, w, h, c, radius, corner); return 0; } @@ -791,7 +791,7 @@ int CLuaInstance::paintHLineRel(lua_State *L) y = 0; if (dx < 0 || x + dx > W->fbwin->dx) dx = W->fbwin->dx - x; - checkMagicMask(c); + c = checkMagicMask(c); W->fbwin->paintHLineRel(x, dx, y, c); return 0; } @@ -814,7 +814,7 @@ int CLuaInstance::paintVLineRel(lua_State *L) y = 0; if (dy < 0 || y + dy > W->fbwin->dy) dy = W->fbwin->dy - y; - checkMagicMask(c); + c = checkMagicMask(c); W->fbwin->paintVLineRel(x, y, dy, c); return 0; } @@ -885,7 +885,7 @@ int CLuaInstance::RenderString(lua_State *L) if (rwidth < w) x += (w - rwidth) / 2; } - checkMagicMask(c); + c = checkMagicMask(c); if (boxh > -1) /* if boxh < 0, don't paint string */ W->fbwin->RenderString(font, x, y, w, text, c, boxh); lua_pushinteger(L, rwidth); /* return renderwidth */