Currently, CSPDirectiveList is the only piece of ContentSecurityPolicy's architecture that can log to the console. I think we can improve the situation by extracting the logging functions and moving them to the policy object, and then teaching each of the lower-level objects about the policy in which they live.
Created attachment 156624 [details] Patch
Hey Adam, this is a pass at the refactoring I asked you about over the weekend. In a nut, it replaces the dependence on ScriptExecutionContext with a dependence on ContentSecurityPolicy, adding a few new methods to CSP in order to route a few of the context-relevant requests through the policy object. Not high priority, so just take a look whenever you have a chance. :) Thanks!
Thanks.
Comment on attachment 156624 [details] Patch Danke! CQ?
Comment on attachment 156624 [details] Patch Clearing flags on attachment: 156624 Committed r125021: <http://trac.webkit.org/changeset/125021>
All reviewed patches have been landed. Closing bug.