Changeset 252962 in webkit
- Timestamp:
- Nov 30, 2019 5:06:49 PM (4 years ago)
- Location:
- trunk/Source
- Files:
-
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r252961 r252962 1 2019-11-30 Tim Horton <timothy_horton@apple.com> 2 3 Reimplement some PlatformCALayer methods using GraphicsContext instead of CGContextRef 4 https://bugs.webkit.org/show_bug.cgi?id=204698 5 6 Reviewed by Sam Weinig. 7 8 In order to make PlatformCALayer-level DisplayList recording possible, 9 reimplement a few methods in terms of WebCore::GraphicsContext instead 10 of CGContextRef directly. Namely, collectRectsToPaint, drawLayerContents, 11 and drawRepaintIndicator. 12 13 In the drawLayerContents case, there are operations (like setting the 14 AppKit global graphics context) that cannot be done without a platform 15 context. In those cases, we skip that operation if we don't have a 16 platform context. 17 18 Anything depending on this downstream will break and need to be 19 implemented a different way in the DisplayList case. 20 21 * platform/graphics/GraphicsContext.h: 22 * platform/graphics/ca/PlatformCALayer.cpp: 23 (WebCore::PlatformCALayer::drawRepaintIndicator): 24 * platform/graphics/ca/PlatformCALayer.h: 25 * platform/graphics/ca/TileGrid.cpp: 26 (WebCore::TileGrid::platformCALayerPaintContents): 27 * platform/graphics/ca/cocoa/PlatformCALayerCocoa.h: 28 * platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm: 29 (WebCore::PlatformCALayer::collectRectsToPaint): 30 (WebCore::PlatformCALayer::drawLayerContents): 31 (WebCore::PlatformCALayerCocoa::enumerateRectsBeingDrawn): 32 * platform/graphics/ca/win/PlatformCALayerWin.cpp: 33 (PlatformCALayer::collectRectsToPaint): 34 * platform/graphics/mac/WebLayer.mm: 35 (-[WebLayer drawInContext:]): 36 1 37 2019-11-30 youenn fablet <youenn@apple.com> 2 38 -
trunk/Source/WebCore/platform/graphics/GraphicsContext.h
r251796 r252962 479 479 480 480 enum IncludeDeviceScale { DefinitelyIncludeDeviceScale, PossiblyIncludeDeviceScale }; 481 AffineTransform getCTM(IncludeDeviceScale includeScale = PossiblyIncludeDeviceScale) const;481 WEBCORE_EXPORT AffineTransform getCTM(IncludeDeviceScale includeScale = PossiblyIncludeDeviceScale) const; 482 482 483 483 // This function applies the device scale factor to the context, making the context capable of -
trunk/Source/WebCore/platform/graphics/ca/PlatformCALayer.cpp
r251123 r252962 80 80 } 81 81 82 void PlatformCALayer::drawRepaintIndicator(CGContextRef context, PlatformCALayer* platformCALayer, int repaintCount, CGColorRef customBackgroundColor) 83 { 84 char text[16]; // that's a lot of repaints 85 snprintf(text, sizeof(text), "%d", repaintCount); 86 87 FloatRect indicatorBox = platformCALayer->bounds();\ 88 indicatorBox.setLocation( { 1, 1 } ); 89 indicatorBox.setSize(FloatSize(12 + 10 * strlen(text), 27)); 90 91 CGContextStateSaver stateSaver(context); 92 93 CGContextSetAlpha(context, 0.5f); 94 CGContextBeginTransparencyLayerWithRect(context, indicatorBox, 0); 95 96 if (customBackgroundColor) 97 CGContextSetFillColorWithColor(context, customBackgroundColor); 98 else 99 CGContextSetRGBFillColor(context, 0, 0.5f, 0.25f, 1); 100 82 void PlatformCALayer::drawRepaintIndicator(GraphicsContext& graphicsContext, PlatformCALayer* platformCALayer, int repaintCount, Color customBackgroundColor) 83 { 84 const float verticalMargin = 2.5; 85 const float horizontalMargin = 5; 86 const unsigned fontSize = 22; 87 const Color backgroundColor(0.5f, 0.25f, 1.0f, 1.0f); 88 const Color acceleratedContextLabelColor(1.0f, 0.f, 0.f, 1.0f); 89 const Color unacceleratedContextLabelColor(1.0f, 1.0f, 1.0f, 1.0f); 90 const Color linearGlyphMaskOutlineColor(0.f, 0.f, 0.f, 0.75f); 91 const Color displayListBorderColor(0.f, 0.f, 0.f, 0.65f); 92 93 TextRun textRun(String::number(repaintCount)); 94 95 FontCascadeDescription fontDescription; 96 fontDescription.setOneFamily("Helvetica"); 97 fontDescription.setSpecifiedSize(fontSize); 98 fontDescription.setComputedSize(fontSize); 99 100 FontCascade cascade(WTFMove(fontDescription)); 101 cascade.update(nullptr); 102 103 float textWidth = cascade.width(textRun); 104 105 GraphicsContextStateSaver stateSaver(graphicsContext); 106 107 graphicsContext.beginTransparencyLayer(0.5f); 108 109 graphicsContext.setFillColor(customBackgroundColor.isValid() ? customBackgroundColor : backgroundColor); 110 FloatRect indicatorBox(1, 1, horizontalMargin * 2 + textWidth, verticalMargin * 2 + fontSize); 101 111 if (platformCALayer->isOpaque()) 102 CGContextFillRect(context,indicatorBox);112 graphicsContext.fillRect(indicatorBox); 103 113 else { 104 114 Path boundsPath; … … 112 122 boundsPath.closeSubpath(); 113 123 114 CGContextAddPath(context, boundsPath.platformPath()); 115 CGContextFillPath(context); 124 graphicsContext.fillPath(boundsPath); 116 125 } 117 126 118 127 if (platformCALayer->owner()->isUsingDisplayListDrawing(platformCALayer)) { 119 CGContextSetRGBStrokeColor(context, 0, 0, 0, 0.65); 120 CGContextSetLineWidth(context, 2); 121 CGContextStrokeRect(context, indicatorBox); 122 } 123 124 CGFloat strokeWidthAsPercentageOfFontSize = 0; 125 Color strokeColor; 128 graphicsContext.setStrokeColor(displayListBorderColor); 129 graphicsContext.strokeRect(indicatorBox, 2); 130 } 126 131 127 132 if (!platformCALayer->isOpaque() && platformCALayer->supportsSubpixelAntialiasedText() && platformCALayer->acceleratesDrawing()) { 128 strokeColor = Color(0, 0, 0, 200); 129 strokeWidthAsPercentageOfFontSize = -4.5; // Negative means "stroke and fill"; see docs for kCTStrokeWidthAttributeName. 130 } 131 132 if (platformCALayer->acceleratesDrawing()) 133 CGContextSetRGBFillColor(context, 1, 0, 0, 1); 134 else 135 CGContextSetRGBFillColor(context, 1, 1, 1, 1); 136 137 platformCALayer->drawTextAtPoint(context, indicatorBox.x() + 5, indicatorBox.y() + 22, CGSizeMake(1, -1), 22, text, strlen(text), strokeWidthAsPercentageOfFontSize, strokeColor); 138 139 CGContextEndTransparencyLayer(context); 133 graphicsContext.setStrokeColor(linearGlyphMaskOutlineColor); 134 graphicsContext.setStrokeThickness(4.5); 135 graphicsContext.setTextDrawingMode(TextModeFill | TextModeStroke); 136 } 137 138 graphicsContext.setFillColor(platformCALayer->acceleratesDrawing() ? acceleratedContextLabelColor : unacceleratedContextLabelColor); 139 140 graphicsContext.drawText(cascade, textRun, FloatPoint(indicatorBox.x() + horizontalMargin, indicatorBox.y() + fontSize)); 141 graphicsContext.endTransparencyLayer(); 140 142 } 141 143 -
trunk/Source/WebCore/platform/graphics/ca/PlatformCALayer.h
r251123 r252962 269 269 270 270 #if PLATFORM(COCOA) 271 virtual void enumerateRectsBeingDrawn( CGContextRef, void (^block)(CGRect)) = 0;271 virtual void enumerateRectsBeingDrawn(GraphicsContext&, void (^block)(FloatRect)) = 0; 272 272 #endif 273 273 … … 282 282 283 283 // Functions allows us to share implementation across WebTiledLayer and WebLayer 284 static RepaintRectList collectRectsToPaint( CGContextRef, PlatformCALayer*);285 static void drawLayerContents( CGContextRef, PlatformCALayer*, RepaintRectList& dirtyRects, GraphicsLayerPaintBehavior);286 static void drawRepaintIndicator( CGContextRef, PlatformCALayer*, int repaintCount, CGColorRef customBackgroundColor);284 static RepaintRectList collectRectsToPaint(GraphicsContext&, PlatformCALayer*); 285 static void drawLayerContents(GraphicsContext&, PlatformCALayer*, RepaintRectList&, GraphicsLayerPaintBehavior); 286 static void drawRepaintIndicator(GraphicsContext&, PlatformCALayer*, int repaintCount, Color customBackgroundColor = { }); 287 287 static CGRect frameForLayer(const PlatformLayer*); 288 288 -
trunk/Source/WebCore/platform/graphics/ca/TileGrid.cpp
r248514 r252962 730 730 context.scale(m_scale); 731 731 732 PlatformCALayer::RepaintRectList dirtyRects = PlatformCALayer::collectRectsToPaint(context .platformContext(), platformCALayer);733 PlatformCALayer::drawLayerContents(context .platformContext(), &m_controller.rootLayer(), dirtyRects, layerPaintBehavior);732 PlatformCALayer::RepaintRectList dirtyRects = PlatformCALayer::collectRectsToPaint(context, platformCALayer); 733 PlatformCALayer::drawLayerContents(context, &m_controller.rootLayer(), dirtyRects, layerPaintBehavior); 734 734 } 735 735 736 736 int repaintCount = platformCALayerIncrementRepaintCount(platformCALayer); 737 737 if (m_controller.rootLayer().owner()->platformCALayerShowRepaintCounter(0)) 738 PlatformCALayer::drawRepaintIndicator(context .platformContext(), platformCALayer, repaintCount, cachedCGColor(m_controller.tileDebugBorderColor()));738 PlatformCALayer::drawRepaintIndicator(context, platformCALayer, repaintCount, m_controller.tileDebugBorderColor()); 739 739 740 740 if (m_controller.scrollingPerformanceLoggingEnabled()) { -
trunk/Source/WebCore/platform/graphics/ca/cocoa/PlatformCALayerCocoa.h
r252346 r252962 179 179 Ref<PlatformCALayer> createCompatibleLayer(PlatformCALayer::LayerType, PlatformCALayerClient*) const override; 180 180 181 void enumerateRectsBeingDrawn( CGContextRef, void (^block)(CGRect)) override;181 void enumerateRectsBeingDrawn(GraphicsContext&, void (^block)(FloatRect)) override; 182 182 183 183 unsigned backingStoreBytesPerPixel() const override; -
trunk/Source/WebCore/platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm
r252346 r252962 1120 1120 #endif // PLATFORM(IOS_FAMILY) 1121 1121 1122 PlatformCALayer::RepaintRectList PlatformCALayer::collectRectsToPaint( CGContextRefcontext, PlatformCALayer* platformCALayer)1122 PlatformCALayer::RepaintRectList PlatformCALayer::collectRectsToPaint(GraphicsContext& context, PlatformCALayer* platformCALayer) 1123 1123 { 1124 1124 __block double totalRectArea = 0; … … 1126 1126 __block RepaintRectList dirtyRects; 1127 1127 1128 platformCALayer->enumerateRectsBeingDrawn(context, ^( CGRect rect) {1128 platformCALayer->enumerateRectsBeingDrawn(context, ^(FloatRect rect) { 1129 1129 if (++rectCount > webLayerMaxRectsToPaint) 1130 1130 return; 1131 1131 1132 totalRectArea += rect. size.width * rect.size.height;1132 totalRectArea += rect.area(); 1133 1133 dirtyRects.append(rect); 1134 1134 }); 1135 1135 1136 FloatRect clipBounds = CGContextGetClipBoundingBox(context);1136 FloatRect clipBounds = context.clipBounds(); 1137 1137 double clipArea = clipBounds.width() * clipBounds.height(); 1138 1138 … … 1145 1145 } 1146 1146 1147 void PlatformCALayer::drawLayerContents( CGContextRef context, WebCore::PlatformCALayer* platformCALayer, RepaintRectList& dirtyRects, GraphicsLayerPaintBehavior layerPaintBehavior)1147 void PlatformCALayer::drawLayerContents(GraphicsContext& graphicsContext, WebCore::PlatformCALayer* platformCALayer, RepaintRectList& dirtyRects, GraphicsLayerPaintBehavior layerPaintBehavior) 1148 1148 { 1149 1149 WebCore::PlatformCALayerClient* layerContents = platformCALayer->owner(); … … 1154 1154 layerPaintBehavior |= GraphicsLayerPaintFirstTilePaint; 1155 1155 1156 #if PLATFORM(IOS_FAMILY) 1157 WKSetCurrentGraphicsContext(context); 1158 #endif 1159 1160 CGContextSaveGState(context); 1161 1156 GraphicsContextStateSaver saver(graphicsContext); 1157 1162 1158 // We never use CompositingCoordinatesOrientation::BottomUp on Mac. 1163 1159 ASSERT(layerContents->platformCALayerContentsOrientation() == GraphicsLayer::CompositingCoordinatesOrientation::TopDown); 1164 1160 1165 1161 #if PLATFORM(IOS_FAMILY) 1166 FontAntialiasingStateSaver fontAntialiasingState(context, [platformCALayer->platformLayer() isOpaque]); 1167 fontAntialiasingState.setup([WAKWindow hasLandscapeOrientation]); 1162 WTF::Optional<FontAntialiasingStateSaver> fontAntialiasingState; 1163 #endif 1164 if (graphicsContext.hasPlatformContext()) { 1165 CGContextRef context = graphicsContext.platformContext(); 1166 #if PLATFORM(IOS_FAMILY) 1167 WKSetCurrentGraphicsContext(context); 1168 1169 fontAntialiasingState = FontAntialiasingStateSaver { context, [platformCALayer->platformLayer() isOpaque] }; 1170 fontAntialiasingState->setup([WAKWindow hasLandscapeOrientation]); 1168 1171 #else 1169 [NSGraphicsContext saveGraphicsState]; 1170 1171 // Set up an NSGraphicsContext for the context, so that parts of AppKit that rely on 1172 // the current NSGraphicsContext (e.g. NSCell drawing) get the right one. 1173 ALLOW_DEPRECATED_DECLARATIONS_BEGIN 1174 NSGraphicsContext* layerContext = [NSGraphicsContext graphicsContextWithGraphicsPort:context flipped:YES]; 1175 ALLOW_DEPRECATED_DECLARATIONS_END 1176 [NSGraphicsContext setCurrentContext:layerContext]; 1177 #endif 1172 [NSGraphicsContext saveGraphicsState]; 1173 1174 // Set up an NSGraphicsContext for the context, so that parts of AppKit that rely on 1175 // the current NSGraphicsContext (e.g. NSCell drawing) get the right one. 1176 ALLOW_DEPRECATED_DECLARATIONS_BEGIN 1177 NSGraphicsContext* layerContext = [NSGraphicsContext graphicsContextWithGraphicsPort:context flipped:YES]; 1178 ALLOW_DEPRECATED_DECLARATIONS_END 1179 [NSGraphicsContext setCurrentContext:layerContext]; 1180 #endif 1181 } 1178 1182 1179 1183 { 1180 GraphicsContext graphicsContext(context);1181 1184 graphicsContext.setIsCALayerContext(true); 1182 1185 graphicsContext.setIsAcceleratedContext(platformCALayer->acceleratesDrawing()); 1183 1186 1184 1187 if (!layerContents->platformCALayerContentsOpaque() && !platformCALayer->supportsSubpixelAntialiasedText() && FontCascade::isSubpixelAntialiasingAvailable()) { 1185 1188 // Turn off font smoothing to improve the appearance of text rendered onto a transparent background. 1186 1189 graphicsContext.setShouldSmoothFonts(false); 1187 1190 } 1188 1191 1189 1192 #if PLATFORM(MAC) 1190 1193 // It's important to get the clip from the context, because it may be significantly 1191 1194 // smaller than the layer bounds (e.g. tiled layers) 1192 ThemeMac::setFocusRingClipRect( CGContextGetClipBoundingBox(context));1193 #endif 1194 1195 ThemeMac::setFocusRingClipRect(graphicsContext.clipBounds()); 1196 #endif 1197 1195 1198 for (const auto& rect : dirtyRects) { 1196 1199 GraphicsContextStateSaver stateSaver(graphicsContext); 1197 1200 graphicsContext.clip(rect); 1198 1201 1199 1202 layerContents->platformCALayerPaintContents(platformCALayer, graphicsContext, rect, layerPaintBehavior); 1200 1203 } 1201 1204 1202 1205 #if PLATFORM(IOS_FAMILY) 1203 fontAntialiasingState.restore(); 1206 if (fontAntialiasingState) 1207 fontAntialiasingState->restore(); 1204 1208 #else 1205 1209 ThemeMac::setFocusRingClipRect(FloatRect()); 1206 1210 1207 1211 [NSGraphicsContext restoreGraphicsState]; 1208 1212 #endif 1209 1213 } 1210 1214 1211 CGContextRestoreGState(context);1215 saver.restore(); 1212 1216 1213 1217 // Re-fetch the layer owner, since <rdar://problem/9125151> indicates that it might have been destroyed during painting. … … 1220 1224 1221 1225 if (!platformCALayer->usesTiledBackingLayer() && layerContents && layerContents->platformCALayerShowRepaintCounter(platformCALayer)) 1222 drawRepaintIndicator( context, platformCALayer, repaintCount, nullptr);1226 drawRepaintIndicator(graphicsContext, platformCALayer, repaintCount); 1223 1227 } 1224 1228 … … 1233 1237 } 1234 1238 1235 void PlatformCALayerCocoa::enumerateRectsBeingDrawn( CGContextRef context, void (^block)(CGRect))1239 void PlatformCALayerCocoa::enumerateRectsBeingDrawn(GraphicsContext& context, void (^block)(FloatRect)) 1236 1240 { 1237 1241 CGSRegionObj region = (CGSRegionObj)[m_layer regionBeingDrawn]; 1238 1242 if (!region) { 1239 block( CGContextGetClipBoundingBox(context));1243 block(context.clipBounds()); 1240 1244 return; 1241 1245 } 1242 1246 1243 CGAffineTransform inverseTransform = CGAffineTransformInvert( CGContextGetCTM(context));1247 CGAffineTransform inverseTransform = CGAffineTransformInvert(context.getCTM()); 1244 1248 CGSRegionEnumeratorObj enumerator = CGSRegionEnumerator(region); 1245 1249 const CGRect* nextRect; -
trunk/Source/WebCore/platform/graphics/ca/win/PlatformCALayerWin.cpp
r248846 r252962 102 102 } 103 103 104 PlatformCALayer::RepaintRectList PlatformCALayer::collectRectsToPaint( CGContextRef, PlatformCALayer*)104 PlatformCALayer::RepaintRectList PlatformCALayer::collectRectsToPaint(GraphicsContext&, PlatformCALayer*) 105 105 { 106 106 // FIXME: We should actually collect rects to use instead of defaulting to Windows' … … 110 110 } 111 111 112 void PlatformCALayer::drawLayerContents( CGContextRefcontext, WebCore::PlatformCALayer* platformCALayer, RepaintRectList&, GraphicsLayerPaintBehavior)113 { 114 intern(platformCALayer)->displayCallback(platformCALayer->platformLayer(), context );112 void PlatformCALayer::drawLayerContents(GraphicsContext& context, WebCore::PlatformCALayer* platformCALayer, RepaintRectList&, GraphicsLayerPaintBehavior) 113 { 114 intern(platformCALayer)->displayCallback(platformCALayer->platformLayer(), context.platformContext()); 115 115 } 116 116 -
trunk/Source/WebCore/platform/graphics/ca/win/PlatformCALayerWinInternal.cpp
r234393 r252962 130 130 backgroundColor = cachedCGColor(Color(255, 0, 0)); 131 131 132 PlatformCALayer::drawRepaintIndicator(context, owner(), drawCount, backgroundColor); 132 GraphicsContext graphicsContext(context); 133 PlatformCALayer::drawRepaintIndicator(graphicsContext, owner(), drawCount, backgroundColor); 133 134 } 134 135 -
trunk/Source/WebCore/platform/graphics/mac/WebLayer.mm
r238410 r252962 52 52 WebCore::PlatformCALayer* layer = WebCore::PlatformCALayer::platformCALayer((__bridge void*)self); 53 53 if (layer) { 54 WebCore::PlatformCALayer::RepaintRectList rectsToPaint = WebCore::PlatformCALayer::collectRectsToPaint(context, layer); 55 WebCore::PlatformCALayer::drawLayerContents(context, layer, rectsToPaint, self.isRenderingInContext ? WebCore::GraphicsLayerPaintSnapshotting : WebCore::GraphicsLayerPaintNormal); 54 WebCore::GraphicsContext graphicsContext(context); 55 WebCore::PlatformCALayer::RepaintRectList rectsToPaint = WebCore::PlatformCALayer::collectRectsToPaint(graphicsContext, layer); 56 WebCore::PlatformCALayer::drawLayerContents(graphicsContext, layer, rectsToPaint, self.isRenderingInContext ? WebCore::GraphicsLayerPaintSnapshotting : WebCore::GraphicsLayerPaintNormal); 56 57 } 57 58 } -
trunk/Source/WebKit/ChangeLog
r252945 r252962 1 2019-11-30 Tim Horton <timothy_horton@apple.com> 2 3 Reimplement some PlatformCALayer methods using GraphicsContext instead of CGContextRef 4 https://bugs.webkit.org/show_bug.cgi?id=204698 5 6 Reviewed by Sam Weinig. 7 8 * Shared/RemoteLayerTree/RemoteLayerBackingStore.h: 9 * Shared/RemoteLayerTree/RemoteLayerBackingStore.mm: 10 (WebKit::RemoteLayerBackingStore::drawInContext): 11 (WebKit::RemoteLayerBackingStore::enumerateRectsBeingDrawn): 12 * WebProcess/WebPage/RemoteLayerTree/PlatformCALayerRemote.cpp: 13 (WebKit::PlatformCALayerRemote::enumerateRectsBeingDrawn): 14 * WebProcess/WebPage/RemoteLayerTree/PlatformCALayerRemote.h: 15 1 16 2019-11-27 Antoine Quint <graouts@apple.com> 2 17 -
trunk/Source/WebKit/Shared/RemoteLayerTree/RemoteLayerBackingStore.h
r233479 r252962 72 72 static bool decode(IPC::Decoder&, RemoteLayerBackingStore&); 73 73 74 void enumerateRectsBeingDrawn( CGContextRef, void (^)(CGRect));74 void enumerateRectsBeingDrawn(WebCore::GraphicsContext&, void (^)(WebCore::FloatRect)); 75 75 76 76 bool hasFrontBuffer() const -
trunk/Source/WebKit/Shared/RemoteLayerTree/RemoteLayerBackingStore.mm
r247921 r252962 354 354 case WebCore::PlatformCALayer::LayerTypeWebLayer: 355 355 case WebCore::PlatformCALayer::LayerTypeBackdropLayer: 356 WebCore::PlatformCALayer::drawLayerContents(c gContext, m_layer, m_paintingRects, flags);356 WebCore::PlatformCALayer::drawLayerContents(context, m_layer, m_paintingRects, flags); 357 357 break; 358 358 case WebCore::PlatformCALayer::LayerTypeDarkSystemBackdropLayer: … … 360 360 // FIXME: These have a more complicated layer hierarchy. We need to paint into 361 361 // a child layer in order to see the rendered results. 362 WebCore::PlatformCALayer::drawLayerContents(c gContext, m_layer, m_paintingRects, flags);362 WebCore::PlatformCALayer::drawLayerContents(context, m_layer, m_paintingRects, flags); 363 363 break; 364 364 case WebCore::PlatformCALayer::LayerTypeLayer: … … 383 383 } 384 384 385 void RemoteLayerBackingStore::enumerateRectsBeingDrawn( CGContextRef context, void (^block)(CGRect))386 { 387 CGAffineTransform inverseTransform = CGAffineTransformInvert( CGContextGetCTM(context));385 void RemoteLayerBackingStore::enumerateRectsBeingDrawn(WebCore::GraphicsContext& context, void (^block)(WebCore::FloatRect)) 386 { 387 CGAffineTransform inverseTransform = CGAffineTransformInvert(context.getCTM()); 388 388 389 389 // We don't want to un-apply the flipping or contentsScale, -
trunk/Source/WebKit/WebProcess/WebPage/RemoteLayerTree/PlatformCALayerRemote.cpp
r248846 r252962 892 892 } 893 893 894 void PlatformCALayerRemote::enumerateRectsBeingDrawn( CGContextRef context, void (^block)(CGRect))894 void PlatformCALayerRemote::enumerateRectsBeingDrawn(WebCore::GraphicsContext& context, void (^block)(WebCore::FloatRect)) 895 895 { 896 896 m_properties.backingStore->enumerateRectsBeingDrawn(context, block); -
trunk/Source/WebKit/WebProcess/WebPage/RemoteLayerTree/PlatformCALayerRemote.h
r243962 r252962 185 185 Ref<PlatformCALayer> createCompatibleLayer(WebCore::PlatformCALayer::LayerType, WebCore::PlatformCALayerClient*) const override; 186 186 187 void enumerateRectsBeingDrawn( CGContextRef, void (^block)(CGRect)) override;187 void enumerateRectsBeingDrawn(WebCore::GraphicsContext&, void (^block)(WebCore::FloatRect)) override; 188 188 189 189 virtual uint32_t hostingContextID();
Note: See TracChangeset
for help on using the changeset viewer.