From: mfranz Date: Fri, 14 Apr 2006 10:17:09 +0000 (+0000) Subject: allow to not only set a general widget , but also specific element X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=fe7869062366663e7710ef1621fc24d9d6d8179d;p=flightgear.git allow to not only set a general widget , but also specific element colors: , for example, sets the input field cursor color, the input field text color. (This feature was always planned as part of the 'theming' capabilities, and most code is already in place. Only this line was apparently fogotten. :-) --- diff --git a/src/GUI/dialog.cxx b/src/GUI/dialog.cxx index 30c300403..b248fc936 100644 --- a/src/GUI/dialog.cxx +++ b/src/GUI/dialog.cxx @@ -841,6 +841,8 @@ FGDialog::setColor(puObject * object, SGPropertyNode * props, int which) if ((pucol[i].mask == LABEL) && !c->isValid()) dirty |= c->merge(_gui->getColor("label")); + dirty |= c->merge(props->getNode(pucol[i].cname)); + if (c->isValid() && dirty) object->setColor(pucol[i].id, c->red(), c->green(), c->blue(), c->alpha()); }