Bug 238108

Summary: Add an addition point for system background color
Product: WebKit Reporter: Tim Horton <thorton>
Component: New BugsAssignee: Tim Horton <thorton>
Status: RESOLVED FIXED    
Severity: Normal CC: akeerthi, changseok, cpugh, dino, esprehn+autocc, ews-watchlist, glenn, hi, kondapallykalyan, pdr, webkit-bug-importer, wenson_hsieh
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch none

Description Tim Horton 2022-03-19 00:21:22 PDT
Use hardcoded base background color to avoid transparent backgrounds
Comment 1 Tim Horton 2022-03-19 00:24:26 PDT
Created attachment 455166 [details]
Patch
Comment 2 Aditya Keerthi 2022-03-19 10:37:28 PDT
Comment on attachment 455166 [details]
Patch

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

> Source/WebCore/platform/ios/WebCoreUIColorExtras.mm:38
> +        return (UIColor *)[PAL::getUIColorClass() blackColor];

The system background color is not always black or white.

The trait collection's `userInterfaceLevel` and `accessibilityContrast` also affect this color.

I don't think it would be a good idea to hardcode all the variations – I'll talk to you about possible alternate solutions.
Comment 3 Tim Horton 2022-03-19 14:25:19 PDT
Created attachment 455175 [details]
Patch
Comment 4 Tim Horton 2022-03-19 14:34:09 PDT
Created attachment 455177 [details]
Patch
Comment 5 EWS 2022-03-21 10:45:56 PDT
Committed r291564 (248666@main): <https://commits.webkit.org/248666@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 455177 [details].
Comment 6 Radar WebKit Bug Importer 2022-03-21 10:46:18 PDT
<rdar://problem/90576569>