Title: [181008] trunk/Source/WebCore
Revision
181008
Author
[email protected]
Date
2015-03-04 11:33:46 -0800 (Wed, 04 Mar 2015)

Log Message

<attachment> title text disappears when dragging
https://bugs.webkit.org/show_bug.cgi?id=142263
<rdar://problem/20035515>

Reviewed by Sam Weinig.

* rendering/RenderThemeMac.mm:
(WebCore::RenderThemeMac::paintAttachment):
We use NSColors with CoreText, which requires that Cocoa knows the current
CGContext out-of-band (through the NSGraphicsContext currentContext mechanism).
Otherwise, sometimes (especially when dragging), it will try to apply the
text foreground color to a null context, complain to the system log, and fail
to render the text.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (181007 => 181008)


--- trunk/Source/WebCore/ChangeLog	2015-03-04 19:27:39 UTC (rev 181007)
+++ trunk/Source/WebCore/ChangeLog	2015-03-04 19:33:46 UTC (rev 181008)
@@ -1,3 +1,19 @@
+2015-03-04  Timothy Horton  <[email protected]>
+
+        <attachment> title text disappears when dragging
+        https://bugs.webkit.org/show_bug.cgi?id=142263
+        <rdar://problem/20035515>
+
+        Reviewed by Sam Weinig.
+
+        * rendering/RenderThemeMac.mm:
+        (WebCore::RenderThemeMac::paintAttachment):
+        We use NSColors with CoreText, which requires that Cocoa knows the current
+        CGContext out-of-band (through the NSGraphicsContext currentContext mechanism).
+        Otherwise, sometimes (especially when dragging), it will try to apply the
+        text foreground color to a null context, complain to the system log, and fail
+        to render the text.
+
 2015-03-04  Jer Noble  <[email protected]>
 
         [Mac] YouTube playback at 1.5x speed has audible distortion

Modified: trunk/Source/WebCore/rendering/RenderThemeMac.mm (181007 => 181008)


--- trunk/Source/WebCore/rendering/RenderThemeMac.mm	2015-03-04 19:27:39 UTC (rev 181007)
+++ trunk/Source/WebCore/rendering/RenderThemeMac.mm	2015-03-04 19:33:46 UTC (rev 181008)
@@ -2459,7 +2459,7 @@
     AttachmentLayout layout(attachment);
 
     GraphicsContext& context = *paintInfo.context;
-
+    LocalCurrentGraphicsContext localContext(&context);
     GraphicsContextStateSaver saver(context);
 
     context.translate(toFloatSize(paintRect.location()));
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to