Exemplo n.º 1
0
//
// Change call propagation behaviour (overrides CClientEntity::SetCallPropagationEnabled)
void CClientGUIElement::SetCallPropagationEnabled ( bool bEnabled )
{
    CClientEntity::SetCallPropagationEnabled ( bEnabled );

    for ( CFastList<CClientEntity*>::iterator iter = m_Children.begin (); iter != m_Children.end (); ++iter )
    {
        if ( (*iter)->GetType () == CCLIENTGUI )
        {
            CClientGUIElement* pGUIElement = static_cast < CClientGUIElement* > ( *iter );
            pGUIElement->GetCGUIElement()->SetInheritsAlpha ( bEnabled );
        }
    }
}
Exemplo n.º 2
0
void CClientGUIManager::FlushQueuedUpdates()
{
    map<ElementID, bool>::iterator iter = m_QueuedGridListUpdates.begin();
    for (; iter != m_QueuedGridListUpdates.end(); ++iter)
    {
        CClientEntity* pEntity = CElementIDs::GetElement(iter->first);
        if (pEntity && !pEntity->IsBeingDeleted() && pEntity->GetType() == CCLIENTGUI)
        {
            CClientGUIElement* pGUIElement = static_cast<CClientGUIElement*>(pEntity);
            if (pGUIElement && IS_CGUIELEMENT_GRIDLIST(pGUIElement))
            {
                CGUIGridList* pGUIGridList = static_cast<CGUIGridList*>(pGUIElement->GetCGUIElement());
                pGUIGridList->ForceUpdate();
            }
        }
    }
    m_QueuedGridListUpdates.clear();
}