Bug 210017 - 'currentcolor' doesn't need setHasExplicitlyInheritedProperties marking anymore
Summary: 'currentcolor' doesn't need setHasExplicitlyInheritedProperties marking anymore
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-04-04 22:13 PDT by Antti Koivisto
Modified: 2020-04-06 11:55 PDT (History)
11 users (show)

See Also:


Attachments
patch (1.52 KB, patch)
2020-04-04 22:14 PDT, Antti Koivisto
no flags Details | Formatted Diff | Diff
wip (15.19 KB, patch)
2020-04-05 03:18 PDT, Antti Koivisto
no flags Details | Formatted Diff | Diff
patch (25.77 KB, patch)
2020-04-06 02:09 PDT, Antti Koivisto
no flags Details | Formatted Diff | Diff
patch (25.79 KB, patch)
2020-04-06 02:49 PDT, Antti Koivisto
no flags Details | Formatted Diff | Diff
patch (26.12 KB, patch)
2020-04-06 10:00 PDT, Antti Koivisto
darin: review+
Details | Formatted Diff | Diff
patch (26.11 KB, patch)
2020-04-06 10:58 PDT, Antti Koivisto
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Antti Koivisto 2020-04-04 22:13:06 PDT
Remove it.
Comment 1 Antti Koivisto 2020-04-04 22:14:41 PDT
Created attachment 395482 [details]
patch
Comment 2 Antti Koivisto 2020-04-05 03:18:46 PDT
Created attachment 395497 [details]
wip
Comment 3 Antti Koivisto 2020-04-06 02:09:45 PDT
Created attachment 395555 [details]
patch
Comment 4 Antti Koivisto 2020-04-06 02:49:29 PDT
Created attachment 395556 [details]
patch
Comment 5 Antti Koivisto 2020-04-06 10:00:04 PDT
Created attachment 395579 [details]
patch
Comment 6 Darin Adler 2020-04-06 10:09:25 PDT
Comment on attachment 395579 [details]
patch

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

> Source/WebCore/css/CSSComputedStyleDeclaration.cpp:2169
> +            // While most color properties are not inherited the value 'currentcolor' resolves to the value of the inherited 'color' property.

Needs a comma after the word "inherited".

> Source/WebCore/css/CSSComputedStyleDeclaration.cpp:2200
> +            for (size_t i = 0; i < shorthand.length(); ++i) {
> +                if (!hasValidStyleForProperty(element, shorthand.properties()[i]))
> +                    return false;
> +            }

Seems like StylePropertyShorthand could use a way to use a for loop without writing it out. Since length() returns unsigned it’s not clear it’s helpful to use size_t for the loop, but that question only arises because we can’t use a modern for loop.

Wish the standard library offered a way to return a pointer and length as a for-loop-compatible range. I’m sure it’s coming in C++20.
Comment 7 Antti Koivisto 2020-04-06 10:12:31 PDT
> Seems like StylePropertyShorthand could use a way to use a for loop without
> writing it out. Since length() returns unsigned it’s not clear it’s helpful
> to use size_t for the loop, but that question only arises because we can’t
> use a modern for loop.

Yeah, noticed that too. I'll fix it separately.
Comment 8 Antti Koivisto 2020-04-06 10:58:46 PDT
Created attachment 395586 [details]
patch
Comment 9 EWS 2020-04-06 11:54:14 PDT
Committed r259585: <https://trac.webkit.org/changeset/259585>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 395586 [details].
Comment 10 Radar WebKit Bug Importer 2020-04-06 11:55:12 PDT
<rdar://problem/61352490>