RESOLVED FIXED 164954
Better testing for accessibility media queries
https://bugs.webkit.org/show_bug.cgi?id=164954
Summary Better testing for accessibility media queries
Dean Jackson
Reported 2016-11-18 14:05:53 PST
Add the "force" option for inverted-colors and monochrome.
Attachments
Patch (20.90 KB, patch)
2016-11-18 14:12 PST, Dean Jackson
mmaxfield: review+
Patch (22.16 KB, patch)
2016-11-18 14:29 PST, Dean Jackson
no flags
Radar WebKit Bug Importer
Comment 1 2016-11-18 14:06:13 PST
Dean Jackson
Comment 2 2016-11-18 14:12:44 PST
Myles C. Maxfield
Comment 3 2016-11-18 14:16:56 PST
Comment on attachment 295188 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=295188&action=review > Source/WebCore/css/MediaQueryEvaluator.cpp:264 > + bool isMonochrome = screenIsMonochrome(frame.mainFrame().view()); I suggest putting this inside a conditional below so it doesn't have to be called. > Source/WebCore/css/MediaQueryEvaluator.cpp:280 > + if (frame.settings().forcedColorsAreInvertedAccessibilityValue() == Settings::ForcedAccessibilityValue::On) Ditto. > Source/WebCore/css/MediaQueryEvaluator.cpp:675 > bool userPrefersReducedMotion = platformTheme()->userPrefersReducedMotion(); Ditto. > Source/WebCore/testing/InternalSettings.idl:97 > + attribute ForcedAccessibilityValue forcedColorsAreInvertedAccessibilityValue; > + attribute ForcedAccessibilityValue forcedDisplayIsMonochromeAccessibilityValue; > + attribute ForcedAccessibilityValue forcedPrefersReducedMotionAccessibilityValue; It's pretty awesome you don't need to make SPI for this. It keeps the patch much simpler than it would otherwise be.
Dean Jackson
Comment 4 2016-11-18 14:29:35 PST
Dean Jackson
Comment 5 2016-11-18 15:00:17 PST
Note You need to log in before you can comment on or make changes to this bug.