Title: [198723] trunk/Source/WebKit2
Revision
198723
Author
[email protected]
Date
2016-03-26 19:13:01 -0700 (Sat, 26 Mar 2016)

Log Message

Tried to fix the build.

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _takeViewSnapshot]):

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (198722 => 198723)


--- trunk/Source/WebKit2/ChangeLog	2016-03-27 01:05:12 UTC (rev 198722)
+++ trunk/Source/WebKit2/ChangeLog	2016-03-27 02:13:01 UTC (rev 198723)
@@ -1,3 +1,10 @@
+2016-03-26  Dan Bernstein  <[email protected]>
+
+        Tried to fix the build.
+
+        * UIProcess/API/Cocoa/WKWebView.mm:
+        (-[WKWebView _takeViewSnapshot]):
+
 2016-03-26  Dean Jackson  <[email protected]>
 
         Fix build after my most recent commit.

Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm (198722 => 198723)


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm	2016-03-27 01:05:12 UTC (rev 198722)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm	2016-03-27 02:13:01 UTC (rev 198723)
@@ -85,6 +85,7 @@
 #import <WebCore/IOSurface.h>
 #import <WebCore/JSDOMBinding.h>
 #import <WebCore/NSTextFinderSPI.h>
+#import <WebCore/PlatformScreen.h>
 #import <WebCore/RuntimeApplicationChecks.h>
 #import <wtf/HashMap.h>
 #import <wtf/MathExtras.h>
@@ -1321,7 +1322,7 @@
     CATransform3D transform = CATransform3DMakeScale(deviceScale, deviceScale, 1);
 
 #if USE(IOSURFACE)
-    WebCore::IOSurface::Format snapshotFormat = WebKit::bufferFormat(true /* is opaque */);
+    WebCore::IOSurface::Format snapshotFormat = screenSupportsExtendedColor() ? WebCore::IOSurface::Format::RGB10 : WebCore::IOSurface::Format::RGBA;
     auto surface = WebCore::IOSurface::create(WebCore::expandedIntSize(snapshotSize), WebCore::ColorSpaceSRGB, snapshotFormat);
     CARenderServerRenderLayerWithTransform(MACH_PORT_NULL, self.layer.context.contextId, reinterpret_cast<uint64_t>(self.layer), surface->surface(), 0, 0, &transform);
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to