[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

morrita at google.com morrita at google.com
Wed Dec 22 12:47:26 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit a43d36a530d79713378148c867440f646f77efcd
Author: morrita at google.com <morrita at google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Mon Aug 30 07:44:46 2010 +0000

    2010-08-13  MORITA Hajime  <morrita at google.com>
    
            Reviewed by Kent Tamura.
    
            https://bugs.webkit.org/show_bug.cgi?id=43960
            [Chromium] styled scroll bar on the window is painted badly.
    
            * platform/chromium/test_expectations.txt: Skips at this time and will rebaseline shortly.
            * platform/mac/Skipped: Mac doesn't suffer from the problem.
            * scrollbars/custom-scrollbar-with-incomplete-style.html: Added.
    2010-08-13  MORITA Hajime  <morrita at google.com>
    
            Reviewed by Kent Tamura.
    
            https://bugs.webkit.org/show_bug.cgi?id=43960
            [Chromium] styled scroll bar on the window is painted badly.
    
            WebKit assumes outermost scrollbar always painted.
            So force their style to have the  background color if it isn't
            given by the stylesheet.
    
            Test: scrollbars/custom-scrollbar-with-incomplete-style.html
    
            * rendering/RenderObject.h:
            (WebCore::RenderObject::hasBackground): Extracted body to RenderStyle for sharing.
            * rendering/RenderScrollbar.cpp:
            (WebCore::RenderScrollbar::getScrollbarPseudoStyle): Added the workaround as mentioned above.
            * rendering/RenderScrollbar.h:
            * rendering/style/RenderStyle.h:
            (WebCore::InheritedFlags::hasBackground): Extracted from RenderObject.
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@66372 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 665d84b..b15301e 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,14 @@
+2010-08-13  MORITA Hajime  <morrita at google.com>
+
+        Reviewed by Kent Tamura.
+
+        https://bugs.webkit.org/show_bug.cgi?id=43960
+        [Chromium] styled scroll bar on the window is painted badly.
+        
+        * platform/chromium/test_expectations.txt: Skips at this time and will rebaseline shortly.
+        * platform/mac/Skipped: Mac doesn't suffer from the problem.
+        * scrollbars/custom-scrollbar-with-incomplete-style.html: Added.
+
 2010-08-30  Adam Barth  <abarth at webkit.org>
 
         Reviewed by Darin Adler.
diff --git a/LayoutTests/platform/chromium/test_expectations.txt b/LayoutTests/platform/chromium/test_expectations.txt
index c6f8517..2c74d1f 100644
--- a/LayoutTests/platform/chromium/test_expectations.txt
+++ b/LayoutTests/platform/chromium/test_expectations.txt
@@ -3215,3 +3215,6 @@ BUGWK44797 : fullscreen = FAIL
 // Started at http://trac.webkit.org/changeset/66318/
 BUG53796 : fast/js/array-splice.html = TEXT
 
+// Need rebasline to pick the results.
+BUG47946 WIN LINUX MAC : scrollbars/custom-scrollbar-with-incomplete-style.html = MISSING
+
diff --git a/LayoutTests/platform/mac/Skipped b/LayoutTests/platform/mac/Skipped
index 9874182..b08e72e 100644
--- a/LayoutTests/platform/mac/Skipped
+++ b/LayoutTests/platform/mac/Skipped
@@ -298,3 +298,7 @@ inspector/dom-breakpoints.html
 
 # https://bugs.webkit.org/show_bug.cgi?id=44566
 fast/canvas/webgl/gl-teximage.html
+
+# Safari doesn't allow to customize outermost scrollbars.
+# https://bugs.webkit.org/show_bug.cgi?id=43960
+scrollbars/custom-scrollbar-with-incomplete-style.html
\ No newline at end of file
diff --git a/LayoutTests/scrollbars/custom-scrollbar-with-incomplete-style.html b/LayoutTests/scrollbars/custom-scrollbar-with-incomplete-style.html
new file mode 100644
index 0000000..d16690b
--- /dev/null
+++ b/LayoutTests/scrollbars/custom-scrollbar-with-incomplete-style.html
@@ -0,0 +1,29 @@
+<html>
+<head>
+<title>Incomplete scrollbar</title>
+<style>
+/* Turn on a 13x13 scrollbar with no background specification. */
+::-webkit-scrollbar {
+    width: 13px;
+    height: 13px;
+}
+
+pre { background-color: green; }
+</style>
+</head>
+<body>
+<h2>It's OK if nothing drawn for a scrollbar (for an outermost frame and an element with overlow)</h2>
+<p>Note that Safari doesn't allow to customize the outermost scdrollbars and just show Cocoa's.</p>
+<pre style="height: 100px; width:100px; overflow:auto;">
+The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
+The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
+The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
+The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
+The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
+The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
+The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog.
+</pre>
+<pre style="height:200%;"></pre>
+<pre style="width:200%;"></pre>
+</body>
+</html>
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 665823c..5df309d 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,24 @@
+2010-08-13  MORITA Hajime  <morrita at google.com>
+
+        Reviewed by Kent Tamura.
+
+        https://bugs.webkit.org/show_bug.cgi?id=43960
+        [Chromium] styled scroll bar on the window is painted badly.
+
+        WebKit assumes outermost scrollbar always painted. 
+        So force their style to have the  background color if it isn't 
+        given by the stylesheet.
+        
+        Test: scrollbars/custom-scrollbar-with-incomplete-style.html
+
+        * rendering/RenderObject.h:
+        (WebCore::RenderObject::hasBackground): Extracted body to RenderStyle for sharing.
+        * rendering/RenderScrollbar.cpp:
+        (WebCore::RenderScrollbar::getScrollbarPseudoStyle): Added the workaround as mentioned above.
+        * rendering/RenderScrollbar.h:
+        * rendering/style/RenderStyle.h:
+        (WebCore::InheritedFlags::hasBackground): Extracted from RenderObject.
+
 2010-08-30  Adam Barth  <abarth at webkit.org>
 
         Reviewed by Darin Adler.
diff --git a/WebCore/rendering/RenderObject.h b/WebCore/rendering/RenderObject.h
index d2046cf..34eba6d 100644
--- a/WebCore/rendering/RenderObject.h
+++ b/WebCore/rendering/RenderObject.h
@@ -383,14 +383,7 @@ public:
     
     bool hasBoxDecorations() const { return m_paintBackground; }
     bool mustRepaintBackgroundOrBorder() const;
-    bool hasBackground() const
-    {
-        Color color = style()->visitedDependentColor(CSSPropertyBackgroundColor);
-        if (color.isValid() && color.alpha() > 0)
-            return true;
-        return style()->hasBackgroundImage();
-    }
-
+    bool hasBackground() const { return style()->hasBackground(); }
     bool needsLayout() const { return m_needsLayout || m_normalChildNeedsLayout || m_posChildNeedsLayout || m_needsPositionedMovementLayout; }
     bool selfNeedsLayout() const { return m_needsLayout; }
     bool needsPositionedMovementLayout() const { return m_needsPositionedMovementLayout; }
diff --git a/WebCore/rendering/RenderScrollbar.cpp b/WebCore/rendering/RenderScrollbar.cpp
index 7378056..e7a70a4 100644
--- a/WebCore/rendering/RenderScrollbar.cpp
+++ b/WebCore/rendering/RenderScrollbar.cpp
@@ -27,6 +27,7 @@
 #include "RenderScrollbar.h"
 
 #include "Frame.h"
+#include "FrameView.h"
 #include "RenderPart.h"
 #include "RenderScrollbarPart.h"
 #include "RenderScrollbarTheme.h"
@@ -150,6 +151,14 @@ PassRefPtr<RenderStyle> RenderScrollbar::getScrollbarPseudoStyle(ScrollbarPart p
     RefPtr<RenderStyle> result = owningRenderer()->getUncachedPseudoStyle(pseudoId, owningRenderer()->style());
     s_styleResolvePart = NoPart;
     s_styleResolveScrollbar = 0;
+
+    // Scrollbars for root frames should always have background color 
+    // unless explicitly specified as transparent. So we force it.
+    // This is because WebKit assumes scrollbar to be always painted and missing background
+    // causes visual artifact like non-repainted dirty region.
+    if (result && m_owningFrame && m_owningFrame->view() && !m_owningFrame->view()->isTransparent() && !result->hasBackground())
+        result->setBackgroundColor(Color::white);
+
     return result;
 }
 
diff --git a/WebCore/rendering/style/RenderStyle.h b/WebCore/rendering/style/RenderStyle.h
index 920e452..9cda97f 100644
--- a/WebCore/rendering/style/RenderStyle.h
+++ b/WebCore/rendering/style/RenderStyle.h
@@ -345,6 +345,14 @@ public:
     bool hasFixedBackgroundImage() const { return m_background->background().hasFixedImage(); }
     bool hasAppearance() const { return appearance() != NoControlPart; }
 
+    bool hasBackground() const
+    {
+        Color color = visitedDependentColor(CSSPropertyBackgroundColor);
+        if (color.isValid() && color.alpha() > 0)
+            return true;
+        return hasBackgroundImage();
+    }
+
     bool visuallyOrdered() const { return inherited_flags._visuallyOrdered; }
     void setVisuallyOrdered(bool b) { inherited_flags._visuallyOrdered = b; }
 

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list