Title: [270034] branches/safari-611.1.6-branch/Source/WebCore
- Revision
- 270034
- Author
- [email protected]
- Date
- 2020-11-19 09:26:00 -0800 (Thu, 19 Nov 2020)
Log Message
Cherry-pick r270000. rdar://problem/71588990
REGRESSION (r269895): Google Maps expanded route options are missing background color
https://bugs.webkit.org/show_bug.cgi?id=219119
<rdar://problem/71510412>
Reviewed by Said Abou-Hallawa.
No new tests, yet. Test is pending.
* platform/graphics/cg/GraphicsContextCG.cpp:
(WebCore::GraphicsContext::drawPlatformImage):
r199071 removed the state save/restore around the CG implementation of
drawNativeImage, explicitly saving and restoring the few things it knew
that the implementation would change. However, it failed to save/restore
the composite operator.
This was mostly not a problem, because e.g. canvas always hands down the
global op. However, in r269895, I added code that passes in a /different/
compositing operator, and it gets stuck on the context.
Save and restore the composite operator and blend mode like we do for other properties.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@270000 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Modified Paths
Diff
Modified: branches/safari-611.1.6-branch/Source/WebCore/ChangeLog (270033 => 270034)
--- branches/safari-611.1.6-branch/Source/WebCore/ChangeLog 2020-11-19 17:23:47 UTC (rev 270033)
+++ branches/safari-611.1.6-branch/Source/WebCore/ChangeLog 2020-11-19 17:26:00 UTC (rev 270034)
@@ -1,3 +1,54 @@
+2020-11-19 Alan Coon <[email protected]>
+
+ Cherry-pick r270000. rdar://problem/71588990
+
+ REGRESSION (r269895): Google Maps expanded route options are missing background color
+ https://bugs.webkit.org/show_bug.cgi?id=219119
+ <rdar://problem/71510412>
+
+ Reviewed by Said Abou-Hallawa.
+
+ No new tests, yet. Test is pending.
+
+ * platform/graphics/cg/GraphicsContextCG.cpp:
+ (WebCore::GraphicsContext::drawPlatformImage):
+ r199071 removed the state save/restore around the CG implementation of
+ drawNativeImage, explicitly saving and restoring the few things it knew
+ that the implementation would change. However, it failed to save/restore
+ the composite operator.
+
+ This was mostly not a problem, because e.g. canvas always hands down the
+ global op. However, in r269895, I added code that passes in a /different/
+ compositing operator, and it gets stuck on the context.
+
+ Save and restore the composite operator and blend mode like we do for other properties.
+
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@270000 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2020-11-18 Tim Horton <[email protected]>
+
+ REGRESSION (r269895): Google Maps expanded route options are missing background color
+ https://bugs.webkit.org/show_bug.cgi?id=219119
+ <rdar://problem/71510412>
+
+ Reviewed by Said Abou-Hallawa.
+
+ No new tests, yet. Test is pending.
+
+ * platform/graphics/cg/GraphicsContextCG.cpp:
+ (WebCore::GraphicsContext::drawPlatformImage):
+ r199071 removed the state save/restore around the CG implementation of
+ drawNativeImage, explicitly saving and restoring the few things it knew
+ that the implementation would change. However, it failed to save/restore
+ the composite operator.
+
+ This was mostly not a problem, because e.g. canvas always hands down the
+ global op. However, in r269895, I added code that passes in a /different/
+ compositing operator, and it gets stuck on the context.
+
+ Save and restore the composite operator and blend mode like we do for other properties.
+
2020-11-18 Kocsen Chung <[email protected]>
Cherry-pick r269944. rdar://problem/71547824
Modified: branches/safari-611.1.6-branch/Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp (270033 => 270034)
--- branches/safari-611.1.6-branch/Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp 2020-11-19 17:23:47 UTC (rev 270033)
+++ branches/safari-611.1.6-branch/Source/WebCore/platform/graphics/cg/GraphicsContextCG.cpp 2020-11-19 17:26:00 UTC (rev 270034)
@@ -365,6 +365,8 @@
adjustedDestRect = roundToDevicePixels(adjustedDestRect);
#endif
+ auto oldCompositeOperator = compositeOperation();
+ auto oldBlendMode = blendModeOperation();
setPlatformCompositeOperation(options.compositeOperator(), options.blendMode());
// ImageOrientation expects the origin to be at (0, 0)
@@ -392,6 +394,7 @@
#if PLATFORM(IOS_FAMILY)
CGContextSetShouldAntialias(context, wasAntialiased);
#endif
+ setPlatformCompositeOperation(oldCompositeOperator, oldBlendMode);
}
LOG_WITH_STREAM(Images, stream << "GraphicsContext::drawNativeImage " << image.get() << " size " << imageSize << " into " << destRect << " took " << (MonotonicTime::now() - startTime).milliseconds() << "ms");
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes