Title: [99890] trunk/Source/WebKit2
Revision
99890
Author
[email protected]
Date
2011-11-10 13:06:34 -0800 (Thu, 10 Nov 2011)

Log Message

The WKView layer hosting subview needs to be flipped
https://bugs.webkit.org/show_bug.cgi?id=72042

Reviewed by Darin Adler.

In order to match the Core Animation layer hierarchy, the layer hosting WKView
subview needs to be flipped.

* UIProcess/API/mac/WKView.mm:
(-[WKFlippedView isFlipped]):
Add a NSView subview whose sole purpose is to be flipped.

(-[WKView _enterAcceleratedCompositingMode:]):
Create a WKFlippedView instead of a regular NSView.

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (99889 => 99890)


--- trunk/Source/WebKit2/ChangeLog	2011-11-10 20:38:23 UTC (rev 99889)
+++ trunk/Source/WebKit2/ChangeLog	2011-11-10 21:06:34 UTC (rev 99890)
@@ -1,3 +1,20 @@
+2011-11-10  Anders Carlsson  <[email protected]>
+
+        The WKView layer hosting subview needs to be flipped
+        https://bugs.webkit.org/show_bug.cgi?id=72042
+
+        Reviewed by Darin Adler.
+
+        In order to match the Core Animation layer hierarchy, the layer hosting WKView
+        subview needs to be flipped.
+
+        * UIProcess/API/mac/WKView.mm:
+        (-[WKFlippedView isFlipped]):
+        Add a NSView subview whose sole purpose is to be flipped.
+
+        (-[WKView _enterAcceleratedCompositingMode:]):
+        Create a WKFlippedView instead of a regular NSView.
+
 2011-11-10  Balazs Kelemen  <[email protected]>
 
         [Qt] X11 plugins need to be reworked for Qt5

Modified: trunk/Source/WebKit2/UIProcess/API/mac/WKView.mm (99889 => 99890)


--- trunk/Source/WebKit2/UIProcess/API/mac/WKView.mm	2011-11-10 20:38:23 UTC (rev 99889)
+++ trunk/Source/WebKit2/UIProcess/API/mac/WKView.mm	2011-11-10 21:06:34 UTC (rev 99890)
@@ -200,6 +200,18 @@
 - (bool)didReceiveUnhandledCommand;
 @end
 
+@interface WKFlippedView : NSView
+@end
+
+@implementation WKFlippedView
+
+- (BOOL)isFlipped
+{
+    return YES;
+}
+
+@end
+
 @implementation WKView
 
 - (id)initWithFrame:(NSRect)frame processGroup:(WKProcessGroup *)processGroup browsingContextGroup:(WKBrowsingContextGroup *)browsingContextGroup
@@ -2338,7 +2350,7 @@
     ASSERT(!layerTreeContext.isEmpty());
 
     // Create an NSView that will host our layer tree.
-    _data->_layerHostingView.adoptNS([[NSView alloc] initWithFrame:[self bounds]]);
+    _data->_layerHostingView.adoptNS([[WKFlippedView alloc] initWithFrame:[self bounds]]);
     [_data->_layerHostingView.get() setAutoresizingMask:NSViewWidthSizable | NSViewHeightSizable];
 
     [CATransaction begin];
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to