Mac: Fix bugs in Sierra color fix
The previous fix uncondiontally replaced populated the solid color
IOSurface and updated the contents_rect for all layers on Sierra,
instead of just doing it for the ones without IOSurfaces.
Fix this bug, parameterize whether or not we are using this workaround,
and add tests for both code paths.
(cherry picked from commit 496c26b5cc3983f40b65729d8fa8bbd4a9951c71)
Mac: Fix Sierra solid color layer color-mismatch
Sierra treats the color correction of IOSurface-backed layers and solid
color layers differently. To ensure that behavior is consistent, do not
use solid color layers, rather, in such cases, use an 16x16 IOSurface
that is initialized to the solid color.
(cherry picked from commit 318395caaf3a43683a41d09e65050649d5fedf27)
Review URL: https://codereview.chromium.org/2391793002 .
4 files changed