Bug 62686

Summary: [Chromium] Switching between overlay and opaque scrollbars causes glitches
Product: WebKit Reporter: Sailesh Agrawal <sail>
Component: PlatformAssignee: Sailesh Agrawal <sail>
Status: RESOLVED FIXED    
Severity: Normal CC: bdakin, jamesr, thakis, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

Sailesh Agrawal
Reported 2011-06-14 17:53:45 PDT
1. Run Chromium 2. Open a page with scrollbars 3. Switch between overlay and opaque scrollbars Expected: Scrollbars repaint and no glitches on screen Actual: There are lots of glitches.
Attachments
Patch (1.63 KB, patch)
2011-08-16 16:26 PDT, Sailesh Agrawal
no flags
Patch (1.77 KB, patch)
2011-08-18 15:43 PDT, Sailesh Agrawal
no flags
Sailesh Agrawal
Comment 1 2011-06-15 21:18:08 PDT
Looks like bdakin just fixed this bug for me :-) https://trac.webkit.org/changeset/88877
Sailesh Agrawal
Comment 2 2011-08-16 16:26:48 PDT
Sailesh Agrawal
Comment 3 2011-08-16 16:27:21 PDT
bdakin please take a look, thanks.
James Robinson
Comment 5 2011-08-16 21:13:55 PDT
Comment on attachment 104116 [details] Patch Where's the test?
Sailesh Agrawal
Comment 6 2011-08-16 22:10:04 PDT
(In reply to comment #5) > (From update of attachment 104116 [details]) > Where's the test? Hey James, I'm not sure how to test this. All this code is only used if it's run on Lion. Are any bots running Lion right now?
Sailesh Agrawal
Comment 7 2011-08-18 15:43:45 PDT
Sailesh Agrawal
Comment 8 2011-08-18 15:44:21 PDT
(In reply to comment #6) > (In reply to comment #5) > > (From update of attachment 104116 [details] [details]) > > Where's the test? > > Hey James, I'm not sure how to test this. All this code is only used if it's run on Lion. Are any bots running Lion right now? I've filed bug 66504 to track the work to add tests for this case.
Nico Weber
Comment 9 2011-08-18 15:45:28 PDT
is scrollBarStyleChanged only called on 10.7? maybe you can trigger it by adding css to the scrollbar dynamically and use that to test? If so, just do it in this bug and close the one you just filed.
Sailesh Agrawal
Comment 10 2011-08-18 15:47:15 PDT
(In reply to comment #9) > is scrollBarStyleChanged only called on 10.7? maybe you can trigger it by adding css to the scrollbar dynamically and use that to test? If so, just do it in this bug and close the one you just filed. It's only called on 10.7. It only called by the scroll animator when we get a callback that the scrollbar has switched from overlay to opaque mode.
Nico Weber
Comment 11 2011-08-18 15:54:23 PDT
Indeed. I wonder if this is really blocked on 10.7 – I guess we need to add a method "scrollbarStyleChanged" method to layoutTestController to tickle this anyway, and checking for invalidation doesn't require 10.7. Hooking this up to the layoutTestController should be fairly straightforward. jamesr, bdakin: Is the right thing to do here to add a method to layoutTestController, to not have a test, or something else?
Beth Dakin
Comment 12 2011-08-18 15:58:50 PDT
(In reply to comment #11) > Indeed. I wonder if this is really blocked on 10.7 – I guess we need to add a method "scrollbarStyleChanged" method to layoutTestController to tickle this anyway, and checking for invalidation doesn't require 10.7. Hooking this up to the layoutTestController should be fairly straightforward. > > jamesr, bdakin: Is the right thing to do here to add a method to layoutTestController, to not have a test, or something else? Hi Nico! I have not been adding tests for the many scrollbar-related bugs I have fixed, which is bad. I haven't been adding them because I couldn't come up with a way to test that was not blocked by 10.7. If you have an idea of how to extend LayoutTestController without relying on 10.7 bots and it works, then adding that would be great!
James Robinson
Comment 13 2011-08-18 15:59:55 PDT
There's a full complement of 10.7 bots for the apple mac port on build.webkit.org, so if you can come up with a test that works there you should be able to just add a test and put it in on the Skipped list for pre-10.7 platforms and get test coverage on the bots.
Sailesh Agrawal
Comment 14 2011-08-18 16:16:38 PDT
(In reply to comment #12) > (In reply to comment #11) > > Indeed. I wonder if this is really blocked on 10.7 – I guess we need to add a method "scrollbarStyleChanged" method to layoutTestController to tickle this anyway, and checking for invalidation doesn't require 10.7. Hooking this up to the layoutTestController should be fairly straightforward. > > > > jamesr, bdakin: Is the right thing to do here to add a method to layoutTestController, to not have a test, or something else? > > Hi Nico! I have not been adding tests for the many scrollbar-related bugs I have fixed, which is bad. I haven't been adding them because I couldn't come up with a way to test that was not blocked by 10.7. If you have an idea of how to extend LayoutTestController without relying on 10.7 bots and it works, then adding that would be great! Hey Beth, jamesr and I discussed adding a hook into the scrollbar drawing code that would let the layout test choose which type of scrollbar it wants. This means making some changes to the ScrollbarTheme code. Are you ok with this idea? If so I don't mind making the change and adding the tests. Thanks,
Beth Dakin
Comment 15 2011-08-18 16:49:21 PDT
(In reply to comment #14) > Hey Beth, jamesr and I discussed adding a hook into the scrollbar drawing code that would let the layout test choose which type of scrollbar it wants. This means making some changes to the ScrollbarTheme code. > I think this is a good way to do it. Thanks!
Sailesh Agrawal
Comment 16 2011-08-18 22:03:53 PDT
> I think this is a good way to do it. Thanks! Awesome. jamesr, can i have a review pleaseee
Nico Weber
Comment 17 2011-08-18 22:27:18 PDT
(In reply to comment #16) > Awesome. jamesr, can i have a review pleaseee Usually you include tests along with the fix, now that it looks like the tests aren't blocked on getting 10.7 bots (since a) this might be doable in a bot-agnostic way b) there are 10.7 bots for the mac port)
Sailesh Agrawal
Comment 18 2011-08-19 07:14:21 PDT
(In reply to comment #17) > (In reply to comment #16) > > Awesome. jamesr, can i have a review pleaseee > > Usually you include tests along with the fix, now that it looks like the tests aren't blocked on getting 10.7 bots (since a) this might be doable in a bot-agnostic way b) there are 10.7 bots for the mac port) Writing up the test is going to require changing a lot of the drawing code. Currently all the drawing code looks up the scrollbar style from system settings. I think it's better to decouple that from this change.
Sailesh Agrawal
Comment 19 2011-08-24 11:24:48 PDT
Ping!
Beth Dakin
Comment 20 2011-08-31 15:49:51 PDT
Comment on attachment 104414 [details] Patch r=me!
WebKit Review Bot
Comment 21 2011-08-31 16:05:10 PDT
Comment on attachment 104414 [details] Patch Clearing flags on attachment: 104414 Committed r94243: <http://trac.webkit.org/changeset/94243>
WebKit Review Bot
Comment 22 2011-08-31 16:05:14 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.