Title: [197937] releases/WebKitGTK/webkit-2.10/Source/WebKit2
Revision
197937
Author
[email protected]
Date
2016-03-10 08:24:14 -0800 (Thu, 10 Mar 2016)

Log Message

Merge r197927 - [GTK] Artifacts when using web view background color
https://bugs.webkit.org/show_bug.cgi?id=155229

Reviewed by Mario Sanchez Prada.

This is because when using a web view color, we fill with the
color every rectangle updated by the web process, but we should
always fill the entire backing store before rendering the actual
contents on top.

* WebProcess/WebPage/DrawingAreaImpl.cpp:
(WebKit::DrawingAreaImpl::display): Ensure the web process always
renders the whole visible rectangle when background is rendered by
the UI process.

Modified Paths

Diff

Modified: releases/WebKitGTK/webkit-2.10/Source/WebKit2/ChangeLog (197936 => 197937)


--- releases/WebKitGTK/webkit-2.10/Source/WebKit2/ChangeLog	2016-03-10 16:22:51 UTC (rev 197936)
+++ releases/WebKitGTK/webkit-2.10/Source/WebKit2/ChangeLog	2016-03-10 16:24:14 UTC (rev 197937)
@@ -1,3 +1,20 @@
+2016-03-09  Carlos Garcia Campos  <[email protected]>
+
+        [GTK] Artifacts when using web view background color
+        https://bugs.webkit.org/show_bug.cgi?id=155229
+
+        Reviewed by Mario Sanchez Prada.
+
+        This is because when using a web view color, we fill with the
+        color every rectangle updated by the web process, but we should
+        always fill the entire backing store before rendering the actual
+        contents on top.
+
+        * WebProcess/WebPage/DrawingAreaImpl.cpp:
+        (WebKit::DrawingAreaImpl::display): Ensure the web process always
+        renders the whole visible rectangle when background is rendered by
+        the UI process.
+
 2016-03-07  Carlos Garcia Campos  <[email protected]>
 
         REGRESSION(r197062): [GTK] Transparent backgrounds no longer work after r197062

Modified: releases/WebKitGTK/webkit-2.10/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.cpp (197936 => 197937)


--- releases/WebKitGTK/webkit-2.10/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.cpp	2016-03-10 16:22:51 UTC (rev 197936)
+++ releases/WebKitGTK/webkit-2.10/Source/WebKit2/WebProcess/WebPage/DrawingAreaImpl.cpp	2016-03-10 16:24:14 UTC (rev 197937)
@@ -634,7 +634,8 @@
     updateInfo.viewSize = m_webPage.size();
     updateInfo.deviceScaleFactor = m_webPage.corePage()->deviceScaleFactor();
 
-    IntRect bounds = m_dirtyRegion.bounds();
+    // Always render the whole page when we don't render the background.
+    IntRect bounds = m_webPage.drawsBackground() ? m_dirtyRegion.bounds() : m_webPage.bounds();
     ASSERT(m_webPage.bounds().contains(bounds));
 
     IntSize bitmapSize = bounds.size();
@@ -647,12 +648,16 @@
     if (!bitmap->createHandle(updateInfo.bitmapHandle))
         return;
 
-    Vector<IntRect> rects = m_dirtyRegion.rects();
+    Vector<IntRect> rects;
+    if (m_webPage.drawsBackground()) {
+        rects = m_dirtyRegion.rects();
 
-    if (shouldPaintBoundsRect(bounds, rects)) {
-        rects.clear();
+        if (shouldPaintBoundsRect(bounds, rects)) {
+            rects.clear();
+            rects.append(bounds);
+        }
+    } else
         rects.append(bounds);
-    }
 
     updateInfo.scrollRect = m_scrollRect;
     updateInfo.scrollOffset = m_scrollOffset;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to