示例#1
0
void DebugPageOverlays::hideRegionOverlay(MainFrame& frame, RegionType regionType)
{
    auto it = m_frameRegionOverlays.find(&frame);
    if (it != m_frameRegionOverlays.end()) {
        auto& visualizers = it->value;
        if (RegionOverlay* visualizer = visualizers[indexOf(regionType)].get()) {
            frame.pageOverlayController().uninstallPageOverlay(&visualizer->overlay(), PageOverlay::FadeMode::DoNotFade);
            visualizers[indexOf(regionType)] = nullptr;
        }
    }
}
示例#2
0
String MockPageOverlayClient::layerTreeAsText(MainFrame& mainFrame)
{
    return "View-relative:\n" + mainFrame.pageOverlayController().viewOverlayRootLayer().layerTreeAsText(LayerTreeAsTextIncludePageOverlayLayers) + "\n\nDocument-relative:\n" + mainFrame.pageOverlayController().documentOverlayRootLayer().layerTreeAsText(LayerTreeAsTextIncludePageOverlayLayers);
}
示例#3
0
void DebugPageOverlays::showRegionOverlay(MainFrame& frame, RegionType regionType)
{
    RegionOverlay& visualizer = ensureRegionOverlayForFrame(frame, regionType);
    frame.pageOverlayController().installPageOverlay(&visualizer.overlay(), PageOverlay::FadeMode::DoNotFade);
}
示例#4
0
void MockPageOverlayClient::installOverlay(MainFrame& mainFrame, PageOverlay::OverlayType overlayType)
{
    RefPtr<PageOverlay> overlay = PageOverlay::create(*this, overlayType);
    mainFrame.pageOverlayController().installPageOverlay(overlay, PageOverlay::FadeMode::DoNotFade);
    m_overlays.add(overlay.get());
}