Bug 141059 - When no background-size is specified on the 2nd background layer, it takes the first instead of the initial value
Summary: When no background-size is specified on the 2nd background layer, it takes th...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL: http://result.dabblet.com/gist/850c60...
Keywords:
Depends on:
Blocks:
 
Reported: 2015-01-29 16:30 PST by Lea Verou
Modified: 2015-01-30 14:59 PST (History)
7 users (show)

See Also:


Attachments
Patch (10.66 KB, patch)
2015-01-29 21:43 PST, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Lea Verou 2015-01-29 16:30:25 PST
Check testcase.

Testcase works everywhere else, fails on WebKit nightlies (as well as Safari, Mobile Safari etc).
Comment 1 Chris Dumez 2015-01-29 19:30:08 PST
(In reply to comment #0)
> Check testcase.
> 
> Testcase works everywhere else, fails on WebKit nightlies (as well as
> Safari, Mobile Safari etc).

Thanks for the bug report and the test case. I am looking into it now.
Comment 2 Chris Dumez 2015-01-29 21:43:22 PST
Created attachment 245693 [details]
Patch
Comment 3 Antti Koivisto 2015-01-30 07:04:51 PST
Comment on attachment 245693 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=245693&action=review

> LayoutTests/fast/css/background-layers-initial-size.html:22
> +// The second layer should have "auto" as background size as it is its initial value.
> +shouldBeEqualToString("computedBackgroundSize", "25px 25px, auto");

Doesn't window.getComputedStyle generally try to resolve auto values and not return them as 'auto'?
Comment 4 Antti Koivisto 2015-01-30 07:05:46 PST
What does Firefox return here?
Comment 5 Chris Dumez 2015-01-30 09:34:58 PST
(In reply to comment #4)
> What does Firefox return here?

Firefox shows "25px 25px, auto auto". Chrome shows "25px 25px, auto".
Comment 6 Chris Dumez 2015-01-30 09:50:02 PST
(In reply to comment #5)
> (In reply to comment #4)
> > What does Firefox return here?
> 
> Firefox shows "25px 25px, auto auto". Chrome shows "25px 25px, auto".

Our previous output was "25px 25px, 25px 25px", which was obviously bad.
Comment 7 Antti Koivisto 2015-01-30 11:46:05 PST
Comment on attachment 245693 [details]
Patch

ok
Comment 8 Chris Dumez 2015-01-30 14:54:29 PST
Comment on attachment 245693 [details]
Patch

Clearing flags on attachment: 245693

Committed r179413: <http://trac.webkit.org/changeset/179413>
Comment 9 Chris Dumez 2015-01-30 14:54:35 PST
All reviewed patches have been landed.  Closing bug.
Comment 10 Lea Verou 2015-01-30 14:59:33 PST
Impressive. Reported and fixed in less than 24 hours!! Thanks everyone!