本文整理汇总了C++中PaintLayer::nextSibling方法的典型用法代码示例。如果您正苦于以下问题:C++ PaintLayer::nextSibling方法的具体用法?C++ PaintLayer::nextSibling怎么用?C++ PaintLayer::nextSibling使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PaintLayer
的用法示例。
在下文中一共展示了PaintLayer::nextSibling方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: updateDescendantDependentFlagsForEntireSubtree
// The descendant-dependent flags system is badly broken because we clean dirty
// bits in upward tree walks, which means we need to call updateDescendantDependentFlags
// at every node in the tree to fully clean all the dirty bits. While we'll in
// the process of fixing this issue, updateDescendantDependentFlagsForEntireSubtree
// provides a big hammer for actually cleaning all the dirty bits in a subtree.
//
// FIXME: Remove this function once the descendant-dependent flags system keeps
// its dirty bits scoped to subtrees.
void updateDescendantDependentFlagsForEntireSubtree(PaintLayer& layer)
{
layer.updateDescendantDependentFlags();
for (PaintLayer* child = layer.firstChild(); child; child = child->nextSibling())
updateDescendantDependentFlagsForEntireSubtree(*child);
}
示例2: buildLayerIdToNodeIdMap
void InspectorLayerTreeAgent::buildLayerIdToNodeIdMap(
PaintLayer* root,
LayerIdToNodeIdMap& layerIdToNodeIdMap) {
if (root->hasCompositedLayerMapping()) {
if (Node* node = root->layoutObject()->generatingNode()) {
GraphicsLayer* graphicsLayer =
root->compositedLayerMapping()->childForSuperlayers();
layerIdToNodeIdMap.set(graphicsLayer->platformLayer()->id(),
idForNode(node));
}
}
for (PaintLayer* child = root->firstChild(); child;
child = child->nextSibling())
buildLayerIdToNodeIdMap(child, layerIdToNodeIdMap);
if (!root->layoutObject()->isLayoutIFrame())
return;
FrameView* childFrameView =
toFrameView(toLayoutPart(root->layoutObject())->widget());
LayoutViewItem childLayoutViewItem = childFrameView->layoutViewItem();
if (!childLayoutViewItem.isNull()) {
if (PaintLayerCompositor* childCompositor =
childLayoutViewItem.compositor())
buildLayerIdToNodeIdMap(childCompositor->rootLayer(), layerIdToNodeIdMap);
}
}
示例3: clearClipRectsIncludingDescendants
void PaintLayerClipper::clearClipRectsIncludingDescendants()
{
m_cache = nullptr;
for (PaintLayer* layer = m_layoutObject.layer()->firstChild(); layer; layer = layer->nextSibling()) {
layer->clipper().clearClipRectsIncludingDescendants();
}
}
示例4: clearClipRectsIncludingDescendants
void PaintLayerClipper::clearClipRectsIncludingDescendants() {
if (m_geometryMapper)
m_geometryMapper.reset(new GeometryMapper);
m_layer.clearClipRectsCache();
for (PaintLayer* layer = m_layer.firstChild(); layer;
layer = layer->nextSibling()) {
layer->clipper().clearClipRectsIncludingDescendants();
}
}
示例5: fullyInvalidatePaintRecursive
static void fullyInvalidatePaintRecursive(PaintLayer* layer)
{
if (layer->compositingState() == PaintsIntoOwnBacking) {
layer->compositedLayerMapping()->setContentsNeedDisplay();
layer->compositedLayerMapping()->setSquashingContentsNeedDisplay();
}
for (PaintLayer* child = layer->firstChild(); child; child = child->nextSibling())
fullyInvalidatePaintRecursive(child);
}
示例6: rebuildZOrderLists
void PaintLayerStackingNode::rebuildZOrderLists() {
#if DCHECK_IS_ON()
DCHECK(m_layerListMutationAllowed);
#endif
DCHECK(isDirtyStackingContext());
for (PaintLayer* child = layer()->firstChild(); child;
child = child->nextSibling())
child->stackingNode()->collectLayers(m_posZOrderList, m_negZOrderList);
// Sort the two lists.
if (m_posZOrderList)
std::stable_sort(m_posZOrderList->begin(), m_posZOrderList->end(),
compareZIndex);
if (m_negZOrderList)
std::stable_sort(m_negZOrderList->begin(), m_negZOrderList->end(),
compareZIndex);
// Append layers for top layer elements after normal layer collection, to
// ensure they are on top regardless of z-indexes. The layoutObjects of top
// layer elements are children of the view, sorted in top layer stacking
// order.
if (layer()->isRootLayer()) {
LayoutBlockFlow* rootBlock = layoutObject()->view();
// If the viewport is paginated, everything (including "top-layer" elements)
// gets redirected to the flow thread. So that's where we have to look, in
// that case.
if (LayoutBlockFlow* multiColumnFlowThread =
rootBlock->multiColumnFlowThread())
rootBlock = multiColumnFlowThread;
for (LayoutObject* child = rootBlock->firstChild(); child;
child = child->nextSibling()) {
Element* childElement = (child->node() && child->node()->isElementNode())
? toElement(child->node())
: 0;
if (childElement && childElement->isInTopLayer()) {
PaintLayer* layer = toLayoutBoxModelObject(child)->layer();
// Create the buffer if it doesn't exist yet.
if (!m_posZOrderList)
m_posZOrderList = wrapUnique(new Vector<PaintLayerStackingNode*>);
m_posZOrderList->append(layer->stackingNode());
}
}
}
#if ENABLE(ASSERT)
updateStackingParentForZOrderLists(this);
#endif
m_zOrderListsDirty = false;
}
示例7: paintLayers
static void paintLayers(PaintLayer& layer, SimDisplayItemList& displayList)
{
if (layer.isAllowedToQueryCompositingState() && layer.compositingState() == PaintsIntoOwnBacking) {
CompositedLayerMapping* mapping = layer.compositedLayerMapping();
GraphicsLayer* graphicsLayer = mapping->mainGraphicsLayer();
if (graphicsLayer->hasTrackedPaintInvalidations()) {
ContentLayerDelegate* delegate = graphicsLayer->contentLayerDelegateForTesting();
delegate->paintContents(&displayList, WebRect(0, 0, layer.size().width(), layer.size().height()));
graphicsLayer->resetTrackedPaintInvalidations();
}
}
for (PaintLayer* child = layer.firstChild(); child; child = child->nextSibling())
paintLayers(*child, displayList);
}
示例8: collectLayers
void PaintLayerStackingNode::collectLayers(
std::unique_ptr<Vector<PaintLayerStackingNode*>>& posBuffer,
std::unique_ptr<Vector<PaintLayerStackingNode*>>& negBuffer) {
if (layer()->isInTopLayer())
return;
if (isStacked()) {
std::unique_ptr<Vector<PaintLayerStackingNode*>>& buffer =
(zIndex() >= 0) ? posBuffer : negBuffer;
if (!buffer)
buffer = wrapUnique(new Vector<PaintLayerStackingNode*>);
buffer->append(this);
}
if (!isStackingContext()) {
for (PaintLayer* child = layer()->firstChild(); child;
child = child->nextSibling())
child->stackingNode()->collectLayers(posBuffer, negBuffer);
}
}