WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
125280
Import the layout test style-sharing-type-and-readonly.html from blink
https://bugs.webkit.org/show_bug.cgi?id=125280
Summary
Import the layout test style-sharing-type-and-readonly.html from blink
Ryosuke Niwa
Reported
2013-12-04 23:09:49 PST
Merge
https://chromium.googlesource.com/chromium/blink/+/b857a7d6c5813dc5d9f10c7eece0ac3d58afeafe
or come up with a better fix RuleSet has a special case in isCommonAttributeSelectorAttribute for allowing style sharing on elements that match "type" or "readonly" attribute selectors as long as they have the same value. This was added long ago in
r96393
and worked based on the assumption that there was logic in canShareStyleWithElement that actually checked the value of the type and readonly attributes on the style sharing candidates. Later in
r123730
the type attribute handling was regressed when it was moved to only check the value for <input>. The readonly attribute was later regressed in the same way in
r134984
. This patch restores the checks those two patches moved but retains the switch from getAttribute to fastGetAttribute for HTML which was likely most of the performance improvement and fixes the bug where elements would incorrectly share style even if one of them matched an attribute selector. Unfortunately this does mean that we need to call the slow geAttribute in SVG documents which may be a minor regression. We can work to improve the performance of SVG in the future once we get the correctness back.
Attachments
Patch
(2.70 KB, patch)
2015-01-27 00:53 PST
,
Benjamin Poulain
svillar
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2015-01-27 00:49:34 PST
<
rdar://problem/19611922
>
Benjamin Poulain
Comment 2
2015-01-27 00:53:14 PST
Created
attachment 245427
[details]
Patch
Sergio Villar Senin
Comment 3
2015-01-27 01:00:47 PST
Comment on
attachment 245427
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=245427&action=review
> LayoutTests/fast/css/style-sharing-type-and-readonly-expected.txt:1 > +Make sure special case style sharing for readonly and type attributes works
Nit: a full stop after "works"
> LayoutTests/fast/css/style-sharing-type-and-readonly.html:19 > +description("Make sure special case style sharing for readonly and type attributes works");
Ditto.
Benjamin Poulain
Comment 4
2015-01-27 12:50:36 PST
Committed
r179205
: <
http://trac.webkit.org/changeset/179205
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug