Refactor ScriptController's proliferation of ExceptionDetails*.
https://bugs.webkit.org/show_bug.cgi?id=205151
Reviewed by Alex Christensen.
Source/WebCore:
No new tests (Refactor, no behavior change).
There's so many ExceptionDetails* null pointers being passed around in the ScriptController
family of functions.
Let's make it a little more explicit which callers get exceptions and which don't.
- Modules/plugins/QuickTimePluginReplacement.mm:
(WebCore::QuickTimePluginReplacement::ensureReplacementScriptInjected):
- bindings/js/ScheduledAction.cpp:
(WebCore::ScheduledAction::execute):
- bindings/js/ScriptController.cpp:
(WebCore::ScriptController::evaluateInWorldIgnoringException):
(WebCore::ScriptController::evaluateInWorld):
(WebCore::ScriptController::evaluateIgnoringException):
(WebCore::ScriptController::executeScriptInWorldIgnoringException):
(WebCore::ScriptController::executeScriptInWorld):
(WebCore::ScriptController::executeUserAgentScriptInWorld):
(WebCore::ScriptController::executeScriptIgnoringException):
(WebCore::ScriptController::executeIfJavaScriptURL):
(WebCore::ScriptController::evaluate): Deleted.
(WebCore::ScriptController::executeScript): Deleted.
- bindings/js/ScriptController.h:
- contentextensions/ContentExtensionsBackend.cpp:
(WebCore::ContentExtensions::ContentExtensionsBackend::processContentRuleListsForLoad):
(WebCore::Document::ensurePlugInsInjectedScript):
(WebCore::ScriptElement::executeClassicScript):
- html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::ensureMediaControlsInjectedScript):
- inspector/InspectorFrontendClientLocal.cpp:
(WebCore::InspectorFrontendClientLocal::evaluateAsBoolean):
(WebCore::InspectorFrontendClientLocal::evaluateOnLoad):
- inspector/agents/InspectorPageAgent.cpp:
(WebCore::InspectorPageAgent::didClearWindowObjectInWorld):
- loader/ContentFilter.cpp:
(WebCore::ContentFilter::didDecide):
(WebCore::Frame::injectUserScriptImmediately):
(WebCore::XMLTreeViewer::transformDocumentToTreeView):
Source/WebKit:
- UIProcess/API/C/WKPage.cpp:
(WKPageRunJavaScriptInMainFrame):
- UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _evaluateJavaScript:forceUserGesture:completionHandler:]):
- UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::runJavaScriptInMainFrame):
(WebKit::WebPageProxy::runJavaScriptInMainFrameScriptWorld):
(WebKit::WebPageProxy::runJavaScriptInFrame):
- UIProcess/WebPageProxy.h:
- UIProcess/WebPageProxy.messages.in:
- WebProcess/Plugins/PluginView.cpp:
(WebKit::PluginView::performJavaScriptURLRequest):
- WebProcess/WebPage/WebInspectorFrontendAPIDispatcher.cpp:
(WebKit::WebInspectorFrontendAPIDispatcher::evaluateOrQueueExpression):
(WebKit::WebInspectorFrontendAPIDispatcher::evaluateQueuedExpressions):
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::runJavaScript):
Source/WebKitLegacy/mac:
- WebCoreSupport/WebInspectorClient.mm:
(WebInspectorFrontendClient::save):
(WebInspectorFrontendClient::append):
(-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
(-[WebFrame _stringByEvaluatingJavaScriptFromString:withGlobalObject:inScriptWorld:]):
(-[WebView aeDescByEvaluatingJavaScriptFromString:]):
Source/WebKitLegacy/win:
(WebCore::PluginView::performRequest):
(WebFrame::stringByEvaluatingJavaScriptInScriptWorld):
(WebView::stringByEvaluatingJavaScriptFromString):