Optimize shouldApplyContainment methods by allowing OptionSet as a parameter. Also restrict the principal box checks to a single location.
Created attachment 458946 [details] Patch
I was going to do something very similar, but first I wanted to move these functions: bug 240156
I can adapt this patch to the moved functions once bug 240156 lands.
(In reply to Simon Fraser (smfr) from comment #3) > I can adapt this patch to the moved functions once bug 240156 lands. Thanks, sounds good!
Created attachment 458963 [details] Patch
Committed r293943 (250389@main): <https://commits.webkit.org/250389@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 458963 [details].
<rdar://problem/92893054>