Exemple #1
0
void UIWidget::setCascadeColorEnabled(bool cascadeColorEnabled)
{
    RGBAProtocol* rgbap = DYNAMIC_CAST_RGBAProtocol;
    if (rgbap)
    {
        rgbap->setCascadeColorEnabled(cascadeColorEnabled);
    }
}
Exemple #2
0
bool UIWidget::init()
{
    m_children = CCArray::create();
    m_children->retain();
    initRenderer();
    m_pRenderer->retain();
    m_pRenderer->setZOrder(m_nWidgetZOrder);
    RGBAProtocol* renderRGBA = DYNAMIC_CAST_RGBAProtocol;
    if (renderRGBA)
    {
        renderRGBA->setCascadeColorEnabled(true);
        renderRGBA->setCascadeOpacityEnabled(true);
    }
    setBright(true);
    ignoreContentAdaptWithSize(true);
    return true;
}