DescriptionDissect and clean up instances of color parsing in CSSPropertyParser
This moves all instances of color parsing (mostly <color> parsing
even) into their separate methods. The new methods (except parseSVGColor)
are formulated using parseColor(). parseColor() itself is combined with
the "most common" color parsing case by folding the keyword case into it.
The new methods are structured as first checking for keywords that they
handle differently from the generic <color> case.
The <quirky-color> determination is moved into a function of its own.
The parsing of <color> for shadow is cleaned up.
Behavioral changes:
* Accept '-internal-*' in all cases (for UA-sheets).
* Keep 'grey' as a keyword in all cases.
* Accept '-webkit-focus-ring-color' in quirks mode and UA-sheets in all
cases.
* Keep keywords for fallback colors to 'fill' and 'stroke.
The intention of the change is to make the differences visible, and try
to eliminate the remaining differences in follow-up CLs.
BUG=505410
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=198062
Patch Set 1 #Patch Set 2 : Harmonize. #Patch Set 3 : Update handling of 'grey' in fast-path color parser. #
Messages
Total messages: 8 (3 generated)
|