Bug 43960 - [Chromium] styled scroll bar on the window is painted badly
Summary: [Chromium] styled scroll bar on the window is painted badly
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC OS X 10.5
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-08-13 02:28 PDT by Hajime Morrita
Modified: 2010-08-30 00:45 PDT (History)
2 users (show)

See Also:


Attachments
Patch (9.31 KB, patch)
2010-08-13 02:54 PDT, Hajime Morrita
no flags Details | Formatted Diff | Diff
Patch (8.51 KB, patch)
2010-08-15 22:05 PDT, Hajime Morrita
tkent: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Hajime Morrita 2010-08-13 02:28:29 PDT
Scrollbars for the outermost frme are painted badly  when it has incomplete CSS style.
Precicely, 
- if it has CSS style that doesn't have  background-* properties, then
- The scrollbars are NOT painted, that causes visual artifact (old paint result lasts there.)

Note that Safari doesn't suffer from this problem because it doesn't allow to customize the outermost scrollbars.

Originally from http://code.google.com/p/chromium/issues/detail?id=47946.
Comment 1 Hajime Morrita 2010-08-13 02:54:12 PDT
Created attachment 64317 [details]
Patch
Comment 2 Dimitri Glazkov (Google) 2010-08-13 09:33:18 PDT
Comment on attachment 64317 [details]
Patch

I am not sure if this is a good patch (not yet that knowledgeable about the mechanics here :), but here are a few nits:

WebCore/ChangeLog:15
 +          (WebCore::RenderObject::hasBackground):
Please use this template to outline the changes you made. For instance: "Moved most of this logic to blah".

WebCore/rendering/RenderScrollbar.cpp:144
 +  void RenderScrollbar::adjustStyle(RenderStyle* style) const
Why a separate method for this? It's only being used in one place and it's short enough to inline, I think?

WebCore/rendering/RenderScrollbar.cpp:149
 +      // causes visual artifact like non-repainted durty region.
"painted" and "dirty".
Comment 3 Hajime Morrita 2010-08-15 22:05:12 PDT
Created attachment 64464 [details]
Patch
Comment 4 Hajime Morrita 2010-08-15 22:06:41 PDT
Hi Dimitri, thank you for reviewing!
I updated the patch.

> WebCore/ChangeLog:15
>  +          (WebCore::RenderObject::hasBackground):
> Please use this template to outline the changes you made. For instance: "Moved most of this logic to blah".
OK, added some explanation. Thank you for pointing this out.

> 
> WebCore/rendering/RenderScrollbar.cpp:144
>  +  void RenderScrollbar::adjustStyle(RenderStyle* style) const
> Why a separate method for this? It's only being used in one place and it's short enough to inline, I think?
> 
Agreed and inlined.

> WebCore/rendering/RenderScrollbar.cpp:149
>  +      // causes visual artifact like non-repainted durty region.
> "painted" and "dirty".
Oops. Fixed.
Comment 5 Kent Tamura 2010-08-26 00:43:12 PDT
Comment on attachment 64464 [details]
Patch

The patch looks reasonable.  I'll set r+ tomorrow if no one objects.
Comment 6 Hajime Morrita 2010-08-30 00:45:04 PDT
Committed r66372: <http://trac.webkit.org/changeset/66372>