void RenderRegion::attachRegion() { if (documentBeingDestroyed()) return; // A region starts off invalid. setIsValid(false); // Initialize the flow thread reference and create the flow thread object if needed. // The flow thread lifetime is influenced by the number of regions attached to it, // and we are attaching the region to the flow thread. installFlowThread(); if (!m_flowThread) return; // Only after adding the region to the thread, the region is marked to be valid. m_flowThread->addRegionToThread(this); // The region just got attached to the flow thread, lets check whether // it has region styling rules associated. checkRegionStyle(); if (!isValid()) return; m_hasAutoLogicalHeight = shouldHaveAutoLogicalHeight(); if (hasAutoLogicalHeight()) incrementAutoLogicalHeightCount(); }
void RenderNamedFlowFragment::updateRegionHasAutoLogicalHeightFlag() { ASSERT(isValid()); bool didHaveAutoLogicalHeight = m_hasAutoLogicalHeight; m_hasAutoLogicalHeight = shouldHaveAutoLogicalHeight(); if (didHaveAutoLogicalHeight == m_hasAutoLogicalHeight) return; if (m_hasAutoLogicalHeight) incrementAutoLogicalHeightCount(); else { clearComputedAutoHeight(); decrementAutoLogicalHeightCount(); } }
void RenderRegion::updateRegionHasAutoLogicalHeightFlag() { ASSERT(m_flowThread); if (!isValid()) return; bool didHaveAutoLogicalHeight = m_hasAutoLogicalHeight; m_hasAutoLogicalHeight = shouldHaveAutoLogicalHeight(); if (m_hasAutoLogicalHeight != didHaveAutoLogicalHeight) { if (m_hasAutoLogicalHeight) incrementAutoLogicalHeightCount(); else { clearOverrideLogicalContentHeight(); decrementAutoLogicalHeightCount(); } } }
void RenderNamedFlowFragment::attachRegion() { RenderRegion::attachRegion(); if (documentBeingDestroyed() || !m_flowThread) return; // The region just got attached to the flow thread, lets check whether // it has region styling rules associated. checkRegionStyle(); if (!isValid()) return; m_hasAutoLogicalHeight = shouldHaveAutoLogicalHeight(); if (hasAutoLogicalHeight()) incrementAutoLogicalHeightCount(); }