Web Inspector: Add Console support to JSContext Inspection
authorjoepeck@webkit.org <joepeck@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 6 Feb 2014 23:45:53 +0000 (23:45 +0000)
committerjoepeck@webkit.org <joepeck@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 6 Feb 2014 23:45:53 +0000 (23:45 +0000)
https://bugs.webkit.org/show_bug.cgi?id=127941

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

* CMakeLists.txt:
* DerivedSources.make:
* GNUmakefile.am:
* GNUmakefile.list.am:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
* JavaScriptCore.xcodeproj/project.pbxproj:
Add new files.

* inspector/agents/InspectorConsoleAgent.cpp: Renamed from Source/WebCore/inspector/InspectorConsoleAgent.cpp.
* inspector/agents/InspectorConsoleAgent.h: Added.
New agent moved from WebCore. Rename a method to work in JS only context.

* inspector/JSGlobalObjectInspectorController.cpp:
(Inspector::JSGlobalObjectInspectorController::JSGlobalObjectInspectorController):
Instantiate ConsoleAgent.

* inspector/agents/JSGlobalObjectConsoleAgent.h: Copied from Source/WebCore/inspector/PageInjectedScriptHost.h.
* inspector/agents/JSGlobalObjectConsoleAgent.cpp: Copied from Source/WebCore/inspector/PageInjectedScriptHost.h.
(Inspector::JSGlobalObjectConsoleAgent::JSGlobalObjectConsoleAgent):
(Inspector::JSGlobalObjectConsoleAgent::setMonitoringXHREnabled):
(Inspector::JSGlobalObjectConsoleAgent::addInspectedNode):
(Inspector::JSGlobalObjectConsoleAgent::addInspectedHeapObject):
JSGlobalObject implementation.

* inspector/agents/JSGlobalObjectDebuggerAgent.h:
* inspector/agents/JSGlobalObjectDebuggerAgent.cpp:
(Inspector::JSGlobalObjectDebuggerAgent::JSGlobalObjectDebuggerAgent):
(Inspector::JSGlobalObjectDebuggerAgent::breakpointActionLog):
Use ConsoleAgent to report logs.

* inspector/ConsoleMessage.cpp: Renamed from Source/WebCore/inspector/ConsoleMessage.cpp.
* inspector/ConsoleMessage.h: Renamed from Source/WebCore/inspector/ConsoleMessage.h.
* inspector/ConsoleTypes.h: Copied from Source/WebCore/inspector/ConsoleAPITypes.h.
* inspector/IdentifiersFactory.cpp: Renamed from Source/WebCore/inspector/IdentifiersFactory.cpp.
* inspector/IdentifiersFactory.h: Renamed from Source/WebCore/inspector/IdentifiersFactory.h.
* inspector/ScriptArguments.cpp: Renamed from Source/WebCore/inspector/ScriptArguments.cpp.
* inspector/ScriptArguments.h: Renamed from Source/WebCore/inspector/ScriptArguments.h.
* inspector/ScriptCallFrame.cpp: Renamed from Source/WebCore/inspector/ScriptCallFrame.cpp.
* inspector/ScriptCallFrame.h: Renamed from Source/WebCore/inspector/ScriptCallFrame.h.
* inspector/ScriptCallStack.cpp: Renamed from Source/WebCore/inspector/ScriptCallStack.cpp.
* inspector/ScriptCallStack.h: Renamed from Source/WebCore/inspector/ScriptCallStack.h.
* inspector/ScriptCallStackFactory.cpp: Renamed from Source/WebCore/bindings/js/ScriptCallStackFactory.cpp.
* inspector/ScriptCallStackFactory.h: Renamed from Source/WebCore/bindings/js/ScriptCallStackFactory.h.
* inspector/protocol/Console.json: Renamed from Source/WebCore/inspector/protocol/Console.json.
* inspector/scripts/generate-combined-inspector-json.py:

Source/WebCore:

  - Move InspectorConsoleAgent and dependencies to JavaScriptCore
    and into the Inspector namespace.
  - Update Console Message enum types to enum classes and update
    all users to the new, simpler names.
  - Since we are updating addConsoleMessage callsites anyways, add
    ASCIILiteral where appropriate.
  - Add WebConsoleAgent base of Page/Worker ConsoleAgent to implement
    what could not be pushed into JavaScriptCore.

* CMakeLists.txt:
* DerivedSources.make:
* ForwardingHeaders/inspector/ConsoleMessage.h: Added.
* ForwardingHeaders/inspector/ConsoleTypes.h: Added.
* ForwardingHeaders/inspector/IdentifiersFactory.h: Added.
* ForwardingHeaders/inspector/ScriptArguments.h: Added.
* ForwardingHeaders/inspector/ScriptCallFrame.h: Added.
* ForwardingHeaders/inspector/ScriptCallStack.h: Added.
* ForwardingHeaders/inspector/ScriptCallStackFactory.h: Added.
* ForwardingHeaders/inspector/agents/InspectorConsoleAgent.h: Added.
* GNUmakefile.am:
* GNUmakefile.list.am:
Add / remove files from builds.

* inspector/WebConsoleAgent.h:
* inspector/WebConsoleAgent.cpp: Added.
(WebCore::WebConsoleAgent::WebConsoleAgent):
(WebCore::WebConsoleAgent::setMonitoringXHREnabled):
(WebCore::WebConsoleAgent::frameWindowDiscarded):
(WebCore::WebConsoleAgent::didFinishXHRLoading):
(WebCore::WebConsoleAgent::didReceiveResponse):
(WebCore::WebConsoleAgent::didFailLoading):
(WebCore::WebConsoleAgent::addInspectedHeapObject):
Implement what could not be pushed down into JavaScriptCore.

* inspector/InstrumentingAgents.h:
(WebCore::InstrumentingAgents::webConsoleAgent):
(WebCore::InstrumentingAgents::setWebConsoleAgent):
Hold a WebConsoleAgent instead of InspectorConsoleAgent.

* Modules/indexeddb/IDBCursor.cpp:
* Modules/indexeddb/IDBDatabase.cpp:
* Modules/indexeddb/IDBTransaction.cpp:
* Modules/quota/DOMWindowQuota.cpp:
(WebCore::DOMWindowQuota::webkitStorageInfo):
* Modules/webaudio/AudioBufferSourceNode.cpp:
(WebCore::AudioBufferSourceNode::looping):
(WebCore::AudioBufferSourceNode::setLooping):
* Modules/webaudio/AudioContext.cpp:
* Modules/webaudio/PannerNode.cpp:
(WebCore::PannerNode::setPanningModel):
* Modules/webdatabase/DatabaseBase.cpp:
(WebCore::DatabaseBase::logErrorMessage):
* Modules/webdatabase/DatabaseManager.cpp:
(WebCore::DatabaseManager::logErrorMessage):
* Modules/websockets/WebSocket.cpp:
(WebCore::WebSocket::connect):
(WebCore::WebSocket::send):
(WebCore::WebSocket::close):
(WebCore::WebSocket::setBinaryType):
* Modules/websockets/WebSocketChannel.cpp:
(WebCore::WebSocketChannel::fail):
(WebCore::WebSocketChannel::didFailSocketStream):
* Modules/websockets/WebSocketHandshake.cpp:
* WebCore.exp.in:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.vcxproj/WebCore.vcxproj.filters:
* WebCore.xcodeproj/project.pbxproj:
* bindings/js/JSAudioContextCustom.cpp:
(WebCore::JSAudioContextConstructor::constructJSAudioContext):
* bindings/js/JSCustomXPathNSResolver.cpp:
(WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
* bindings/js/JSDOMBinding.cpp:
* bindings/js/JSSubtleCryptoCustom.cpp:
(WebCore::JSSubtleCrypto::encrypt):
(WebCore::JSSubtleCrypto::decrypt):
(WebCore::JSSubtleCrypto::sign):
(WebCore::JSSubtleCrypto::verify):
(WebCore::JSSubtleCrypto::wrapKey):
(WebCore::JSSubtleCrypto::unwrapKey):
* bindings/js/ScriptController.cpp:
(WebCore::ScriptController::canExecuteScripts):
* bindings/scripts/CodeGeneratorJS.pm:
(GenerateCallWith):
* bindings/scripts/test/JS/JSTestObj.cpp:
* css/CSSParser.cpp:
(WebCore::CSSParser::logError):
* css/MediaList.cpp:
(WebCore::addResolutionWarningMessageToConsole):
* dom/Document.cpp:
(WebCore::Document::logExceptionToConsole):
(WebCore::Document::processHttpEquiv):
(WebCore::Document::addMessage):
* dom/Document.h:
* dom/ScriptElement.cpp:
(WebCore::ScriptElement::executeScript):
(WebCore::ScriptElement::notifyFinished):
* dom/ScriptExecutionContext.cpp:
* dom/ScriptExecutionContext.h:
* dom/ViewportArguments.cpp:
(WebCore::viewportErrorMessageLevel):
(WebCore::reportViewportWarning):
* fileapi/Blob.cpp:
* fileapi/WebKitBlobBuilder.cpp:
* html/HTMLFormControlElement.cpp:
(WebCore::shouldAutofocus):
* html/HTMLFormElement.cpp:
(WebCore::HTMLFormElement::validateInteractively):
* html/HTMLIFrameElement.cpp:
(WebCore::HTMLIFrameElement::parseAttribute):
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::parseAttribute):
* html/canvas/CanvasRenderingContext2D.cpp:
(WebCore::CanvasRenderingContext2D::getImageData):
* html/canvas/WebGLRenderingContext.cpp:
(WebCore::WebGLRenderingContext::printWarningToConsole):
* html/parser/XSSAuditor.cpp:
(WebCore::XSSAuditor::init):
* html/parser/XSSAuditorDelegate.cpp:
(WebCore::XSSAuditorDelegate::didBlockScript):
* inspector/CommandLineAPIHost.cpp:
* inspector/CommandLineAPIHost.h:
(WebCore::CommandLineAPIHost::init):
* inspector/InspectorAllInOne.cpp:
* inspector/InspectorConsoleAgent.h: Removed.
* inspector/InspectorConsoleInstrumentation.h:
(WebCore::InspectorInstrumentation::addMessageToConsole):
(WebCore::InspectorInstrumentation::consoleCount):
(WebCore::InspectorInstrumentation::stopConsoleTiming):
(WebCore::InspectorInstrumentation::consoleTimeStamp):
(WebCore::InspectorInstrumentation::addProfile):
* inspector/InspectorController.cpp:
(WebCore::InspectorController::InspectorController):
* inspector/InspectorDOMAgent.cpp:
* inspector/InspectorFrontendHost.h:
* inspector/InspectorInstrumentation.cpp:
(WebCore::InspectorInstrumentation::frameWindowDiscardedImpl):
(WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
(WebCore::InspectorInstrumentation::didFailLoadingImpl):
(WebCore::InspectorInstrumentation::didFinishXHRLoadingImpl):
(WebCore::InspectorInstrumentation::didCommitLoadImpl):
(WebCore::isConsoleAssertMessage):
(WebCore::InspectorInstrumentation::addMessageToConsoleImpl):
(WebCore::InspectorInstrumentation::consoleCountImpl):
(WebCore::InspectorInstrumentation::startConsoleTimingImpl):
(WebCore::InspectorInstrumentation::stopConsoleTimingImpl):
(WebCore::InspectorInstrumentation::consoleAgentEnabled):
* inspector/InspectorInstrumentation.h:
* inspector/InspectorLayerTreeAgent.cpp:
* inspector/InspectorPageAgent.cpp:
* inspector/InspectorProfilerAgent.cpp:
(WebCore::InspectorProfilerAgent::addProfileFinishedMessageToConsole):
(WebCore::InspectorProfilerAgent::addStartProfilingMessageToConsole):
* inspector/InspectorProfilerAgent.h:
* inspector/InspectorResourceAgent.cpp:
(WebCore::InspectorResourceAgent::buildInitiatorObject):
* inspector/InspectorTimelineAgent.cpp:
* inspector/InstrumentingAgents.cpp:
(WebCore::InstrumentingAgents::InstrumentingAgents):
(WebCore::InstrumentingAgents::reset):
* inspector/PageConsoleAgent.cpp:
(WebCore::PageConsoleAgent::PageConsoleAgent):
(WebCore::PageConsoleAgent::clearMessages):
(WebCore::PageConsoleAgent::addInspectedNode):
* inspector/PageConsoleAgent.h:
* inspector/PageDebuggerAgent.cpp:
(WebCore::PageDebuggerAgent::breakpointActionLog):
* inspector/PageInjectedScriptHost.h:
* inspector/PageInjectedScriptManager.h:
* inspector/TimelineRecordFactory.cpp:
(WebCore::TimelineRecordFactory::createGenericRecord):
(WebCore::WebConsoleAgent::~WebConsoleAgent):
* inspector/WorkerConsoleAgent.cpp:
(WebCore::WorkerConsoleAgent::WorkerConsoleAgent):
(WebCore::WorkerConsoleAgent::addInspectedNode):
* inspector/WorkerConsoleAgent.h:
* inspector/WorkerDebuggerAgent.cpp:
(WebCore::WorkerDebuggerAgent::breakpointActionLog):
* inspector/WorkerInspectorController.cpp:
(WebCore::WorkerInspectorController::WorkerInspectorController):
* loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::responseReceived):
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::submitForm):
(WebCore::FrameLoader::reportLocalLoadFailed):
(WebCore::FrameLoader::handleBeforeUnloadEvent):
(WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions):
(WebCore::createWindow):
* loader/ImageLoader.cpp:
(WebCore::ImageLoader::notifyFinished):
* loader/MixedContentChecker.cpp:
(WebCore::MixedContentChecker::logWarning):
* loader/TextTrackLoader.cpp:
(WebCore::TextTrackLoader::corsPolicyPreventedLoad):
* loader/appcache/ApplicationCacheGroup.cpp:
(WebCore::ApplicationCacheGroup::abort):
(WebCore::ApplicationCacheGroup::didReceiveResponse):
(WebCore::ApplicationCacheGroup::didFinishLoading):
(WebCore::ApplicationCacheGroup::didFail):
(WebCore::ApplicationCacheGroup::didReceiveManifestResponse):
(WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
(WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
* loader/cache/CachedResourceLoader.cpp:
(WebCore::CachedResourceLoader::printAccessDeniedMessage):
* page/ChromeClient.h:
* page/Console.cpp:
(WebCore::internalAddMessage):
(WebCore::Console::debug):
(WebCore::Console::error):
(WebCore::Console::log):
(WebCore::Console::warn):
(WebCore::Console::dir):
(WebCore::Console::dirxml):
(WebCore::Console::table):
(WebCore::Console::clear):
(WebCore::Console::trace):
(WebCore::Console::assertCondition):
(WebCore::Console::group):
(WebCore::Console::groupCollapsed):
(WebCore::Console::groupEnd):
* page/Console.h:
* page/ConsoleTypes.h: Removed.
* page/ContentSecurityPolicy.cpp:
(WebCore::ContentSecurityPolicy::reportViolation):
(WebCore::ContentSecurityPolicy::logToConsole):
* page/DOMSecurityPolicy.cpp:
* page/DOMWindow.cpp:
(WebCore::DOMWindow::postMessage):
(WebCore::DOMWindow::dispatchMessageEventWithOriginCheck):
(WebCore::DOMWindow::close):
(WebCore::DOMWindow::printErrorMessage):
* page/DOMWindow.h:
* page/EventSource.cpp:
(WebCore::EventSource::didReceiveResponse):
(WebCore::EventSource::didFailAccessControlCheck):
* page/PageConsole.cpp:
(WebCore::PageConsole::printMessageSourceAndLevelPrefix):
(WebCore::PageConsole::addMessage):
* page/PageConsole.h:
* page/PointerLockController.cpp:
(WebCore::PointerLockController::requestPointerLock):
* platform/CrossThreadCopier.h:
* rendering/shapes/ShapeInfo.cpp:
(WebCore::checkShapeImageOrigin):
* svg/SVGDocumentExtensions.cpp:
(WebCore::reportMessage):
(WebCore::SVGDocumentExtensions::reportWarning):
(WebCore::SVGDocumentExtensions::reportError):
* testing/Internals.cpp:
(WebCore::Internals::consoleMessageArgumentCounts):
* workers/DefaultSharedWorkerRepository.cpp:
* workers/SharedWorkerGlobalScope.cpp:
(WebCore::SharedWorkerGlobalScope::logExceptionToConsole):
* workers/SharedWorkerGlobalScope.h:
* workers/WorkerGlobalScope.cpp:
(WebCore::WorkerGlobalScope::addMessageToWorkerConsole):
* workers/WorkerGlobalScope.h:
* workers/WorkerMessagingProxy.cpp:
* workers/WorkerReportingProxy.h:
* xml/XMLHttpRequest.cpp:
(WebCore::logConsoleError):
(WebCore::XMLHttpRequest::send):
* xml/XSLTProcessorLibxslt.cpp:
(WebCore::XSLTProcessor::parseErrorFunc):

Source/WebInspectorUI:

* UserInterface/InspectorJSBackendCommands.js:
* UserInterface/InspectorWebBackendCommands.js:
ConsoleAgent moved to JavaScript section.

Source/WebKit/gtk:

* WebCoreSupport/ChromeClientGtk.cpp:
(WebKit::ChromeClient::addMessageToConsole):

Source/WebKit/mac:

* WebCoreSupport/WebChromeClient.h:
* WebCoreSupport/WebChromeClient.mm:
(stringForMessageSource):
(stringForMessageLevel):
(WebChromeClient::addMessageToConsole):

Source/WebKit/win:

* WebCoreSupport/WebChromeClient.h:

Source/WebKit/wince:

* WebCoreSupport/ChromeClientWinCE.h:

Source/WebKit2:

* WebProcess/WebCoreSupport/WebChromeClient.h:

LayoutTests:

* inspector-protocol/page/deny-X-FrameOption-expected.txt:
Update with better line/column numbers now.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@163568 268f45cc-cd09-0410-ab3c-d52691b4dbfc

165 files changed:
LayoutTests/ChangeLog
LayoutTests/http/tests/inspector-protocol/loading-iframe-document-node.html
LayoutTests/http/tests/inspector/inspector-test.js
LayoutTests/inspector-protocol/page/deny-X-FrameOption-expected.txt
Source/JavaScriptCore/CMakeLists.txt
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/DerivedSources.make
Source/JavaScriptCore/GNUmakefile.am
Source/JavaScriptCore/GNUmakefile.list.am
Source/JavaScriptCore/JavaScriptCore.vcxproj/JavaScriptCore.vcxproj
Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj
Source/JavaScriptCore/inspector/ConsoleMessage.cpp [moved from Source/WebCore/inspector/ConsoleMessage.cpp with 69% similarity]
Source/JavaScriptCore/inspector/ConsoleMessage.h [moved from Source/WebCore/inspector/ConsoleMessage.h with 84% similarity]
Source/JavaScriptCore/inspector/ConsoleTypes.h [moved from Source/WebCore/inspector/ConsoleAPITypes.h with 64% similarity]
Source/JavaScriptCore/inspector/IdentifiersFactory.cpp [moved from Source/WebCore/inspector/IdentifiersFactory.cpp with 93% similarity]
Source/JavaScriptCore/inspector/IdentifiersFactory.h [moved from Source/WebCore/inspector/IdentifiersFactory.h with 95% similarity]
Source/JavaScriptCore/inspector/JSGlobalObjectInspectorController.cpp
Source/JavaScriptCore/inspector/ScriptArguments.cpp [moved from Source/WebCore/inspector/ScriptArguments.cpp with 90% similarity]
Source/JavaScriptCore/inspector/ScriptArguments.h [moved from Source/WebCore/inspector/ScriptArguments.h with 90% similarity]
Source/JavaScriptCore/inspector/ScriptCallFrame.cpp [moved from Source/WebCore/inspector/ScriptCallFrame.cpp with 92% similarity]
Source/JavaScriptCore/inspector/ScriptCallFrame.h [moved from Source/WebCore/inspector/ScriptCallFrame.h with 93% similarity]
Source/JavaScriptCore/inspector/ScriptCallStack.cpp [moved from Source/WebCore/inspector/ScriptCallStack.cpp with 92% similarity]
Source/JavaScriptCore/inspector/ScriptCallStack.h [moved from Source/WebCore/inspector/ScriptCallStack.h with 89% similarity]
Source/JavaScriptCore/inspector/ScriptCallStackFactory.cpp [moved from Source/WebCore/bindings/js/ScriptCallStackFactory.cpp with 69% similarity]
Source/JavaScriptCore/inspector/ScriptCallStackFactory.h [moved from Source/WebCore/bindings/js/ScriptCallStackFactory.h with 69% similarity]
Source/JavaScriptCore/inspector/agents/InspectorConsoleAgent.cpp [moved from Source/WebCore/inspector/InspectorConsoleAgent.cpp with 62% similarity]
Source/JavaScriptCore/inspector/agents/InspectorConsoleAgent.h [new file with mode: 0644]
Source/JavaScriptCore/inspector/agents/JSGlobalObjectConsoleAgent.cpp [new file with mode: 0644]
Source/JavaScriptCore/inspector/agents/JSGlobalObjectConsoleAgent.h [new file with mode: 0644]
Source/JavaScriptCore/inspector/agents/JSGlobalObjectDebuggerAgent.cpp
Source/JavaScriptCore/inspector/agents/JSGlobalObjectDebuggerAgent.h
Source/JavaScriptCore/inspector/protocol/Console.json [moved from Source/WebCore/inspector/protocol/Console.json with 86% similarity]
Source/JavaScriptCore/inspector/scripts/generate-combined-inspector-json.py
Source/WebCore/CMakeLists.txt
Source/WebCore/ChangeLog
Source/WebCore/DerivedSources.make
Source/WebCore/ForwardingHeaders/inspector/ConsoleMessage.h [new file with mode: 0644]
Source/WebCore/ForwardingHeaders/inspector/ConsoleTypes.h [new file with mode: 0644]
Source/WebCore/ForwardingHeaders/inspector/IdentifiersFactory.h [new file with mode: 0644]
Source/WebCore/ForwardingHeaders/inspector/ScriptArguments.h [new file with mode: 0644]
Source/WebCore/ForwardingHeaders/inspector/ScriptCallFrame.h [new file with mode: 0644]
Source/WebCore/ForwardingHeaders/inspector/ScriptCallStack.h [new file with mode: 0644]
Source/WebCore/ForwardingHeaders/inspector/ScriptCallStackFactory.h [new file with mode: 0644]
Source/WebCore/ForwardingHeaders/inspector/agents/InspectorConsoleAgent.h [new file with mode: 0644]
Source/WebCore/GNUmakefile.am
Source/WebCore/GNUmakefile.list.am
Source/WebCore/Modules/indexeddb/IDBCursor.cpp
Source/WebCore/Modules/indexeddb/IDBDatabase.cpp
Source/WebCore/Modules/indexeddb/IDBTransaction.cpp
Source/WebCore/Modules/quota/DOMWindowQuota.cpp
Source/WebCore/Modules/webaudio/AudioBufferSourceNode.cpp
Source/WebCore/Modules/webaudio/AudioContext.cpp
Source/WebCore/Modules/webaudio/PannerNode.cpp
Source/WebCore/Modules/webdatabase/DatabaseBase.cpp
Source/WebCore/Modules/webdatabase/DatabaseManager.cpp
Source/WebCore/Modules/websockets/WebSocket.cpp
Source/WebCore/Modules/websockets/WebSocketChannel.cpp
Source/WebCore/Modules/websockets/WebSocketHandshake.cpp
Source/WebCore/UseJSC.cmake
Source/WebCore/WebCore.exp.in
Source/WebCore/WebCore.vcxproj/WebCore.vcxproj
Source/WebCore/WebCore.vcxproj/WebCore.vcxproj.filters
Source/WebCore/WebCore.xcodeproj/project.pbxproj
Source/WebCore/bindings/js/JSAudioContextCustom.cpp
Source/WebCore/bindings/js/JSBindingsAllInOne.cpp
Source/WebCore/bindings/js/JSCustomXPathNSResolver.cpp
Source/WebCore/bindings/js/JSDOMBinding.cpp
Source/WebCore/bindings/js/JSSubtleCryptoCustom.cpp
Source/WebCore/bindings/js/ScriptController.cpp
Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp
Source/WebCore/css/CSSParser.cpp
Source/WebCore/css/MediaList.cpp
Source/WebCore/dom/Document.cpp
Source/WebCore/dom/Document.h
Source/WebCore/dom/ScriptElement.cpp
Source/WebCore/dom/ScriptExecutionContext.cpp
Source/WebCore/dom/ScriptExecutionContext.h
Source/WebCore/dom/ViewportArguments.cpp
Source/WebCore/fileapi/Blob.cpp
Source/WebCore/fileapi/WebKitBlobBuilder.cpp
Source/WebCore/html/HTMLFormControlElement.cpp
Source/WebCore/html/HTMLFormElement.cpp
Source/WebCore/html/HTMLIFrameElement.cpp
Source/WebCore/html/HTMLMediaElement.cpp
Source/WebCore/html/canvas/CanvasRenderingContext2D.cpp
Source/WebCore/html/canvas/WebGLRenderingContext.cpp
Source/WebCore/html/parser/XSSAuditor.cpp
Source/WebCore/html/parser/XSSAuditorDelegate.cpp
Source/WebCore/inspector/CommandLineAPIHost.cpp
Source/WebCore/inspector/CommandLineAPIHost.h
Source/WebCore/inspector/InspectorAllInOne.cpp
Source/WebCore/inspector/InspectorConsoleAgent.h [deleted file]
Source/WebCore/inspector/InspectorConsoleInstrumentation.h
Source/WebCore/inspector/InspectorController.cpp
Source/WebCore/inspector/InspectorDOMAgent.cpp
Source/WebCore/inspector/InspectorFrontendHost.h
Source/WebCore/inspector/InspectorInstrumentation.cpp
Source/WebCore/inspector/InspectorInstrumentation.h
Source/WebCore/inspector/InspectorLayerTreeAgent.cpp
Source/WebCore/inspector/InspectorPageAgent.cpp
Source/WebCore/inspector/InspectorProfilerAgent.cpp
Source/WebCore/inspector/InspectorProfilerAgent.h
Source/WebCore/inspector/InspectorResourceAgent.cpp
Source/WebCore/inspector/InspectorTimelineAgent.cpp
Source/WebCore/inspector/InstrumentingAgents.cpp
Source/WebCore/inspector/InstrumentingAgents.h
Source/WebCore/inspector/PageConsoleAgent.cpp
Source/WebCore/inspector/PageConsoleAgent.h
Source/WebCore/inspector/PageDebuggerAgent.cpp
Source/WebCore/inspector/PageInjectedScriptHost.h
Source/WebCore/inspector/PageInjectedScriptManager.h
Source/WebCore/inspector/TimelineRecordFactory.cpp
Source/WebCore/inspector/WebConsoleAgent.cpp [new file with mode: 0644]
Source/WebCore/inspector/WebConsoleAgent.h [new file with mode: 0644]
Source/WebCore/inspector/WorkerConsoleAgent.cpp
Source/WebCore/inspector/WorkerConsoleAgent.h
Source/WebCore/inspector/WorkerDebuggerAgent.cpp
Source/WebCore/inspector/WorkerInspectorController.cpp
Source/WebCore/loader/DocumentLoader.cpp
Source/WebCore/loader/FrameLoader.cpp
Source/WebCore/loader/ImageLoader.cpp
Source/WebCore/loader/MixedContentChecker.cpp
Source/WebCore/loader/TextTrackLoader.cpp
Source/WebCore/loader/appcache/ApplicationCacheGroup.cpp
Source/WebCore/loader/cache/CachedResourceLoader.cpp
Source/WebCore/page/ChromeClient.h
Source/WebCore/page/Console.cpp
Source/WebCore/page/Console.h
Source/WebCore/page/ConsoleTypes.h [deleted file]
Source/WebCore/page/ContentSecurityPolicy.cpp
Source/WebCore/page/DOMSecurityPolicy.cpp
Source/WebCore/page/DOMWindow.cpp
Source/WebCore/page/DOMWindow.h
Source/WebCore/page/EventSource.cpp
Source/WebCore/page/PageConsole.cpp
Source/WebCore/page/PageConsole.h
Source/WebCore/page/PointerLockController.cpp
Source/WebCore/platform/CrossThreadCopier.h
Source/WebCore/rendering/shapes/ShapeInfo.cpp
Source/WebCore/svg/SVGDocumentExtensions.cpp
Source/WebCore/testing/Internals.cpp
Source/WebCore/workers/DefaultSharedWorkerRepository.cpp
Source/WebCore/workers/SharedWorkerGlobalScope.cpp
Source/WebCore/workers/SharedWorkerGlobalScope.h
Source/WebCore/workers/WorkerGlobalScope.cpp
Source/WebCore/workers/WorkerGlobalScope.h
Source/WebCore/workers/WorkerMessagingProxy.cpp
Source/WebCore/workers/WorkerReportingProxy.h
Source/WebCore/xml/XMLHttpRequest.cpp
Source/WebCore/xml/XSLTProcessorLibxslt.cpp
Source/WebInspectorUI/ChangeLog
Source/WebInspectorUI/UserInterface/InspectorJSBackendCommands.js
Source/WebInspectorUI/UserInterface/InspectorWebBackendCommands.js
Source/WebKit/gtk/ChangeLog
Source/WebKit/gtk/WebCoreSupport/ChromeClientGtk.cpp
Source/WebKit/mac/ChangeLog
Source/WebKit/mac/WebCoreSupport/WebChromeClient.h
Source/WebKit/mac/WebCoreSupport/WebChromeClient.mm
Source/WebKit/win/ChangeLog
Source/WebKit/win/WebCoreSupport/WebChromeClient.h
Source/WebKit/wince/ChangeLog
Source/WebKit/wince/WebCoreSupport/ChromeClientWinCE.h
Source/WebKit2/ChangeLog
Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h

index 847e06416ca88c9afac0af9180b1eaf12f56a55b..cf18367e1fc9ab7162d78b7ba7be469f391873e3 100644 (file)
@@ -1,3 +1,13 @@
+2014-02-06  Joseph Pecoraro  <pecoraro@apple.com>
+
+        Web Inspector: Add Console support to JSContext Inspection
+        https://bugs.webkit.org/show_bug.cgi?id=127941
+
+        Reviewed by Geoffrey Garen.
+
+        * inspector-protocol/page/deny-X-FrameOption-expected.txt:
+        Update with better line/column numbers now.
+
 2014-01-30  Oliver Hunt  <oliver@apple.com>
         Push DOM attributes into the prototype chain
         https://bugs.webkit.org/show_bug.cgi?id=127969
index e5871810f7eefc85e7384f8eb3c399f118d7eab7..81b16a49aeea094fcdbf02af750f22eb43d09ca6 100644 (file)
@@ -70,7 +70,7 @@ function test()
             "includeCommandLineAPI": false,
             "contextId": event.params.context.id,
             "doNotPauseOnExceptionsAndMuteConsole": false,
-            "returnByValue": false, 
+            "returnByValue": false,
             "generatePreview": false
         }, callback);
 
index bb735985e1b88d007b2d2110d76876da99fdd29b..30bac40ee099830acb62eab5281f1b576fbe5926 100644 (file)
@@ -13,17 +13,17 @@ console.error = consoleOutputHook.bind(InspectorTest, "error");
 console.info = consoleOutputHook.bind(InspectorTest, "info");
 
 InspectorTest.Output = {   // override in window.initialize_yourName
-    testComplete: function() 
+    testComplete: function()
     {
         RuntimeAgent.evaluate("didEvaluateForTestInFrontend(" + InspectorTest.completeTestCallId + ", \"\")", "test");
     },
 
-    addResult: function(text) 
+    addResult: function(text)
     {
         InspectorTest.evaluateInPage("output(unescape('" + escape(text) + "'))");
     },
     
-    clearResults: function() 
+    clearResults: function()
     {
         InspectorTest.evaluateInPage("clearOutput()");
     }
index 8352223846f62d8468901af8feb83b664fe304f0..c1f6168c77668befc9a449fc82bef3291e237dd7 100644 (file)
@@ -1,4 +1,4 @@
 CONSOLE MESSAGE: Refused to display 'deny-X-FrameOption.html' in a frame because it set 'X-Frame-Options' to 'deny'.
 
-deny-X-FrameOption.html:0:0
+deny-X-FrameOption.html:30:17
 
index ade9a5953bbc821c403a4040e66352c4960be744..08b9987d56327ff475c18f028bdce48f2a83d145 100644 (file)
@@ -227,7 +227,9 @@ set(JavaScriptCore_SOURCES
     heap/WriteBarrierBuffer.cpp
     heap/WriteBarrierSupport.cpp
 
+    inspector/ConsoleMessage.cpp
     inspector/ContentSearchUtilities.cpp
+    inspector/IdentifiersFactory.cpp
     inspector/InjectedScript.cpp
     inspector/InjectedScriptBase.cpp
     inspector/InjectedScriptHost.cpp
@@ -241,8 +243,13 @@ set(JavaScriptCore_SOURCES
     inspector/JSJavaScriptCallFrame.cpp
     inspector/JSJavaScriptCallFramePrototype.cpp
     inspector/JavaScriptCallFrame.cpp
+    inspector/ScriptArguments.cpp
+    inspector/ScriptCallFrame.cpp
+    inspector/ScriptCallStack.cpp
+    inspector/ScriptCallStackFactory.cpp
     inspector/ScriptDebugServer.cpp
     inspector/agents/InspectorAgent.cpp
+    inspector/agents/InspectorConsoleAgent.cpp
     inspector/agents/InspectorDebuggerAgent.cpp
     inspector/agents/InspectorRuntimeAgent.cpp
 
@@ -796,6 +803,7 @@ ADD_SOURCE_DEPENDENCIES(${CMAKE_CURRENT_SOURCE_DIR}/parser/Lexer.cpp ${DERIVED_S
 set(JavaScriptCore_INSPECTOR_SCRIPTS_DIR "${JAVASCRIPTCORE_DIR}/inspector/scripts")
 
 set(JavaScriptCore_INSPECTOR_DOMAINS
+    inspector/protocol/Console.json
     inspector/protocol/Debugger.json
     inspector/protocol/GenericTypes.json
     inspector/protocol/InspectorDomain.json
index 10520378ad41e1c1d6b4fca97fd759b9e1402b79..3af1e20b2d2ae142d6dfe235e15aa933210979f7 100644 (file)
@@ -1,3 +1,56 @@
+2014-02-06  Joseph Pecoraro  <pecoraro@apple.com>
+
+        Web Inspector: Add Console support to JSContext Inspection
+        https://bugs.webkit.org/show_bug.cgi?id=127941
+
+        Reviewed by Geoffrey Garen.
+
+        * CMakeLists.txt:
+        * DerivedSources.make:
+        * GNUmakefile.am:
+        * GNUmakefile.list.am:
+        * JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
+        * JavaScriptCore.xcodeproj/project.pbxproj:
+        Add new files.
+
+        * inspector/agents/InspectorConsoleAgent.cpp: Renamed from Source/WebCore/inspector/InspectorConsoleAgent.cpp.
+        * inspector/agents/InspectorConsoleAgent.h: Added.
+        New agent moved from WebCore. Rename a method to work in JS only context.
+
+        * inspector/JSGlobalObjectInspectorController.cpp:
+        (Inspector::JSGlobalObjectInspectorController::JSGlobalObjectInspectorController):
+        Instantiate ConsoleAgent.
+
+        * inspector/agents/JSGlobalObjectConsoleAgent.h: Copied from Source/WebCore/inspector/PageInjectedScriptHost.h.
+        * inspector/agents/JSGlobalObjectConsoleAgent.cpp: Copied from Source/WebCore/inspector/PageInjectedScriptHost.h.
+        (Inspector::JSGlobalObjectConsoleAgent::JSGlobalObjectConsoleAgent):
+        (Inspector::JSGlobalObjectConsoleAgent::setMonitoringXHREnabled):
+        (Inspector::JSGlobalObjectConsoleAgent::addInspectedNode):
+        (Inspector::JSGlobalObjectConsoleAgent::addInspectedHeapObject):
+        JSGlobalObject implementation.
+
+        * inspector/agents/JSGlobalObjectDebuggerAgent.h:
+        * inspector/agents/JSGlobalObjectDebuggerAgent.cpp:
+        (Inspector::JSGlobalObjectDebuggerAgent::JSGlobalObjectDebuggerAgent):
+        (Inspector::JSGlobalObjectDebuggerAgent::breakpointActionLog):
+        Use ConsoleAgent to report logs.
+
+        * inspector/ConsoleMessage.cpp: Renamed from Source/WebCore/inspector/ConsoleMessage.cpp.
+        * inspector/ConsoleMessage.h: Renamed from Source/WebCore/inspector/ConsoleMessage.h.
+        * inspector/ConsoleTypes.h: Copied from Source/WebCore/inspector/ConsoleAPITypes.h.
+        * inspector/IdentifiersFactory.cpp: Renamed from Source/WebCore/inspector/IdentifiersFactory.cpp.
+        * inspector/IdentifiersFactory.h: Renamed from Source/WebCore/inspector/IdentifiersFactory.h.
+        * inspector/ScriptArguments.cpp: Renamed from Source/WebCore/inspector/ScriptArguments.cpp.
+        * inspector/ScriptArguments.h: Renamed from Source/WebCore/inspector/ScriptArguments.h.
+        * inspector/ScriptCallFrame.cpp: Renamed from Source/WebCore/inspector/ScriptCallFrame.cpp.
+        * inspector/ScriptCallFrame.h: Renamed from Source/WebCore/inspector/ScriptCallFrame.h.
+        * inspector/ScriptCallStack.cpp: Renamed from Source/WebCore/inspector/ScriptCallStack.cpp.
+        * inspector/ScriptCallStack.h: Renamed from Source/WebCore/inspector/ScriptCallStack.h.
+        * inspector/ScriptCallStackFactory.cpp: Renamed from Source/WebCore/bindings/js/ScriptCallStackFactory.cpp.
+        * inspector/ScriptCallStackFactory.h: Renamed from Source/WebCore/bindings/js/ScriptCallStackFactory.h.
+        * inspector/protocol/Console.json: Renamed from Source/WebCore/inspector/protocol/Console.json.
+        * inspector/scripts/generate-combined-inspector-json.py:
+
 2014-02-06  Commit Queue  <commit-queue@webkit.org>
 
         Unreviewed, rolling out r163542.
index 1156e97fd8862557c9cf8d3b68bf4d03c3e8ba8f..6027466309bcafc1126337fa3183ffaff730f0f5 100644 (file)
@@ -83,6 +83,7 @@ udis86_itab.h: $(JavaScriptCore)/disassembler/udis86/itab.py $(JavaScriptCore)/d
 # Inspector interfaces
 
 INSPECTOR_DOMAINS = \
+    $(JavaScriptCore)/inspector/protocol/Console.json \
     $(JavaScriptCore)/inspector/protocol/Debugger.json \
     $(JavaScriptCore)/inspector/protocol/GenericTypes.json \
     $(JavaScriptCore)/inspector/protocol/InspectorDomain.json \
index fe5448ddc1bcfaa4c729a1cc00dea624319390a2..cc3bc190b79ddc417e748ad7105b181351822052 100644 (file)
@@ -202,6 +202,7 @@ EXTRA_DIST += \
        Source/JavaScriptCore/icu/LICENSE \
        Source/JavaScriptCore/icu/README \
        Source/JavaScriptCore/inspector/InjectedScriptSource.js \
+       Source/JavaScriptCore/inspector/protocol/Console.json \
        Source/JavaScriptCore/inspector/protocol/Debugger.json \
        Source/JavaScriptCore/inspector/protocol/GenericTypes.json \
        Source/JavaScriptCore/inspector/protocol/InspectorDomain.json \
@@ -243,6 +244,7 @@ endif
 # Inspector Interfaces
 
 JavaScriptCore_INSPECTOR_DOMAINS := \
+    $(JavaScriptCore)/inspector/protocol/Console.json \
     $(JavaScriptCore)/inspector/protocol/Debugger.json \
     $(JavaScriptCore)/inspector/protocol/GenericTypes.json \
     $(JavaScriptCore)/inspector/protocol/InspectorDomain.json \
index faf765ac5be79e2d405fa0d2d3de079a6dfc55e9..5f07efcc7f21ecda49f2aa5afc9cce67f471754e 100644 (file)
@@ -633,8 +633,13 @@ javascriptcore_sources += \
        Source/JavaScriptCore/icu/unicode/utf_old.h \
        Source/JavaScriptCore/icu/unicode/utypes.h \
        Source/JavaScriptCore/icu/unicode/uversion.h \
+       Source/JavaScriptCore/inspector/ConsoleMessage.cpp \
+       Source/JavaScriptCore/inspector/ConsoleMessage.h \
+       Source/JavaScriptCore/inspector/ConsoleTypes.h \
        Source/JavaScriptCore/inspector/ContentSearchUtilities.cpp \
        Source/JavaScriptCore/inspector/ContentSearchUtilities.h \
+       Source/JavaScriptCore/inspector/IdentifiersFactory.cpp \
+       Source/JavaScriptCore/inspector/IdentifiersFactory.h \
        Source/JavaScriptCore/inspector/InjectedScript.cpp \
        Source/JavaScriptCore/inspector/InjectedScript.h \
        Source/JavaScriptCore/inspector/InjectedScriptBase.cpp \
@@ -665,16 +670,26 @@ javascriptcore_sources += \
        Source/JavaScriptCore/inspector/JSJavaScriptCallFramePrototype.h \
        Source/JavaScriptCore/inspector/JavaScriptCallFrame.cpp \
        Source/JavaScriptCore/inspector/JavaScriptCallFrame.h \
+       Source/JavaScriptCore/inspector/ScriptArguments.cpp \
+       Source/JavaScriptCore/inspector/ScriptArguments.h \
        Source/JavaScriptCore/inspector/ScriptBreakpoint.h \
+       Source/JavaScriptCore/inspector/ScriptCallFrame.cpp \
+       Source/JavaScriptCore/inspector/ScriptCallFrame.h \
+       Source/JavaScriptCore/inspector/ScriptCallStack.cpp \
+       Source/JavaScriptCore/inspector/ScriptCallStack.h \
+       Source/JavaScriptCore/inspector/ScriptCallStackFactory.cpp \
+       Source/JavaScriptCore/inspector/ScriptCallStackFactory.h \
        Source/JavaScriptCore/inspector/ScriptDebugListener.h \
        Source/JavaScriptCore/inspector/ScriptDebugServer.cpp \
        Source/JavaScriptCore/inspector/ScriptDebugServer.h \
-       Source/JavaScriptCore/inspector/agents/InspectorAgent.h \
        Source/JavaScriptCore/inspector/agents/InspectorAgent.cpp \
-       Source/JavaScriptCore/inspector/agents/InspectorDebuggerAgent.h \
+       Source/JavaScriptCore/inspector/agents/InspectorAgent.h \
+       Source/JavaScriptCore/inspector/agents/InspectorConsoleAgent.cpp \
+       Source/JavaScriptCore/inspector/agents/InspectorConsoleAgent.h \
        Source/JavaScriptCore/inspector/agents/InspectorDebuggerAgent.cpp \
-       Source/JavaScriptCore/inspector/agents/InspectorRuntimeAgent.h \
+       Source/JavaScriptCore/inspector/agents/InspectorDebuggerAgent.h \
        Source/JavaScriptCore/inspector/agents/InspectorRuntimeAgent.cpp \
+       Source/JavaScriptCore/inspector/agents/InspectorRuntimeAgent.h \
        Source/JavaScriptCore/interpreter/AbstractPC.cpp \
        Source/JavaScriptCore/interpreter/AbstractPC.h \
        Source/JavaScriptCore/interpreter/CachedCall.h \
index 31ebe51177b3b7f161564f9ca13e50116240e27e..e56071fcc4b1d7fe72063a57d5c7f3154e615d57 100644 (file)
     <ClCompile Include="..\heap\WeakSet.cpp" />
     <ClCompile Include="..\heap\WriteBarrierBuffer.cpp" />
     <ClCompile Include="..\heap\WriteBarrierSupport.cpp" />
+    <ClCompile Include="..\inspector\ConsoleMessage.cpp" />
     <ClCompile Include="..\inspector\ContentSearchUtilities.cpp" />
+    <ClCompile Include="..\inspector\IdentifiersFactory.cpp" />
     <ClCompile Include="..\inspector\InjectedScript.cpp" />
     <ClCompile Include="..\inspector\InjectedScriptBase.cpp" />
     <ClCompile Include="..\inspector\InjectedScriptHost.cpp" />
     <ClCompile Include="..\inspector\JSJavaScriptCallFrame.cpp" />
     <ClCompile Include="..\inspector\JSJavaScriptCallFramePrototype.cpp" />
     <ClCompile Include="..\inspector\JavaScriptCallFrame.cpp" />
+    <ClCompile Include="..\inspector\ScriptArguments.cpp" />
+    <ClCompile Include="..\inspector\ScriptCallFrame.cpp" />
+    <ClCompile Include="..\inspector\ScriptCallStack.cpp" />
+    <ClCompile Include="..\inspector\ScriptCallStackFactory.cpp" />
     <ClCompile Include="..\inspector\ScriptDebugServer.cpp" />
     <ClCompile Include="..\inspector\agents\InspectorAgent.cpp" />
+    <ClCompile Include="..\inspector\agents\InspectorConsoleAgent.cpp" />
     <ClCompile Include="..\inspector\agents\InspectorDebuggerAgent.cpp" />
     <ClCompile Include="..\inspector\agents\InspectorRuntimeAgent.cpp" />
     <ClCompile Include="..\interpreter\AbstractPC.cpp" />
     <ClInclude Include="..\heap\WeakSetInlines.h" />
     <ClInclude Include="..\heap\WriteBarrierBuffer.h" />
     <ClInclude Include="..\heap\WriteBarrierSupport.h" />
+    <ClInclude Include="..\inspector\ConsoleMessage.h" />
+    <ClInclude Include="..\inspector\ConsoleTypes.h" />
     <ClInclude Include="..\inspector\ContentSearchUtilities.h" />
+    <ClInclude Include="..\inspector\IdentifiersFactory.h" />
     <ClInclude Include="..\inspector\InjectedScript.h" />
     <ClInclude Include="..\inspector\InjectedScriptBase.h" />
     <ClInclude Include="..\inspector\InjectedScriptHost.h" />
     <ClInclude Include="..\inspector\JSJavaScriptCallFrame.h" />
     <ClInclude Include="..\inspector\JSJavaScriptCallFramePrototype.h" />
     <ClInclude Include="..\inspector\JavaScriptCallFrame.h" />
+    <ClInclude Include="..\inspector\ScriptArguments.h" />
     <ClInclude Include="..\inspector\ScriptBreakpoint.h" />
+    <ClInclude Include="..\inspector\ScriptCallFrame.h" />
+    <ClInclude Include="..\inspector\ScriptCallStack.h" />
+    <ClInclude Include="..\inspector\ScriptCallStackFactory.h" />
     <ClInclude Include="..\inspector\ScriptDebugListener.h" />
     <ClInclude Include="..\inspector\ScriptDebugServer.h" />
     <ClInclude Include="..\inspector\agents\InspectorAgent.h" />
+    <ClInclude Include="..\inspector\agents\InspectorConsoleAgent.h" />
     <ClInclude Include="..\inspector\agents\InspectorDebuggerAgent.h" />
     <ClInclude Include="..\inspector\agents\InspectorRuntimeAgent.h" />
     <ClInclude Include="..\interpreter\AbstractPC.h" />
index 6b67a3fea32936b45e8d27c54652bd49e3ee298e..ad77424ec583cf81b67ecd530cc8a43c8f227e53 100644 (file)
                A5CEEE14187F3BAD00E55C99 /* InspectorAgent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5CEEE12187F3BAD00E55C99 /* InspectorAgent.cpp */; };
                A5CEEE15187F3BAD00E55C99 /* InspectorAgent.h in Headers */ = {isa = PBXBuildFile; fileRef = A5CEEE13187F3BAD00E55C99 /* InspectorAgent.h */; settings = {ATTRIBUTES = (Private, ); }; };
                A5D0A1BB1862301B00C7B496 /* InspectorEnvironment.h in Headers */ = {isa = PBXBuildFile; fileRef = A5D0A1BA1862301B00C7B496 /* InspectorEnvironment.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               A5FD0067189AFE9C00633231 /* ScriptArguments.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5FD0065189AFE9C00633231 /* ScriptArguments.cpp */; };
+               A5FD0068189AFE9C00633231 /* ScriptArguments.h in Headers */ = {isa = PBXBuildFile; fileRef = A5FD0066189AFE9C00633231 /* ScriptArguments.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               A5FD006D189B00AA00633231 /* ScriptCallFrame.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5FD0069189B00A900633231 /* ScriptCallFrame.cpp */; };
+               A5FD006E189B00AA00633231 /* ScriptCallFrame.h in Headers */ = {isa = PBXBuildFile; fileRef = A5FD006A189B00A900633231 /* ScriptCallFrame.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               A5FD006F189B00AA00633231 /* ScriptCallStack.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5FD006B189B00A900633231 /* ScriptCallStack.cpp */; };
+               A5FD0070189B00AA00633231 /* ScriptCallStack.h in Headers */ = {isa = PBXBuildFile; fileRef = A5FD006C189B00AA00633231 /* ScriptCallStack.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               A5FD0074189B038C00633231 /* ConsoleTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = A5FD0071189B038C00633231 /* ConsoleTypes.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               A5FD0075189B038C00633231 /* IdentifiersFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5FD0072189B038C00633231 /* IdentifiersFactory.cpp */; };
+               A5FD0076189B038C00633231 /* IdentifiersFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = A5FD0073189B038C00633231 /* IdentifiersFactory.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               A5FD0079189B051000633231 /* ConsoleMessage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5FD0077189B051000633231 /* ConsoleMessage.cpp */; };
+               A5FD007A189B051000633231 /* ConsoleMessage.h in Headers */ = {isa = PBXBuildFile; fileRef = A5FD0078189B051000633231 /* ConsoleMessage.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               A5FD007D189B0B4C00633231 /* ScriptCallStackFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5FD007B189B0B4C00633231 /* ScriptCallStackFactory.cpp */; };
+               A5FD007E189B0B4C00633231 /* ScriptCallStackFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = A5FD007C189B0B4C00633231 /* ScriptCallStackFactory.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               A5FD0081189B191A00633231 /* InspectorConsoleAgent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5FD007F189B191A00633231 /* InspectorConsoleAgent.cpp */; };
+               A5FD0082189B191A00633231 /* InspectorConsoleAgent.h in Headers */ = {isa = PBXBuildFile; fileRef = A5FD0080189B191A00633231 /* InspectorConsoleAgent.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               A5FD0085189B1B7E00633231 /* JSGlobalObjectConsoleAgent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5FD0083189B1B7E00633231 /* JSGlobalObjectConsoleAgent.cpp */; };
+               A5FD0086189B1B7E00633231 /* JSGlobalObjectConsoleAgent.h in Headers */ = {isa = PBXBuildFile; fileRef = A5FD0084189B1B7E00633231 /* JSGlobalObjectConsoleAgent.h */; };
                A700873917CBE85300C3E643 /* MapConstructor.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A700873717CBE85300C3E643 /* MapConstructor.cpp */; };
                A700873A17CBE85300C3E643 /* MapConstructor.h in Headers */ = {isa = PBXBuildFile; fileRef = A700873817CBE85300C3E643 /* MapConstructor.h */; };
                A700873D17CBE8D300C3E643 /* MapPrototype.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A700873B17CBE8D300C3E643 /* MapPrototype.cpp */; };
                A5CEEE12187F3BAD00E55C99 /* InspectorAgent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InspectorAgent.cpp; sourceTree = "<group>"; };
                A5CEEE13187F3BAD00E55C99 /* InspectorAgent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorAgent.h; sourceTree = "<group>"; };
                A5D0A1BA1862301B00C7B496 /* InspectorEnvironment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorEnvironment.h; sourceTree = "<group>"; };
+               A5FD0065189AFE9C00633231 /* ScriptArguments.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScriptArguments.cpp; sourceTree = "<group>"; };
+               A5FD0066189AFE9C00633231 /* ScriptArguments.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScriptArguments.h; sourceTree = "<group>"; };
+               A5FD0069189B00A900633231 /* ScriptCallFrame.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScriptCallFrame.cpp; sourceTree = "<group>"; };
+               A5FD006A189B00A900633231 /* ScriptCallFrame.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScriptCallFrame.h; sourceTree = "<group>"; };
+               A5FD006B189B00A900633231 /* ScriptCallStack.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScriptCallStack.cpp; sourceTree = "<group>"; };
+               A5FD006C189B00AA00633231 /* ScriptCallStack.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScriptCallStack.h; sourceTree = "<group>"; };
+               A5FD0071189B038C00633231 /* ConsoleTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ConsoleTypes.h; sourceTree = "<group>"; };
+               A5FD0072189B038C00633231 /* IdentifiersFactory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IdentifiersFactory.cpp; sourceTree = "<group>"; };
+               A5FD0073189B038C00633231 /* IdentifiersFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IdentifiersFactory.h; sourceTree = "<group>"; };
+               A5FD0077189B051000633231 /* ConsoleMessage.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ConsoleMessage.cpp; sourceTree = "<group>"; };
+               A5FD0078189B051000633231 /* ConsoleMessage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ConsoleMessage.h; sourceTree = "<group>"; };
+               A5FD007B189B0B4C00633231 /* ScriptCallStackFactory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScriptCallStackFactory.cpp; sourceTree = "<group>"; };
+               A5FD007C189B0B4C00633231 /* ScriptCallStackFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScriptCallStackFactory.h; sourceTree = "<group>"; };
+               A5FD007F189B191A00633231 /* InspectorConsoleAgent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InspectorConsoleAgent.cpp; sourceTree = "<group>"; };
+               A5FD0080189B191A00633231 /* InspectorConsoleAgent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorConsoleAgent.h; sourceTree = "<group>"; };
+               A5FD0083189B1B7E00633231 /* JSGlobalObjectConsoleAgent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSGlobalObjectConsoleAgent.cpp; sourceTree = "<group>"; };
+               A5FD0084189B1B7E00633231 /* JSGlobalObjectConsoleAgent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSGlobalObjectConsoleAgent.h; sourceTree = "<group>"; };
                A700873717CBE85300C3E643 /* MapConstructor.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MapConstructor.cpp; sourceTree = "<group>"; };
                A700873817CBE85300C3E643 /* MapConstructor.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MapConstructor.h; sourceTree = "<group>"; };
                A700873B17CBE8D300C3E643 /* MapPrototype.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MapPrototype.cpp; sourceTree = "<group>"; };
                        children = (
                                A5CEEE12187F3BAD00E55C99 /* InspectorAgent.cpp */,
                                A5CEEE13187F3BAD00E55C99 /* InspectorAgent.h */,
+                               A5FD007F189B191A00633231 /* InspectorConsoleAgent.cpp */,
+                               A5FD0080189B191A00633231 /* InspectorConsoleAgent.h */,
                                A57D23E31890CEBF0031C7FA /* InspectorDebuggerAgent.cpp */,
                                A57D23E41890CEBF0031C7FA /* InspectorDebuggerAgent.h */,
                                A50E4B5D18809DD50068A46D /* InspectorRuntimeAgent.cpp */,
                                A50E4B5E18809DD50068A46D /* InspectorRuntimeAgent.h */,
+                               A5FD0083189B1B7E00633231 /* JSGlobalObjectConsoleAgent.cpp */,
+                               A5FD0084189B1B7E00633231 /* JSGlobalObjectConsoleAgent.h */,
                                A57D23E71891B0770031C7FA /* JSGlobalObjectDebuggerAgent.cpp */,
                                A57D23E81891B0770031C7FA /* JSGlobalObjectDebuggerAgent.h */,
                                A50E4B5F18809DD50068A46D /* JSGlobalObjectRuntimeAgent.cpp */,
                                A513E5CC185FB992007E95AD /* agents */,
                                A5BA15E01823409D00A82E69 /* remote */,
                                A532438E185696CE002ED692 /* scripts */,
+                               A5FD0077189B051000633231 /* ConsoleMessage.cpp */,
+                               A5FD0078189B051000633231 /* ConsoleMessage.h */,
+                               A5FD0071189B038C00633231 /* ConsoleTypes.h */,
                                A57D23EF1891B5B40031C7FA /* ContentSearchUtilities.cpp */,
                                A57D23F01891B5B40031C7FA /* ContentSearchUtilities.h */,
                                A54982011891D0B00081E5B8 /* EventLoop.cpp */,
                                A54982021891D0B00081E5B8 /* EventLoop.h */,
+                               A5FD0072189B038C00633231 /* IdentifiersFactory.cpp */,
+                               A5FD0073189B038C00633231 /* IdentifiersFactory.h */,
                                A513E5B5185B8BD3007E95AD /* InjectedScript.cpp */,
                                A513E5B6185B8BD3007E95AD /* InjectedScript.h */,
                                A514B2C0185A684400F3C7CB /* InjectedScriptBase.cpp */,
                                A503FA18188E0FB000110F14 /* JSJavaScriptCallFramePrototype.h */,
                                A503FA13188E0FAF00110F14 /* JavaScriptCallFrame.cpp */,
                                A503FA14188E0FAF00110F14 /* JavaScriptCallFrame.h */,
+                               A5FD0065189AFE9C00633231 /* ScriptArguments.cpp */,
+                               A5FD0066189AFE9C00633231 /* ScriptArguments.h */,
                                A503FA1F188EFF6800110F14 /* ScriptBreakpoint.h */,
+                               A5FD0069189B00A900633231 /* ScriptCallFrame.cpp */,
+                               A5FD006A189B00A900633231 /* ScriptCallFrame.h */,
+                               A5FD006B189B00A900633231 /* ScriptCallStack.cpp */,
+                               A5FD006C189B00AA00633231 /* ScriptCallStack.h */,
+                               A5FD007B189B0B4C00633231 /* ScriptCallStackFactory.cpp */,
+                               A5FD007C189B0B4C00633231 /* ScriptCallStackFactory.h */,
                                A503FA20188EFF6800110F14 /* ScriptDebugListener.h */,
                                A503FA23188EFFFD00110F14 /* ScriptDebugServer.cpp */,
                                A503FA24188EFFFD00110F14 /* ScriptDebugServer.h */,
                                0F6B1CC61862C47800845D97 /* FTLUnwindInfo.h in Headers */,
                                C2239D1816262BDD005AC5FD /* CopyVisitor.h in Headers */,
                                C2239D1916262BDD005AC5FD /* CopyVisitorInlines.h in Headers */,
+                               A5FD007A189B051000633231 /* ConsoleMessage.h in Headers */,
                                C218D1401655CFD50062BB81 /* CopyWorkList.h in Headers */,
                                5DE6E5B30E1728EC00180407 /* create_hash_table in Headers */,
                                0F426A4B1460CD6E00131F8F /* DataFormat.h in Headers */,
                                0FFB921A16D02EC50055A5DB /* DFGBasicBlockInlines.h in Headers */,
                                A70B083317A0B79B00DAF14B /* DFGBinarySwitch.h in Headers */,
                                A7D89CF417A0B8CC00773AD8 /* DFGBlockInsertionSet.h in Headers */,
+                               A5FD006E189B00AA00633231 /* ScriptCallFrame.h in Headers */,
                                0F8364B7164B0C110053329A /* DFGBranchDirection.h in Headers */,
                                A1A009C01831A22D00CF8711 /* MacroAssemblerARM64.h in Headers */,
                                86EC9DC51328DF82002B2AD7 /* DFGByteCodeParser.h in Headers */,
                                A503FA1E188E0FB000110F14 /* JSJavaScriptCallFramePrototype.h in Headers */,
                                0F38B01A17CFE75500B144D3 /* DFGCompilationMode.h in Headers */,
                                0F3B3A1B153E68F4003ED0FF /* DFGConstantFoldingPhase.h in Headers */,
+                               A5FD0082189B191A00633231 /* InspectorConsoleAgent.h in Headers */,
                                0FBE0F7316C1DB050082C5E8 /* DFGCPSRethreadingPhase.h in Headers */,
                                A7D89CF617A0B8CC00773AD8 /* DFGCriticalEdgeBreakingPhase.h in Headers */,
                                0FFFC95A14EF90A900C72532 /* DFGCSEPhase.h in Headers */,
                                0F2BDC451522801B00CD8910 /* DFGMinifiedGraph.h in Headers */,
                                0F2E892D16D02BAF009E4FD2 /* DFGMinifiedID.h in Headers */,
                                0F2BDC461522802000CD8910 /* DFGMinifiedNode.h in Headers */,
+                               A5FD0068189AFE9C00633231 /* ScriptArguments.h in Headers */,
                                A737810E1799EA2E00817533 /* DFGNaturalLoops.h in Headers */,
                                86ECA3EA132DEF1C002B2AD7 /* DFGNode.h in Headers */,
                                0FFB921B16D02F010055A5DB /* DFGNodeAllocator.h in Headers */,
                                0F2BDC481522802900CD8910 /* DFGValueSource.h in Headers */,
                                0F620174143FCD330068B77C /* DFGVariableAccessData.h in Headers */,
                                0FDDBFB61666EEDA00C55FEF /* DFGVariableAccessDataDump.h in Headers */,
+                               A5FD0074189B038C00633231 /* ConsoleTypes.h in Headers */,
                                0F2BDC491522809600CD8910 /* DFGVariableEvent.h in Headers */,
                                0F2BDC4B1522809D00CD8910 /* DFGVariableEventStream.h in Headers */,
                                A514B2C3185A684400F3C7CB /* InjectedScriptBase.h in Headers */,
                                0FEA0A241709606900BB722C /* FTLIntrinsicRepository.h in Headers */,
                                0FEA0A0E170513DB00BB722C /* FTLJITCode.h in Headers */,
                                A78A9781179738D5009DF744 /* FTLJITFinalizer.h in Headers */,
+                               A5FD0076189B038C00633231 /* IdentifiersFactory.h in Headers */,
                                0F5A6284188C98D40072C9DF /* FTLValueRange.h in Headers */,
                                0F8F2B96172E04A3007DBDA5 /* FTLLink.h in Headers */,
                                0FCEFAE0180738C000472CE4 /* FTLLocation.h in Headers */,
                                A7A4AE1017973B4D005612B1 /* JITStubsX86Common.h in Headers */,
                                0F5EF91F16878F7D003E5C25 /* JITThunks.h in Headers */,
                                0FC712E317CD8793008CC93C /* JITToDFGDeferredCompilationCallback.h in Headers */,
+                               A5FD0070189B00AA00633231 /* ScriptCallStack.h in Headers */,
                                A76F54A313B28AAB00EF2BCE /* JITWriteBarrier.h in Headers */,
                                BC18C4160E16F5CD00B34460 /* JSActivation.h in Headers */,
                                0F6B1CB91861244C00845D97 /* ArityCheckMode.h in Headers */,
                                BC02E9110E1839DB000F9297 /* NativeErrorConstructor.h in Headers */,
                                BC02E9130E1839DB000F9297 /* NativeErrorPrototype.h in Headers */,
                                0FFB922016D033B70055A5DB /* NodeConstructors.h in Headers */,
+                               A5FD007E189B0B4C00633231 /* ScriptCallStackFactory.h in Headers */,
                                7EFF00640EC05A9A00AA7C93 /* NodeInfo.h in Headers */,
                                BC18C43F0E16F5CD00B34460 /* Nodes.h in Headers */,
                                BC18C4410E16F5CD00B34460 /* NumberConstructor.h in Headers */,
                                A7A8AF4117ADB5F3005AB174 /* Uint16Array.h in Headers */,
                                866739D313BFDE710023D87C /* Uint16WithFraction.h in Headers */,
                                A7A8AF4217ADB5F3005AB174 /* Uint32Array.h in Headers */,
+                               A5FD0086189B1B7E00633231 /* JSGlobalObjectConsoleAgent.h in Headers */,
                                A7A8AF3F17ADB5F3005AB174 /* Uint8Array.h in Headers */,
                                A7A8AF4017ADB5F3005AB174 /* Uint8ClampedArray.h in Headers */,
                                0F5F08CF146C7633000472A9 /* UnconditionalFinalizer.h in Headers */,
                                A790DD6F182F499700588807 /* JSSetIterator.cpp in Sources */,
                                0F63945415D07055006A597C /* ArrayProfile.cpp in Sources */,
                                147F39C0107EC37600427A48 /* ArrayPrototype.cpp in Sources */,
+                               A5FD006D189B00AA00633231 /* ScriptCallFrame.cpp in Sources */,
                                0F24E54017EA9F5900ABB217 /* AssemblyHelpers.cpp in Sources */,
                                14816E1B154CC56C00B8054C /* BlockAllocator.cpp in Sources */,
                                14280863107EC11A0013E7B2 /* BooleanConstructor.cpp in Sources */,
                                147F39C8107EC37600427A48 /* ErrorConstructor.cpp in Sources */,
                                147F39C9107EC37600427A48 /* ErrorInstance.cpp in Sources */,
                                147F39CA107EC37600427A48 /* ErrorPrototype.cpp in Sources */,
+                               A5FD0067189AFE9C00633231 /* ScriptArguments.cpp in Sources */,
                                1429D8780ED21ACD00B89619 /* ExceptionHelpers.cpp in Sources */,
                                86CA032E1038E8440028A609 /* Executable.cpp in Sources */,
                                A7B48F490EE8936F00DCBDB6 /* ExecutableAllocator.cpp in Sources */,
                                A78A9780179738D5009DF744 /* FTLJITFinalizer.cpp in Sources */,
                                0F8F2B95172E04A0007DBDA5 /* FTLLink.cpp in Sources */,
                                A74DEF95182D991400522C22 /* JSMapIterator.cpp in Sources */,
+                               A5FD0081189B191A00633231 /* InspectorConsoleAgent.cpp in Sources */,
                                0FCEFADF180738C000472CE4 /* FTLLocation.cpp in Sources */,
                                0FEA0A0F170513DB00BB722C /* FTLLowerDFGToLLVM.cpp in Sources */,
                                0FD8A31B17D51F2200CA2C40 /* FTLOSREntry.cpp in Sources */,
                                86E3C616167BABEE006D760A /* JSContext.mm in Sources */,
                                14BD5A300A3E91F600BAF59C /* JSContextRef.cpp in Sources */,
                                A72028B61797601E0098028C /* JSCTestRunnerUtils.cpp in Sources */,
+                               A5FD0075189B038C00633231 /* IdentifiersFactory.cpp in Sources */,
                                B59F89391891F29F00D5CCDC /* UnlinkedInstructionStream.cpp in Sources */,
+                               A5FD006F189B00AA00633231 /* ScriptCallStack.cpp in Sources */,
                                0F2B66EB17B6B5AB00A7AE3F /* JSDataView.cpp in Sources */,
                                0F2B66ED17B6B5AB00A7AE3F /* JSDataViewPrototype.cpp in Sources */,
                                978801401471AD920041B016 /* JSDateMath.cpp in Sources */,
                                148F21BC107EC54D0042EC2C /* Parser.cpp in Sources */,
                                93052C340FB792190048FDC3 /* ParserArena.cpp in Sources */,
                                0F9FC8C314E1B5FE00D52AE0 /* PolymorphicPutByIdList.cpp in Sources */,
+                               A5FD0085189B1B7E00633231 /* JSGlobalObjectConsoleAgent.cpp in Sources */,
                                0F98206016BFE38100240D02 /* PreciseJumpTargets.cpp in Sources */,
                                95742F650DD11F5A000917FB /* Profile.cpp in Sources */,
                                0FC97F35182020D7002C9B26 /* ProfiledCodeBlockJettisoningWatchpoint.cpp in Sources */,
                                C225494315F7DBAA0065E898 /* SlotVisitor.cpp in Sources */,
                                9330402C0E6A764000786E6A /* SmallStrings.cpp in Sources */,
                                0F8F2B9E17306C8D007DBDA5 /* SourceCode.cpp in Sources */,
+                               A5FD0079189B051000633231 /* ConsoleMessage.cpp in Sources */,
                                0F493AFA16D0CAD30084508B /* SourceProvider.cpp in Sources */,
                                E49DC16B12EF293E00184A1F /* SourceProviderCache.cpp in Sources */,
                                0F6B1CC918641DF800845D97 /* ArityCheckFailReturnThunks.cpp in Sources */,
                                C2DF442F1707AC0100A5CA96 /* SuperRegion.cpp in Sources */,
                                0F919D2815856773004A4E7D /* SymbolTable.cpp in Sources */,
                                0FC314131814559100033232 /* TempRegisterSet.cpp in Sources */,
+                               A5FD007D189B0B4C00633231 /* ScriptCallStackFactory.cpp in Sources */,
                                0FA2C17B17D7CF84009D015F /* TestRunnerUtils.cpp in Sources */,
                                A7386555118697B400540279 /* ThunkGenerators.cpp in Sources */,
                                0F2B670717B6B5AB00A7AE3F /* TypedArrayController.cpp in Sources */,
similarity index 69%
rename from Source/WebCore/inspector/ConsoleMessage.cpp
rename to Source/JavaScriptCore/inspector/ConsoleMessage.cpp
index d3b93ac5c7ca76c95fe9e6709bb6dd6dd66655da..b3a752a731e98f0f391c610b3e8bb43d8891d7ee 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.
+ * Copyright (C) 2007, 2008, 2014 Apple Inc. All rights reserved.
  * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com>
  * Copyright (C) 2009, 2010 Google Inc. All rights reserved.
  *
 
 #if ENABLE(INSPECTOR)
 
-#include "Console.h"
 #include "IdentifiersFactory.h"
+#include "InjectedScript.h"
+#include "InjectedScriptManager.h"
+#include "InspectorValues.h"
 #include "ScriptArguments.h"
 #include "ScriptCallFrame.h"
 #include "ScriptCallStack.h"
 #include "ScriptCallStackFactory.h"
-#include <bindings/ScriptValue.h>
-#include <inspector/InjectedScript.h>
-#include <inspector/InjectedScriptManager.h>
-#include <inspector/InspectorValues.h>
-#include <wtf/MainThread.h>
+#include "ScriptValue.h"
 
-using namespace Inspector;
-
-namespace WebCore {
+namespace Inspector {
 
 ConsoleMessage::ConsoleMessage(bool canGenerateCallStack, MessageSource source, MessageType type, MessageLevel level, const String& message, unsigned long requestIdentifier)
     : m_source(source)
@@ -116,15 +112,16 @@ ConsoleMessage::~ConsoleMessage()
 {
 }
 
-void ConsoleMessage::autogenerateMetadata(bool canGenerateCallStack, JSC::ExecState* state)
+// FIXME: Remove the generate without ExecState path. The caller should always provide an ExecState.
+void ConsoleMessage::autogenerateMetadata(bool /*canGenerateCallStack*/, JSC::ExecState* state)
 {
-    if (m_type == EndGroupMessageType)
+    if (m_type == MessageType::EndGroup)
         return;
 
     if (state)
         m_callStack = createScriptCallStackForConsole(state);
-    else if (canGenerateCallStack)
-        m_callStack = createScriptCallStack(ScriptCallStack::maxCallStackSizeToCapture, true);
+    // else if (canGenerateCallStack)
+    //     m_callStack = createScriptCallStack(ScriptCallStack::maxCallStackSizeToCapture, true);
     else
         return;
 
@@ -139,20 +136,19 @@ void ConsoleMessage::autogenerateMetadata(bool canGenerateCallStack, JSC::ExecSt
     m_callStack.clear();
 }
 
-// Keep in sync with inspector/front-end/ConsoleView.js
 static Inspector::TypeBuilder::Console::ConsoleMessage::Source::Enum messageSourceValue(MessageSource source)
 {
     switch (source) {
-    case XMLMessageSource: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::XML;
-    case JSMessageSource: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Javascript;
-    case NetworkMessageSource: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Network;
-    case ConsoleAPIMessageSource: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::ConsoleAPI;
-    case StorageMessageSource: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Storage;
-    case AppCacheMessageSource: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Appcache;
-    case RenderingMessageSource: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Rendering;
-    case CSSMessageSource: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::CSS;
-    case SecurityMessageSource: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Security;
-    case OtherMessageSource: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Other;
+    case MessageSource::XML: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::XML;
+    case MessageSource::JS: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Javascript;
+    case MessageSource::Network: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Network;
+    case MessageSource::ConsoleAPI: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::ConsoleAPI;
+    case MessageSource::Storage: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Storage;
+    case MessageSource::AppCache: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Appcache;
+    case MessageSource::Rendering: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Rendering;
+    case MessageSource::CSS: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::CSS;
+    case MessageSource::Security: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Security;
+    case MessageSource::Other: return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Other;
     }
     return Inspector::TypeBuilder::Console::ConsoleMessage::Source::Other;
 }
@@ -160,19 +156,19 @@ static Inspector::TypeBuilder::Console::ConsoleMessage::Source::Enum messageSour
 static Inspector::TypeBuilder::Console::ConsoleMessage::Type::Enum messageTypeValue(MessageType type)
 {
     switch (type) {
-    case LogMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Log;
-    case ClearMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Clear;
-    case DirMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Dir;
-    case DirXMLMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::DirXML;
-    case TableMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Table;
-    case TraceMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Trace;
-    case StartGroupMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::StartGroup;
-    case StartGroupCollapsedMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::StartGroupCollapsed;
-    case EndGroupMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::EndGroup;
-    case AssertMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Assert;
-    case TimingMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Timing;
-    case ProfileMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Profile;
-    case ProfileEndMessageType: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::ProfileEnd;
+    case MessageType::Log: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Log;
+    case MessageType::Clear: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Clear;
+    case MessageType::Dir: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Dir;
+    case MessageType::DirXML: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::DirXML;
+    case MessageType::Table: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Table;
+    case MessageType::Trace: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Trace;
+    case MessageType::StartGroup: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::StartGroup;
+    case MessageType::StartGroupCollapsed: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::StartGroupCollapsed;
+    case MessageType::EndGroup: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::EndGroup;
+    case MessageType::Assert: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Assert;
+    case MessageType::Timing: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Timing;
+    case MessageType::Profile: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Profile;
+    case MessageType::ProfileEnd: return Inspector::TypeBuilder::Console::ConsoleMessage::Type::ProfileEnd;
     }
     return Inspector::TypeBuilder::Console::ConsoleMessage::Type::Log;
 }
@@ -180,10 +176,10 @@ static Inspector::TypeBuilder::Console::ConsoleMessage::Type::Enum messageTypeVa
 static Inspector::TypeBuilder::Console::ConsoleMessage::Level::Enum messageLevelValue(MessageLevel level)
 {
     switch (level) {
-    case DebugMessageLevel: return Inspector::TypeBuilder::Console::ConsoleMessage::Level::Debug;
-    case LogMessageLevel: return Inspector::TypeBuilder::Console::ConsoleMessage::Level::Log;
-    case WarningMessageLevel: return Inspector::TypeBuilder::Console::ConsoleMessage::Level::Warning;
-    case ErrorMessageLevel: return Inspector::TypeBuilder::Console::ConsoleMessage::Level::Error;
+    case MessageLevel::Log: return Inspector::TypeBuilder::Console::ConsoleMessage::Level::Log;
+    case MessageLevel::Warning: return Inspector::TypeBuilder::Console::ConsoleMessage::Level::Warning;
+    case MessageLevel::Error: return Inspector::TypeBuilder::Console::ConsoleMessage::Level::Error;
+    case MessageLevel::Debug: return Inspector::TypeBuilder::Console::ConsoleMessage::Level::Debug;
     }
     return Inspector::TypeBuilder::Console::ConsoleMessage::Level::Log;
 }
@@ -194,19 +190,22 @@ void ConsoleMessage::addToFrontend(InspectorConsoleFrontendDispatcher* consoleFr
         .setSource(messageSourceValue(m_source))
         .setLevel(messageLevelValue(m_level))
         .setText(m_message);
+
     // FIXME: only send out type for ConsoleAPI source messages.
     jsonObj->setType(messageTypeValue(m_type));
     jsonObj->setLine(static_cast<int>(m_line));
     jsonObj->setColumn(static_cast<int>(m_column));
     jsonObj->setUrl(m_url);
     jsonObj->setRepeatCount(static_cast<int>(m_repeatCount));
-    if (m_source == NetworkMessageSource && !m_requestId.isEmpty())
+
+    if (m_source == MessageSource::Network && !m_requestId.isEmpty())
         jsonObj->setNetworkRequestId(m_requestId);
+
     if (m_arguments && m_arguments->argumentCount()) {
         InjectedScript injectedScript = injectedScriptManager->injectedScriptFor(m_arguments->globalState());
         if (!injectedScript.hasNoValue()) {
             RefPtr<Inspector::TypeBuilder::Array<Inspector::TypeBuilder::Runtime::RemoteObject>> jsonArgs = Inspector::TypeBuilder::Array<Inspector::TypeBuilder::Runtime::RemoteObject>::create();
-            if (m_type == TableMessageType && generatePreview && m_arguments->argumentCount()) {
+            if (m_type == MessageType::Table && generatePreview && m_arguments->argumentCount()) {
                 Deprecated::ScriptValue table = m_arguments->argumentAt(0);
                 Deprecated::ScriptValue columns = m_arguments->argumentCount() > 1 ? m_arguments->argumentAt(1) : Deprecated::ScriptValue();
                 RefPtr<Inspector::TypeBuilder::Runtime::RemoteObject> inspectorValue = injectedScript.wrapTable(table, columns);
@@ -228,8 +227,10 @@ void ConsoleMessage::addToFrontend(InspectorConsoleFrontendDispatcher* consoleFr
             jsonObj->setParameters(jsonArgs);
         }
     }
+
     if (m_callStack)
         jsonObj->setStackTrace(m_callStack->buildInspectorArray());
+
     consoleFrontendDispatcher->messageAdded(jsonObj);
 }
 
@@ -243,6 +244,7 @@ bool ConsoleMessage::isEqual(ConsoleMessage* msg) const
     if (m_arguments) {
         if (!m_arguments->isEqual(msg->m_arguments.get()))
             return false;
+
         // Never treat objects as equal - their properties might change over time.
         for (size_t i = 0; i < m_arguments->argumentCount(); ++i) {
             if (m_arguments->argumentAt(i).isObject())
@@ -267,24 +269,31 @@ bool ConsoleMessage::isEqual(ConsoleMessage* msg) const
         && msg->m_requestId == m_requestId;
 }
 
-void ConsoleMessage::windowCleared(DOMWindow* window)
+void ConsoleMessage::clear()
 {
-    if (!m_arguments)
-        return;
-    if (domWindowFromExecState(m_arguments->globalState()) != window)
-        return;
     if (!m_message)
-        m_message = "<message collected>";
-    m_arguments.clear();
+        m_message = ASCIILiteral("<message collected>");
+
+    if (m_arguments)
+        m_arguments.clear();
+}
+
+JSC::ExecState* ConsoleMessage::scriptState() const
+{
+    if (m_arguments)
+        return m_arguments->globalState();
+
+    return nullptr;
 }
 
-unsigned ConsoleMessage::argumentCount()
+unsigned ConsoleMessage::argumentCount() const
 {
     if (m_arguments)
         return m_arguments->argumentCount();
+
     return 0;
 }
 
-} // namespace WebCore
+} // namespace Inspector
 
 #endif // ENABLE(INSPECTOR)
similarity index 84%
rename from Source/WebCore/inspector/ConsoleMessage.h
rename to Source/JavaScriptCore/inspector/ConsoleMessage.h
index 1a1eaa117635d61c8018d8a2e548248ed47c4901..498eb1fa1766c6ad5cbc36c192410256a3ff7c0f 100644 (file)
 #ifndef ConsoleMessage_h
 #define ConsoleMessage_h
 
-#include "ConsoleAPITypes.h"
+#if ENABLE(INSPECTOR)
+
 #include "ConsoleTypes.h"
-#include "InspectorWebFrontendDispatchers.h"
-#include "ScriptState.h"
+#include "InspectorJSFrontendDispatchers.h"
 #include <wtf/Forward.h>
-#include <wtf/Vector.h>
 
-namespace Inspector {
-class InjectedScriptManager;
-class InspectorObject;
+namespace JSC {
+class ExecState;
 }
 
-namespace WebCore {
+namespace Inspector {
 
-class DOMWindow;
+class InjectedScriptManager;
 class ScriptArguments;
-class ScriptCallFrame;
 class ScriptCallStack;
 
-class ConsoleMessage {
-    WTF_MAKE_NONCOPYABLE(ConsoleMessage); WTF_MAKE_FAST_ALLOCATED;
+class JS_EXPORT_PRIVATE ConsoleMessage {
+    WTF_MAKE_NONCOPYABLE(ConsoleMessage);
+    WTF_MAKE_FAST_ALLOCATED;
 public:
     ConsoleMessage(bool canGenerateCallStack, MessageSource, MessageType, MessageLevel, const String& message, unsigned long requestIdentifier = 0);
     ConsoleMessage(bool canGenerateCallStack, MessageSource, MessageType, MessageLevel, const String& message, const String& url, unsigned line, unsigned column, JSC::ExecState* = nullptr, unsigned long requestIdentifier = 0);
@@ -59,18 +57,21 @@ public:
     ConsoleMessage(bool canGenerateCallStack, MessageSource, MessageType, MessageLevel, const String& message, PassRefPtr<ScriptArguments>, JSC::ExecState*, unsigned long requestIdentifier = 0);
     ~ConsoleMessage();
 
-    void addToFrontend(Inspector::InspectorConsoleFrontendDispatcher*, Inspector::InjectedScriptManager*, bool generatePreview);
-    void updateRepeatCountInConsole(Inspector::InspectorConsoleFrontendDispatcher*);
-    void incrementCount() { ++m_repeatCount; }
-    bool isEqual(ConsoleMessage* msg) const;
+    void addToFrontend(InspectorConsoleFrontendDispatcher*, InjectedScriptManager*, bool generatePreview);
+    void updateRepeatCountInConsole(InspectorConsoleFrontendDispatcher*);
 
     MessageSource source() const { return m_source; }
     const String& message() const { return m_message; }
     MessageType type() const { return m_type; }
+    JSC::ExecState* scriptState() const;
+
+    void incrementCount() { ++m_repeatCount; }
 
-    void windowCleared(DOMWindow*);
+    unsigned argumentCount() const;
 
-    unsigned argumentCount();
+    bool isEqual(ConsoleMessage* msg) const;
+
+    void clear();
 
 private:
     void autogenerateMetadata(bool canGenerateCallStack, JSC::ExecState* = nullptr);
@@ -88,6 +89,8 @@ private:
     String m_requestId;
 };
 
-} // namespace WebCore
+} // namespace Inspector
 
 #endif // ConsoleMessage_h
+
+#endif // ENABLE(INSPECTOR)
similarity index 64%
rename from Source/WebCore/inspector/ConsoleAPITypes.h
rename to Source/JavaScriptCore/inspector/ConsoleTypes.h
index 11f65ec210c9e2d7102941ca155b834a74fd383c..1c9409d1ff78411cf781f78e56a63c9f39497e21 100644 (file)
@@ -1,4 +1,5 @@
 /*
+ * Copyright (C) 2011 Apple Inc. All rights reserved.
  * Copyright (C) 2012 Google Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-#ifndef ConsoleAPITypes_h
-#define ConsoleAPITypes_h
-
-namespace WebCore {
-
-enum MessageType {
-    LogMessageType,
-    DirMessageType,
-    DirXMLMessageType,
-    TableMessageType,
-    TraceMessageType,
-    StartGroupMessageType,
-    StartGroupCollapsedMessageType,
-    EndGroupMessageType,
-    ClearMessageType,
-    AssertMessageType,
-    TimingMessageType,
-    ProfileMessageType,
-    ProfileEndMessageType
+#ifndef ConsoleTypes_h
+#define ConsoleTypes_h
+
+namespace Inspector {
+
+enum class MessageSource {
+    XML,
+    JS,
+    Network,
+    ConsoleAPI,
+    Storage,
+    AppCache,
+    Rendering,
+    CSS,
+    Security,
+    Other,
+};
+
+enum class MessageType {
+    Log,
+    Dir,
+    DirXML,
+    Table,
+    Trace,
+    StartGroup,
+    StartGroupCollapsed,
+    EndGroup,
+    Clear,
+    Assert,
+    Timing,
+    Profile,
+    ProfileEnd,
 };
 
-} // namespace WebCore
+enum class MessageLevel {
+    Log = 1,
+    Warning = 2,
+    Error = 3,
+    Debug = 4,
+};
+
+} // namespace Inspector
+
+// These will likely move out of the inspector namespace.
+using Inspector::MessageSource;
+using Inspector::MessageType;
+using Inspector::MessageLevel;
 
-#endif // ConsoleAPITypes_h
+#endif // ConsoleTypes_h
similarity index 93%
rename from Source/WebCore/inspector/IdentifiersFactory.cpp
rename to Source/JavaScriptCore/inspector/IdentifiersFactory.cpp
index dce2a2850e3756276315bd89874ce95920d72b28..4fbb331248cd3c73dababc8b787eef992dd5d74d 100644 (file)
@@ -1,4 +1,5 @@
 /*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
  * Copyright (C) 2011 Google Inc.  All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  */
 
 #include "config.h"
+#include "IdentifiersFactory.h"
 
 #if ENABLE(INSPECTOR)
 
-#include "IdentifiersFactory.h"
-
 #include <wtf/text/StringBuilder.h>
 
-namespace WebCore {
+namespace Inspector {
 
 namespace {
 static long s_lastUsedIdentifier = 0;
 }
 
-// static
-long IdentifiersFactory::s_processId;
+long IdentifiersFactory::s_processId = 0;
 
-// static
 String IdentifiersFactory::createIdentifier()
 {
     return addProcessIdPrefixTo(String::number(++s_lastUsedIdentifier));
 }
 
-// static
 String IdentifiersFactory::requestId(unsigned long identifier)
 {
     if (identifier)
@@ -54,7 +51,6 @@ String IdentifiersFactory::requestId(unsigned long identifier)
     return String();
 }
 
-// static
 String IdentifiersFactory::addProcessIdPrefixTo(const String& id)
 {
     StringBuilder builder;
@@ -64,6 +60,6 @@ String IdentifiersFactory::addProcessIdPrefixTo(const String& id)
     return builder.toString();
 }
 
-} // namespace WebCore
+} // namespace Inspector
 
 #endif // ENABLE(INSPECTOR)
similarity index 95%
rename from Source/WebCore/inspector/IdentifiersFactory.h
rename to Source/JavaScriptCore/inspector/IdentifiersFactory.h
index b1a9c48b2229031d6c34d18941e5d4da08e41ef7..b284aad3536df4444f62533d66bc44447191d598 100644 (file)
 #ifndef IdentifiersFactory_h
 #define IdentifiersFactory_h
 
-#include <wtf/text/WTFString.h>
-
 #if ENABLE(INSPECTOR)
 
-namespace WebCore {
+#include <wtf/text/WTFString.h>
 
-class IdentifiersFactory {
+namespace Inspector {
+
+class JS_EXPORT_PRIVATE IdentifiersFactory {
 public:
     static void setProcessId(long processId) { s_processId = processId; }
     static String createIdentifier();
     static String requestId(unsigned long identifier);
+
 private:
     static String addProcessIdPrefixTo(const String& id);
 
     static long s_processId;
 };
 
-} // namespace WebCore
+} // namespace Inspector
 
 #endif // !defined(IdentifiersFactory_h)
 
index 424a87fc9dad65781d11d448a9f7d0eba2fb9894..75dbdb7ba5c7b47acfff050e77ab61c25da084bb 100644 (file)
@@ -35,6 +35,7 @@
 #include "InspectorBackendDispatcher.h"
 #include "InspectorFrontendChannel.h"
 #include "JSGlobalObject.h"
+#include "JSGlobalObjectConsoleAgent.h"
 #include "JSGlobalObjectDebuggerAgent.h"
 #include "JSGlobalObjectRuntimeAgent.h"
 
@@ -53,7 +54,11 @@ JSGlobalObjectInspectorController::JSGlobalObjectInspectorController(JSGlobalObj
     InspectorRuntimeAgent* runtimeAgent = runtimeAgentPtr.get();
     m_agents.append(std::move(runtimeAgentPtr));
 
-    auto debuggerAgentPtr = std::make_unique<JSGlobalObjectDebuggerAgent>(m_injectedScriptManager.get(), m_globalObject);
+    auto consoleAgentPtr = std::make_unique<JSGlobalObjectConsoleAgent>(m_injectedScriptManager.get());
+    InspectorConsoleAgent* consoleAgent = consoleAgentPtr.get();
+    m_agents.append(std::move(consoleAgentPtr));
+
+    auto debuggerAgentPtr = std::make_unique<JSGlobalObjectDebuggerAgent>(m_injectedScriptManager.get(), m_globalObject, consoleAgent);
     InspectorDebuggerAgent* debuggerAgent = debuggerAgentPtr.get();
     m_agents.append(std::move(debuggerAgentPtr));
 
similarity index 90%
rename from Source/WebCore/inspector/ScriptArguments.cpp
rename to Source/JavaScriptCore/inspector/ScriptArguments.cpp
index 9e65f7ef9077781fa7d5fa0c37806ab014ae5238..15f14da2483cb6c4c3a9ed36df308ee77ca831b2 100644 (file)
@@ -1,10 +1,11 @@
 /*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
  * Copyright (c) 2010 Google Inc. All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions are
  * met:
- * 
+ *
  *     * Redistributions of source code must retain the above copyright
  * notice, this list of conditions and the following disclaimer.
  *     * Redistributions in binary form must reproduce the above
@@ -14,7 +15,7 @@
  *     * Neither the name of Google Inc. nor the names of its
  * contributors may be used to endorse or promote products derived from
  * this software without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 #include "config.h"
 #include "ScriptArguments.h"
 
-#include <bindings/ScriptValue.h>
+#include "ScriptValue.h"
 
-namespace WebCore {
+namespace Inspector {
 
 PassRefPtr<ScriptArguments> ScriptArguments::create(JSC::ExecState* scriptState, Vector<Deprecated::ScriptValue>& arguments)
 {
     return adoptRef(new ScriptArguments(scriptState, arguments));
 }
 
-ScriptArguments::ScriptArguments(JSC::ExecState* scriptState, Vector<Deprecated::ScriptValue>& arguments)
-    : m_globalObject(scriptState->vm(), scriptState->lexicalGlobalObject())
+ScriptArguments::ScriptArguments(JSC::ExecState* execState, Vector<Deprecated::ScriptValue>& arguments)
+    : m_globalObject(execState->vm(), execState->lexicalGlobalObject())
 {
     m_arguments.swap(arguments);
 }
@@ -60,6 +61,7 @@ JSC::ExecState* ScriptArguments::globalState() const
 {
     if (m_globalObject)
         return const_cast<JSC::JSGlobalObject*>(m_globalObject.get())->globalExec();
+
     return nullptr;
 }
 
@@ -95,7 +97,8 @@ bool ScriptArguments::isEqual(ScriptArguments* other) const
         if (!m_arguments[i].isEqual(other->globalState(), other->m_arguments[i]))
             return false;
     }
+
     return true;
 }
 
-} // namespace WebCore
+} // namespace Inspector
similarity index 90%
rename from Source/WebCore/inspector/ScriptArguments.h
rename to Source/JavaScriptCore/inspector/ScriptArguments.h
index 47a96238b783e9ce8b923cab70ac8da64903a71a..5337e019e09c39517803b84d779fdbfa3212a790 100644 (file)
@@ -1,4 +1,5 @@
 /*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
  * Copyright (c) 2010 Google Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -46,12 +47,11 @@ class ExecState;
 class JSGlobalObject;
 }
 
-namespace WebCore {
+namespace Inspector {
 
-class ScriptArguments : public RefCounted<ScriptArguments> {
+class JS_EXPORT_PRIVATE ScriptArguments : public RefCounted<ScriptArguments> {
 public:
     static PassRefPtr<ScriptArguments> create(JSC::ExecState*, Vector<Deprecated::ScriptValue>& arguments);
-
     ~ScriptArguments();
 
     const Deprecated::ScriptValue& argumentAt(size_t) const;
@@ -59,7 +59,7 @@ public:
 
     JSC::ExecState* globalState() const;
 
-    bool getFirstArgumentAsString(WTF::String& result, bool checkForNullOrUndefined = false);
+    bool getFirstArgumentAsString(String& result, bool checkForNullOrUndefined = false);
     bool isEqual(ScriptArguments*) const;
 
 private:
@@ -69,6 +69,6 @@ private:
     Vector<Deprecated::ScriptValue> m_arguments;
 };
 
-} // namespace WebCore
+} // namespace Inspector
 
 #endif // ScriptArguments_h
similarity index 92%
rename from Source/WebCore/inspector/ScriptCallFrame.cpp
rename to Source/JavaScriptCore/inspector/ScriptCallFrame.cpp
index 69c28f99f447a08111432d68ab03b884908f3628..c7a822ef9ef439952ab7ff20b84459eb81fa11d3 100644 (file)
@@ -1,10 +1,11 @@
 /*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
  * Copyright (c) 2010 Google Inc. All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions are
  * met:
- * 
+ *
  *     * Redistributions of source code must retain the above copyright
  * notice, this list of conditions and the following disclaimer.
  *     * Redistributions in binary form must reproduce the above
@@ -14,7 +15,7 @@
  *     * Neither the name of Google Inc. nor the names of its
  * contributors may be used to endorse or promote products derived from
  * this software without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 #include "config.h"
 #include "ScriptCallFrame.h"
 
-#include "InspectorWebFrontendDispatchers.h"
-#include <inspector/InspectorValues.h>
-#include <wtf/RefPtr.h>
+#include "InspectorValues.h"
+#include <wtf/PassRefPtr.h>
 
-using namespace Inspector;
-
-namespace WebCore {
+namespace Inspector {
 
 ScriptCallFrame::ScriptCallFrame(const String& functionName, const String& scriptName, unsigned lineNumber, unsigned column)
     : m_functionName(functionName)
@@ -71,4 +69,4 @@ PassRefPtr<Inspector::TypeBuilder::Console::CallFrame> ScriptCallFrame::buildIns
 }
 #endif
 
-} // namespace WebCore
+} // namespace Inspector
similarity index 93%
rename from Source/WebCore/inspector/ScriptCallFrame.h
rename to Source/JavaScriptCore/inspector/ScriptCallFrame.h
index d6dcfa3f2b1824efd25db7b29263b34ff6802488..00524dc501d0eb35b8db3e421cf6d46f9dfbfbbc 100644 (file)
@@ -1,10 +1,11 @@
 /*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
  * Copyright (c) 2010 Google Inc. All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions are
  * met:
- * 
+ *
  *     * Redistributions of source code must retain the above copyright
  * notice, this list of conditions and the following disclaimer.
  *     * Redistributions in binary form must reproduce the above
@@ -14,7 +15,7 @@
  *     * Neither the name of Google Inc. nor the names of its
  * contributors may be used to endorse or promote products derived from
  * this software without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 #ifndef ScriptCallFrame_h
 #define ScriptCallFrame_h
 
-#if ENABLE(INSPECTOR)
-#include "InspectorWebTypeBuilders.h"
-#endif
-
 #include <wtf/Forward.h>
 #include <wtf/text/WTFString.h>
 
-namespace Inspector {
-class InspectorObject;
-}
+#if ENABLE(INSPECTOR)
+#include "InspectorJSTypeBuilders.h"
+#endif
 
-namespace WebCore {
+namespace Inspector {
 
-class ScriptCallFrame  {
+class JS_EXPORT_PRIVATE ScriptCallFrame  {
 public:
     ScriptCallFrame(const String& functionName, const String& scriptName, unsigned lineNumber, unsigned column);
     ~ScriptCallFrame();
@@ -67,6 +64,6 @@ private:
     unsigned m_column;
 };
 
-} // namespace WebCore
+} // namespace Inspector
 
 #endif // ScriptCallFrame_h
similarity index 92%
rename from Source/WebCore/inspector/ScriptCallStack.cpp
rename to Source/JavaScriptCore/inspector/ScriptCallStack.cpp
index c4af1b426eb49e2b8c9075e885417ec3806e0e33..2dd285f6a524dc10648cbb0f36db06e559ae08e7 100644 (file)
@@ -1,10 +1,11 @@
 /*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
  * Copyright (c) 2008, Google Inc. All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions are
  * met:
- * 
+ *
  *     * Redistributions of source code must retain the above copyright
  * notice, this list of conditions and the following disclaimer.
  *     * Redistributions in binary form must reproduce the above
@@ -14,7 +15,7 @@
  *     * Neither the name of Google Inc. nor the names of its
  * contributors may be used to endorse or promote products derived from
  * this software without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 #include "config.h"
 #include "ScriptCallStack.h"
 
-#include "InspectorWebTypeBuilders.h"
-#include <inspector/InspectorValues.h>
+#include "InspectorValues.h"
 
-using namespace Inspector;
-
-namespace WebCore {
+namespace Inspector {
 
 PassRefPtr<ScriptCallStack> ScriptCallStack::create(Vector<ScriptCallFrame>& frames)
 {
@@ -52,7 +50,7 @@ ScriptCallStack::~ScriptCallStack()
 {
 }
 
-const ScriptCallFrame &ScriptCallStack::at(size_t index) const
+const ScriptCallFrameScriptCallStack::at(size_t index) const
 {
     ASSERT(m_frames.size() > index);
     return m_frames[index];
@@ -90,4 +88,4 @@ PassRefPtr<Inspector::TypeBuilder::Array<Inspector::TypeBuilder::Console::CallFr
 }
 #endif
 
-} // namespace WebCore
+} // namespace Inspector
similarity index 89%
rename from Source/WebCore/inspector/ScriptCallStack.h
rename to Source/JavaScriptCore/inspector/ScriptCallStack.h
index 1975da5c861f0433c49ab7d12587b4f5e4704f72..ddaa2bf9b9f5ab902d1e02b8545140f90500d8a5 100644 (file)
@@ -1,10 +1,11 @@
 /*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
  * Copyright (c) 2008, 2010 Google Inc. All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions are
  * met:
- * 
+ *
  *     * Redistributions of source code must retain the above copyright
  * notice, this list of conditions and the following disclaimer.
  *     * Redistributions in binary form must reproduce the above
@@ -14,7 +15,7 @@
  *     * Neither the name of Google Inc. nor the names of its
  * contributors may be used to endorse or promote products derived from
  * this software without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 #ifndef ScriptCallStack_h
 #define ScriptCallStack_h
 
-#if ENABLE(INSPECTOR)
-#include "InspectorWebTypeBuilders.h"
-#endif
-
 #include "ScriptCallFrame.h"
 #include <wtf/Forward.h>
 #include <wtf/RefCounted.h>
 #include <wtf/Vector.h>
 
-namespace WebCore {
+#if ENABLE(INSPECTOR)
+#include "InspectorJSTypeBuilders.h"
+#endif
+
+namespace Inspector {
 
-class ScriptCallStack : public RefCounted<ScriptCallStack> {
+class JS_EXPORT_PRIVATE ScriptCallStack : public RefCounted<ScriptCallStack> {
 public:
     static const size_t maxCallStackSizeToCapture = 200;
     
@@ -50,7 +51,7 @@ public:
 
     ~ScriptCallStack();
 
-    const ScriptCallFrame &at(size_t) const;
+    const ScriptCallFrameat(size_t) const;
     size_t size() const;
 
     bool isEqual(ScriptCallStack*) const;
@@ -65,6 +66,6 @@ private:
     Vector<ScriptCallFrame> m_frames;
 };
 
-} // namespace WebCore
+} // namespace Inspector
 
 #endif // ScriptCallStack_h
similarity index 69%
rename from Source/WebCore/bindings/js/ScriptCallStackFactory.cpp
rename to Source/JavaScriptCore/inspector/ScriptCallStackFactory.cpp
index 7d695a4449514458a0c9f7e23c894e73de74ea56..3b13dfc41f6b5057b3cf386e7af65100c4f9831b 100644 (file)
@@ -1,11 +1,12 @@
 /*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
  * Copyright (c) 2010 Google Inc. All rights reserved.
  * Copyright (C) 2012 Research In Motion Limited. All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions are
  * met:
- * 
+ *
  *     * Redistributions of source code must retain the above copyright
  * notice, this list of conditions and the following disclaimer.
  *     * Redistributions in binary form must reproduce the above
@@ -15,7 +16,7 @@
  *     * Neither the name of Google Inc. nor the names of its
  * contributors may be used to endorse or promote products derived from
  * this software without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 #include "config.h"
 #include "ScriptCallStackFactory.h"
 
-#include "InspectorInstrumentation.h"
-#include "JSDOMBinding.h"
-#include "JSMainThreadExecState.h"
+#include "ArgList.h"
+#include "CallFrame.h"
+#include "CallFrameInlines.h"
+#include "JSCJSValue.h"
+#include "JSFunction.h"
 #include "ScriptArguments.h"
 #include "ScriptCallFrame.h"
 #include "ScriptCallStack.h"
-#include <bindings/ScriptValue.h>
-#include <interpreter/CallFrame.h>
-#include <interpreter/CallFrameInlines.h>
-#include <interpreter/StackVisitor.h>
-#include <runtime/ArgList.h>
-#include <runtime/JSCJSValue.h>
-#include <runtime/JSFunction.h>
-#include <runtime/VM.h>
+#include "ScriptValue.h"
+#include "StackVisitor.h"
+#include "VM.h"
+#include <wtf/RefCountedArray.h>
 #include <wtf/text/WTFString.h>
 
 using namespace JSC;
 
-namespace WebCore {
-
-class ScriptExecutionContext;
+namespace Inspector {
 
 class CreateScriptCallStackFunctor {
 public:
-    CreateScriptCallStackFunctor(Vector<ScriptCallFrame>& frames,  size_t remainingCapacity)
-        : m_frames(frames)
+    CreateScriptCallStackFunctor(bool needToSkipAFrame, Vector<ScriptCallFrame>& frames, size_t remainingCapacity)
+        : m_needToSkipAFrame(needToSkipAFrame)
+        , m_frames(frames)
         , m_remainingCapacityForFrameCapture(remainingCapacity)
     {
     }
 
     StackVisitor::Status operator()(StackVisitor& visitor)
     {
+        if (m_needToSkipAFrame) {
+            m_needToSkipAFrame = false;
+            return StackVisitor::Continue;
+        }
+
         if (m_remainingCapacityForFrameCapture) {
             unsigned line;
             unsigned column;
@@ -73,85 +76,58 @@ public:
             m_remainingCapacityForFrameCapture--;
             return StackVisitor::Continue;
         }
+
         return StackVisitor::Done;
     }
 
 private:
+    bool m_needToSkipAFrame;
     Vector<ScriptCallFrame>& m_frames;
     size_t m_remainingCapacityForFrameCapture;
 };
 
-PassRefPtr<ScriptCallStack> createScriptCallStack(size_t maxStackSize, bool emptyIsAllowed)
+PassRefPtr<ScriptCallStack> createScriptCallStack(JSC::ExecState* exec, size_t maxStackSize, bool emptyIsAllowed)
 {
     Vector<ScriptCallFrame> frames;
-    if (JSC::ExecState* exec = JSMainThreadExecState::currentState()) {
+
+    if (exec) {
         CallFrame* frame = exec->vm().topCallFrame;
-        CreateScriptCallStackFunctor functor(frames, maxStackSize);
+        CreateScriptCallStackFunctor functor(false, frames, maxStackSize);
         frame->iterate(functor);
     }
+
     if (frames.isEmpty() && !emptyIsAllowed) {
         // No frames found. It may happen in the case where
         // a bound function is called from native code for example.
         // Fallback to setting lineNumber to 0, and source and function name to "undefined".
-        frames.append(ScriptCallFrame("undefined", "undefined", 0, 0));
+        frames.append(ScriptCallFrame(ASCIILiteral("undefined"), ASCIILiteral("undefined"), 0, 0));
     }
+
     return ScriptCallStack::create(frames);
 }
 
-class CreateScriptCallStackForConsoleFunctor {
-public:
-    CreateScriptCallStackForConsoleFunctor(bool needToSkipAFrame,  size_t remainingCapacity, Vector<ScriptCallFrame>& frames)
-        : m_needToSkipAFrame(needToSkipAFrame)
-        , m_remainingCapacityForFrameCapture(remainingCapacity)
-        , m_frames(frames)
-    {
-    }
-
-    StackVisitor::Status operator()(StackVisitor& visitor)
-    {
-        if (m_needToSkipAFrame) {
-            m_needToSkipAFrame = false;
-            return StackVisitor::Continue;
-        }
-
-        if (m_remainingCapacityForFrameCapture) {
-            // This early exit is necessary to maintain our old behaviour
-            // but the stack trace we produce now is complete and handles all
-            // ways in which code may be running
-            if (!visitor->callee() && m_frames.size())
-                return StackVisitor::Done;
-
-            unsigned line;
-            unsigned column;
-            visitor->computeLineAndColumn(line, column);
-            m_frames.append(ScriptCallFrame(visitor->functionName(), visitor->sourceURL(), line, column));
-
-            m_remainingCapacityForFrameCapture--;
-            return StackVisitor::Continue;
-        }
-        return StackVisitor::Done;
-    }
-
-private:
-    bool m_needToSkipAFrame;
-    size_t m_remainingCapacityForFrameCapture;
-    Vector<ScriptCallFrame>& m_frames;
-};
-
 PassRefPtr<ScriptCallStack> createScriptCallStack(JSC::ExecState* exec, size_t maxStackSize)
 {
     Vector<ScriptCallFrame> frames;
-    ASSERT(exec);
+
     CallFrame* frame = exec->vm().topCallFrame;
-    CreateScriptCallStackForConsoleFunctor functor(true, maxStackSize, frames);
+    CreateScriptCallStackFunctor functor(true, frames, maxStackSize);
     frame->iterate(functor);
+
     if (frames.isEmpty()) {
-        CreateScriptCallStackForConsoleFunctor functor(false, maxStackSize, frames);
+        CreateScriptCallStackFunctor functor(false, frames, maxStackSize);
         frame->iterate(functor);
     }
+
     return ScriptCallStack::create(frames);
 }
 
+PassRefPtr<ScriptCallStack> createScriptCallStackForConsole(JSC::ExecState* exec)
+{
+    // FIXME: Caller should use createScriptCallStack alternative with the exec and appropriate max.
+    return createScriptCallStack(exec, ScriptCallStack::maxCallStackSizeToCapture);
+}
+
 PassRefPtr<ScriptCallStack> createScriptCallStackFromException(JSC::ExecState* exec, JSC::JSValue& exception, size_t maxStackSize)
 {
     Vector<ScriptCallFrame> frames;
@@ -160,10 +136,10 @@ PassRefPtr<ScriptCallStack> createScriptCallStackFromException(JSC::ExecState* e
         if (!stackTrace[i].callee && frames.size())
             break;
 
-        String functionName = stackTrace[i].friendlyFunctionName(exec);
         unsigned line;
         unsigned column;
         stackTrace[i].computeLineAndColumn(line, column);
+        String functionName = stackTrace[i].friendlyFunctionName(exec);
         frames.append(ScriptCallFrame(functionName, stackTrace[i].sourceURL, line, column));
     }
 
@@ -186,17 +162,6 @@ PassRefPtr<ScriptCallStack> createScriptCallStackFromException(JSC::ExecState* e
     return ScriptCallStack::create(frames);
 }
 
-PassRefPtr<ScriptCallStack> createScriptCallStackForConsole(JSC::ExecState* exec)
-{
-    size_t maxStackSize = 1;
-    if (InspectorInstrumentation::hasFrontends()) {
-        ScriptExecutionContext* scriptExecutionContext = jsCast<JSDOMGlobalObject*>(exec->lexicalGlobalObject())->scriptExecutionContext();
-        if (InspectorInstrumentation::consoleAgentEnabled(scriptExecutionContext))
-            maxStackSize = ScriptCallStack::maxCallStackSizeToCapture;
-    }
-    return createScriptCallStack(exec, maxStackSize);
-}
-
 PassRefPtr<ScriptArguments> createScriptArguments(JSC::ExecState* exec, unsigned skipArgumentCount)
 {
     Vector<Deprecated::ScriptValue> arguments;
similarity index 69%
rename from Source/WebCore/bindings/js/ScriptCallStackFactory.h
rename to Source/JavaScriptCore/inspector/ScriptCallStackFactory.h
index 298bbbd4030f901936a7791d942c350736a55960..7ce9c90da23d2ecb58982bea7cd0bb64992d371f 100644 (file)
@@ -1,10 +1,11 @@
 /*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
  * Copyright (c) 2010 Google Inc. All rights reserved.
- * 
+ *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions are
  * met:
- * 
+ *
  *     * Redistributions of source code must retain the above copyright
  * notice, this list of conditions and the following disclaimer.
  *     * Redistributions in binary form must reproduce the above
@@ -14,7 +15,7 @@
  *     * Neither the name of Google Inc. nor the names of its
  * contributors may be used to endorse or promote products derived from
  * this software without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
 #define ScriptCallStackFactory_h
 
 #include <wtf/Forward.h>
-#include <wtf/RefCountedArray.h>
 
 namespace JSC {
 class ExecState;
 class JSValue;
-struct StackFrame;
 }
 
-namespace WebCore {
+namespace Inspector {
 
 class ScriptArguments;
 class ScriptCallStack;
 
-PassRefPtr<ScriptCallStack> createScriptCallStack(size_t maxStackSize, bool emptyStackIsAllowed);
-PassRefPtr<ScriptCallStack> createScriptCallStack(JSC::ExecState*, size_t maxStackSize);
-PassRefPtr<ScriptCallStack> createScriptCallStackFromException(JSC::ExecState*, JSC::JSValue& exception, size_t maxStackSize);
-PassRefPtr<ScriptCallStack> createScriptCallStackForConsole(JSC::ExecState*);
-PassRefPtr<ScriptArguments> createScriptArguments(JSC::ExecState*, unsigned skipArgumentCount);
+// FIXME: The subtle differences between these should be eliminated.
+JS_EXPORT_PRIVATE PassRefPtr<ScriptCallStack> createScriptCallStack(JSC::ExecState*, size_t maxStackSize, bool emptyIsAllowed);
+JS_EXPORT_PRIVATE PassRefPtr<ScriptCallStack> createScriptCallStack(JSC::ExecState*, size_t maxStackSize);
+JS_EXPORT_PRIVATE PassRefPtr<ScriptCallStack> createScriptCallStackForConsole(JSC::ExecState*);
+JS_EXPORT_PRIVATE PassRefPtr<ScriptCallStack> createScriptCallStackFromException(JSC::ExecState*, JSC::JSValue& exception, size_t maxStackSize);
+JS_EXPORT_PRIVATE PassRefPtr<ScriptArguments> createScriptArguments(JSC::ExecState*, unsigned skipArgumentCount);
 
-} // namespace WebCore
+} // namespace Inspector
 
 #endif // ScriptCallStackFactory_h
similarity index 62%
rename from Source/WebCore/inspector/InspectorConsoleAgent.cpp
rename to Source/JavaScriptCore/inspector/agents/InspectorConsoleAgent.cpp
index 8a46d696fc0ae9bdf94827ee953de742de50e469..db6f9106cde6da16a8eece945b7d9b2ea489e7ea 100644 (file)
@@ -1,4 +1,5 @@
 /*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
  * Copyright (C) 2011 Google Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
-
 #include "config.h"
+#include "InspectorConsoleAgent.h"
 
 #if ENABLE(INSPECTOR)
 
-#include "InspectorConsoleAgent.h"
-
-#include "CommandLineAPIHost.h"
-#include "Console.h"
 #include "ConsoleMessage.h"
-#include "DOMWindow.h"
-#include "InspectorWebFrontendDispatchers.h"
-#include "InstrumentingAgents.h"
-#include "PageInjectedScriptManager.h"
-#include "ResourceError.h"
-#include "ResourceResponse.h"
+#include "InjectedScriptManager.h"
 #include "ScriptArguments.h"
 #include "ScriptCallFrame.h"
 #include "ScriptCallStack.h"
 #include "ScriptCallStackFactory.h"
-#include "ScriptProfiler.h"
-#include <bindings/ScriptObject.h>
+#include "ScriptObject.h"
 #include <wtf/CurrentTime.h>
 #include <wtf/OwnPtr.h>
 #include <wtf/PassOwnPtr.h>
 #include <wtf/text/StringBuilder.h>
 #include <wtf/text/WTFString.h>
 
-using namespace Inspector;
-
-namespace WebCore {
+namespace Inspector {
 
 static const unsigned maximumConsoleMessages = 1000;
 static const int expireConsoleMessagesStep = 100;
 
-InspectorConsoleAgent::InspectorConsoleAgent(InstrumentingAgents* instrumentingAgents, PageInjectedScriptManager* injectedScriptManager)
-    : InspectorAgentBase(ASCIILiteral("Console"), instrumentingAgents)
+InspectorConsoleAgent::InspectorConsoleAgent(InjectedScriptManager* injectedScriptManager)
+    : InspectorAgentBase(ASCIILiteral("Console"))
     , m_injectedScriptManager(injectedScriptManager)
     , m_previousMessage(nullptr)
     , m_expiredConsoleMessageCount(0)
     , m_enabled(false)
-    , m_monitoringXHREnabled(false)
 {
-    m_instrumentingAgents->setInspectorConsoleAgent(this);
 }
 
 InspectorConsoleAgent::~InspectorConsoleAgent()
 {
-    m_instrumentingAgents->setInspectorConsoleAgent(nullptr);
-    m_instrumentingAgents = nullptr;
-    m_injectedScriptManager = nullptr;
+}
+
+void InspectorConsoleAgent::didCreateFrontendAndBackend(Inspector::InspectorFrontendChannel* frontendChannel, InspectorBackendDispatcher* backendDispatcher)
+{
+    m_frontendDispatcher = std::make_unique<InspectorConsoleFrontendDispatcher>(frontendChannel);
+    m_backendDispatcher = InspectorConsoleBackendDispatcher::create(backendDispatcher, this);
+}
+
+void InspectorConsoleAgent::willDestroyFrontendAndBackend(InspectorDisconnectReason)
+{
+    m_frontendDispatcher = nullptr;
+    m_backendDispatcher.clear();
+
+    String errorString;
+    disable(&errorString);
 }
 
 void InspectorConsoleAgent::enable(ErrorString*)
 {
     if (m_enabled)
         return;
+
     m_enabled = true;
 
     if (m_expiredConsoleMessageCount) {
-        ConsoleMessage expiredMessage(!isWorkerAgent(), OtherMessageSource, LogMessageType, WarningMessageLevel, String::format("%d console messages are not shown.", m_expiredConsoleMessageCount));
+        ConsoleMessage expiredMessage(!isWorkerAgent(), MessageSource::Other, MessageType::Log, MessageLevel::Warning, String::format("%d console messages are not shown.", m_expiredConsoleMessageCount));
         expiredMessage.addToFrontend(m_frontendDispatcher.get(), m_injectedScriptManager, false);
     }
 
@@ -95,6 +95,7 @@ void InspectorConsoleAgent::disable(ErrorString*)
 {
     if (!m_enabled)
         return;
+
     m_enabled = false;
 }
 
@@ -103,7 +104,9 @@ void InspectorConsoleAgent::clearMessages(ErrorString*)
     m_consoleMessages.clear();
     m_expiredConsoleMessageCount = 0;
     m_previousMessage = nullptr;
-    m_injectedScriptManager->releaseObjectGroup("console");
+
+    m_injectedScriptManager->releaseObjectGroup(ASCIILiteral("console"));
+
     if (m_frontendDispatcher && m_enabled)
         m_frontendDispatcher->messagesCleared();
 }
@@ -112,31 +115,17 @@ void InspectorConsoleAgent::reset()
 {
     ErrorString error;
     clearMessages(&error);
+
     m_times.clear();
     m_counts.clear();
 }
 
-void InspectorConsoleAgent::didCreateFrontendAndBackend(Inspector::InspectorFrontendChannel* frontendChannel, InspectorBackendDispatcher* backendDispatcher)
-{
-    m_frontendDispatcher = std::make_unique<InspectorConsoleFrontendDispatcher>(frontendChannel);
-    m_backendDispatcher = InspectorConsoleBackendDispatcher::create(backendDispatcher, this);
-}
-
-void InspectorConsoleAgent::willDestroyFrontendAndBackend(InspectorDisconnectReason)
-{
-    m_frontendDispatcher = nullptr;
-    m_backendDispatcher.clear();
-
-    String errorString;
-    disable(&errorString);
-}
-
 void InspectorConsoleAgent::addMessageToConsole(MessageSource source, MessageType type, MessageLevel level, const String& message, PassRefPtr<ScriptCallStack> callStack, unsigned long requestIdentifier)
 {
-    if (!m_instrumentingAgents->inspectorEnvironment().developerExtrasEnabled())
+    if (!m_injectedScriptManager->inspectorEnvironment().developerExtrasEnabled())
         return;
 
-    if (type == ClearMessageType) {
+    if (type == MessageType::Clear) {
         ErrorString error;
         clearMessages(&error);
     }
@@ -146,10 +135,10 @@ void InspectorConsoleAgent::addMessageToConsole(MessageSource source, MessageTyp
 
 void InspectorConsoleAgent::addMessageToConsole(MessageSource source, MessageType type, MessageLevel level, const String& message, JSC::ExecState* state, PassRefPtr<ScriptArguments> arguments, unsigned long requestIdentifier)
 {
-    if (!m_instrumentingAgents->inspectorEnvironment().developerExtrasEnabled())
+    if (!m_injectedScriptManager->inspectorEnvironment().developerExtrasEnabled())
         return;
 
-    if (type == ClearMessageType) {
+    if (type == MessageType::Clear) {
         ErrorString error;
         clearMessages(&error);
     }
@@ -159,10 +148,10 @@ void InspectorConsoleAgent::addMessageToConsole(MessageSource source, MessageTyp
 
 void InspectorConsoleAgent::addMessageToConsole(MessageSource source, MessageType type, MessageLevel level, const String& message, const String& scriptID, unsigned lineNumber, unsigned columnNumber, JSC::ExecState* state, unsigned long requestIdentifier)
 {
-    if (!m_instrumentingAgents->inspectorEnvironment().developerExtrasEnabled())
+    if (!m_injectedScriptManager->inspectorEnvironment().developerExtrasEnabled())
         return;
 
-    if (type == ClearMessageType) {
+    if (type == MessageType::Clear) {
         ErrorString error;
         clearMessages(&error);
     }
@@ -171,7 +160,7 @@ void InspectorConsoleAgent::addMessageToConsole(MessageSource source, MessageTyp
     addConsoleMessage(adoptPtr(new ConsoleMessage(canGenerateCallStack, source, type, level, message, scriptID, lineNumber, columnNumber, state, requestIdentifier)));
 }
 
-Vector<unsigned> InspectorConsoleAgent::consoleMessageArgumentCounts()
+Vector<unsigned> InspectorConsoleAgent::consoleMessageArgumentCounts() const
 {
     Vector<unsigned> result(m_consoleMessages.size());
     for (size_t i = 0; i < m_consoleMessages.size(); i++)
@@ -205,7 +194,7 @@ void InspectorConsoleAgent::stopTiming(const String& title, PassRefPtr<ScriptCal
 
     double elapsed = monotonicallyIncreasingTime() - startTime;
     String message = title + String::format(": %.3fms", elapsed * 1000);
-    addMessageToConsole(ConsoleAPIMessageSource, TimingMessageType, DebugMessageLevel, message, callStack);
+    addMessageToConsole(MessageSource::ConsoleAPI, MessageType::Timing, MessageLevel::Debug, message, callStack);
 }
 
 void InspectorConsoleAgent::count(JSC::ExecState* state, PassRefPtr<ScriptArguments> arguments)
@@ -230,68 +219,19 @@ void InspectorConsoleAgent::count(JSC::ExecState* state, PassRefPtr<ScriptArgume
     m_counts.add(identifier, count);
 
     String message = title + ": " + String::number(count);
-    addMessageToConsole(ConsoleAPIMessageSource, LogMessageType, DebugMessageLevel, message, callStack);
-}
-
-void InspectorConsoleAgent::frameWindowDiscarded(DOMWindow* window)
-{
-    size_t messageCount = m_consoleMessages.size();
-    for (size_t i = 0; i < messageCount; ++i)
-        m_consoleMessages[i]->windowCleared(window);
-    m_injectedScriptManager->discardInjectedScriptsFor(window);
-}
-
-void InspectorConsoleAgent::didFinishXHRLoading(unsigned long requestIdentifier, const String& url, const String& sendURL, unsigned sendLineNumber, unsigned sendColumnNumber)
-{
-    if (!m_instrumentingAgents->inspectorEnvironment().developerExtrasEnabled())
-        return;
-    if (m_frontendDispatcher && m_monitoringXHREnabled) {
-        String message = "XHR finished loading: \"" + url + "\".";
-        addMessageToConsole(NetworkMessageSource, LogMessageType, DebugMessageLevel, message, sendURL, sendLineNumber, sendColumnNumber, nullptr, requestIdentifier);
-    }
-}
-
-void InspectorConsoleAgent::didReceiveResponse(unsigned long requestIdentifier, const ResourceResponse& response)
-{
-    if (!m_instrumentingAgents->inspectorEnvironment().developerExtrasEnabled())
-        return;
-
-    if (response.httpStatusCode() >= 400) {
-        String message = "Failed to load resource: the server responded with a status of " + String::number(response.httpStatusCode()) + " (" + response.httpStatusText() + ')';
-        addMessageToConsole(NetworkMessageSource, LogMessageType, ErrorMessageLevel, message, response.url().string(), 0, 0, nullptr, requestIdentifier);
-    }
-}
-
-void InspectorConsoleAgent::didFailLoading(unsigned long requestIdentifier, const ResourceError& error)
-{
-    if (!m_instrumentingAgents->inspectorEnvironment().developerExtrasEnabled())
-        return;
-    if (error.isCancellation()) // Report failures only.
-        return;
-    StringBuilder message;
-    message.appendLiteral("Failed to load resource");
-    if (!error.localizedDescription().isEmpty()) {
-        message.appendLiteral(": ");
-        message.append(error.localizedDescription());
-    }
-    addMessageToConsole(NetworkMessageSource, LogMessageType, ErrorMessageLevel, message.toString(), error.failingURL(), 0, 0, nullptr, requestIdentifier);
-}
-
-void InspectorConsoleAgent::setMonitoringXHREnabled(ErrorString*, bool enabled)
-{
-    m_monitoringXHREnabled = enabled;
+    addMessageToConsole(MessageSource::ConsoleAPI, MessageType::Log, MessageLevel::Debug, message, callStack);
 }
 
 static bool isGroupMessage(MessageType type)
 {
-    return type == StartGroupMessageType
-        || type ==  StartGroupCollapsedMessageType
-        || type == EndGroupMessageType;
+    return type == MessageType::StartGroup
+        || type == MessageType::StartGroupCollapsed
+        || type == MessageType::EndGroup;
 }
 
 void InspectorConsoleAgent::addConsoleMessage(PassOwnPtr<ConsoleMessage> consoleMessage)
 {
-    ASSERT(m_instrumentingAgents->inspectorEnvironment().developerExtrasEnabled());
+    ASSERT(m_injectedScriptManager->inspectorEnvironment().developerExtrasEnabled());
     ASSERT_ARG(consoleMessage, consoleMessage);
 
     if (m_previousMessage && !isGroupMessage(m_previousMessage->type()) && m_previousMessage->isEqual(consoleMessage.get())) {
@@ -311,23 +251,6 @@ void InspectorConsoleAgent::addConsoleMessage(PassOwnPtr<ConsoleMessage> console
     }
 }
 
-class InspectableHeapObject final : public CommandLineAPIHost::InspectableObject {
-public:
-    explicit InspectableHeapObject(int heapObjectId) : m_heapObjectId(heapObjectId) { }
-    virtual Deprecated::ScriptValue get(JSC::ExecState*) override
-    {
-        return ScriptProfiler::objectByHeapObjectId(m_heapObjectId);
-    }
-private:
-    int m_heapObjectId;
-};
-
-void InspectorConsoleAgent::addInspectedHeapObject(ErrorString*, int inspectedHeapObjectId)
-{
-    if (CommandLineAPIHost* commandLineAPIHost = m_injectedScriptManager->commandLineAPIHost())
-        commandLineAPIHost->addInspectedObject(adoptPtr(new InspectableHeapObject(inspectedHeapObjectId)));
-}
-
-} // namespace WebCore
+} // namespace Inspector
 
 #endif // ENABLE(INSPECTOR)
diff --git a/Source/JavaScriptCore/inspector/agents/InspectorConsoleAgent.h b/Source/JavaScriptCore/inspector/agents/InspectorConsoleAgent.h
new file mode 100644 (file)
index 0000000..49a79e6
--- /dev/null
@@ -0,0 +1,103 @@
+/*
+* Copyright (C) 2014 Apple Inc. All rights reserved.
+* Copyright (C) 2011 Google Inc. All rights reserved.
+*
+* Redistribution and use in source and binary forms, with or without
+* modification, are permitted provided that the following conditions
+* are met:
+* 1.  Redistributions of source code must retain the above copyright
+*     notice, this list of conditions and the following disclaimer.
+* 2.  Redistributions in binary form must reproduce the above copyright
+*     notice, this list of conditions and the following disclaimer in the
+*     documentation and/or other materials provided with the distribution.
+*
+* THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND ANY
+* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+* DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY
+* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+*/
+
+#ifndef InspectorConsoleAgent_h
+#define InspectorConsoleAgent_h
+
+#if ENABLE(INSPECTOR)
+
+#include "InspectorJSBackendDispatchers.h"
+#include "InspectorJSFrontendDispatchers.h"
+#include "inspector/ConsoleTypes.h"
+#include "inspector/InspectorAgentBase.h"
+#include <wtf/Forward.h>
+#include <wtf/HashMap.h>
+#include <wtf/Noncopyable.h>
+#include <wtf/Vector.h>
+#include <wtf/text/StringHash.h>
+
+namespace JSC {
+class ExecState;
+}
+
+namespace Inspector {
+
+class ConsoleMessage;
+class InjectedScriptManager;
+class ScriptArguments;
+class ScriptCallStack;
+typedef String ErrorString;
+
+class JS_EXPORT_PRIVATE InspectorConsoleAgent : public InspectorAgentBase, public InspectorConsoleBackendDispatcherHandler {
+    WTF_MAKE_NONCOPYABLE(InspectorConsoleAgent);
+    WTF_MAKE_FAST_ALLOCATED;
+public:
+    InspectorConsoleAgent(InjectedScriptManager*);
+    virtual ~InspectorConsoleAgent();
+
+    virtual void didCreateFrontendAndBackend(InspectorFrontendChannel*, InspectorBackendDispatcher*) override;
+    virtual void willDestroyFrontendAndBackend(InspectorDisconnectReason) override;
+
+    virtual void enable(ErrorString*) override;
+    virtual void disable(ErrorString*) override;
+    virtual void clearMessages(ErrorString*) override;
+    virtual void setMonitoringXHREnabled(ErrorString*, bool enabled) = 0;
+    virtual void addInspectedNode(ErrorString*, int nodeId) = 0;
+    virtual void addInspectedHeapObject(ErrorString*, int inspectedHeapObjectId) = 0;
+
+    virtual bool isWorkerAgent() const = 0;
+
+    bool enabled() const { return m_enabled; }
+    void reset();
+
+    void addMessageToConsole(MessageSource, MessageType, MessageLevel, const String& message, JSC::ExecState*, PassRefPtr<ScriptArguments>, unsigned long requestIdentifier = 0);
+    void addMessageToConsole(MessageSource, MessageType, MessageLevel, const String& message, const String& scriptID, unsigned lineNumber, unsigned columnNumber, JSC::ExecState* = nullptr, unsigned long requestIdentifier = 0);
+    void addMessageToConsole(MessageSource, MessageType, MessageLevel, const String& message, PassRefPtr<ScriptCallStack>, unsigned long requestIdentifier = 0);
+
+    Vector<unsigned> consoleMessageArgumentCounts() const;
+
+    void startTiming(const String& title);
+    void stopTiming(const String& title, PassRefPtr<ScriptCallStack>);
+    void count(JSC::ExecState*, PassRefPtr<ScriptArguments>);
+
+protected:
+    void addConsoleMessage(PassOwnPtr<ConsoleMessage>);
+
+    InjectedScriptManager* m_injectedScriptManager;
+    std::unique_ptr<InspectorConsoleFrontendDispatcher> m_frontendDispatcher;
+    RefPtr<InspectorConsoleBackendDispatcher> m_backendDispatcher;
+    ConsoleMessage* m_previousMessage;
+    Vector<OwnPtr<ConsoleMessage>> m_consoleMessages;
+    int m_expiredConsoleMessageCount;
+    HashMap<String, unsigned> m_counts;
+    HashMap<String, double> m_times;
+    bool m_enabled;
+};
+
+} // namespace Inspector
+
+#endif // ENABLE(INSPECTOR)
+
+#endif // !defined(InspectorConsoleAgent_h)
diff --git a/Source/JavaScriptCore/inspector/agents/JSGlobalObjectConsoleAgent.cpp b/Source/JavaScriptCore/inspector/agents/JSGlobalObjectConsoleAgent.cpp
new file mode 100644 (file)
index 0000000..1fe2e82
--- /dev/null
@@ -0,0 +1,55 @@
+/*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL APPLE INC. OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+ * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include "config.h"
+#include "JSGlobalObjectConsoleAgent.h"
+
+#if ENABLE(INSPECTOR)
+
+namespace Inspector {
+
+JSGlobalObjectConsoleAgent::JSGlobalObjectConsoleAgent(InjectedScriptManager* injectedScriptManager)
+    : InspectorConsoleAgent(injectedScriptManager)
+{
+}
+
+void JSGlobalObjectConsoleAgent::setMonitoringXHREnabled(ErrorString* errorString, bool)
+{
+    *errorString = ASCIILiteral("Not supported for JavaScript context");
+}
+
+void JSGlobalObjectConsoleAgent::addInspectedNode(ErrorString* errorString, int)
+{
+    *errorString = ASCIILiteral("Not supported for JavaScript context");
+}
+
+void JSGlobalObjectConsoleAgent::addInspectedHeapObject(ErrorString* errorString, int)
+{
+    *errorString = ASCIILiteral("Not supported for JavaScript context");
+}
+
+} // namespace Inspector
+
+#endif // ENABLE(INSPECTOR)
diff --git a/Source/JavaScriptCore/inspector/agents/JSGlobalObjectConsoleAgent.h b/Source/JavaScriptCore/inspector/agents/JSGlobalObjectConsoleAgent.h
new file mode 100644 (file)
index 0000000..e585ebd
--- /dev/null
@@ -0,0 +1,55 @@
+/*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL APPLE INC. OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+ * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef JSGlobalObjectConsoleAgent_h
+#define JSGlobalObjectConsoleAgent_h
+
+#if ENABLE(INSPECTOR)
+
+#include "InspectorConsoleAgent.h"
+#include "JSGlobalObjectScriptDebugServer.h"
+
+namespace Inspector {
+
+class JSGlobalObjectConsoleAgent final : public InspectorConsoleAgent {
+    WTF_MAKE_NONCOPYABLE(JSGlobalObjectConsoleAgent);
+    WTF_MAKE_FAST_ALLOCATED;
+public:
+    JSGlobalObjectConsoleAgent(InjectedScriptManager*);
+    virtual ~JSGlobalObjectConsoleAgent() { }
+
+    // FIXME: XHRs and Nodes only makes sense debugging a Web context. Can this be moved to a different agent?
+    virtual void setMonitoringXHREnabled(ErrorString*, bool enabled) override;
+    virtual void addInspectedNode(ErrorString*, int nodeId) override;
+    virtual void addInspectedHeapObject(ErrorString*, int inspectedHeapObjectId) override;
+
+    virtual bool isWorkerAgent() const { return false; }
+};
+
+} // namespace Inspector
+
+#endif // ENABLE(INSPECTOR)
+
+#endif // !defined(JSGlobalObjectConsoleAgent_h)
index d4c32d7310799c98f8620b56aecb67d0cc36c1d1..2e1750bea79424c905477d76bdf6a4cd4d8bca8a 100644 (file)
 #if ENABLE(INSPECTOR)
 
 #include "InjectedScriptManager.h"
+#include "InspectorConsoleAgent.h"
 #include "JSGlobalObject.h"
+#include "ScriptArguments.h"
+#include "ScriptCallStack.h"
+#include "ScriptCallStackFactory.h"
 
 using namespace JSC;
 
 namespace Inspector {
 
-JSGlobalObjectDebuggerAgent::JSGlobalObjectDebuggerAgent(InjectedScriptManager* injectedScriptManager, JSC::JSGlobalObject& globalObject)
+JSGlobalObjectDebuggerAgent::JSGlobalObjectDebuggerAgent(InjectedScriptManager* injectedScriptManager, JSC::JSGlobalObject& globalObject, InspectorConsoleAgent* consoleAgent)
     : InspectorDebuggerAgent(injectedScriptManager)
     , m_scriptDebugServer(globalObject)
+    , m_consoleAgent(consoleAgent)
 {
 }
 
@@ -62,6 +67,11 @@ InjectedScript JSGlobalObjectDebuggerAgent::injectedScriptForEval(ErrorString* e
     return injectedScriptManager()->injectedScriptFor(exec);
 }
 
+void JSGlobalObjectDebuggerAgent::breakpointActionLog(JSC::ExecState* exec, const String& message)
+{
+    m_consoleAgent->addMessageToConsole(MessageSource::JS, MessageType::Log, MessageLevel::Log, message, createScriptCallStack(exec, ScriptCallStack::maxCallStackSizeToCapture, true), 0);
+}
+
 } // namespace Inspector
 
 #endif // ENABLE(INSPECTOR)
index a9fd679ce06321c2ff8882091aeeb23f9ccc9763..170ad538f3f8b8c82ba3d4c818eb772428cad1a9 100644 (file)
 
 namespace Inspector {
 
+class InspectorConsoleAgent;
+
 class JSGlobalObjectDebuggerAgent final : public InspectorDebuggerAgent {
     WTF_MAKE_NONCOPYABLE(JSGlobalObjectDebuggerAgent);
     WTF_MAKE_FAST_ALLOCATED;
 public:
-    JSGlobalObjectDebuggerAgent(InjectedScriptManager*, JSC::JSGlobalObject&);
+    JSGlobalObjectDebuggerAgent(InjectedScriptManager*, JSC::JSGlobalObject&, InspectorConsoleAgent*);
     virtual ~JSGlobalObjectDebuggerAgent() { }
 
     virtual JSGlobalObjectScriptDebugServer& scriptDebugServer() override { return m_scriptDebugServer; }
@@ -46,8 +48,7 @@ public:
     virtual void stopListeningScriptDebugServer(bool isBeingDestroyed) override;
     virtual InjectedScript injectedScriptForEval(ErrorString*, const int* executionContextId) override;
 
-    // FIXME: This needs a ConsoleAgent to send a log to.
-    virtual void breakpointActionLog(JSC::ExecState*, const String&) override final { }
+    virtual void breakpointActionLog(JSC::ExecState*, const String&) override;
 
     // FIXME: JavaScript inspector does not yet have a console object to mute.
     virtual void muteConsole() override { }
@@ -55,6 +56,7 @@ public:
 
 private:
     JSGlobalObjectScriptDebugServer m_scriptDebugServer;
+    InspectorConsoleAgent* m_consoleAgent;
 };
 
 } // namespace Inspector
similarity index 86%
rename from Source/WebCore/inspector/protocol/Console.json
rename to Source/JavaScriptCore/inspector/protocol/Console.json
index 35bd11af99e03b354e37a871100c43cfa33e5295..fc3c901780cdde8ba67ffca7a68c2ebca8643c05 100644 (file)
@@ -2,6 +2,16 @@
     "domain": "Console",
     "description": "Console domain defines methods and events for interaction with the JavaScript console. Console collects messages created by means of the <a href='http://getfirebug.com/wiki/index.php/Console_API'>JavaScript Console API</a>. One needs to enable this domain using <code>enable</code> command in order to start receiving the console messages. Browser collects messages issued while console domain is not enabled as well and reports them using <code>messageAdded</code> notification upon enabling.",
     "types": [
+        {
+            "id": "ConsoleNetworkRequestId",
+            "type": "string",
+            "description": "Unique request identifier. FIXME: Duplicate of Network.RequestId <https://webkit.org/b/125664> Web Inspector: FIX Type Dependency Issues"
+        },
+        {
+            "id": "ConsoleDOMNodeId",
+            "type": "integer",
+            "description": "Unique DOM node identifier. FIXME: Duplicate of DOM.NodeId <https://webkit.org/b/125664> Web Inspector: FIX Type Dependency Issues"
+        },
         {
             "id": "ConsoleMessage",
             "type": "object",
@@ -17,7 +27,7 @@
                 { "name": "repeatCount", "type": "integer", "optional": true, "description": "Repeat count for repeated messages." },
                 { "name": "parameters", "type": "array", "items": { "$ref": "Runtime.RemoteObject" }, "optional": true, "description": "Message parameters in case of the formatted message." },
                 { "name": "stackTrace", "$ref": "StackTrace", "optional": true, "description": "JavaScript stack trace for assertions and error messages." },
-                { "name": "networkRequestId", "$ref": "Network.RequestId", "optional": true, "description": "Identifier of the network request associated with this message." }
+                { "name": "networkRequestId", "$ref": "ConsoleNetworkRequestId", "optional": true, "description": "Identifier of the network request associated with this message." }
             ]
         },
         {
@@ -61,7 +71,7 @@
         {
             "name": "addInspectedNode",
             "parameters": [
-                { "name": "nodeId", "$ref": "DOM.NodeId", "description": "DOM node id to be accessible by means of $x command line API." }
+                { "name": "nodeId", "$ref": "ConsoleDOMNodeId", "description": "DOM node id to be accessible by means of $x command line API." }
             ],
             "description": "Enables console to refer to the node with given id via $x (see Command Line API for more details $x functions)."
         },
index db163bfe41838f6bea3d6eb03cdd91631f128180..53660318ddce3ba78cbb0696a217581960f91012 100755 (executable)
@@ -66,3 +66,4 @@ for file in files:
 
     print(string.rstrip())
 print("]}")
+
index 051a4ea987e6586635872ff5229a447c9b2bcebd..845840ca82c99a5c34b1242bb169e84a233c246a 100644 (file)
@@ -760,7 +760,6 @@ set(WebCore_INSPECTOR_DOMAINS
     inspector/protocol/ApplicationCache.json
     inspector/protocol/CSS.json
     inspector/protocol/Canvas.json
-    inspector/protocol/Console.json
     inspector/protocol/DOM.json
     inspector/protocol/DOMDebugger.json
     inspector/protocol/DOMStorage.json
@@ -1566,16 +1565,13 @@ set(WebCore_SOURCES
 
     inspector/CommandLineAPIHost.cpp
     inspector/CommandLineAPIModule.cpp
-    inspector/ConsoleMessage.cpp
     inspector/DOMEditor.cpp
     inspector/DOMPatchSupport.cpp
-    inspector/IdentifiersFactory.cpp
     inspector/InjectedScriptCanvasModule.cpp
     inspector/InspectorApplicationCacheAgent.cpp
     inspector/InspectorCSSAgent.cpp
     inspector/InspectorCanvasAgent.cpp
     inspector/InspectorClient.cpp
-    inspector/InspectorConsoleAgent.cpp
     inspector/InspectorController.cpp
     inspector/InspectorCounters.cpp
     inspector/InspectorDOMAgent.cpp
@@ -1609,10 +1605,8 @@ set(WebCore_SOURCES
     inspector/PageInjectedScriptHost.cpp
     inspector/PageInjectedScriptManager.cpp
     inspector/PageRuntimeAgent.cpp
-    inspector/ScriptArguments.cpp
-    inspector/ScriptCallFrame.cpp
-    inspector/ScriptCallStack.cpp
     inspector/TimelineRecordFactory.cpp
+    inspector/WebConsoleAgent.cpp
     inspector/WebDebuggerAgent.cpp
     inspector/WorkerConsoleAgent.cpp
     inspector/WorkerDebuggerAgent.cpp
index d315f1738c2317a47d989a818a0b6cbde031b5a8..2d308a600bff87801d52c363c04f7af41be5175a 100644 (file)
@@ -1,3 +1,274 @@
+2014-02-06  Joseph Pecoraro  <pecoraro@apple.com>
+
+        Web Inspector: Add Console support to JSContext Inspection
+        https://bugs.webkit.org/show_bug.cgi?id=127941
+
+        Reviewed by Geoffrey Garen.
+
+          - Move InspectorConsoleAgent and dependencies to JavaScriptCore
+            and into the Inspector namespace.
+          - Update Console Message enum types to enum classes and update
+            all users to the new, simpler names.
+          - Since we are updating addConsoleMessage callsites anyways, add
+            ASCIILiteral where appropriate.
+          - Add WebConsoleAgent base of Page/Worker ConsoleAgent to implement
+            what could not be pushed into JavaScriptCore.
+
+        * CMakeLists.txt:
+        * DerivedSources.make:
+        * ForwardingHeaders/inspector/ConsoleMessage.h: Added.
+        * ForwardingHeaders/inspector/ConsoleTypes.h: Added.
+        * ForwardingHeaders/inspector/IdentifiersFactory.h: Added.
+        * ForwardingHeaders/inspector/ScriptArguments.h: Added.
+        * ForwardingHeaders/inspector/ScriptCallFrame.h: Added.
+        * ForwardingHeaders/inspector/ScriptCallStack.h: Added.
+        * ForwardingHeaders/inspector/ScriptCallStackFactory.h: Added.
+        * ForwardingHeaders/inspector/agents/InspectorConsoleAgent.h: Added.
+        * GNUmakefile.am:
+        * GNUmakefile.list.am:
+        Add / remove files from builds.
+
+        * inspector/WebConsoleAgent.h:
+        * inspector/WebConsoleAgent.cpp: Added.
+        (WebCore::WebConsoleAgent::WebConsoleAgent):
+        (WebCore::WebConsoleAgent::setMonitoringXHREnabled):
+        (WebCore::WebConsoleAgent::frameWindowDiscarded):
+        (WebCore::WebConsoleAgent::didFinishXHRLoading):
+        (WebCore::WebConsoleAgent::didReceiveResponse):
+        (WebCore::WebConsoleAgent::didFailLoading):
+        (WebCore::WebConsoleAgent::addInspectedHeapObject):
+        Implement what could not be pushed down into JavaScriptCore.
+
+        * inspector/InstrumentingAgents.h:
+        (WebCore::InstrumentingAgents::webConsoleAgent):
+        (WebCore::InstrumentingAgents::setWebConsoleAgent):
+        Hold a WebConsoleAgent instead of InspectorConsoleAgent.
+
+        * Modules/indexeddb/IDBCursor.cpp:
+        * Modules/indexeddb/IDBDatabase.cpp:
+        * Modules/indexeddb/IDBTransaction.cpp:
+        * Modules/quota/DOMWindowQuota.cpp:
+        (WebCore::DOMWindowQuota::webkitStorageInfo):
+        * Modules/webaudio/AudioBufferSourceNode.cpp:
+        (WebCore::AudioBufferSourceNode::looping):
+        (WebCore::AudioBufferSourceNode::setLooping):
+        * Modules/webaudio/AudioContext.cpp:
+        * Modules/webaudio/PannerNode.cpp:
+        (WebCore::PannerNode::setPanningModel):
+        * Modules/webdatabase/DatabaseBase.cpp:
+        (WebCore::DatabaseBase::logErrorMessage):
+        * Modules/webdatabase/DatabaseManager.cpp:
+        (WebCore::DatabaseManager::logErrorMessage):
+        * Modules/websockets/WebSocket.cpp:
+        (WebCore::WebSocket::connect):
+        (WebCore::WebSocket::send):
+        (WebCore::WebSocket::close):
+        (WebCore::WebSocket::setBinaryType):
+        * Modules/websockets/WebSocketChannel.cpp:
+        (WebCore::WebSocketChannel::fail):
+        (WebCore::WebSocketChannel::didFailSocketStream):
+        * Modules/websockets/WebSocketHandshake.cpp:
+        * WebCore.exp.in:
+        * WebCore.vcxproj/WebCore.vcxproj:
+        * WebCore.vcxproj/WebCore.vcxproj.filters:
+        * WebCore.xcodeproj/project.pbxproj:
+        * bindings/js/JSAudioContextCustom.cpp:
+        (WebCore::JSAudioContextConstructor::constructJSAudioContext):
+        * bindings/js/JSCustomXPathNSResolver.cpp:
+        (WebCore::JSCustomXPathNSResolver::lookupNamespaceURI):
+        * bindings/js/JSDOMBinding.cpp:
+        * bindings/js/JSSubtleCryptoCustom.cpp:
+        (WebCore::JSSubtleCrypto::encrypt):
+        (WebCore::JSSubtleCrypto::decrypt):
+        (WebCore::JSSubtleCrypto::sign):
+        (WebCore::JSSubtleCrypto::verify):
+        (WebCore::JSSubtleCrypto::wrapKey):
+        (WebCore::JSSubtleCrypto::unwrapKey):
+        * bindings/js/ScriptController.cpp:
+        (WebCore::ScriptController::canExecuteScripts):
+        * bindings/scripts/CodeGeneratorJS.pm:
+        (GenerateCallWith):
+        * bindings/scripts/test/JS/JSTestObj.cpp:
+        * css/CSSParser.cpp:
+        (WebCore::CSSParser::logError):
+        * css/MediaList.cpp:
+        (WebCore::addResolutionWarningMessageToConsole):
+        * dom/Document.cpp:
+        (WebCore::Document::logExceptionToConsole):
+        (WebCore::Document::processHttpEquiv):
+        (WebCore::Document::addMessage):
+        * dom/Document.h:
+        * dom/ScriptElement.cpp:
+        (WebCore::ScriptElement::executeScript):
+        (WebCore::ScriptElement::notifyFinished):
+        * dom/ScriptExecutionContext.cpp:
+        * dom/ScriptExecutionContext.h:
+        * dom/ViewportArguments.cpp:
+        (WebCore::viewportErrorMessageLevel):
+        (WebCore::reportViewportWarning):
+        * fileapi/Blob.cpp:
+        * fileapi/WebKitBlobBuilder.cpp:
+        * html/HTMLFormControlElement.cpp:
+        (WebCore::shouldAutofocus):
+        * html/HTMLFormElement.cpp:
+        (WebCore::HTMLFormElement::validateInteractively):
+        * html/HTMLIFrameElement.cpp:
+        (WebCore::HTMLIFrameElement::parseAttribute):
+        * html/HTMLMediaElement.cpp:
+        (WebCore::HTMLMediaElement::parseAttribute):
+        * html/canvas/CanvasRenderingContext2D.cpp:
+        (WebCore::CanvasRenderingContext2D::getImageData):
+        * html/canvas/WebGLRenderingContext.cpp:
+        (WebCore::WebGLRenderingContext::printWarningToConsole):
+        * html/parser/XSSAuditor.cpp:
+        (WebCore::XSSAuditor::init):
+        * html/parser/XSSAuditorDelegate.cpp:
+        (WebCore::XSSAuditorDelegate::didBlockScript):
+        * inspector/CommandLineAPIHost.cpp:
+        * inspector/CommandLineAPIHost.h:
+        (WebCore::CommandLineAPIHost::init):
+        * inspector/InspectorAllInOne.cpp:
+        * inspector/InspectorConsoleAgent.h: Removed.
+        * inspector/InspectorConsoleInstrumentation.h:
+        (WebCore::InspectorInstrumentation::addMessageToConsole):
+        (WebCore::InspectorInstrumentation::consoleCount):
+        (WebCore::InspectorInstrumentation::stopConsoleTiming):
+        (WebCore::InspectorInstrumentation::consoleTimeStamp):
+        (WebCore::InspectorInstrumentation::addProfile):
+        * inspector/InspectorController.cpp:
+        (WebCore::InspectorController::InspectorController):
+        * inspector/InspectorDOMAgent.cpp:
+        * inspector/InspectorFrontendHost.h:
+        * inspector/InspectorInstrumentation.cpp:
+        (WebCore::InspectorInstrumentation::frameWindowDiscardedImpl):
+        (WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
+        (WebCore::InspectorInstrumentation::didFailLoadingImpl):
+        (WebCore::InspectorInstrumentation::didFinishXHRLoadingImpl):
+        (WebCore::InspectorInstrumentation::didCommitLoadImpl):
+        (WebCore::isConsoleAssertMessage):
+        (WebCore::InspectorInstrumentation::addMessageToConsoleImpl):
+        (WebCore::InspectorInstrumentation::consoleCountImpl):
+        (WebCore::InspectorInstrumentation::startConsoleTimingImpl):
+        (WebCore::InspectorInstrumentation::stopConsoleTimingImpl):
+        (WebCore::InspectorInstrumentation::consoleAgentEnabled):
+        * inspector/InspectorInstrumentation.h:
+        * inspector/InspectorLayerTreeAgent.cpp:
+        * inspector/InspectorPageAgent.cpp:
+        * inspector/InspectorProfilerAgent.cpp:
+        (WebCore::InspectorProfilerAgent::addProfileFinishedMessageToConsole):
+        (WebCore::InspectorProfilerAgent::addStartProfilingMessageToConsole):
+        * inspector/InspectorProfilerAgent.h:
+        * inspector/InspectorResourceAgent.cpp:
+        (WebCore::InspectorResourceAgent::buildInitiatorObject):
+        * inspector/InspectorTimelineAgent.cpp:
+        * inspector/InstrumentingAgents.cpp:
+        (WebCore::InstrumentingAgents::InstrumentingAgents):
+        (WebCore::InstrumentingAgents::reset):
+        * inspector/PageConsoleAgent.cpp:
+        (WebCore::PageConsoleAgent::PageConsoleAgent):
+        (WebCore::PageConsoleAgent::clearMessages):
+        (WebCore::PageConsoleAgent::addInspectedNode):
+        * inspector/PageConsoleAgent.h:
+        * inspector/PageDebuggerAgent.cpp:
+        (WebCore::PageDebuggerAgent::breakpointActionLog):
+        * inspector/PageInjectedScriptHost.h:
+        * inspector/PageInjectedScriptManager.h:
+        * inspector/TimelineRecordFactory.cpp:
+        (WebCore::TimelineRecordFactory::createGenericRecord):
+        (WebCore::WebConsoleAgent::~WebConsoleAgent):
+        * inspector/WorkerConsoleAgent.cpp:
+        (WebCore::WorkerConsoleAgent::WorkerConsoleAgent):
+        (WebCore::WorkerConsoleAgent::addInspectedNode):
+        * inspector/WorkerConsoleAgent.h:
+        * inspector/WorkerDebuggerAgent.cpp:
+        (WebCore::WorkerDebuggerAgent::breakpointActionLog):
+        * inspector/WorkerInspectorController.cpp:
+        (WebCore::WorkerInspectorController::WorkerInspectorController):
+        * loader/DocumentLoader.cpp:
+        (WebCore::DocumentLoader::responseReceived):
+        * loader/FrameLoader.cpp:
+        (WebCore::FrameLoader::submitForm):
+        (WebCore::FrameLoader::reportLocalLoadFailed):
+        (WebCore::FrameLoader::handleBeforeUnloadEvent):
+        (WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions):
+        (WebCore::createWindow):
+        * loader/ImageLoader.cpp:
+        (WebCore::ImageLoader::notifyFinished):
+        * loader/MixedContentChecker.cpp:
+        (WebCore::MixedContentChecker::logWarning):
+        * loader/TextTrackLoader.cpp:
+        (WebCore::TextTrackLoader::corsPolicyPreventedLoad):
+        * loader/appcache/ApplicationCacheGroup.cpp:
+        (WebCore::ApplicationCacheGroup::abort):
+        (WebCore::ApplicationCacheGroup::didReceiveResponse):
+        (WebCore::ApplicationCacheGroup::didFinishLoading):
+        (WebCore::ApplicationCacheGroup::didFail):
+        (WebCore::ApplicationCacheGroup::didReceiveManifestResponse):
+        (WebCore::ApplicationCacheGroup::didFinishLoadingManifest):
+        (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
+        * loader/cache/CachedResourceLoader.cpp:
+        (WebCore::CachedResourceLoader::printAccessDeniedMessage):
+        * page/ChromeClient.h:
+        * page/Console.cpp:
+        (WebCore::internalAddMessage):
+        (WebCore::Console::debug):
+        (WebCore::Console::error):
+        (WebCore::Console::log):
+        (WebCore::Console::warn):
+        (WebCore::Console::dir):
+        (WebCore::Console::dirxml):
+        (WebCore::Console::table):
+        (WebCore::Console::clear):
+        (WebCore::Console::trace):
+        (WebCore::Console::assertCondition):
+        (WebCore::Console::group):
+        (WebCore::Console::groupCollapsed):
+        (WebCore::Console::groupEnd):
+        * page/Console.h:
+        * page/ConsoleTypes.h: Removed.
+        * page/ContentSecurityPolicy.cpp:
+        (WebCore::ContentSecurityPolicy::reportViolation):
+        (WebCore::ContentSecurityPolicy::logToConsole):
+        * page/DOMSecurityPolicy.cpp:
+        * page/DOMWindow.cpp:
+        (WebCore::DOMWindow::postMessage):
+        (WebCore::DOMWindow::dispatchMessageEventWithOriginCheck):
+        (WebCore::DOMWindow::close):
+        (WebCore::DOMWindow::printErrorMessage):
+        * page/DOMWindow.h:
+        * page/EventSource.cpp:
+        (WebCore::EventSource::didReceiveResponse):
+        (WebCore::EventSource::didFailAccessControlCheck):
+        * page/PageConsole.cpp:
+        (WebCore::PageConsole::printMessageSourceAndLevelPrefix):
+        (WebCore::PageConsole::addMessage):
+        * page/PageConsole.h:
+        * page/PointerLockController.cpp:
+        (WebCore::PointerLockController::requestPointerLock):
+        * platform/CrossThreadCopier.h:
+        * rendering/shapes/ShapeInfo.cpp:
+        (WebCore::checkShapeImageOrigin):
+        * svg/SVGDocumentExtensions.cpp:
+        (WebCore::reportMessage):
+        (WebCore::SVGDocumentExtensions::reportWarning):
+        (WebCore::SVGDocumentExtensions::reportError):
+        * testing/Internals.cpp:
+        (WebCore::Internals::consoleMessageArgumentCounts):
+        * workers/DefaultSharedWorkerRepository.cpp:
+        * workers/SharedWorkerGlobalScope.cpp:
+        (WebCore::SharedWorkerGlobalScope::logExceptionToConsole):
+        * workers/SharedWorkerGlobalScope.h:
+        * workers/WorkerGlobalScope.cpp:
+        (WebCore::WorkerGlobalScope::addMessageToWorkerConsole):
+        * workers/WorkerGlobalScope.h:
+        * workers/WorkerMessagingProxy.cpp:
+        * workers/WorkerReportingProxy.h:
+        * xml/XMLHttpRequest.cpp:
+        (WebCore::logConsoleError):
+        (WebCore::XMLHttpRequest::send):
+        * xml/XSLTProcessorLibxslt.cpp:
+        (WebCore::XSLTProcessor::parseErrorFunc):
+
 2014-02-06  Joseph Pecoraro  <pecoraro@apple.com>
 
         Convert a parameter to PassRefPtr
index 0f6dbc46bdb16273da1f3bafe99bd91984ae0761..c28dd9699c85d561e1c02235cbc3635beb7dfa75 100644 (file)
@@ -1092,7 +1092,6 @@ INSPECTOR_DOMAINS = \
     $(WebCore)/inspector/protocol/ApplicationCache.json \
     $(WebCore)/inspector/protocol/CSS.json \
     $(WebCore)/inspector/protocol/Canvas.json \
-    $(WebCore)/inspector/protocol/Console.json \
     $(WebCore)/inspector/protocol/DOM.json \
     $(WebCore)/inspector/protocol/DOMDebugger.json \
     $(WebCore)/inspector/protocol/DOMStorage.json \
diff --git a/Source/WebCore/ForwardingHeaders/inspector/ConsoleMessage.h b/Source/WebCore/ForwardingHeaders/inspector/ConsoleMessage.h
new file mode 100644 (file)
index 0000000..cd57d16
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef WebCore_FWD_ConsoleMessage_h
+#define WebCore_FWD_ConsoleMessage_h
+#include <JavaScriptCore/ConsoleMessage.h>
+#endif
diff --git a/Source/WebCore/ForwardingHeaders/inspector/ConsoleTypes.h b/Source/WebCore/ForwardingHeaders/inspector/ConsoleTypes.h
new file mode 100644 (file)
index 0000000..7b729d7
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef WebCore_FWD_ConsoleTypes_h
+#define WebCore_FWD_ConsoleTypes_h
+#include <JavaScriptCore/ConsoleTypes.h>
+#endif
diff --git a/Source/WebCore/ForwardingHeaders/inspector/IdentifiersFactory.h b/Source/WebCore/ForwardingHeaders/inspector/IdentifiersFactory.h
new file mode 100644 (file)
index 0000000..8a135b4
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef WebCore_FWD_IdentifiersFactory_h
+#define WebCore_FWD_IdentifiersFactory_h
+#include <JavaScriptCore/IdentifiersFactory.h>
+#endif
diff --git a/Source/WebCore/ForwardingHeaders/inspector/ScriptArguments.h b/Source/WebCore/ForwardingHeaders/inspector/ScriptArguments.h
new file mode 100644 (file)
index 0000000..05a6f98
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef WebCore_FWD_ScriptArguments_h
+#define WebCore_FWD_ScriptArguments_h
+#include <JavaScriptCore/ScriptArguments.h>
+#endif
diff --git a/Source/WebCore/ForwardingHeaders/inspector/ScriptCallFrame.h b/Source/WebCore/ForwardingHeaders/inspector/ScriptCallFrame.h
new file mode 100644 (file)
index 0000000..0767858
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef WebCore_FWD_ScriptCallFrame_h
+#define WebCore_FWD_ScriptCallFrame_h
+#include <JavaScriptCore/ScriptCallFrame.h>
+#endif
diff --git a/Source/WebCore/ForwardingHeaders/inspector/ScriptCallStack.h b/Source/WebCore/ForwardingHeaders/inspector/ScriptCallStack.h
new file mode 100644 (file)
index 0000000..7d97f7d
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef WebCore_FWD_ScriptCallStack_h
+#define WebCore_FWD_ScriptCallStack_h
+#include <JavaScriptCore/ScriptCallStack.h>
+#endif
diff --git a/Source/WebCore/ForwardingHeaders/inspector/ScriptCallStackFactory.h b/Source/WebCore/ForwardingHeaders/inspector/ScriptCallStackFactory.h
new file mode 100644 (file)
index 0000000..441e7c4
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef WebCore_FWD_ScriptCallStackFactory_h
+#define WebCore_FWD_ScriptCallStackFactory_h
+#include <JavaScriptCore/ScriptCallStackFactory.h>
+#endif
diff --git a/Source/WebCore/ForwardingHeaders/inspector/agents/InspectorConsoleAgent.h b/Source/WebCore/ForwardingHeaders/inspector/agents/InspectorConsoleAgent.h
new file mode 100644 (file)
index 0000000..2feceaa
--- /dev/null
@@ -0,0 +1,4 @@
+#ifndef WebCore_FWD_InspectorConsoleAgent_h
+#define WebCore_FWD_InspectorConsoleAgent_h
+#include <JavaScriptCore/InspectorConsoleAgent.h>
+#endif
index 6e48954d60b91219190963f7806c1fc3f6493c60..2e2accbede2da6f43452ba32bc352c456b15b947 100644 (file)
@@ -337,7 +337,6 @@ WebCore_INSPECTOR_DOMAINS := \
     $(WebCore)/inspector/protocol/ApplicationCache.json \
     $(WebCore)/inspector/protocol/CSS.json \
     $(WebCore)/inspector/protocol/Canvas.json \
-    $(WebCore)/inspector/protocol/Console.json \
     $(WebCore)/inspector/protocol/DOM.json \
     $(WebCore)/inspector/protocol/DOMDebugger.json \
     $(WebCore)/inspector/protocol/DOMStorage.json \
index 193975e64ae8267f49457a99f5a6a3c2b6e49a55..2877ddf372adfd9c376b4b1ac26cb1ffcbd3d432 100644 (file)
@@ -2436,8 +2436,6 @@ webcore_sources += \
        Source/WebCore/bindings/js/ScheduledAction.h \
        Source/WebCore/bindings/js/ScriptCachedFrameData.cpp \
        Source/WebCore/bindings/js/ScriptCachedFrameData.h \
-       Source/WebCore/bindings/js/ScriptCallStackFactory.cpp \
-       Source/WebCore/bindings/js/ScriptCallStackFactory.h \
        Source/WebCore/bindings/js/ScriptController.cpp \
        Source/WebCore/bindings/js/ScriptController.h \
        Source/WebCore/bindings/js/ScriptHeapSnapshot.h \
@@ -3744,15 +3742,10 @@ webcore_sources += \
        Source/WebCore/inspector/CommandLineAPIHost.h \
        Source/WebCore/inspector/CommandLineAPIModule.cpp \
        Source/WebCore/inspector/CommandLineAPIModule.h \
-       Source/WebCore/inspector/ConsoleAPITypes.h \
-       Source/WebCore/inspector/ConsoleMessage.cpp \
-       Source/WebCore/inspector/ConsoleMessage.h \
        Source/WebCore/inspector/DOMEditor.cpp \
        Source/WebCore/inspector/DOMEditor.h \
        Source/WebCore/inspector/DOMPatchSupport.cpp \
        Source/WebCore/inspector/DOMPatchSupport.h \
-       Source/WebCore/inspector/IdentifiersFactory.cpp \
-       Source/WebCore/inspector/IdentifiersFactory.h \
        Source/WebCore/inspector/InjectedScriptCanvasModule.cpp \
        Source/WebCore/inspector/InjectedScriptCanvasModule.h \
        Source/WebCore/inspector/InspectorApplicationCacheAgent.cpp \
@@ -3764,8 +3757,6 @@ webcore_sources += \
        Source/WebCore/inspector/InspectorClient.h \
        Source/WebCore/inspector/InspectorController.cpp \
        Source/WebCore/inspector/InspectorController.h \
-       Source/WebCore/inspector/InspectorConsoleAgent.cpp \
-       Source/WebCore/inspector/InspectorConsoleAgent.h \
        Source/WebCore/inspector/InspectorConsoleInstrumentation.h \
        Source/WebCore/inspector/InspectorCounters.cpp \
        Source/WebCore/inspector/InspectorCounters.h \
@@ -3838,14 +3829,10 @@ webcore_sources += \
        Source/WebCore/inspector/PageInjectedScriptManager.h \
        Source/WebCore/inspector/PageRuntimeAgent.cpp \
        Source/WebCore/inspector/PageRuntimeAgent.h \
-       Source/WebCore/inspector/ScriptArguments.cpp \
-       Source/WebCore/inspector/ScriptArguments.h \
-       Source/WebCore/inspector/ScriptCallFrame.cpp \
-       Source/WebCore/inspector/ScriptCallFrame.h \
-       Source/WebCore/inspector/ScriptCallStack.cpp \
-       Source/WebCore/inspector/ScriptCallStack.h \
        Source/WebCore/inspector/TimelineRecordFactory.cpp \
        Source/WebCore/inspector/TimelineRecordFactory.h \
+       Source/WebCore/inspector/WebConsoleAgent.cpp \
+       Source/WebCore/inspector/WebConsoleAgent.h \
        Source/WebCore/inspector/WebDebuggerAgent.cpp \
        Source/WebCore/inspector/WebDebuggerAgent.h \
        Source/WebCore/inspector/WorkerConsoleAgent.cpp \
@@ -4054,7 +4041,6 @@ webcore_sources += \
        Source/WebCore/page/ChromeClient.h \
        Source/WebCore/page/Console.cpp \
        Source/WebCore/page/Console.h \
-       Source/WebCore/page/ConsoleTypes.h \
        Source/WebCore/page/ContentSecurityPolicy.cpp \
        Source/WebCore/page/ContentSecurityPolicy.h \
        Source/WebCore/page/ContextMenuClient.h \
index f6ea30ed53b6e6ec4b54661b1332cb56b50e6b94..91a77e8f77f9acc83a034f3a7445f17dd6175cd3 100644 (file)
@@ -37,8 +37,8 @@
 #include "IDBRequest.h"
 #include "IDBTransaction.h"
 #include "Logging.h"
-#include "ScriptCallStack.h"
 #include "ScriptExecutionContext.h"
+#include <inspector/ScriptCallStack.h>
 #include <limits>
 
 namespace WebCore {
index 401119a84ff75f2304a16200ce4058842da3cd5b..83e47dfe4e2bb5610aefcaf0ba20ecf1b23b5c5f 100644 (file)
@@ -44,9 +44,9 @@
 #include "IDBTransaction.h"
 #include "IDBVersionChangeEvent.h"
 #include "Logging.h"
-#include "ScriptCallStack.h"
 #include "ScriptExecutionContext.h"
 #include <atomic>
+#include <inspector/ScriptCallStack.h>
 #include <limits>
 #include <wtf/Atomics.h>
 
index 8d6d53aaf42d93e0d2884ebc3537ccc71f09ac27..ff250dba8f0ab8ca3eae5fe24c0240508b72d0e5 100644 (file)
@@ -39,7 +39,6 @@
 #include "IDBOpenDBRequest.h"
 #include "IDBPendingTransactionMonitor.h"
 #include "Logging.h"
-#include "ScriptCallStack.h"
 #include "ScriptExecutionContext.h"
 
 namespace WebCore {
index ea3d659385ae94459199eb6d290f77f7aa6dc330..2270a04149a5828b54bd6b245b91210ff2906e4b 100644 (file)
@@ -75,7 +75,7 @@ StorageInfo* DOMWindowQuota::webkitStorageInfo(DOMWindow* window)
 StorageInfo* DOMWindowQuota::webkitStorageInfo() const
 {
     if (!m_storageInfo && frame()) {
-        frame()->document()->addConsoleMessage(JSMessageSource, WarningMessageLevel, "window.webkitStorageInfo is deprecated. Use navigator.webkitTemporaryStorage or navigator.webkitPersistentStorage instead.");
+        frame()->document()->addConsoleMessage(MessageSource::JS, MessageLevel::Warning, ASCIILiteral("window.webkitStorageInfo is deprecated. Use navigator.webkitTemporaryStorage or navigator.webkitPersistentStorage instead."));
         m_storageInfo = StorageInfo::create();
     }
     return m_storageInfo.get();
index 8ee6d61b9dd70862488d8dddff49b8c9bb9ffd5f..6200fc9b3f16dc229bfcc452cda83da6dbc1c384 100644 (file)
 #include "AudioNodeOutput.h"
 #include "AudioUtilities.h"
 #include "FloatConversion.h"
-#include "ScriptCallStack.h"
 #include "ScriptController.h"
 #include "ScriptExecutionContext.h"
 #include <algorithm>
+#include <inspector/ScriptCallStack.h>
 #include <wtf/MainThread.h>
 #include <wtf/MathExtras.h>
 #include <wtf/StdLibExtras.h>
@@ -460,7 +460,7 @@ bool AudioBufferSourceNode::looping()
 {
     static bool firstTime = true;
     if (firstTime && context() && context()->scriptExecutionContext()) {
-        context()->scriptExecutionContext()->addConsoleMessage(JSMessageSource, WarningMessageLevel, "AudioBufferSourceNode 'looping' attribute is deprecated.  Use 'loop' instead.");
+        context()->scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Warning, ASCIILiteral("AudioBufferSourceNode 'looping' attribute is deprecated.  Use 'loop' instead."));
         firstTime = false;
     }
 
@@ -471,7 +471,7 @@ void AudioBufferSourceNode::setLooping(bool looping)
 {
     static bool firstTime = true;
     if (firstTime && context() && context()->scriptExecutionContext()) {
-        context()->scriptExecutionContext()->addConsoleMessage(JSMessageSource, WarningMessageLevel, "AudioBufferSourceNode 'looping' attribute is deprecated.  Use 'loop' instead.");
+        context()->scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Warning, ASCIILiteral("AudioBufferSourceNode 'looping' attribute is deprecated.  Use 'loop' instead."));
         firstTime = false;
     }
 
index 4854ff03bfd6a39ae29c115fe0861f98da8a9ef0..ac2250374f0dec309de30c98f9a9871afebe310a 100644 (file)
@@ -55,7 +55,7 @@
 #include "Page.h"
 #include "PannerNode.h"
 #include "PeriodicWave.h"
-#include "ScriptCallStack.h"
+#include <inspector/ScriptCallStack.h>
 #include "ScriptController.h"
 #include "ScriptProcessorNode.h"
 #include "WaveShaperNode.h"
index 17bf13042585c83e79df654e63e3bcb5d3562ae1..822589fa57abdf32644e260d9ee34d1ab964871a 100644 (file)
@@ -205,7 +205,7 @@ bool PannerNode::setPanningModel(unsigned model)
         break;
     case SOUNDFIELD:
         // FIXME: Implement sound field model. See // https://bugs.webkit.org/show_bug.cgi?id=77367.
-        context()->scriptExecutionContext()->addConsoleMessage(JSMessageSource, WarningMessageLevel, "'soundfield' panning model not implemented.");
+        context()->scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Warning, ASCIILiteral("'soundfield' panning model not implemented."));
         break;
     default:
         return false;
index af2377a7372569cf6b98b1fdf7587a71594bc1a2..5f10bdad59e13cbcad90df5a2080a8eaed920956 100644 (file)
@@ -46,7 +46,7 @@ ScriptExecutionContext* DatabaseBase::scriptExecutionContext() const
 
 void DatabaseBase::logErrorMessage(const String& message)
 {
-    m_scriptExecutionContext->addConsoleMessage(StorageMessageSource, ErrorMessageLevel, message);
+    m_scriptExecutionContext->addConsoleMessage(MessageSource::Storage, MessageLevel::Error, message);
 }
 
 } // namespace WebCore
index 0b60c96aa22754f361667687d1629d2453ddacf8..1f025adb0f695961c18747982b493b2098bbb7c2 100644 (file)
@@ -467,7 +467,7 @@ void DatabaseManager::interruptAllDatabasesForContext(ScriptExecutionContext* co
 
 void DatabaseManager::logErrorMessage(ScriptExecutionContext* context, const String& message)
 {
-    context->addConsoleMessage(StorageMessageSource, ErrorMessageLevel, message);
+    context->addConsoleMessage(MessageSource::Storage, MessageLevel::Error, message);
 }
 
 } // namespace WebCore
index 72b192af343eb596fa09a75e8a05d4cbbbad5c13..d3160d66359dd9406bc1123461bee7a8da709a91 100644 (file)
 #include "Frame.h"
 #include "Logging.h"
 #include "MessageEvent.h"
-#include "ScriptCallStack.h"
 #include "ScriptController.h"
 #include "ScriptExecutionContext.h"
 #include "SecurityOrigin.h"
 #include "ThreadableWebSocketChannel.h"
 #include "WebSocketChannel.h"
+#include <inspector/ScriptCallStack.h>
 #include <runtime/ArrayBuffer.h>
 #include <runtime/ArrayBufferView.h>
 #include <wtf/HashSet.h>
@@ -214,26 +214,26 @@ void WebSocket::connect(const String& url, const Vector<String>& protocols, Exce
     m_url = URL(URL(), url);
 
     if (!m_url.isValid()) {
-        scriptExecutionContext()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "Invalid url for WebSocket " + m_url.stringCenterEllipsizedToLength());
+        scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, "Invalid url for WebSocket " + m_url.stringCenterEllipsizedToLength());
         m_state = CLOSED;
         ec = SYNTAX_ERR;
         return;
     }
 
     if (!m_url.protocolIs("ws") && !m_url.protocolIs("wss")) {
-        scriptExecutionContext()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "Wrong url scheme for WebSocket " + m_url.stringCenterEllipsizedToLength());
+        scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, "Wrong url scheme for WebSocket " + m_url.stringCenterEllipsizedToLength());
         m_state = CLOSED;
         ec = SYNTAX_ERR;
         return;
     }
     if (m_url.hasFragmentIdentifier()) {
-        scriptExecutionContext()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "URL has fragment component " + m_url.stringCenterEllipsizedToLength());
+        scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, "URL has fragment component " + m_url.stringCenterEllipsizedToLength());
         m_state = CLOSED;
         ec = SYNTAX_ERR;
         return;
     }
     if (!portAllowed(m_url)) {
-        scriptExecutionContext()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "WebSocket port " + String::number(m_url.port()) + " blocked");
+        scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, "WebSocket port " + String::number(m_url.port()) + " blocked");
         m_state = CLOSED;
         ec = SECURITY_ERR;
         return;
@@ -264,7 +264,7 @@ void WebSocket::connect(const String& url, const Vector<String>& protocols, Exce
     // comply with WebSocket API specification, but it seems to be the only reasonable way to handle this conflict.
     for (size_t i = 0; i < protocols.size(); ++i) {
         if (!isValidProtocolString(protocols[i])) {
-            scriptExecutionContext()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "Wrong protocol for WebSocket '" + encodeProtocolString(protocols[i]) + "'");
+            scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, "Wrong protocol for WebSocket '" + encodeProtocolString(protocols[i]) + "'");
             m_state = CLOSED;
             ec = SYNTAX_ERR;
             return;
@@ -273,7 +273,7 @@ void WebSocket::connect(const String& url, const Vector<String>& protocols, Exce
     HashSet<String> visited;
     for (size_t i = 0; i < protocols.size(); ++i) {
         if (!visited.add(protocols[i]).isNewEntry) {
-            scriptExecutionContext()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "WebSocket protocols contain duplicates: '" + encodeProtocolString(protocols[i]) + "'");
+            scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, "WebSocket protocols contain duplicates: '" + encodeProtocolString(protocols[i]) + "'");
             m_state = CLOSED;
             ec = SYNTAX_ERR;
             return;
@@ -305,7 +305,7 @@ void WebSocket::send(const String& message, ExceptionCode& ec)
     ASSERT(m_channel);
     ThreadableWebSocketChannel::SendResult result = m_channel->send(message);
     if (result == ThreadableWebSocketChannel::InvalidMessage) {
-        scriptExecutionContext()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "Websocket message contains invalid character(s).");
+        scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, ASCIILiteral("Websocket message contains invalid character(s)."));
         ec = SYNTAX_ERR;
         return;
     }
@@ -378,7 +378,7 @@ void WebSocket::close(int code, const String& reason, ExceptionCode& ec)
         }
         CString utf8 = reason.utf8(StrictConversionReplacingUnpairedSurrogatesWithFFFD);
         if (utf8.length() > maxReasonSizeInBytes) {
-            scriptExecutionContext()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "WebSocket close message is too long.");
+            scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, ASCIILiteral("WebSocket close message is too long."));
             ec = SYNTAX_ERR;
             return;
         }
@@ -443,7 +443,7 @@ void WebSocket::setBinaryType(const String& binaryType)
         m_binaryType = BinaryTypeArrayBuffer;
         return;
     }
-    scriptExecutionContext()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "'" + binaryType + "' is not a valid value for binaryType; binaryType remains unchanged.");
+    scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, "'" + binaryType + "' is not a valid value for binaryType; binaryType remains unchanged.");
 }
 
 EventTargetInterface WebSocket::eventTargetInterface() const
index 7164edc1eb6cac3ec9f34223ebed649129df43c4..81c6f765d28db8a6c7b4002a6490a010e8254d2a 100644 (file)
 #include "Page.h"
 #include "ProgressTracker.h"
 #include "ResourceRequest.h"
-#include "ScriptCallStack.h"
 #include "ScriptExecutionContext.h"
 #include "Settings.h"
 #include "SocketStreamError.h"
 #include "SocketStreamHandle.h"
 #include "WebSocketChannelClient.h"
 #include "WebSocketHandshake.h"
-
 #include <runtime/ArrayBuffer.h>
 #include <wtf/Deque.h>
 #include <wtf/FastMalloc.h>
@@ -198,7 +196,7 @@ void WebSocketChannel::fail(const String& reason)
     ASSERT(!m_suspended);
     if (m_document) {
         InspectorInstrumentation::didReceiveWebSocketFrameError(m_document, m_identifier, reason);
-        m_document->addConsoleMessage(NetworkMessageSource, ErrorMessageLevel, "WebSocket connection to '" + m_handshake->url().stringCenterEllipsizedToLength() + "' failed: " + reason);
+        m_document->addConsoleMessage(MessageSource::Network, MessageLevel::Error, "WebSocket connection to '" + m_handshake->url().stringCenterEllipsizedToLength() + "' failed: " + reason);
     }
 
     // Hybi-10 specification explicitly states we must not continue to handle incoming data
@@ -335,7 +333,7 @@ void WebSocketChannel::didFailSocketStream(SocketStreamHandle* handle, const Soc
         else
             message = "WebSocket network error: " + error.localizedDescription();
         InspectorInstrumentation::didReceiveWebSocketFrameError(m_document, m_identifier, message);
-        m_document->addConsoleMessage(NetworkMessageSource, ErrorMessageLevel, message);
+        m_document->addConsoleMessage(MessageSource::Network, MessageLevel::Error, message);
     }
     m_shouldDiscardReceivedData = true;
     handle->disconnect();
index e6782cf8f58f2aadde2a64dae6efa20f638d1c30..686f4d6bf7c3fb64c5a38f23328ba0b479421ca3 100644 (file)
@@ -44,7 +44,6 @@
 #include "URL.h"
 #include "Logging.h"
 #include "ResourceRequest.h"
-#include "ScriptCallStack.h"
 #include "ScriptExecutionContext.h"
 #include "SecurityOrigin.h"
 #include <wtf/CryptographicallyRandomNumber.h>
index 372e5d99a22a848934907c90319d1562a4e651a9..28dcae4f54a8228fd21f24eb7dc89bc51de42d38 100644 (file)
@@ -159,7 +159,6 @@ list(APPEND WebCore_SOURCES
     bindings/js/PageScriptDebugServer.cpp
     bindings/js/ScheduledAction.cpp
     bindings/js/ScriptCachedFrameData.cpp
-    bindings/js/ScriptCallStackFactory.cpp
     bindings/js/ScriptController.cpp
     bindings/js/ScriptGlobalObject.cpp
     bindings/js/ScriptProfile.cpp
index 8ae2709b935ae9583cfb4a499253e1be383dbca1..a5174c4d8cb368bf401e8749671ca602956fade8 100644 (file)
@@ -2791,7 +2791,6 @@ __ZN7WebCore19InspectorController26setInspectorFrontendClientENSt3__110unique_pt
 __ZN7WebCore19InspectorController39setResourcesDataSizeLimitsFromInternalsEii
 __ZN7WebCore19InspectorController4showEv
 __ZN7WebCore19InspectorController5closeEv
-__ZN7WebCore21InspectorConsoleAgent28consoleMessageArgumentCountsEv
 __ZN7WebCore22instrumentationForPageEPNS_4PageE
 __ZN7WebCore24InspectorInstrumentation17s_frontendCounterE
 __ZN7WebCore24InspectorInstrumentation26instrumentingAgentsForPageEPNS_4PageE
index bcc31e8272ffb53ffad3b50ebe7a080493d4b461..6a216c50cec5850f25a16a0347fdc77dafe64171 100644 (file)
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
     </ClCompile>
-    <ClCompile Include="..\bindings\js\ScriptCallStackFactory.cpp">
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug_WinCairo|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug_WinCairo|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='DebugSuffix|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='DebugSuffix|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
-    </ClCompile>
     <ClCompile Include="..\bindings\js\ScriptController.cpp">
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
     </ClCompile>
-    <ClCompile Include="..\inspector\ConsoleMessage.cpp">
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
-    </ClCompile>
     <ClCompile Include="..\inspector\DOMEditor.cpp">
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
     </ClCompile>
-    <ClCompile Include="..\inspector\IdentifiersFactory.cpp">
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
-    </ClCompile>
     <ClCompile Include="..\inspector\InjectedScriptCanvasModule.cpp">
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
     </ClCompile>
-    <ClCompile Include="..\inspector\InspectorConsoleAgent.cpp">
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
-    </ClCompile>
     <ClCompile Include="..\inspector\InspectorController.cpp">
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
     </ClCompile>
-    <ClCompile Include="..\inspector\ScriptArguments.cpp">
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
-    </ClCompile>
-    <ClCompile Include="..\inspector\ScriptCallFrame.cpp">
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|x64'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
-      <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
-    </ClCompile>
-    <ClCompile Include="..\inspector\ScriptCallStack.cpp">
+    <ClCompile Include="..\inspector\TimelineRecordFactory.cpp">
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Production|x64'">true</ExcludedFromBuild>
     </ClCompile>
-    <ClCompile Include="..\inspector\TimelineRecordFactory.cpp">
+    <ClCompile Include="..\inspector\WebConsoleAgent.cpp">
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
       <ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release_WinCairo|Win32'">true</ExcludedFromBuild>
     <ClInclude Include="..\ForwardingHeaders\heap\SlotVisitor.h" />
     <ClInclude Include="..\ForwardingHeaders\heap\StrongInlines.h" />
     <ClInclude Include="..\ForwardingHeaders\heap\Weak.h" />
+    <ClInclude Include="..\ForwardingHeaders\inspector\ConsoleMessage.h" />
+    <ClInclude Include="..\ForwardingHeaders\inspector\ConsoleTypes.h" />
+    <ClInclude Include="..\ForwardingHeaders\inspector\IdentifiersFactory.h" />
     <ClInclude Include="..\ForwardingHeaders\inspector\InjectedScript.h" />
     <ClInclude Include="..\ForwardingHeaders\inspector\InjectedScriptBase.h" />
     <ClInclude Include="..\ForwardingHeaders\inspector\InjectedScriptHost.h" />
     <ClInclude Include="..\ForwardingHeaders\inspector\InspectorJSTypeBuilders.h" />
     <ClInclude Include="..\ForwardingHeaders\inspector\InspectorTypeBuilder.h" />
     <ClInclude Include="..\ForwardingHeaders\inspector\InspectorValues.h" />
+    <ClInclude Include="..\ForwardingHeaders\inspector\ScriptArguments.h" />
+    <ClInclude Include="..\ForwardingHeaders\inspector\ScriptBreakpoint.h" />
+    <ClInclude Include="..\ForwardingHeaders\inspector\ScriptCallFrame.h" />
+    <ClInclude Include="..\ForwardingHeaders\inspector\ScriptCallStack.h" />
+    <ClInclude Include="..\ForwardingHeaders\inspector\ScriptCallStackFactory.h" />
     <ClInclude Include="..\ForwardingHeaders\inspector\agents\InspectorAgent.h" />
+    <ClInclude Include="..\ForwardingHeaders\inspector\agents\InspectorConsoleAgent.h" />
+    <ClInclude Include="..\ForwardingHeaders\inspector\agents\InspectorDebuggerAgent.h" />
     <ClInclude Include="..\ForwardingHeaders\inspector\agents\InspectorRuntimeAgent.h" />
     <ClInclude Include="..\ForwardingHeaders\masm\X86Assembler.h" />
     <ClInclude Include="..\ForwardingHeaders\parser\SourceCode.h" />
     <ClInclude Include="..\page\ChromeClient.h" />
     <ClInclude Include="..\page\animation\CompositeAnimation.h" />
     <ClInclude Include="..\page\Console.h" />
-    <ClInclude Include="..\page\ConsoleTypes.h" />
     <ClInclude Include="..\page\ContentSecurityPolicy.h" />
     <ClInclude Include="..\page\ContextMenuClient.h" />
     <ClInclude Include="..\page\ContextMenuController.h" />
     <ClInclude Include="..\bindings\js\PageScriptDebugServer.h" />
     <ClInclude Include="..\bindings\js\ScheduledAction.h" />
     <ClInclude Include="..\bindings\js\ScriptCachedFrameData.h" />
-    <ClInclude Include="..\bindings\js\ScriptCallStackFactory.h" />
     <ClInclude Include="..\bindings\js\ScriptController.h" />
     <ClInclude Include="..\bindings\js\ScriptHeapSnapshot.h" />
     <ClInclude Include="..\bindings\js\ScriptGlobalObject.h" />
     <ClInclude Include="..\bridge\runtime_method.h" />
     <ClInclude Include="..\bridge\runtime_object.h" />
     <ClInclude Include="..\bridge\runtime_root.h" />
-    <ClInclude Include="..\inspector\ConsoleAPITypes.h" />
     <ClInclude Include="..\inspector\CommandLineAPIHost.h" />
     <ClInclude Include="..\inspector\CommandLineAPIModule.h" />
-    <ClInclude Include="..\inspector\ConsoleMessage.h" />
     <ClInclude Include="..\inspector\DOMEditor.h" />
     <ClInclude Include="..\inspector\DOMPatchSupport.h" />
-    <ClInclude Include="..\inspector\IdentifiersFactory.h" />
     <ClInclude Include="..\inspector\InjectedScriptCanvasModule.h" />
     <ClInclude Include="..\inspector\InspectorApplicationCacheAgent.h" />
     <ClInclude Include="..\inspector\InspectorCanvasAgent.h" />
     <ClInclude Include="..\inspector\InspectorCanvasInstrumentation.h" />
     <ClInclude Include="..\inspector\InspectorClient.h" />
-    <ClInclude Include="..\inspector\InspectorConsoleAgent.h" />
     <ClInclude Include="..\inspector\InspectorConsoleInstrumentation.h" />
     <ClInclude Include="..\inspector\InspectorController.h" />
     <ClInclude Include="..\inspector\InspectorCounters.h" />
     <ClInclude Include="..\inspector\PageInjectedScriptHost.h" />
     <ClInclude Include="..\inspector\PageInjectedScriptManager.h" />
     <ClInclude Include="..\inspector\PageRuntimeAgent.h" />
-    <ClInclude Include="..\inspector\ScriptArguments.h" />
-    <ClInclude Include="..\inspector\ScriptCallFrame.h" />
-    <ClInclude Include="..\inspector\ScriptCallStack.h" />
     <ClInclude Include="..\inspector\TimelineRecordFactory.h" />
+    <ClInclude Include="..\inspector\WebConsoleAgent.h" />
     <ClInclude Include="..\inspector\WebDebuggerAgent.h" />
     <ClInclude Include="..\inspector\WorkerConsoleAgent.h" />
     <ClInclude Include="..\inspector\WorkerDebuggerAgent.h" />
index eef78a5031e15a4f126924999a26b341a5e66d0c..b715d87aae4255bceaa77cf77a00454f880d2762 100644 (file)
     <ClCompile Include="..\bindings\js\ScriptCachedFrameData.cpp">
       <Filter>bindings\js</Filter>
     </ClCompile>
-    <ClCompile Include="..\bindings\js\ScriptCallStackFactory.cpp">
-      <Filter>bindings\js</Filter>
-    </ClCompile>
     <ClCompile Include="..\bindings\js\ScriptController.cpp">
       <Filter>bindings\js</Filter>
     </ClCompile>
     <ClCompile Include="..\inspector\CommandLineAPIModule.cpp">
       <Filter>inspector</Filter>
     </ClCompile>
-    <ClCompile Include="..\inspector\ConsoleMessage.cpp">
-      <Filter>inspector</Filter>
-    </ClCompile>
     <ClCompile Include="..\inspector\DOMEditor.cpp">
       <Filter>inspector</Filter>
     </ClCompile>
     <ClCompile Include="..\inspector\DOMPatchSupport.cpp">
       <Filter>inspector</Filter>
     </ClCompile>
-    <ClCompile Include="..\inspector\IdentifiersFactory.cpp">
-      <Filter>inspector</Filter>
-    </ClCompile>
     <ClCompile Include="..\inspector\InjectedScriptCanvasModule.cpp">
       <Filter>inspector</Filter>
     </ClCompile>
     <ClCompile Include="..\inspector\InspectorClient.cpp">
       <Filter>inspector</Filter>
     </ClCompile>
-    <ClCompile Include="..\inspector\InspectorConsoleAgent.cpp">
-      <Filter>inspector</Filter>
-    </ClCompile>
     <ClCompile Include="..\inspector\InspectorController.cpp">
       <Filter>inspector</Filter>
     </ClCompile>
     <ClCompile Include="..\inspector\PageRuntimeAgent.cpp">
       <Filter>inspector</Filter>
     </ClCompile>
-    <ClCompile Include="..\inspector\ScriptArguments.cpp">
-      <Filter>inspector</Filter>
-    </ClCompile>
-    <ClCompile Include="..\inspector\ScriptCallFrame.cpp">
-      <Filter>inspector</Filter>
-    </ClCompile>
-    <ClCompile Include="..\inspector\ScriptCallStack.cpp">
+    <ClCompile Include="..\inspector\TimelineRecordFactory.cpp">
       <Filter>inspector</Filter>
     </ClCompile>
-    <ClCompile Include="..\inspector\TimelineRecordFactory.cpp">
+    <ClCompile Include="..\inspector\WebConsoleAgent.cpp">
       <Filter>inspector</Filter>
     </ClCompile>
     <ClCompile Include="..\inspector\WebDebuggerAgent.cpp">
     <ClInclude Include="..\page\Console.h">
       <Filter>page</Filter>
     </ClInclude>
-    <ClInclude Include="..\page\ConsoleTypes.h">
-      <Filter>page</Filter>
-    </ClInclude>
     <ClInclude Include="..\page\ContentSecurityPolicy.h">
       <Filter>page</Filter>
     </ClInclude>
     <ClInclude Include="..\bindings\js\ScriptCachedFrameData.h">
       <Filter>bindings\js</Filter>
     </ClInclude>
-    <ClInclude Include="..\bindings\js\ScriptCallStackFactory.h">
-      <Filter>bindings\js</Filter>
-    </ClInclude>
     <ClInclude Include="..\bindings\js\ScriptController.h">
       <Filter>bindings\js</Filter>
     </ClInclude>
     <ClInclude Include="..\ForwardingHeaders\heap\Strong.h">
       <Filter>ForwardingHeaders\heap</Filter>
     </ClInclude>
+    <ClInclude Include="..\ForwardingHeaders\inspector\ConsoleMessage.h">
+      <Filter>ForwardingHeaders\inspector</Filter>
+    </ClInclude>
+    <ClInclude Include="..\ForwardingHeaders\inspector\ConsoleTypes.h">
+      <Filter>ForwardingHeaders\inspector</Filter>
+    </ClInclude>
+    <ClInclude Include="..\ForwardingHeaders\inspector\IdentifiersFactory.h">
+      <Filter>ForwardingHeaders\inspector</Filter>
+    </ClInclude>
     <ClInclude Include="..\ForwardingHeaders\inspector\InjectedScript.h">
       <Filter>ForwardingHeaders\inspector</Filter>
     </ClInclude>
     <ClInclude Include="..\ForwardingHeaders\inspector\InspectorValues.h">
       <Filter>ForwardingHeaders\inspector</Filter>
     </ClInclude>
+    <ClInclude Include="..\ForwardingHeaders\inspector\ScriptArguments.h">
+      <Filter>ForwardingHeaders\inspector</Filter>
+    </ClInclude>
+    <ClInclude Include="..\ForwardingHeaders\inspector\ScriptBreakpoint.h">
+      <Filter>ForwardingHeaders\inspector</Filter>
+    </ClInclude>
+    <ClInclude Include="..\ForwardingHeaders\inspector\ScriptCallFrame.h">
+      <Filter>ForwardingHeaders\inspector</Filter>
+    </ClInclude>
+    <ClInclude Include="..\ForwardingHeaders\inspector\ScriptCallStack.h">
+      <Filter>ForwardingHeaders\inspector</Filter>
+    </ClInclude>
+    <ClInclude Include="..\ForwardingHeaders\inspector\ScriptCallStackFactory.h">
+      <Filter>ForwardingHeaders\inspector</Filter>
+    </ClInclude>
     <ClInclude Include="..\ForwardingHeaders\inspector\agents\InspectorAgent.h">
       <Filter>ForwardingHeaders\inspector</Filter>
     </ClInclude>
+    <ClInclude Include="..\ForwardingHeaders\inspector\agents\InspectorConsoleAgent.h">
+      <Filter>ForwardingHeaders\inspector</Filter>
+    </ClInclude>
+    <ClInclude Include="..\ForwardingHeaders\inspector\agents\InspectorDebuggerAgent.h">
+      <Filter>ForwardingHeaders\inspector</Filter>
+    </ClInclude>
     <ClInclude Include="..\ForwardingHeaders\inspector\agents\InspectorRuntimeAgent.h">
       <Filter>ForwardingHeaders\inspector</Filter>
     </ClInclude>
     <ClInclude Include="..\inspector\CommandLineAPIModule.h">
       <Filter>inspector</Filter>
     </ClInclude>
-    <ClInclude Include="..\inspector\ConsoleAPITypes.h">
-      <Filter>inspector</Filter>
-    </ClInclude>
-    <ClInclude Include="..\inspector\ConsoleMessage.h">
-      <Filter>inspector</Filter>
-    </ClInclude>
     <ClInclude Include="..\inspector\DOMEditor.h">
       <Filter>inspector</Filter>
     </ClInclude>
     <ClInclude Include="..\inspector\DOMPatchSupport.h">
       <Filter>inspector</Filter>
     </ClInclude>
-    <ClInclude Include="..\inspector\IdentifiersFactory.h">
-      <Filter>inspector</Filter>
-    </ClInclude>
     <ClInclude Include="..\inspector\InjectedScriptCanvasModule.h">
       <Filter>inspector</Filter>
     </ClInclude>
     <ClInclude Include="..\inspector\InspectorClient.h">
       <Filter>inspector</Filter>
     </ClInclude>
-    <ClInclude Include="..\inspector\InspectorConsoleAgent.h">
-      <Filter>inspector</Filter>
-    </ClInclude>
     <ClInclude Include="..\inspector\InspectorConsoleInstrumentation.h">
       <Filter>inspector</Filter>
     </ClInclude>
     <ClInclude Include="..\inspector\PageRuntimeAgent.h">
       <Filter>inspector</Filter>
     </ClInclude>
-    <ClInclude Include="..\inspector\ScriptArguments.h">
-      <Filter>inspector</Filter>
-    </ClInclude>
-    <ClInclude Include="..\inspector\ScriptCallFrame.h">
-      <Filter>inspector</Filter>
-    </ClInclude>
-    <ClInclude Include="..\inspector\ScriptCallStack.h">
+    <ClInclude Include="..\inspector\TimelineRecordFactory.h">
       <Filter>inspector</Filter>
     </ClInclude>
-    <ClInclude Include="..\inspector\TimelineRecordFactory.h">
+    <ClInclude Include="..\inspector\WebConsoleAgent.h">
       <Filter>inspector</Filter>
     </ClInclude>
     <ClInclude Include="..\inspector\WebDebuggerAgent.h">
index aca855c478979504a0d237c3414c44fa6593684f..8c7ef41fe5adcb97b6b94d8f9d3a541e00fad245 100644 (file)
                2D9F0E1314FF1CBF00BA0FF7 /* linearSRGB.icc in Resources */ = {isa = PBXBuildFile; fileRef = 2D9F0E1214FF1CBF00BA0FF7 /* linearSRGB.icc */; };
                2DBADE0B188E5915004D7981 /* WebCoreCALayerExtras.h in Headers */ = {isa = PBXBuildFile; fileRef = 2DBADE09188E5915004D7981 /* WebCoreCALayerExtras.h */; settings = {ATTRIBUTES = (Private, ); }; };
                2DBADE0C188E5915004D7981 /* WebCoreCALayerExtras.mm in Sources */ = {isa = PBXBuildFile; fileRef = 2DBADE0A188E5915004D7981 /* WebCoreCALayerExtras.mm */; };
-               2DF2E9D5166E39750035BEF2 /* ConsoleAPITypes.h in Headers */ = {isa = PBXBuildFile; fileRef = 2DF2E9D4166E39740035BEF2 /* ConsoleAPITypes.h */; settings = {ATTRIBUTES = (Private, ); }; };
                2E0888D41148848A00AF4265 /* JSDOMFormData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2E0888D21148848A00AF4265 /* JSDOMFormData.cpp */; };
                2E0888D51148848A00AF4265 /* JSDOMFormData.h in Headers */ = {isa = PBXBuildFile; fileRef = 2E0888D31148848A00AF4265 /* JSDOMFormData.h */; };
                2E0888E6114884E200AF4265 /* JSDOMFormDataCustom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2E0888E5114884E200AF4265 /* JSDOMFormDataCustom.cpp */; };
                4167EBF5102962BA003D252A /* DefaultSharedWorkerRepository.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 4167EBF3102962BA003D252A /* DefaultSharedWorkerRepository.cpp */; };
                4167EBF6102962BA003D252A /* DefaultSharedWorkerRepository.h in Headers */ = {isa = PBXBuildFile; fileRef = 4167EBF4102962BA003D252A /* DefaultSharedWorkerRepository.h */; };
                416E29A6102FA962007FC14E /* WorkerReportingProxy.h in Headers */ = {isa = PBXBuildFile; fileRef = 416E29A5102FA962007FC14E /* WorkerReportingProxy.h */; };
-               416E75BE0EDF8FD700360E1D /* ScriptCallStack.h in Headers */ = {isa = PBXBuildFile; fileRef = 416E75BC0EDF8FD700360E1D /* ScriptCallStack.h */; settings = {ATTRIBUTES = (Private, ); }; };
-               416E75BF0EDF8FD700360E1D /* ScriptCallStack.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 416E75BD0EDF8FD700360E1D /* ScriptCallStack.cpp */; };
-               416E75CB0EDF90C700360E1D /* ScriptCallFrame.h in Headers */ = {isa = PBXBuildFile; fileRef = 416E75C90EDF90C700360E1D /* ScriptCallFrame.h */; settings = {ATTRIBUTES = (Private, ); }; };
-               416E75CC0EDF90C700360E1D /* ScriptCallFrame.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 416E75CA0EDF90C700360E1D /* ScriptCallFrame.cpp */; };
                417253AA1354BBBC00360F2A /* MediaControlElements.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 417253A81354BBBC00360F2A /* MediaControlElements.cpp */; };
                417253AB1354BBBC00360F2A /* MediaControlElements.h in Headers */ = {isa = PBXBuildFile; fileRef = 417253A91354BBBC00360F2A /* MediaControlElements.h */; };
                417DA6D913734E6E007C57FB /* Internals.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 417DA4CF13734326007C57FB /* Internals.cpp */; };
                41E1B1D10FF5986900576B3B /* AbstractWorker.h in Headers */ = {isa = PBXBuildFile; fileRef = 41E1B1CB0FF5986900576B3B /* AbstractWorker.h */; };
                41E1B1D30FF5986900576B3B /* SharedWorker.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 41E1B1CD0FF5986900576B3B /* SharedWorker.cpp */; };
                41E1B1D40FF5986900576B3B /* SharedWorker.h in Headers */ = {isa = PBXBuildFile; fileRef = 41E1B1CE0FF5986900576B3B /* SharedWorker.h */; };
-               41F0618E0F5F069800A07EAC /* ConsoleMessage.h in Headers */ = {isa = PBXBuildFile; fileRef = 41F0618C0F5F069800A07EAC /* ConsoleMessage.h */; };
-               41F0618F0F5F069800A07EAC /* ConsoleMessage.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 41F0618D0F5F069800A07EAC /* ConsoleMessage.cpp */; };
                41F062140F5F192600A07EAC /* InspectorDatabaseResource.h in Headers */ = {isa = PBXBuildFile; fileRef = 41F062120F5F192600A07EAC /* InspectorDatabaseResource.h */; };
                41F062150F5F192600A07EAC /* InspectorDatabaseResource.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 41F062130F5F192600A07EAC /* InspectorDatabaseResource.cpp */; };
                41F066E40F64BCF600A07EAC /* ScriptGlobalObject.h in Headers */ = {isa = PBXBuildFile; fileRef = 41F066E20F64BCF600A07EAC /* ScriptGlobalObject.h */; settings = {ATTRIBUTES = (Private, ); }; };
                5905ADC01302F3CE00F116DF /* XMLTreeViewer.h in Headers */ = {isa = PBXBuildFile; fileRef = 5905ADBE1302F3CE00F116DF /* XMLTreeViewer.h */; };
                590E1B4911E4EF4B0069F784 /* DeviceOrientationData.h in Headers */ = {isa = PBXBuildFile; fileRef = 590E1B4811E4EF4B0069F784 /* DeviceOrientationData.h */; settings = {ATTRIBUTES = (Private, ); }; };
                590E1B4B11E4EF700069F784 /* JSDeviceOrientationEventCustom.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 590E1B4A11E4EF700069F784 /* JSDeviceOrientationEventCustom.cpp */; };
-               5913A24113D49EBA00F5B05C /* IdentifiersFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5913A23F13D49EBA00F5B05C /* IdentifiersFactory.cpp */; };
-               5913A24213D49EBA00F5B05C /* IdentifiersFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = 5913A24013D49EBA00F5B05C /* IdentifiersFactory.h */; };
                59309A1111F4AE5800250603 /* DeviceOrientationClientMock.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 59309A1011F4AE5800250603 /* DeviceOrientationClientMock.cpp */; };
                59309A1311F4AE6A00250603 /* DeviceOrientationClientMock.h in Headers */ = {isa = PBXBuildFile; fileRef = 59309A1211F4AE6A00250603 /* DeviceOrientationClientMock.h */; settings = {ATTRIBUTES = (Private, ); }; };
                598365DD1355F557001B185D /* JSPositionCallback.h in Headers */ = {isa = PBXBuildFile; fileRef = 598365DC1355F53C001B185D /* JSPositionCallback.h */; };
                A5416FE618810EF80009FC5F /* YouTubeEmbedShadowElement.h in Headers */ = {isa = PBXBuildFile; fileRef = A5416FE418810EF80009FC5F /* YouTubeEmbedShadowElement.h */; };
                A54A82EC15228D2F00C72BA6 /* DOMNodePrivate.h in Headers */ = {isa = PBXBuildFile; fileRef = A54A82EA15228CA300C72BA6 /* DOMNodePrivate.h */; };
                A54A82F115228DF600C72BA6 /* DOMNodePrivate.h in Copy Generated Headers */ = {isa = PBXBuildFile; fileRef = A54A82EA15228CA300C72BA6 /* DOMNodePrivate.h */; };
+               A56C5B9A189F34570082D13C /* WebConsoleAgent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A56C5B98189F34570082D13C /* WebConsoleAgent.cpp */; };
+               A56C5B9B189F34570082D13C /* WebConsoleAgent.h in Headers */ = {isa = PBXBuildFile; fileRef = A56C5B99189F34570082D13C /* WebConsoleAgent.h */; };
                A5732B0A136A161D005C8D7C /* DateComponents.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5732B08136A161D005C8D7C /* DateComponents.cpp */; };
                A5732B0B136A161D005C8D7C /* DateComponents.h in Headers */ = {isa = PBXBuildFile; fileRef = A5732B09136A161D005C8D7C /* DateComponents.h */; settings = {ATTRIBUTES = (Private, ); }; };
                A5840E1C187B74D500843B10 /* InspectorInstrumentationCookie.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A5840E1A187B74D500843B10 /* InspectorInstrumentationCookie.cpp */; };
                BCE4413312F748E2009B84B8 /* RenderCombineText.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BCE4413112F748E2009B84B8 /* RenderCombineText.cpp */; };
                BCE4413412F748E2009B84B8 /* RenderCombineText.h in Headers */ = {isa = PBXBuildFile; fileRef = BCE4413212F748E2009B84B8 /* RenderCombineText.h */; };
                BCE4413612F7490B009B84B8 /* FontWidthVariant.h in Headers */ = {isa = PBXBuildFile; fileRef = BCE4413512F7490B009B84B8 /* FontWidthVariant.h */; settings = {ATTRIBUTES = (Private, ); }; };
-               BCE5644E137A34D6007D2934 /* ConsoleTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = BCE5644D137A34D6007D2934 /* ConsoleTypes.h */; settings = {ATTRIBUTES = (Private, ); }; };
                BCE658FF0EA9248A007E4533 /* Theme.h in Headers */ = {isa = PBXBuildFile; fileRef = BCE658FE0EA9248A007E4533 /* Theme.h */; settings = {ATTRIBUTES = (Private, ); }; };
                BCE659A90EA927B9007E4533 /* ThemeTypes.h in Headers */ = {isa = PBXBuildFile; fileRef = BCE659A80EA927B9007E4533 /* ThemeTypes.h */; settings = {ATTRIBUTES = (Private, ); }; };
                BCE659E60EA92FB2007E4533 /* ThemeMac.h in Headers */ = {isa = PBXBuildFile; fileRef = BCE659E50EA92FB2007E4533 /* ThemeMac.h */; };
                F293B27E56C112F373FFF27E /* DNSResolveQueue.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7C60128060078BB70E367A95 /* DNSResolveQueue.cpp */; };
                F325A40A14EE36FA007324E2 /* InspectorCounters.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F325A40814EE36FA007324E2 /* InspectorCounters.cpp */; };
                F325A40B14EE36FA007324E2 /* InspectorCounters.h in Headers */ = {isa = PBXBuildFile; fileRef = F325A40914EE36FA007324E2 /* InspectorCounters.h */; settings = {ATTRIBUTES = (Private, ); }; };
-               F3335BF812E07DC300D33011 /* InspectorConsoleAgent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F3335BF612E07DC300D33011 /* InspectorConsoleAgent.cpp */; };
-               F3335BF912E07DC300D33011 /* InspectorConsoleAgent.h in Headers */ = {isa = PBXBuildFile; fileRef = F3335BF712E07DC300D33011 /* InspectorConsoleAgent.h */; };
                F33F0282120947F200E5743A /* ScriptProfile.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F33F0281120947F200E5743A /* ScriptProfile.cpp */; };
                F344C7141125B82C00F26EEE /* InspectorFrontendClient.h in Headers */ = {isa = PBXBuildFile; fileRef = F344C7121125B82C00F26EEE /* InspectorFrontendClient.h */; settings = {ATTRIBUTES = (Private, ); }; };
                F344C75311294D9D00F26EEE /* InspectorFrontendClientLocal.h in Headers */ = {isa = PBXBuildFile; fileRef = F344C75211294D9D00F26EEE /* InspectorFrontendClientLocal.h */; settings = {ATTRIBUTES = (Private, ); }; };
                F3820897147D35F90010BC06 /* WorkerConsoleAgent.h in Headers */ = {isa = PBXBuildFile; fileRef = F382088F147D35F90010BC06 /* WorkerConsoleAgent.h */; };
                F3820898147D35F90010BC06 /* WorkerRuntimeAgent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F3820890147D35F90010BC06 /* WorkerRuntimeAgent.cpp */; };
                F3820899147D35F90010BC06 /* WorkerRuntimeAgent.h in Headers */ = {isa = PBXBuildFile; fileRef = F3820891147D35F90010BC06 /* WorkerRuntimeAgent.h */; };
-               F392249C126F11AE00A926D9 /* ScriptCallStackFactory.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F392249A126F11AE00A926D9 /* ScriptCallStackFactory.cpp */; };
-               F392249D126F11AE00A926D9 /* ScriptCallStackFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = F392249B126F11AE00A926D9 /* ScriptCallStackFactory.h */; };
-               F39BE95B12673BF400E0A674 /* ScriptArguments.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F39BE95912673BF400E0A674 /* ScriptArguments.cpp */; };
-               F39BE95C12673BF400E0A674 /* ScriptArguments.h in Headers */ = {isa = PBXBuildFile; fileRef = F39BE95A12673BF400E0A674 /* ScriptArguments.h */; };
                F3ABFE0C130E9DA000E7F7D1 /* InstrumentingAgents.h in Headers */ = {isa = PBXBuildFile; fileRef = F3ABFE0B130E9DA000E7F7D1 /* InstrumentingAgents.h */; };
                F3D461481161D53200CA0D09 /* JSErrorHandler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = F3D461461161D53200CA0D09 /* JSErrorHandler.cpp */; };
                F3D461491161D53200CA0D09 /* JSErrorHandler.h in Headers */ = {isa = PBXBuildFile; fileRef = F3D461471161D53200CA0D09 /* JSErrorHandler.h */; };
                2D9F0E1214FF1CBF00BA0FF7 /* linearSRGB.icc */ = {isa = PBXFileReference; lastKnownFileType = file; path = linearSRGB.icc; sourceTree = "<group>"; };
                2DBADE09188E5915004D7981 /* WebCoreCALayerExtras.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebCoreCALayerExtras.h; sourceTree = "<group>"; };
                2DBADE0A188E5915004D7981 /* WebCoreCALayerExtras.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebCoreCALayerExtras.mm; sourceTree = "<group>"; };
-               2DF2E9D4166E39740035BEF2 /* ConsoleAPITypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ConsoleAPITypes.h; sourceTree = "<group>"; };
                2E0888C3114883A900AF4265 /* DOMFormData.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = DOMFormData.idl; sourceTree = "<group>"; };
                2E0888D21148848A00AF4265 /* JSDOMFormData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSDOMFormData.cpp; sourceTree = "<group>"; };
                2E0888D31148848A00AF4265 /* JSDOMFormData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSDOMFormData.h; sourceTree = "<group>"; };
                4167EBF3102962BA003D252A /* DefaultSharedWorkerRepository.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DefaultSharedWorkerRepository.cpp; path = workers/DefaultSharedWorkerRepository.cpp; sourceTree = "<group>"; };
                4167EBF4102962BA003D252A /* DefaultSharedWorkerRepository.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = DefaultSharedWorkerRepository.h; path = workers/DefaultSharedWorkerRepository.h; sourceTree = "<group>"; };
                416E29A5102FA962007FC14E /* WorkerReportingProxy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WorkerReportingProxy.h; path = workers/WorkerReportingProxy.h; sourceTree = "<group>"; };
-               416E75BC0EDF8FD700360E1D /* ScriptCallStack.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScriptCallStack.h; sourceTree = "<group>"; };
-               416E75BD0EDF8FD700360E1D /* ScriptCallStack.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScriptCallStack.cpp; sourceTree = "<group>"; };
-               416E75C90EDF90C700360E1D /* ScriptCallFrame.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScriptCallFrame.h; sourceTree = "<group>"; };
-               416E75CA0EDF90C700360E1D /* ScriptCallFrame.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScriptCallFrame.cpp; sourceTree = "<group>"; };
                417253A81354BBBC00360F2A /* MediaControlElements.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MediaControlElements.cpp; sourceTree = "<group>"; };
                417253A91354BBBC00360F2A /* MediaControlElements.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MediaControlElements.h; sourceTree = "<group>"; };
                417DA4CE13734326007C57FB /* Internals.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Internals.h; sourceTree = "<group>"; };
                41E1B1CD0FF5986900576B3B /* SharedWorker.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = SharedWorker.cpp; path = workers/SharedWorker.cpp; sourceTree = "<group>"; };
                41E1B1CE0FF5986900576B3B /* SharedWorker.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SharedWorker.h; path = workers/SharedWorker.h; sourceTree = "<group>"; };
                41E1B1CF0FF5986900576B3B /* SharedWorker.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = SharedWorker.idl; path = workers/SharedWorker.idl; sourceTree = "<group>"; };
-               41F0618C0F5F069800A07EAC /* ConsoleMessage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ConsoleMessage.h; sourceTree = "<group>"; };
-               41F0618D0F5F069800A07EAC /* ConsoleMessage.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ConsoleMessage.cpp; sourceTree = "<group>"; };
                41F062120F5F192600A07EAC /* InspectorDatabaseResource.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorDatabaseResource.h; sourceTree = "<group>"; };
                41F062130F5F192600A07EAC /* InspectorDatabaseResource.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InspectorDatabaseResource.cpp; sourceTree = "<group>"; };
                41F066E20F64BCF600A07EAC /* ScriptGlobalObject.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScriptGlobalObject.h; sourceTree = "<group>"; };
                5905ADBE1302F3CE00F116DF /* XMLTreeViewer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = XMLTreeViewer.h; sourceTree = "<group>"; };
                590E1B4811E4EF4B0069F784 /* DeviceOrientationData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DeviceOrientationData.h; sourceTree = "<group>"; };
                590E1B4A11E4EF700069F784 /* JSDeviceOrientationEventCustom.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSDeviceOrientationEventCustom.cpp; sourceTree = "<group>"; };
-               5913A23F13D49EBA00F5B05C /* IdentifiersFactory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IdentifiersFactory.cpp; sourceTree = "<group>"; };
-               5913A24013D49EBA00F5B05C /* IdentifiersFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = IdentifiersFactory.h; sourceTree = "<group>"; };
                59309A1011F4AE5800250603 /* DeviceOrientationClientMock.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DeviceOrientationClientMock.cpp; sourceTree = "<group>"; };
                59309A1211F4AE6A00250603 /* DeviceOrientationClientMock.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DeviceOrientationClientMock.h; sourceTree = "<group>"; };
                5958F1CB1343917C0080B31F /* XMLViewer.css */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.css; path = XMLViewer.css; sourceTree = "<group>"; };
                A5416FE318810EF80009FC5F /* YouTubeEmbedShadowElement.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = YouTubeEmbedShadowElement.cpp; sourceTree = "<group>"; };
                A5416FE418810EF80009FC5F /* YouTubeEmbedShadowElement.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = YouTubeEmbedShadowElement.h; sourceTree = "<group>"; };
                A54A82EA15228CA300C72BA6 /* DOMNodePrivate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DOMNodePrivate.h; sourceTree = "<group>"; };
+               A56C5B98189F34570082D13C /* WebConsoleAgent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebConsoleAgent.cpp; sourceTree = "<group>"; };
+               A56C5B99189F34570082D13C /* WebConsoleAgent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebConsoleAgent.h; sourceTree = "<group>"; };
                A5732B08136A161D005C8D7C /* DateComponents.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = DateComponents.cpp; sourceTree = "<group>"; };
                A5732B09136A161D005C8D7C /* DateComponents.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DateComponents.h; sourceTree = "<group>"; };
                A5840E1A187B74D500843B10 /* InspectorInstrumentationCookie.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InspectorInstrumentationCookie.cpp; sourceTree = "<group>"; };
                BCE4413112F748E2009B84B8 /* RenderCombineText.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = RenderCombineText.cpp; sourceTree = "<group>"; };
                BCE4413212F748E2009B84B8 /* RenderCombineText.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RenderCombineText.h; sourceTree = "<group>"; };
                BCE4413512F7490B009B84B8 /* FontWidthVariant.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = FontWidthVariant.h; sourceTree = "<group>"; };
-               BCE5644D137A34D6007D2934 /* ConsoleTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ConsoleTypes.h; sourceTree = "<group>"; };
                BCE658FE0EA9248A007E4533 /* Theme.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Theme.h; sourceTree = "<group>"; };
                BCE659A80EA927B9007E4533 /* ThemeTypes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ThemeTypes.h; sourceTree = "<group>"; };
                BCE659E50EA92FB2007E4533 /* ThemeMac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ThemeMac.h; sourceTree = "<group>"; };
                F12171F416A8BC63000053CA /* WebVTTElement.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebVTTElement.h; sourceTree = "<group>"; };
                F325A40814EE36FA007324E2 /* InspectorCounters.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InspectorCounters.cpp; sourceTree = "<group>"; };
                F325A40914EE36FA007324E2 /* InspectorCounters.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorCounters.h; sourceTree = "<group>"; };
-               F3335BF612E07DC300D33011 /* InspectorConsoleAgent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InspectorConsoleAgent.cpp; sourceTree = "<group>"; };
-               F3335BF712E07DC300D33011 /* InspectorConsoleAgent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorConsoleAgent.h; sourceTree = "<group>"; };
                F33F0281120947F200E5743A /* ScriptProfile.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScriptProfile.cpp; sourceTree = "<group>"; };
                F344C7121125B82C00F26EEE /* InspectorFrontendClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorFrontendClient.h; sourceTree = "<group>"; };
                F344C75211294D9D00F26EEE /* InspectorFrontendClientLocal.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorFrontendClientLocal.h; sourceTree = "<group>"; };
                F382088F147D35F90010BC06 /* WorkerConsoleAgent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WorkerConsoleAgent.h; sourceTree = "<group>"; };
                F3820890147D35F90010BC06 /* WorkerRuntimeAgent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WorkerRuntimeAgent.cpp; sourceTree = "<group>"; };
                F3820891147D35F90010BC06 /* WorkerRuntimeAgent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WorkerRuntimeAgent.h; sourceTree = "<group>"; };
-               F392249A126F11AE00A926D9 /* ScriptCallStackFactory.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScriptCallStackFactory.cpp; sourceTree = "<group>"; };
-               F392249B126F11AE00A926D9 /* ScriptCallStackFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScriptCallStackFactory.h; sourceTree = "<group>"; };
-               F39BE95912673BF400E0A674 /* ScriptArguments.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = ScriptArguments.cpp; sourceTree = "<group>"; };
-               F39BE95A12673BF400E0A674 /* ScriptArguments.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScriptArguments.h; sourceTree = "<group>"; };
                F3ABFE0B130E9DA000E7F7D1 /* InstrumentingAgents.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InstrumentingAgents.h; sourceTree = "<group>"; };
                F3D461461161D53200CA0D09 /* JSErrorHandler.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSErrorHandler.cpp; sourceTree = "<group>"; };
                F3D461471161D53200CA0D09 /* JSErrorHandler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSErrorHandler.h; sourceTree = "<group>"; };
                                A584FE291863870F00843B10 /* CommandLineAPIModule.cpp */,
                                A584FE2A1863870F00843B10 /* CommandLineAPIModule.h */,
                                A584FE2718637DCA00843B10 /* CommandLineAPIModuleSource.js */,
-                               2DF2E9D4166E39740035BEF2 /* ConsoleAPITypes.h */,
-                               41F0618D0F5F069800A07EAC /* ConsoleMessage.cpp */,
-                               41F0618C0F5F069800A07EAC /* ConsoleMessage.h */,
                                7AABA25714BC613300AA9A11 /* DOMEditor.cpp */,
                                7AABA25814BC613300AA9A11 /* DOMEditor.h */,
                                7A54881614E432A1006AE05A /* DOMPatchSupport.cpp */,
                                7A54881514E432A1006AE05A /* DOMPatchSupport.h */,
-                               5913A23F13D49EBA00F5B05C /* IdentifiersFactory.cpp */,
-                               5913A24013D49EBA00F5B05C /* IdentifiersFactory.h */,
                                AA73183C159255B900A93E6E /* InjectedScriptCanvasModule.cpp */,
                                AA73183D159255B900A93E6E /* InjectedScriptCanvasModule.h */,
                                AA9030FE157E16A000276247 /* InjectedScriptCanvasModuleSource.js */,
                                AAD766EA157E502F00E85423 /* InspectorCanvasInstrumentation.h */,
                                7A1F2B51126C61B20006A7E6 /* InspectorClient.cpp */,
                                1C81B9580E97330800266E07 /* InspectorClient.h */,
-                               F3335BF612E07DC300D33011 /* InspectorConsoleAgent.cpp */,
-                               F3335BF712E07DC300D33011 /* InspectorConsoleAgent.h */,
                                F3F5CF1012ED81A80084C569 /* InspectorConsoleInstrumentation.h */,
                                1C81B9570E97330800266E07 /* InspectorController.cpp */,
                                1C81B9560E97330800266E07 /* InspectorController.h */,
                                A584FE2E1864CB8400843B10 /* PageInjectedScriptManager.h */,
                                F382088C147D35F90010BC06 /* PageRuntimeAgent.cpp */,
                                F382088D147D35F90010BC06 /* PageRuntimeAgent.h */,
-                               F39BE95912673BF400E0A674 /* ScriptArguments.cpp */,
-                               F39BE95A12673BF400E0A674 /* ScriptArguments.h */,
-                               416E75CA0EDF90C700360E1D /* ScriptCallFrame.cpp */,
-                               416E75C90EDF90C700360E1D /* ScriptCallFrame.h */,
-                               416E75BD0EDF8FD700360E1D /* ScriptCallStack.cpp */,
-                               416E75BC0EDF8FD700360E1D /* ScriptCallStack.h */,
                                9FA37EEF1172FD4100C4CD55 /* ScriptProfile.idl */,
                                9FA37EF01172FD4100C4CD55 /* ScriptProfileNode.idl */,
                                7553CFE7108F473F00EA281E /* TimelineRecordFactory.cpp */,
                                7553CFE6108F473F00EA281E /* TimelineRecordFactory.h */,
+                               A56C5B98189F34570082D13C /* WebConsoleAgent.cpp */,
+                               A56C5B99189F34570082D13C /* WebConsoleAgent.h */,
                                A5E616711894581F009ADF50 /* WebDebuggerAgent.cpp */,
                                A5E616721894581F009ADF50 /* WebDebuggerAgent.h */,
                                F382088E147D35F90010BC06 /* WorkerConsoleAgent.cpp */,
                                BC0B36A10CD3C67C00AC7EB5 /* Console.cpp */,
                                BC0B36A20CD3C67C00AC7EB5 /* Console.h */,
                                BC0B36A30CD3C67C00AC7EB5 /* Console.idl */,
-                               BCE5644D137A34D6007D2934 /* ConsoleTypes.h */,
                                97C471D912F925BC0086354B /* ContentSecurityPolicy.cpp */,
                                97C471DA12F925BD0086354B /* ContentSecurityPolicy.h */,
                                065AD4F20B0C2EDA005A2B1D /* ContextMenuClient.h */,
                                BCA378BB0D15F64200B793D6 /* ScheduledAction.h */,
                                41F1D21E0EF35C2A00DA8753 /* ScriptCachedFrameData.cpp */,
                                41F1D21D0EF35C2A00DA8753 /* ScriptCachedFrameData.h */,
-                               F392249A126F11AE00A926D9 /* ScriptCallStackFactory.cpp */,
-                               F392249B126F11AE00A926D9 /* ScriptCallStackFactory.h */,
                                93B70D5309EB0C7C009D8468 /* ScriptController.cpp */,
                                93B70D5409EB0C7C009D8468 /* ScriptController.h */,
                                A83E1C720E49042B00140B9C /* ScriptControllerMac.mm */,
                                FD31608F12B026F700C1A359 /* Cone.h in Headers */,
                                65C97AF308EA908800ACD273 /* config.h in Headers */,
                                BC0B36A50CD3C67C00AC7EB5 /* Console.h in Headers */,
-                               2DF2E9D5166E39750035BEF2 /* ConsoleAPITypes.h in Headers */,
-                               41F0618E0F5F069800A07EAC /* ConsoleMessage.h in Headers */,
                                073AB4B317F8BACA006E0D6F /* AllVideoCapabilities.h in Headers */,
-                               BCE5644E137A34D6007D2934 /* ConsoleTypes.h in Headers */,
                                A818721C0977D3C0005826D9 /* ContainerNode.h in Headers */,
                                E1A1470811102B1500EEC0F3 /* ContainerNodeAlgorithms.h in Headers */,
                                078E091D17D14D1C00420AA1 /* NavigatorUserMediaSuccessCallback.h in Headers */,
                                93309DE6099E64920056E581 /* HTMLInterchange.h in Headers */,
                                A81369E4097374F600D74463 /* HTMLKeygenElement.h in Headers */,
                                A81369E2097374F600D74463 /* HTMLLabelElement.h in Headers */,
+                               A56C5B9B189F34570082D13C /* WebConsoleAgent.h in Headers */,
                                A81369E0097374F600D74463 /* HTMLLegendElement.h in Headers */,
                                A8EA79F60A1916DF00A8EF5F /* HTMLLIElement.h in Headers */,
                                A871DC200A15205700B12A68 /* HTMLLinkElement.h in Headers */,
                                078E092117D14D1C00420AA1 /* RTCDTMFToneChangeEvent.h in Headers */,
                                07277E5117D018CC0015534D /* JSMediaStreamEvent.h in Headers */,
                                1A71D57C0F33819000F9CE4E /* IdentifierRep.h in Headers */,
-                               5913A24213D49EBA00F5B05C /* IdentifiersFactory.h in Headers */,
                                49E911C50EF86D47009D0CAF /* IdentityTransformOperation.h in Headers */,
                                E125F856182C0F8300D84CD9 /* CryptoKeySerialization.h in Headers */,
                                A584FE2618637DAB00843B10 /* CommandLineAPIModuleSource.h in Headers */,
                                AAD766EC157E502F00E85423 /* InspectorCanvasAgent.h in Headers */,
                                AAD766ED157E502F00E85423 /* InspectorCanvasInstrumentation.h in Headers */,
                                1C81B95C0E97330800266E07 /* InspectorClient.h in Headers */,
-                               F3335BF912E07DC300D33011 /* InspectorConsoleAgent.h in Headers */,
                                F3F5CF1112ED81A80084C569 /* InspectorConsoleInstrumentation.h in Headers */,
                                1C81B95A0E97330800266E07 /* InspectorController.h in Headers */,
                                F325A40B14EE36FA007324E2 /* InspectorCounters.h in Headers */,
                                9BD0BF9312A42BF50072FD43 /* ScopedEventQueue.h in Headers */,
                                BCEC01BE0C274DAC009F4EC9 /* Screen.h in Headers */,
                                A84D82C111D3474800972990 /* ScriptableDocumentParser.h in Headers */,
-                               F39BE95C12673BF400E0A674 /* ScriptArguments.h in Headers */,
                                41F1D21F0EF35C2A00DA8753 /* ScriptCachedFrameData.h in Headers */,
-                               416E75CB0EDF90C700360E1D /* ScriptCallFrame.h in Headers */,
-                               416E75BE0EDF8FD700360E1D /* ScriptCallStack.h in Headers */,
-                               F392249D126F11AE00A926D9 /* ScriptCallStackFactory.h in Headers */,
                                93B70D7009EB0C7C009D8468 /* ScriptController.h in Headers */,
                                4998AED213FB224D0090B1AA /* ScriptedAnimationController.h in Headers */,
                                08A484780E5272C500C3FE76 /* ScriptElement.h in Headers */,
                                FD31608E12B026F700C1A359 /* Cone.cpp in Sources */,
                                3146FE6F184420AA001A937C /* OESTextureFloatLinear.cpp in Sources */,
                                BC0B36A40CD3C67C00AC7EB5 /* Console.cpp in Sources */,
-                               41F0618F0F5F069800A07EAC /* ConsoleMessage.cpp in Sources */,
                                A818721F0977D3C0005826D9 /* ContainerNode.cpp in Sources */,
                                A7A78CD51532BA62006C21E4 /* ContainerNodeAlgorithms.cpp in Sources */,
                                BC5EB9800E82072500B25965 /* ContentData.cpp in Sources */,
                                C585A66211D4FAC5004C3E4B /* IDBBindingUtilities.cpp in Sources */,
                                1A71D57B0F33819000F9CE4E /* IdentifierRep.cpp in Sources */,
                                0705853117FDE6D9005F2BCB /* JSMediaTrackConstraint.cpp in Sources */,
-                               5913A24113D49EBA00F5B05C /* IdentifiersFactory.cpp in Sources */,
                                C3CF17A415B0063F00276D39 /* IdTargetObserver.cpp in Sources */,
                                C3CF17A615B0063F00276D39 /* IdTargetObserverRegistry.cpp in Sources */,
                                B275356F0B053814002CE64F /* Image.cpp in Sources */,
                                E1F80B8A183172A2007885C3 /* JSCryptoKeyPairCustom.cpp in Sources */,
                                AAD766EB157E502F00E85423 /* InspectorCanvasAgent.cpp in Sources */,
                                7A1F2B52126C61B20006A7E6 /* InspectorClient.cpp in Sources */,
-                               F3335BF812E07DC300D33011 /* InspectorConsoleAgent.cpp in Sources */,
                                1C81B95B0E97330800266E07 /* InspectorController.cpp in Sources */,
                                F325A40A14EE36FA007324E2 /* InspectorCounters.cpp in Sources */,
                                82AB1743124B99EC00C5069D /* InspectorCSSAgent.cpp in Sources */,
                                9BD0BF9412A42BF50072FD43 /* ScopedEventQueue.cpp in Sources */,
                                BCEC01BD0C274DAC009F4EC9 /* Screen.cpp in Sources */,
                                A84D82C211D3474800972990 /* ScriptableDocumentParser.cpp in Sources */,
-                               F39BE95B12673BF400E0A674 /* ScriptArguments.cpp in Sources */,
                                41F1D2200EF35C2A00DA8753 /* ScriptCachedFrameData.cpp in Sources */,
-                               416E75CC0EDF90C700360E1D /* ScriptCallFrame.cpp in Sources */,
-                               416E75BF0EDF8FD700360E1D /* ScriptCallStack.cpp in Sources */,
-                               F392249C126F11AE00A926D9 /* ScriptCallStackFactory.cpp in Sources */,
                                93B70D6F09EB0C7C009D8468 /* ScriptController.cpp in Sources */,
                                A83E1C740E49042C00140B9C /* ScriptControllerMac.mm in Sources */,
                                4998AED113FB224D0090B1AA /* ScriptedAnimationController.cpp in Sources */,
                                31A795C81888BCB500382F90 /* ANGLEInstancedArrays.cpp in Sources */,
                                A5840E24187B8AC200843B10 /* PageInjectedScriptHost.cpp in Sources */,
                                A8C4A7FE09D563270003AC8D /* StyledElement.cpp in Sources */,
+                               A56C5B9A189F34570082D13C /* WebConsoleAgent.cpp in Sources */,
                                BC5EB8B80E8201BD00B25965 /* StyleDeprecatedFlexibleBoxData.cpp in Sources */,
                                AA4C3A760B2B1679002334A2 /* InlineStyleSheetOwner.cpp in Sources */,
                                319AE063142D6B24006563A1 /* StyleFilterData.cpp in Sources */,
index e195ddf1108ff6deebf100be408a60d81a2f27f9..01968f0a10fa28b66197cbb5a468d83fd51139c1 100644 (file)
@@ -73,8 +73,7 @@ EncodedJSValue JSC_HOST_CALL JSAudioContextConstructor::constructJSAudioContext(
 #if ENABLE(LEGACY_WEB_AUDIO)
         // Constructor for offline (render-target) AudioContext which renders into an AudioBuffer.
         // new AudioContext(in unsigned long numberOfChannels, in unsigned long numberOfFrames, in float sampleRate);
-        document.addConsoleMessage(JSMessageSource, WarningMessageLevel,
-            "Deprecated AudioContext constructor: use OfflineAudioContext instead");
+        document.addConsoleMessage(MessageSource::JS, MessageLevel::Warning, ASCIILiteral("Deprecated AudioContext constructor: use OfflineAudioContext instead"));
 
         if (exec->argumentCount() < 3)
             return throwVMError(exec, createNotEnoughArgumentsError(exec));
index 0428e83946931ea17b9d3102918bbed1e95a2477..72ec9cecb914715864c3bb44ead6ca1a65a459fd 100644 (file)
 #include "PageScriptDebugServer.cpp"
 #include "ScheduledAction.cpp"
 #include "ScriptCachedFrameData.cpp"
-#include "ScriptCallStackFactory.cpp"
 #include "ScriptController.cpp"
 #include "ScriptProfiler.cpp"
 #include "ScriptState.cpp"
index f1b63f85a9e9fad2bd74f55504c9b860c3ed083f..4c10e083e95e4d690d75743da4ef2267bd50f498 100644 (file)
@@ -81,7 +81,7 @@ String JSCustomXPathNSResolver::lookupNamespaceURI(const String& prefix)
         if (callType == CallTypeNone) {
             // FIXME: <http://webkit.org/b/114312> JSCustomXPathNSResolver::lookupNamespaceURI Console Message should include Line, Column, and SourceURL
             if (PageConsole* console = m_globalObject->impl().pageConsole())
-                console->addMessage(JSMessageSource, ErrorMessageLevel, "XPathNSResolver does not have a lookupNamespaceURI method.");
+                console->addMessage(MessageSource::JS, MessageLevel::Error, ASCIILiteral("XPathNSResolver does not have a lookupNamespaceURI method."));
             return String();
         }
         function = m_customResolver.get();
index 2621c67b10538953b8e791b9b892f5b31d3aadc9..58092ea403888f4909dd48fe1b25c829074bd9ae 100644 (file)
@@ -34,8 +34,8 @@
 #include "JSDOMWindowCustom.h"
 #include "JSExceptionBase.h"
 #include "SecurityOrigin.h"
-#include "ScriptCallStack.h"
-#include "ScriptCallStackFactory.h"
+#include <inspector/ScriptCallStack.h>
+#include <inspector/ScriptCallStackFactory.h>
 #include <interpreter/Interpreter.h>
 #include <runtime/DateInstance.h>
 #include <runtime/Error.h>
@@ -45,6 +45,7 @@
 #include <wtf/MathExtras.h>
 
 using namespace JSC;
+using namespace Inspector;
 
 namespace WebCore {
 
index 19a780048c09bc6f16121e55dd54349c92b9cbbf..c15bccbbcda4ae111277e52d96e24007587ad15c 100644 (file)
@@ -150,7 +150,7 @@ JSValue JSSubtleCrypto::encrypt(ExecState* exec)
         return throwTypeError(exec);
 
     if (!key->allows(CryptoKeyUsageEncrypt)) {
-        m_impl->document()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "Key usages do not include 'encrypt'");
+        m_impl->document()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, ASCIILiteral("Key usages do not include 'encrypt'"));
         setDOMException(exec, NOT_SUPPORTED_ERR);
         return jsUndefined();
     }
@@ -202,7 +202,7 @@ JSValue JSSubtleCrypto::decrypt(ExecState* exec)
         return throwTypeError(exec);
 
     if (!key->allows(CryptoKeyUsageDecrypt)) {
-        m_impl->document()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "Key usages do not include 'decrypt'");
+        m_impl->document()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, ASCIILiteral("Key usages do not include 'decrypt'"));
         setDOMException(exec, NOT_SUPPORTED_ERR);
         return jsUndefined();
     }
@@ -253,7 +253,7 @@ JSValue JSSubtleCrypto::sign(ExecState* exec)
         return throwTypeError(exec);
 
     if (!key->allows(CryptoKeyUsageSign)) {
-        m_impl->document()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "Key usages do not include 'sign'");
+        m_impl->document()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, ASCIILiteral("Key usages do not include 'sign'"));
         setDOMException(exec, NOT_SUPPORTED_ERR);
         return jsUndefined();
     }
@@ -304,7 +304,7 @@ JSValue JSSubtleCrypto::verify(ExecState* exec)
         return throwTypeError(exec);
 
     if (!key->allows(CryptoKeyUsageVerify)) {
-        m_impl->document()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "Key usages do not include 'verify'");
+        m_impl->document()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, ASCIILiteral("Key usages do not include 'verify'"));
         setDOMException(exec, NOT_SUPPORTED_ERR);
         return jsUndefined();
     }
@@ -639,7 +639,7 @@ JSValue JSSubtleCrypto::wrapKey(ExecState* exec)
         return throwTypeError(exec);
 
     if (!wrappingKey->allows(CryptoKeyUsageWrapKey)) {
-        m_impl->document()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "Key usages do not include 'wrapKey'");
+        m_impl->document()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, ASCIILiteral("Key usages do not include 'wrapKey'"));
         setDOMException(exec, NOT_SUPPORTED_ERR);
         return jsUndefined();
     }
@@ -718,7 +718,7 @@ JSValue JSSubtleCrypto::unwrapKey(ExecState* exec)
         return throwTypeError(exec);
 
     if (!unwrappingKey->allows(CryptoKeyUsageUnwrapKey)) {
-        m_impl->document()->addConsoleMessage(JSMessageSource, ErrorMessageLevel, "Key usages do not include 'unwrapKey'");
+        m_impl->document()->addConsoleMessage(MessageSource::JS, MessageLevel::Error, ASCIILiteral("Key usages do not include 'unwrapKey'"));
         setDOMException(exec, NOT_SUPPORTED_ERR);
         return jsUndefined();
     }
index bd58b820ade5f7037ed4d8c9933f89e7d082a619..dadeb3f9b57eabce5c75d9d02c0297ae5da4fe5d 100644 (file)
@@ -38,7 +38,6 @@
 #include "Page.h"
 #include "PageGroup.h"
 #include "PluginView.h"
-#include "ScriptCallStack.h"
 #include "ScriptSourceCode.h"
 #include "ScriptableDocumentParser.h"
 #include "Settings.h"
@@ -50,6 +49,7 @@
 #include <bindings/ScriptValue.h>
 #include <debugger/Debugger.h>
 #include <heap/StrongInlines.h>
+#include <inspector/ScriptCallStack.h>
 #include <runtime/InitializeThreading.h>
 #include <runtime/JSLock.h>
 #include <wtf/Threading.h>
@@ -482,7 +482,7 @@ bool ScriptController::canExecuteScripts(ReasonForCallingCanExecuteScripts reaso
     if (m_frame.document() && m_frame.document()->isSandboxed(SandboxScripts)) {
         // FIXME: This message should be moved off the console once a solution to https://bugs.webkit.org/show_bug.cgi?id=103274 exists.
         if (reason == AboutToExecuteScript)
-            m_frame.document()->addConsoleMessage(SecurityMessageSource, ErrorMessageLevel, "Blocked script execution in '" + m_frame.document()->url().stringCenterEllipsizedToLength() + "' because the document's frame is sandboxed and the 'allow-scripts' permission is not set.");
+            m_frame.document()->addConsoleMessage(MessageSource::Security, MessageLevel::Error, "Blocked script execution in '" + m_frame.document()->url().stringCenterEllipsizedToLength() + "' because the document's frame is sandboxed and the 'allow-scripts' permission is not set.");
         return false;
     }
 
index a21416f403e93d9c36cb8f64ad73b9fcf6622636..e46c32b80fe9f1927ddae7d002d843792c91938a 100644 (file)
@@ -3059,9 +3059,9 @@ sub GenerateCallWith
         push(@callWithArgs, "scriptContext");
     }
     if ($function and $codeGenerator->ExtendedAttributeContains($callWith, "ScriptArguments")) {
-        push(@$outputArray, "    RefPtr<ScriptArguments> scriptArguments(createScriptArguments(exec, " . @{$function->parameters} . "));\n");
-        $implIncludes{"ScriptArguments.h"} = 1;
-        $implIncludes{"ScriptCallStackFactory.h"} = 1;
+        push(@$outputArray, "    RefPtr<Inspector::ScriptArguments> scriptArguments(Inspector::createScriptArguments(exec, " . @{$function->parameters} . "));\n");
+        $implIncludes{"<inspector/ScriptArguments.h>"} = 1;
+        $implIncludes{"<inspector/ScriptCallStackFactory.h>"} = 1;
         push(@callWithArgs, "scriptArguments.release()");
     }
     return @callWithArgs;
index 2ea73be7e416a71764c87ba01c6ac4e15a25e32d..e373ff9079078ba2672ce3512a6c137984ace327 100644 (file)
 #include "SVGDocument.h"
 #include "SVGPoint.h"
 #include "SVGStaticPropertyTearOff.h"
-#include "ScriptArguments.h"
-#include "ScriptCallStackFactory.h"
 #include "ScriptProfile.h"
 #include "SerializedScriptValue.h"
 #include "Settings.h"
 #include "TestObj.h"
 #include "URL.h"
 #include "bool.h"
+#include <inspector/ScriptArguments.h>
+#include <inspector/ScriptCallStackFactory.h>
 #include <runtime/Error.h>
 #include <runtime/JSArray.h>
 #include <runtime/JSString.h>
index 1c6d24c8a9e44e53f0173871138a10bdee109b56..d21c43efc482e0a1b481c36074d09120e7f4cddb 100644 (file)
@@ -11476,7 +11476,7 @@ void CSSParser::logError(const String& message, int lineNumber)
 {
     // FIXME: <http://webkit.org/b/114313> CSS parser console message errors should include column numbers.
     PageConsole& console = m_styleSheet->singleOwnerDocument()->page()->console();
-    console.addMessage(CSSMessageSource, WarningMessageLevel, message, m_styleSheet->baseURL().string(), lineNumber + 1, 0);
+    console.addMessage(MessageSource::CSS, MessageLevel::Warning, message, m_styleSheet->baseURL().string(), lineNumber + 1, 0);
 }
 
 PassRefPtr<StyleRuleKeyframes> CSSParser::createKeyframesRule(const String& name, PassOwnPtr<Vector<RefPtr<StyleKeyframe>>> popKeyframes)
index 2320ff6ced65cd8def3f1d14faaf2ffd14ecb964..f00014ffc276538913ce562e02132df9398dd1d5 100644 (file)
@@ -310,7 +310,7 @@ static void addResolutionWarningMessageToConsole(Document* document, const Strin
 
     message.append(serializedExpression);
 
-    document->addConsoleMessage(CSSMessageSource, DebugMessageLevel, message);
+    document->addConsoleMessage(MessageSource::CSS, MessageLevel::Debug, message);
 }
 
 void reportMediaQueryWarningIfNeeded(Document* document, const MediaQuerySet* mediaQuerySet)
index 5c24c2da4003d88b474476ccc0029edfb8c5b517..8db300b4d637542b0a436421d48af294c8d080c8 100644 (file)
@@ -60,9 +60,6 @@
 #include "FrameLoader.h"
 #include "FrameLoaderClient.h"
 #include "FrameView.h"
-#include "HashChangeEvent.h"
-#include "HistogramSupport.h"
-#include "History.h"
 #include "HTMLAllCollection.h"
 #include "HTMLAnchorElement.h"
 #include "HTMLBaseElement.h"
@@ -86,6 +83,9 @@
 #include "HTMLStyleElement.h"
 #include "HTMLTitleElement.h"
 #include "HTTPParsers.h"
+#include "HashChangeEvent.h"
+#include "HistogramSupport.h"
+#include "History.h"
 #include "HitTestResult.h"
 #include "IconController.h"
 #include "ImageLoader.h"
 #include "SVGSVGElement.h"
 #include "SchemeRegistry.h"
 #include "ScopedEventQueue.h"
-#include "ScriptCallStack.h"
 #include "ScriptController.h"
 #include "ScriptRunner.h"
 #include "ScriptSourceCode.h"
 #include "XPathNSResolver.h"
 #include "XPathResult.h"
 #include "htmlediting.h"
+#include <inspector/ScriptCallStack.h>
 #include <wtf/CurrentTime.h>
 #include <wtf/TemporaryChange.h>
 #include <wtf/text/StringBuffer.h>
@@ -2560,9 +2560,9 @@ EventTarget* Document::errorEventTarget()
     return m_domWindow.get();
 }
 
-void Document::logExceptionToConsole(const String& errorMessage, const String& sourceURL, int lineNumber, int columnNumber, PassRefPtr<ScriptCallStack> callStack)
+void Document::logExceptionToConsole(const String& errorMessage, const String& sourceURL, int lineNumber, int columnNumber, PassRefPtr<Inspector::ScriptCallStack> callStack)
 {
-    addMessage(JSMessageSource, ErrorMessageLevel, errorMessage, sourceURL, lineNumber, columnNumber, callStack);
+    addMessage(MessageSource::JS, MessageLevel::Error, errorMessage, sourceURL, lineNumber, columnNumber, callStack);
 }
 
 void Document::setURL(const URL& url)
@@ -2821,7 +2821,7 @@ void Document::processHttpEquiv(const String& equiv, const String& content)
                 // intent, we must navigate away from the possibly partially-rendered document to a location that
                 // doesn't inherit the parent's SecurityOrigin.
                 frame->navigationScheduler().scheduleLocationChange(securityOrigin(), SecurityOrigin::urlWithUniqueSecurityOrigin(), String());
-                addConsoleMessage(SecurityMessageSource, ErrorMessageLevel, message, requestIdentifier);
+                addConsoleMessage(MessageSource::Security, MessageLevel::Error, message, requestIdentifier);
             }
         }
     } else if (equalIgnoringCase(equiv, "content-security-policy"))
@@ -4781,7 +4781,7 @@ void Document::addConsoleMessage(MessageSource source, MessageLevel level, const
         page->console().addMessage(source, level, message, requestIdentifier, this);
 }
 
-void Document::addMessage(MessageSource source, MessageLevel level, const String& message, const String& sourceURL, unsigned lineNumber, unsigned columnNumber, PassRefPtr<ScriptCallStack> callStack, JSC::ExecState* state, unsigned long requestIdentifier)
+void Document::addMessage(MessageSource source, MessageLevel level, const String& message, const String& sourceURL, unsigned lineNumber, unsigned columnNumber, PassRefPtr<Inspector::ScriptCallStack> callStack, JSC::ExecState* state, unsigned long requestIdentifier)
 {
     if (!isContextThread()) {
         postTask(AddConsoleMessageTask::create(source, level, message));
index 4864351c3b5b86ddd58085b498619759604d2c24..90597af9a42ed849ca5258ce7fe4bdb38426b072 100644 (file)
@@ -1140,7 +1140,7 @@ public:
 #endif
 
     virtual EventTarget* errorEventTarget() override;
-    virtual void logExceptionToConsole(const String& errorMessage, const String& sourceURL, int lineNumber, int columnNumber, PassRefPtr<ScriptCallStack>) override;
+    virtual void logExceptionToConsole(const String& errorMessage, const String& sourceURL, int lineNumber, int columnNumber, PassRefPtr<Inspector::ScriptCallStack>) override;
 
     void initDNSPrefetch();
 
@@ -1262,7 +1262,7 @@ private:
     virtual void refScriptExecutionContext() override { ref(); }
     virtual void derefScriptExecutionContext() override { deref(); }
 
-    virtual void addMessage(MessageSource, MessageLevel, const String& message, const String& sourceURL, unsigned lineNumber, unsigned columnNumber, PassRefPtr<ScriptCallStack>, JSC::ExecState* = 0, unsigned long requestIdentifier = 0) override;
+    virtual void addMessage(MessageSource, MessageLevel, const String& message, const String& sourceURL, unsigned lineNumber, unsigned columnNumber, PassRefPtr<Inspector::ScriptCallStack>, JSC::ExecState* = 0, unsigned long requestIdentifier = 0) override;
 
     virtual double minimumTimerInterval() const override;
 
index 452b71df902f8fd13f5b1fbedff142d474e64d74..fce4f50cb39fa01e725821696573598b945de1d0 100644 (file)
@@ -24,9 +24,9 @@
 #include "config.h"
 #include "ScriptElement.h"
 
-#include "CachedScript.h"
 #include "CachedResourceLoader.h"
 #include "CachedResourceRequest.h"
+#include "CachedScript.h"
 #include "ContentSecurityPolicy.h"
 #include "CrossOriginAccessControl.h"
 #include "CurrentScriptIncrementer.h"
@@ -40,7 +40,6 @@
 #include "Page.h"
 #include "SVGNames.h"
 #include "SVGScriptElement.h"
-#include "ScriptCallStack.h"
 #include "ScriptController.h"
 #include "ScriptRunner.h"
 #include "ScriptSourceCode.h"
@@ -49,6 +48,7 @@
 #include "Settings.h"
 #include "TextNodeTraversal.h"
 #include <bindings/ScriptValue.h>
+#include <inspector/ScriptCallStack.h>
 #include <wtf/StdLibExtras.h>
 #include <wtf/text/StringBuilder.h>
 #include <wtf/text/StringHash.h>
@@ -291,7 +291,7 @@ void ScriptElement::executeScript(const ScriptSourceCode& sourceCode)
 
 #if ENABLE(NOSNIFF)
     if (m_isExternalScript && m_cachedScript && !m_cachedScript->mimeTypeAllowedByNosniff()) {
-        m_element->document().addConsoleMessage(SecurityMessageSource, ErrorMessageLevel, "Refused to execute script from '" + m_cachedScript->url().stringCenterEllipsizedToLength() + "' because its MIME type ('" + m_cachedScript->mimeType() + "') is not executable, and strict MIME type checking is enabled.");
+        m_element->document().addConsoleMessage(MessageSource::Security, MessageLevel::Error, "Refused to execute script from '" + m_cachedScript->url().stringCenterEllipsizedToLength() + "' because its MIME type ('" + m_cachedScript->mimeType() + "') is not executable, and strict MIME type checking is enabled.");
         return;
     }
 #endif
@@ -348,7 +348,7 @@ void ScriptElement::notifyFinished(CachedResource* resource)
 
         dispatchErrorEvent();
         DEFINE_STATIC_LOCAL(String, consoleMessage, (ASCIILiteral("Cross-origin script load denied by Cross-Origin Resource Sharing policy.")));
-        m_element->document().addConsoleMessage(JSMessageSource, ErrorMessageLevel, consoleMessage);
+        m_element->document().addConsoleMessage(MessageSource::JS, MessageLevel::Error, consoleMessage);
         return;
     }
 
index ca6041f9a0554822d5eac3ec6d612f69262b1e54..3665235dfd39fb2fbf94b08d0943d13a8e98d7c6 100644 (file)
 #include "ErrorEvent.h"
 #include "MessagePort.h"
 #include "PublicURLManager.h"
-#include "ScriptCallStack.h"
 #include "Settings.h"
 #include "WorkerGlobalScope.h"
 #include "WorkerThread.h"
+#include <inspector/ScriptCallStack.h>
 #include <wtf/MainThread.h>
 #include <wtf/Ref.h>
 
@@ -51,6 +51,8 @@
 #include "DatabaseContext.h"
 #endif
 
+using namespace Inspector;
+
 namespace WebCore {
 
 class ProcessMessagesSoonTask : public ScriptExecutionContext::Task {
index 1c7f0dae1fc02fa04cb2395214b98b1310017b81..b5bf80a9b387b3589b62c463446a45649bfce85b 100644 (file)
 #define ScriptExecutionContext_h
 
 #include "ActiveDOMObject.h"
-#include "ConsoleTypes.h"
-#include "URL.h"
 #include "SecurityContext.h"
 #include "Supplementable.h"
+#include "URL.h"
+#include <inspector/ConsoleTypes.h>
 #include <wtf/HashSet.h>
 
 namespace JSC {
@@ -40,6 +40,10 @@ class ExecState;
 class VM;
 }
 
+namespace Inspector {
+class ScriptCallStack;
+}
+
 namespace WebCore {
 
 class CachedScript;
@@ -49,7 +53,6 @@ class EventListener;
 class EventQueue;
 class EventTarget;
 class MessagePort;
-class ScriptCallStack;
 
 #if ENABLE(BLOB)
 class PublicURLManager;
@@ -75,7 +78,7 @@ public:
 
     bool sanitizeScriptError(String& errorMessage, int& lineNumber, int& columnNumber, String& sourceURL, CachedScript* = 0);
     // FIXME: <http://webkit.org/b/114315> ScriptExecutionContext log exception should include a column number
-    void reportException(const String& errorMessage, int lineNumber, int columnNumber, const String& sourceURL, PassRefPtr<ScriptCallStack>, CachedScript* = 0);
+    void reportException(const String& errorMessage, int lineNumber, int columnNumber, const String& sourceURL, PassRefPtr<Inspector::ScriptCallStack>, CachedScript* = 0);
 
     void addConsoleMessage(MessageSource, MessageLevel, const String& message, const String& sourceURL, unsigned lineNumber, unsigned columnNumber, JSC::ExecState* = 0, unsigned long requestIdentifier = 0);
     virtual void addConsoleMessage(MessageSource, MessageLevel, const String& message, unsigned long requestIdentifier = 0) = 0;
@@ -177,9 +180,9 @@ protected:
     ActiveDOMObject::ReasonForSuspension reasonForSuspendingActiveDOMObjects() const { return m_reasonForSuspendingActiveDOMObjects; }
 
 private:
-    virtual void addMessage(MessageSource, MessageLevel, const String& message, const String& sourceURL, unsigned lineNumber, unsigned columnNumber, PassRefPtr<ScriptCallStack>, JSC::ExecState* = 0, unsigned long requestIdentifier = 0) = 0;
+    virtual void addMessage(MessageSource, MessageLevel, const String& message, const String& sourceURL, unsigned lineNumber, unsigned columnNumber, PassRefPtr<Inspector::ScriptCallStack>, JSC::ExecState* = 0, unsigned long requestIdentifier = 0) = 0;
     virtual EventTarget* errorEventTarget() = 0;
-    virtual void logExceptionToConsole(const String& errorMessage, const String& sourceURL, int lineNumber, int columnNumber, PassRefPtr<ScriptCallStack>) = 0;
+    virtual void logExceptionToConsole(const String& errorMessage, const String& sourceURL, int lineNumber, int columnNumber, PassRefPtr<Inspector::ScriptCallStack>) = 0;
     bool dispatchErrorEvent(const String& errorMessage, int lineNumber, int columnNumber, const String& sourceURL, CachedScript*);
 
     void closeMessagePorts();
index 2c9539daa47d15b40fc9463d388997934539605b..0f6c083b5ea35d5cec33ada2d1d235db27c739ec 100644 (file)
@@ -448,15 +448,15 @@ static MessageLevel viewportErrorMessageLevel(ViewportErrorCode errorCode)
 {
     switch (errorCode) {
     case TruncatedViewportArgumentValueError:
-        return WarningMessageLevel;
+        return MessageLevel::Warning;
     case UnrecognizedViewportArgumentKeyError:
     case UnrecognizedViewportArgumentValueError:
     case MaximumScaleTooLargeError:
-        return ErrorMessageLevel;
+        return MessageLevel::Error;
     }
 
     ASSERT_NOT_REACHED();
-    return ErrorMessageLevel;
+    return MessageLevel::Error;
 }
 
 void reportViewportWarning(Document* document, ViewportErrorCode errorCode, const String& replacement1, const String& replacement2)
@@ -475,7 +475,7 @@ void reportViewportWarning(Document* document, ViewportErrorCode errorCode, cons
         message.append(" Note that ';' is not a separator in viewport values. The list should be comma-separated.");
 
     // FIXME: This message should be moved off the console once a solution to https://bugs.webkit.org/show_bug.cgi?id=103274 exists.
-    document->addConsoleMessage(RenderingMessageSource, viewportErrorMessageLevel(errorCode), message);
+    document->addConsoleMessage(MessageSource::Rendering, viewportErrorMessageLevel(errorCode), message);
 }
 
 } // namespace WebCore
index 6726bf4705500ac8d21dc563ad80b9e7e03a1ed1..6341d13605d10a37bd0328ab63af5c3631d12956 100644 (file)
@@ -34,7 +34,6 @@
 #include "BlobURL.h"
 #include "File.h"
 #include "HistogramSupport.h"
-#include "ScriptCallStack.h"
 #include "ScriptExecutionContext.h"
 #include "ThreadableBlobRegistry.h"
 #include <wtf/text/CString.h>
index c47eb1f514bd0d19e230a17923d376fdcf6ad2c1..8a458053f7f77dd6a7fcf9c877a1dbcd3c374747 100644 (file)
@@ -29,7 +29,6 @@
  */
 
 #include "config.h"
-
 #include "WebKitBlobBuilder.h"
 
 #include "Blob.h"
@@ -38,7 +37,6 @@
 #include "File.h"
 #include "HistogramSupport.h"
 #include "LineEnding.h"
-#include "ScriptCallStack.h"
 #include "TextEncoding.h"
 #include <runtime/ArrayBuffer.h>
 #include <runtime/ArrayBufferView.h>
index e6102299340cc362fafaaaca5cefcb46a090a941..638813d2c119ce69842cb7d229c53fd07f2d7568 100644 (file)
@@ -180,7 +180,7 @@ static bool shouldAutofocus(HTMLFormControlElement* element)
         return false;
     if (element->document().isSandboxed(SandboxAutomaticFeatures)) {
         // FIXME: This message should be moved off the console once a solution to https://bugs.webkit.org/show_bug.cgi?id=103274 exists.
-        element->document().addConsoleMessage(SecurityMessageSource, ErrorMessageLevel, "Blocked autofocusing on a form control because the form's frame is sandboxed and the 'allow-scripts' permission is not set.");
+        element->document().addConsoleMessage(MessageSource::Security, MessageLevel::Error, ASCIILiteral("Blocked autofocusing on a form control because the form's frame is sandboxed and the 'allow-scripts' permission is not set."));
         return false;
     }
     if (element->hasAutofocused())
index 132ed914e115cd283ad3bcfd5e2b04c092905474..60a138796f5cf3d02948edd77128403dc82933fc 100644 (file)
@@ -253,7 +253,7 @@ bool HTMLFormElement::validateInteractively(Event* event)
                 continue;
             String message("An invalid form control with name='%name' is not focusable.");
             message.replace("%name", control.name());
-            document().addConsoleMessage(RenderingMessageSource, ErrorMessageLevel, message);
+            document().addConsoleMessage(MessageSource::Rendering, MessageLevel::Error, message);
         }
     }
 
index a87e039daeafdc5f0d7e8b029c39179645128cd2..d3eba40189f9181dfe301722fe6fa3342a5eae5a 100644 (file)
@@ -80,7 +80,7 @@ void HTMLIFrameElement::parseAttribute(const QualifiedName& name, const AtomicSt
         String invalidTokens;
         setSandboxFlags(value.isNull() ? SandboxNone : SecurityContext::parseSandboxPolicy(value, invalidTokens));
         if (!invalidTokens.isNull())
-            document().addConsoleMessage(OtherMessageSource, ErrorMessageLevel, "Error while parsing the 'sandbox' attribute: " + invalidTokens);
+            document().addConsoleMessage(MessageSource::Other, MessageLevel::Error, "Error while parsing the 'sandbox' attribute: " + invalidTokens);
     } else
         HTMLFrameElementBase::parseAttribute(name, value);
 }
index bde2ba533c86d20490134aeb8345b565f6ae66f6..527cd13e7922c3db7721e23e8aead5d9a7dacce7 100644 (file)
@@ -2747,7 +2747,7 @@ void HTMLMediaElement::webkitGenerateKeyRequest(const String& keySystem, PassRef
 #if ENABLE(ENCRYPTED_MEDIA_V2)
     static bool firstTime = true;
     if (firstTime && scriptExecutionContext()) {
-        scriptExecutionContext()->addConsoleMessage(JSMessageSource, WarningMessageLevel, "'HTMLMediaElement.webkitGenerateKeyRequest()' is deprecated.  Use 'MediaKeys.createSession()' instead.");
+        scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Warning, ASCIILiteral("'HTMLMediaElement.webkitGenerateKeyRequest()' is deprecated.  Use 'MediaKeys.createSession()' instead."));
         firstTime = false;
     }
 #endif
@@ -2783,7 +2783,7 @@ void HTMLMediaElement::webkitAddKey(const String& keySystem, PassRefPtr<Uint8Arr
 #if ENABLE(ENCRYPTED_MEDIA_V2)
     static bool firstTime = true;
     if (firstTime && scriptExecutionContext()) {
-        scriptExecutionContext()->addConsoleMessage(JSMessageSource, WarningMessageLevel, "'HTMLMediaElement.webkitAddKey()' is deprecated.  Use 'MediaKeySession.update()' instead.");
+        scriptExecutionContext()->addConsoleMessage(MessageSource::JS, MessageLevel::Warning, ASCIILiteral("'HTMLMediaElement.webkitAddKey()' is deprecated.  Use 'MediaKeySession.update()' instead."));
         firstTime = false;
     }
 #endif
index 0d7b69ed446ffc89e77c0022bbcf7ec96cc4c8d0..1655a7bcb902fd7f47e20d21ea1e721454ccecf9 100755 (executable)
@@ -1859,7 +1859,7 @@ PassRefPtr<ImageData> CanvasRenderingContext2D::getImageData(ImageBuffer::Coordi
 {
     if (!canvas()->originClean()) {
         DEFINE_STATIC_LOCAL(String, consoleMessage, (ASCIILiteral("Unable to get image data from canvas because the canvas has been tainted by cross-origin data.")));
-        canvas()->document().addConsoleMessage(SecurityMessageSource, ErrorMessageLevel, consoleMessage);
+        canvas()->document().addConsoleMessage(MessageSource::Security, MessageLevel::Error, consoleMessage);
         ec = SECURITY_ERR;
         return 0;
     }
index 3810399022bfa78611a7d6422ef292a3afd97b95..a7fefb97e69dad9f019b2387dff7c5244594da4b 100644 (file)
@@ -5528,7 +5528,7 @@ void WebGLRenderingContext::printWarningToConsole(const String& message)
 {
     if (!canvas())
         return;
-    canvas()->document().addConsoleMessage(RenderingMessageSource, WarningMessageLevel, message);
+    canvas()->document().addConsoleMessage(MessageSource::Rendering, MessageLevel::Warning, message);
 }
 
 bool WebGLRenderingContext::validateFramebufferFuncParameters(const char* functionName, GC3Denum target, GC3Denum attachment)
index 084fa78e0eea70f3d623f24d787f99980acd0257..b3635b9e26ae57636167bff93ca32df54e1018a4 100644 (file)
@@ -280,7 +280,7 @@ void XSSAuditor::init(Document* document, XSSAuditorDelegate* auditorDelegate)
             }
         }
         if (xssProtectionHeader == ContentSecurityPolicy::ReflectedXSSInvalid)
-            document->addConsoleMessage(SecurityMessageSource, ErrorMessageLevel, "Error parsing header X-XSS-Protection: " + headerValue + ": "  + errorDetails + " at character position " + String::format("%u", errorPosition) + ". The default protections will be applied.");
+            document->addConsoleMessage(MessageSource::Security, MessageLevel::Error, "Error parsing header X-XSS-Protection: " + headerValue + ": "  + errorDetails + " at character position " + String::format("%u", errorPosition) + ". The default protections will be applied.");
 
         ContentSecurityPolicy::ReflectedXSSDisposition cspHeader = document->contentSecurityPolicy()->reflectedXSSDisposition();
         m_didSendValidCSPHeader = cspHeader != ContentSecurityPolicy::ReflectedXSSUnset && cspHeader != ContentSecurityPolicy::ReflectedXSSInvalid;
index d06069b319c5a4d7c1ad08ec36ca7f1f7dae9ca0..9cba069b378f0befe962e4c3207cf75ee339e18e 100644 (file)
@@ -98,7 +98,7 @@ void XSSAuditorDelegate::didBlockScript(const XSSInfo& xssInfo)
 {
     ASSERT(isMainThread());
 
-    m_document.addConsoleMessage(JSMessageSource, ErrorMessageLevel, buildConsoleError(xssInfo, m_document.url().string()));
+    m_document.addConsoleMessage(MessageSource::JS, MessageLevel::Error, buildConsoleError(xssInfo, m_document.url().string()));
 
     FrameLoader& frameLoader = m_document.frame()->loader();
     if (xssInfo.m_didBlockEntirePage)
index 92f1d27d2e641d9b37536a684a3e472e9f1bad95..f404a52febef111f82797bc1ada22a917b0f515a 100644 (file)
@@ -38,7 +38,6 @@
 #include "FrameLoader.h"
 #include "HTMLFrameOwnerElement.h"
 #include "InspectorClient.h"
-#include "InspectorConsoleAgent.h"
 #include "InspectorDOMAgent.h"
 #include "InspectorDOMStorageAgent.h"
 #include "InspectorDatabaseAgent.h"
@@ -49,6 +48,7 @@
 #include <bindings/ScriptValue.h>
 #include <inspector/InspectorValues.h>
 #include <inspector/agents/InspectorAgent.h>
+#include <inspector/agents/InspectorConsoleAgent.h>
 #include <wtf/RefPtr.h>
 #include <wtf/StdLibExtras.h>
 
index 6f9025f086adfc946fb70f1d3b39c116bed13708..08f0c15d61ec1f0018d88ee77381ae0f5d8c72aa 100644 (file)
@@ -30,8 +30,8 @@
 #ifndef CommandLineAPIHost_h
 #define CommandLineAPIHost_h
 
-#include "ConsoleTypes.h"
 #include "ScriptState.h"
+#include <inspector/ConsoleTypes.h>
 #include <wtf/RefCounted.h>
 #include <wtf/Vector.h>
 #include <wtf/text/WTFString.h>
@@ -42,6 +42,7 @@ class ScriptValue;
 
 namespace Inspector {
 class InspectorAgent;
+class InspectorConsoleAgent;
 class InspectorObject;
 class InspectorValue;
 }
@@ -49,7 +50,6 @@ class InspectorValue;
 namespace WebCore {
 
 class Database;
-class InspectorConsoleAgent;
 class InspectorDOMAgent;
 class InspectorDOMStorageAgent;
 class InspectorDatabaseAgent;
@@ -64,11 +64,11 @@ public:
     ~CommandLineAPIHost();
 
     void init(Inspector::InspectorAgent* inspectorAgent
-            , InspectorConsoleAgent* consoleAgent
-            , InspectorDOMAgent* domAgent
-            , InspectorDOMStorageAgent* domStorageAgent
+        , Inspector::InspectorConsoleAgent* consoleAgent
+        , InspectorDOMAgent* domAgent
+        , InspectorDOMStorageAgent* domStorageAgent
 #if ENABLE(SQL_DATABASE)
-            , InspectorDatabaseAgent* databaseAgent
+        , InspectorDatabaseAgent* databaseAgent
 #endif
         )
     {
@@ -108,7 +108,7 @@ private:
     CommandLineAPIHost();
 
     Inspector::InspectorAgent* m_inspectorAgent;
-    InspectorConsoleAgent* m_consoleAgent;
+    Inspector::InspectorConsoleAgent* m_consoleAgent;
     InspectorDOMAgent* m_domAgent;
     InspectorDOMStorageAgent* m_domStorageAgent;
 #if ENABLE(SQL_DATABASE)
index f7252236c3048081e3d5c1ddd408aa982d024437..bfc42d47bb29af2e19ef642621ea2d2e1638dbfc 100644 (file)
 
 #include "CommandLineAPIHost.cpp"
 #include "CommandLineAPIModule.cpp"
-#include "ConsoleMessage.cpp"
 #include "DOMEditor.cpp"
 #include "DOMPatchSupport.cpp"
-#include "IdentifiersFactory.cpp"
 #include "InjectedScriptCanvasModule.cpp"
 #include "InspectorApplicationCacheAgent.cpp"
 #include "InspectorCSSAgent.cpp"
 #include "InspectorCanvasAgent.cpp"
 #include "InspectorClient.cpp"
-#include "InspectorConsoleAgent.cpp"
 #include "InspectorController.cpp"
 #include "InspectorCounters.cpp"
 #include "InspectorDOMAgent.cpp"
 #include "PageInjectedScriptHost.cpp"
 #include "PageInjectedScriptManager.cpp"
 #include "PageRuntimeAgent.cpp"
-#include "ScriptArguments.cpp"
-#include "ScriptCallFrame.cpp"
-#include "ScriptCallStack.cpp"
 #include "TimelineRecordFactory.cpp"
+#include "WebConsoleAgent.cpp"
 #include "WebDebuggerAgent.cpp"
 #include "WorkerConsoleAgent.cpp"
 #include "WorkerDebuggerAgent.cpp"
diff --git a/Source/WebCore/inspector/InspectorConsoleAgent.h b/Source/WebCore/inspector/InspectorConsoleAgent.h
deleted file mode 100644 (file)
index 749bad8..0000000
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * Copyright (C) 2011 Google Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1.  Redistributions of source code must retain the above copyright
- *     notice, this list of conditions and the following disclaimer.
- * 2.  Redistributions in binary form must reproduce the above copyright
- *     notice, this list of conditions and the following disclaimer in the
- *     documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY
- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef InspectorConsoleAgent_h
-#define InspectorConsoleAgent_h
-
-#if ENABLE(INSPECTOR)
-
-#include "ConsoleAPITypes.h"
-#include "ConsoleTypes.h"
-#include "InspectorWebAgentBase.h"
-#include "InspectorWebBackendDispatchers.h"
-#include "InspectorWebFrontendDispatchers.h"
-#include "ScriptState.h"
-#include <wtf/Forward.h>
-#include <wtf/HashMap.h>
-#include <wtf/Noncopyable.h>
-#include <wtf/Vector.h>
-#include <wtf/text/StringHash.h>
-
-namespace WebCore {
-
-class ConsoleMessage;
-class DOMWindow;
-class InstrumentingAgents;
-class PageInjectedScriptManager;
-class ResourceError;
-class ResourceResponse;
-class ScriptArguments;
-class ScriptCallStack;
-class ScriptProfile;
-
-typedef String ErrorString;
-
-class InspectorConsoleAgent : public InspectorAgentBase, public Inspector::InspectorConsoleBackendDispatcherHandler {
-    WTF_MAKE_NONCOPYABLE(InspectorConsoleAgent);
-public:
-    InspectorConsoleAgent(InstrumentingAgents*, PageInjectedScriptManager*);
-    virtual ~InspectorConsoleAgent();
-
-    virtual void enable(ErrorString*) override;
-    virtual void disable(ErrorString*) override;
-    virtual void clearMessages(ErrorString*) override;
-    bool enabled() const { return m_enabled; }
-    void reset();
-
-    virtual void didCreateFrontendAndBackend(Inspector::InspectorFrontendChannel*, Inspector::InspectorBackendDispatcher*) override;
-    virtual void willDestroyFrontendAndBackend(Inspector::InspectorDisconnectReason) override;
-
-    void addMessageToConsole(MessageSource, MessageType, MessageLevel, const String& message, JSC::ExecState*, PassRefPtr<ScriptArguments>, unsigned long requestIdentifier = 0);
-    void addMessageToConsole(MessageSource, MessageType, MessageLevel, const String& message, const String& scriptID, unsigned lineNumber, unsigned columnNumber, JSC::ExecState* = nullptr, unsigned long requestIdentifier = 0);
-
-    // FIXME: Remove once we no longer generate stacks outside of Inspector.
-    void addMessageToConsole(MessageSource, MessageType, MessageLevel, const String& message, PassRefPtr<ScriptCallStack>, unsigned long requestIdentifier = 0);
-
-    Vector<unsigned> consoleMessageArgumentCounts();
-
-    void startTiming(const String& title);
-    void stopTiming(const String& title, PassRefPtr<ScriptCallStack>);
-    void count(JSC::ExecState*, PassRefPtr<ScriptArguments>);
-
-    void frameWindowDiscarded(DOMWindow*);
-
-    void didFinishXHRLoading(unsigned long requestIdentifier, const String& url, const String& sendURL, unsigned sendLineNumber, unsigned sendColumnNumber);
-    void didReceiveResponse(unsigned long requestIdentifier, const ResourceResponse&);
-    void didFailLoading(unsigned long requestIdentifier, const ResourceError&);
-    void addProfileFinishedMessageToConsole(PassRefPtr<ScriptProfile>, unsigned lineNumber, unsigned columnNumber, const String& sourceURL);
-    void addStartProfilingMessageToConsole(const String& title, unsigned lineNumber, unsigned columnNumber, const String& sourceURL);
-    virtual void setMonitoringXHREnabled(ErrorString*, bool enabled) override;
-    virtual void addInspectedNode(ErrorString*, int nodeId) = 0;
-    virtual void addInspectedHeapObject(ErrorString*, int inspectedHeapObjectId) override;
-
-    virtual bool isWorkerAgent() = 0;
-
-protected:
-    void addConsoleMessage(PassOwnPtr<ConsoleMessage>);
-
-    PageInjectedScriptManager* m_injectedScriptManager;
-    std::unique_ptr<Inspector::InspectorConsoleFrontendDispatcher> m_frontendDispatcher;
-    RefPtr<Inspector::InspectorConsoleBackendDispatcher> m_backendDispatcher;
-    ConsoleMessage* m_previousMessage;
-    Vector<OwnPtr<ConsoleMessage>> m_consoleMessages;
-    int m_expiredConsoleMessageCount;
-    HashMap<String, unsigned> m_counts;
-    HashMap<String, double> m_times;
-    bool m_enabled;
-    bool m_monitoringXHREnabled;
-};
-
-} // namespace WebCore
-
-#endif // ENABLE(INSPECTOR)
-
-#endif // !defined(InspectorConsoleAgent_h)
index d88baa2ae4c4fb91737e85b1c5b638d6a3530a42..6200e6f3bc35567dcd253e44a347d56809315e4c 100644 (file)
 #define InspectorConsoleInstrumentation_h
 
 #include "InspectorInstrumentation.h"
-#include "ScriptArguments.h"
-#include "ScriptCallStack.h"
 #include "ScriptProfile.h"
+#include <inspector/ScriptArguments.h>
+#include <inspector/ScriptCallStack.h>
 #include <wtf/PassRefPtr.h>
 
 namespace WebCore {
 
-inline void InspectorInstrumentation::addMessageToConsole(Page* page, MessageSource source, MessageType type, MessageLevel level, const String& message, PassRefPtr<ScriptCallStack> callStack, unsigned long requestIdentifier)
+inline void InspectorInstrumentation::addMessageToConsole(Page* page, MessageSource source, MessageType type, MessageLevel level, const String& message, PassRefPtr<Inspector::ScriptCallStack> callStack, unsigned long requestIdentifier)
 {
 #if ENABLE(INSPECTOR)
     if (InstrumentingAgents* instrumentingAgents = instrumentingAgentsForPage(page))
@@ -55,7 +55,7 @@ inline void InspectorInstrumentation::addMessageToConsole(Page* page, MessageSou
 #endif
 }
 
-inline void InspectorInstrumentation::addMessageToConsole(Page* page, MessageSource source, MessageType type, MessageLevel level, const String& message, JSC::ExecState* state, PassRefPtr<ScriptArguments> arguments, unsigned long requestIdentifier)
+inline void InspectorInstrumentation::addMessageToConsole(Page* page, MessageSource source, MessageType type, MessageLevel level, const String& message, JSC::ExecState* state, PassRefPtr<Inspector::ScriptArguments> arguments, unsigned long requestIdentifier)
 {
 #if ENABLE(INSPECTOR)
     if (InstrumentingAgents* instrumentingAgents = instrumentingAgentsForPage(page))
@@ -91,7 +91,7 @@ inline void InspectorInstrumentation::addMessageToConsole(Page* page, MessageSou
 #endif
 }
 
-inline void InspectorInstrumentation::addMessageToConsole(WorkerGlobalScope* workerGlobalScope, MessageSource source, MessageType type, MessageLevel level, const String& message, PassRefPtr<ScriptCallStack> callStack, unsigned long requestIdentifier)
+inline void InspectorInstrumentation::addMessageToConsole(WorkerGlobalScope* workerGlobalScope, MessageSource source, MessageType type, MessageLevel level, const String& message, PassRefPtr<Inspector::ScriptCallStack> callStack, unsigned long requestIdentifier)
 {
 #if ENABLE(INSPECTOR)
     if (InstrumentingAgents* instrumentingAgents = instrumentingAgentsForWorkerGlobalScope(workerGlobalScope))
@@ -126,7 +126,7 @@ inline void InspectorInstrumentation::addMessageToConsole(WorkerGlobalScope* wor
 #endif
 }
 
-inline void InspectorInstrumentation::consoleCount(Page* page, JSC::ExecState* state, PassRefPtr<ScriptArguments> arguments)
+inline void InspectorInstrumentation::consoleCount(Page* page, JSC::ExecState* state, PassRefPtr<Inspector::ScriptArguments> arguments)
 {
 #if ENABLE(INSPECTOR)
     if (InstrumentingAgents* instrumentingAgents = instrumentingAgentsForPage(page))
@@ -149,7 +149,7 @@ inline void InspectorInstrumentation::startConsoleTiming(Frame* frame, const Str
 #endif
 }
 
-inline void InspectorInstrumentation::stopConsoleTiming(Frame* frame, const String& title, PassRefPtr<ScriptCallStack> stack)
+inline void InspectorInstrumentation::stopConsoleTiming(Frame* frame, const String& title, PassRefPtr<Inspector::ScriptCallStack> stack)
 {
 #if ENABLE(INSPECTOR)
     if (InstrumentingAgents* instrumentingAgents = instrumentingAgentsForFrame(frame))
@@ -161,7 +161,7 @@ inline void InspectorInstrumentation::stopConsoleTiming(Frame* frame, const Stri
 #endif
 }
 
-inline void InspectorInstrumentation::consoleTimeStamp(Frame* frame, PassRefPtr<ScriptArguments> arguments)
+inline void InspectorInstrumentation::consoleTimeStamp(Frame* frame, PassRefPtr<Inspector::ScriptArguments> arguments)
 {
 #if ENABLE(INSPECTOR)
     FAST_RETURN_IF_NO_FRONTENDS(void());
@@ -187,7 +187,7 @@ inline void InspectorInstrumentation::addStartProfilingMessageToConsole(Page* pa
 #endif
 }
 
-inline void InspectorInstrumentation::addProfile(Page* page, PassRefPtr<ScriptProfile> profile, PassRefPtr<ScriptCallStack> callStack)
+inline void InspectorInstrumentation::addProfile(Page* page, PassRefPtr<ScriptProfile> profile, PassRefPtr<Inspector::ScriptCallStack> callStack)
 {
 #if ENABLE(INSPECTOR)
     if (InstrumentingAgents* instrumentingAgents = instrumentingAgentsForPage(page))
index 233b0388079f6b9e07b44be74f5252e14912ea87..3dac01b315d63551086468bbaa1298ca029c241f 100644 (file)
@@ -36,7 +36,6 @@
 #include "CommandLineAPIHost.h"
 #include "DOMWrapperWorld.h"
 #include "GraphicsContext.h"
-#include "IdentifiersFactory.h"
 #include "InspectorApplicationCacheAgent.h"
 #include "InspectorCSSAgent.h"
 #include "InspectorCanvasAgent.h"
@@ -72,6 +71,7 @@
 #include "PageInjectedScriptManager.h"
 #include "PageRuntimeAgent.h"
 #include "Settings.h"
+#include <inspector/IdentifiersFactory.h>
 #include <inspector/InspectorBackendDispatcher.h>
 #include <inspector/agents/InspectorAgent.h>
 #include <runtime/JSLock.h>
@@ -141,8 +141,9 @@ InspectorController::InspectorController(Page& page, InspectorClient* inspectorC
     m_resourceAgent = resourceAgentPtr.get();
     m_agents.append(std::move(resourceAgentPtr));
 
-    auto consoleAgentPtr = std::make_unique<PageConsoleAgent>(m_instrumentingAgents.get(), m_injectedScriptManager.get(), m_domAgent);
-    InspectorConsoleAgent* consoleAgent = consoleAgentPtr.get();
+    auto consoleAgentPtr = std::make_unique<PageConsoleAgent>(m_injectedScriptManager.get(), m_domAgent);
+    WebConsoleAgent* consoleAgent = consoleAgentPtr.get();
+    m_instrumentingAgents->setWebConsoleAgent(consoleAgentPtr.get());
     m_agents.append(std::move(consoleAgentPtr));
 
     auto debuggerAgentPtr = std::make_unique<PageDebuggerAgent>(m_injectedScriptManager.get(), m_instrumentingAgents.get(), pageAgent, m_overlay.get());
@@ -271,7 +272,7 @@ void InspectorController::disconnectFrontend(InspectorDisconnectReason reason)
     m_inspectorBackendDispatcher.clear();
     m_inspectorFrontendChannel = nullptr;
 
-    // relese overlay page resources
+    // Release overlay page resources.
     m_overlay->freePage();
     InspectorInstrumentation::frontendDeleted();
     InspectorInstrumentation::unregisterInstrumentingAgents(m_instrumentingAgents.get());
index 73131643ddced1eaf4943ac481363305ebafa4ac..74a526dd396d2bcedbb65f9b7d76cb06988b9ee8 100644 (file)
@@ -63,7 +63,6 @@
 #include "HTMLNames.h"
 #include "HTMLTemplateElement.h"
 #include "HitTestResult.h"
-#include "IdentifiersFactory.h"
 #include "InspectorHistory.h"
 #include "InspectorNodeFinder.h"
 #include "InspectorOverlay.h"
@@ -91,6 +90,7 @@
 #include "XPathResult.h"
 #include "htmlediting.h"
 #include "markup.h"
+#include <inspector/IdentifiersFactory.h>
 #include <inspector/InjectedScript.h>
 #include <inspector/InjectedScriptManager.h>
 #include <wtf/HashSet.h>
index 9dc67b0c777d0867c9e6749313d0d296061b1364..ab0e7d32459e90894bdc3317e2d002fe6ca5b932 100644 (file)
@@ -29,7 +29,6 @@
 #ifndef InspectorFrontendHost_h
 #define InspectorFrontendHost_h
 
-#include "ConsoleTypes.h"
 #include "ContextMenu.h"
 #include "ContextMenuProvider.h"
 #include <wtf/RefCounted.h>
index 235eccee4236454dc43ee1bcf4de2975c4e06c7b..f158923de48faf70f3d477d9c3cb3af547e32e89 100644 (file)
@@ -35,8 +35,6 @@
 
 #include "CSSRule.h"
 #include "CSSStyleRule.h"
-#include "ConsoleAPITypes.h"
-#include "ConsoleTypes.h"
 #include "DOMWindow.h"
 #include "DOMWrapperWorld.h"
 #include "Database.h"
@@ -46,7 +44,6 @@
 #include "InspectorApplicationCacheAgent.h"
 #include "InspectorCSSAgent.h"
 #include "InspectorCanvasAgent.h"
-#include "InspectorConsoleAgent.h"
 #include "InspectorDOMAgent.h"
 #include "InspectorDOMDebuggerAgent.h"
 #include "InspectorDOMStorageAgent.h"
 #include "PageRuntimeAgent.h"
 #include "RenderObject.h"
 #include "RenderView.h"
-#include "ScriptArguments.h"
-#include "ScriptCallStack.h"
 #include "ScriptController.h"
 #include "ScriptProfile.h"
 #include "StyleResolver.h"
 #include "StyleRule.h"
+#include "WebConsoleAgent.h"
 #include "WorkerGlobalScope.h"
 #include "WorkerRuntimeAgent.h"
 #include "WorkerThread.h"
 #include "XMLHttpRequest.h"
+#include <inspector/ConsoleTypes.h>
+#include <inspector/ScriptArguments.h>
+#include <inspector/ScriptCallStack.h>
 #include <inspector/agents/InspectorDebuggerAgent.h>
 #include <wtf/StdLibExtras.h>
 #include <wtf/text/CString.h>
@@ -183,7 +182,7 @@ void InspectorInstrumentation::didInvalidateStyleAttrImpl(InstrumentingAgents* i
 
 void InspectorInstrumentation::frameWindowDiscardedImpl(InstrumentingAgents* instrumentingAgents, DOMWindow* window)
 {
-    if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+    if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
         consoleAgent->frameWindowDiscarded(window);
 }
 
@@ -600,7 +599,7 @@ void InspectorInstrumentation::didReceiveResourceResponseImpl(const InspectorIns
     InstrumentingAgents* instrumentingAgents = cookie.instrumentingAgents();
     if (InspectorResourceAgent* resourceAgent = instrumentingAgents->inspectorResourceAgent())
         resourceAgent->didReceiveResponse(identifier, loader, response, resourceLoader);
-    if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+    if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
         consoleAgent->didReceiveResponse(identifier, response); // This should come AFTER resource notification, front-end relies on this.
 }
 
@@ -645,7 +644,7 @@ void InspectorInstrumentation::didFailLoadingImpl(InstrumentingAgents* instrumen
         timelineAgent->didFinishLoadingResource(identifier, true, 0, loader->frame());
     if (InspectorResourceAgent* resourceAgent = instrumentingAgents->inspectorResourceAgent())
         resourceAgent->didFailLoading(identifier, loader, error);
-    if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+    if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
         consoleAgent->didFailLoading(identifier, error); // This should come AFTER resource notification, front-end relies on this.
 }
 
@@ -669,7 +668,7 @@ void InspectorInstrumentation::didFailXHRLoadingImpl(InstrumentingAgents* instru
 
 void InspectorInstrumentation::didFinishXHRLoadingImpl(InstrumentingAgents* instrumentingAgents, ThreadableLoaderClient* client, unsigned long identifier, const String& sourceString, const String& url, const String& sendURL, unsigned sendLineNumber, unsigned sendColumnNumber)
 {
-    if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+    if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
         consoleAgent->didFinishXHRLoading(identifier, url, sendURL, sendLineNumber, sendColumnNumber);
     if (InspectorResourceAgent* resourceAgent = instrumentingAgents->inspectorResourceAgent())
         resourceAgent->didFinishXHRLoading(client, identifier, sourceString);
@@ -752,7 +751,7 @@ void InspectorInstrumentation::didCommitLoadImpl(InstrumentingAgents* instrument
         return;
 
     if (loader->frame()->isMainFrame()) {
-        if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+        if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
             consoleAgent->reset();
 
         if (InspectorResourceAgent* resourceAgent = instrumentingAgents->inspectorResourceAgent())
@@ -862,13 +861,13 @@ void InspectorInstrumentation::didWriteHTMLImpl(const InspectorInstrumentationCo
 // JavaScriptCore InspectorDebuggerAgent should know Console MessageTypes.
 static bool isConsoleAssertMessage(MessageSource source, MessageType type)
 {
-    return source == ConsoleAPIMessageSource && type == AssertMessageType;
+    return source == MessageSource::ConsoleAPI && type == MessageType::Assert;
 }
 
 // FIXME: Drop this once we no longer generate stacks outside of Inspector.
 void InspectorInstrumentation::addMessageToConsoleImpl(InstrumentingAgents* instrumentingAgents, MessageSource source, MessageType type, MessageLevel level, const String& message, PassRefPtr<ScriptCallStack> callStack, unsigned long requestIdentifier)
 {
-    if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+    if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
         consoleAgent->addMessageToConsole(source, type, level, message, callStack, requestIdentifier);
     // FIXME: This should just pass the message on to the debugger agent. JavaScriptCore InspectorDebuggerAgent should know Console MessageTypes.
     if (InspectorDebuggerAgent* debuggerAgent = instrumentingAgents->inspectorDebuggerAgent()) {
@@ -879,7 +878,7 @@ void InspectorInstrumentation::addMessageToConsoleImpl(InstrumentingAgents* inst
 
 void InspectorInstrumentation::addMessageToConsoleImpl(InstrumentingAgents* instrumentingAgents, MessageSource source, MessageType type, MessageLevel level, const String& message, JSC::ExecState* state, PassRefPtr<ScriptArguments> arguments, unsigned long requestIdentifier)
 {
-    if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+    if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
         consoleAgent->addMessageToConsole(source, type, level, message, state, arguments, requestIdentifier);
     // FIXME: This should just pass the message on to the debugger agent. JavaScriptCore InspectorDebuggerAgent should know Console MessageTypes.
     if (InspectorDebuggerAgent* debuggerAgent = instrumentingAgents->inspectorDebuggerAgent()) {
@@ -890,13 +889,13 @@ void InspectorInstrumentation::addMessageToConsoleImpl(InstrumentingAgents* inst
 
 void InspectorInstrumentation::addMessageToConsoleImpl(InstrumentingAgents* instrumentingAgents, MessageSource source, MessageType type, MessageLevel level, const String& message, const String& scriptID, unsigned lineNumber, unsigned columnNumber, JSC::ExecState* state, unsigned long requestIdentifier)
 {
-    if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+    if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
         consoleAgent->addMessageToConsole(source, type, level, message, scriptID, lineNumber, columnNumber, state, requestIdentifier);
 }
 
 void InspectorInstrumentation::consoleCountImpl(InstrumentingAgents* instrumentingAgents, JSC::ExecState* state, PassRefPtr<ScriptArguments> arguments)
 {
-    if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+    if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
         consoleAgent->count(state, arguments);
 }
 
@@ -904,13 +903,13 @@ void InspectorInstrumentation::startConsoleTimingImpl(InstrumentingAgents* instr
 {
     if (InspectorTimelineAgent* timelineAgent = instrumentingAgents->inspectorTimelineAgent())
         timelineAgent->time(frame, title);
-    if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+    if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
         consoleAgent->startTiming(title);
 }
 
 void InspectorInstrumentation::stopConsoleTimingImpl(InstrumentingAgents* instrumentingAgents, Frame* frame, const String& title, PassRefPtr<ScriptCallStack> stack)
 {
-    if (InspectorConsoleAgent* consoleAgent = instrumentingAgents->inspectorConsoleAgent())
+    if (WebConsoleAgent* consoleAgent = instrumentingAgents->webConsoleAgent())
         consoleAgent->stopTiming(title, stack);
     if (InspectorTimelineAgent* timelineAgent = instrumentingAgents->inspectorTimelineAgent())
         timelineAgent->timeEnd(frame, title);
@@ -1072,7 +1071,7 @@ bool InspectorInstrumentation::canvasAgentEnabled(ScriptExecutionContext* script
 bool InspectorInstrumentation::consoleAgentEnabled(ScriptExecutionContext* scriptExecutionContext)
 {
     InstrumentingAgents* instrumentingAgents = instrumentingAgentsForContext(scriptExecutionContext);
-    InspectorConsoleAgent* consoleAgent = instrumentingAgents ? instrumentingAgents->inspectorConsoleAgent() : nullptr;
+    InspectorConsoleAgent* consoleAgent = instrumentingAgents ? instrumentingAgents->webConsoleAgent() : nullptr;
     return consoleAgent && consoleAgent->enabled();
 }
 
index 62399dc328ef241be0ba23a7e2ce7c8242cda111..cd5e91ca7e915f9abb4c2b93f64e7f8b285ab325 100644 (file)
@@ -32,8 +32,6 @@
 #define InspectorInstrumentation_h
 
 #include "CSSSelector.h"
-#include "ConsoleAPITypes.h"
-#include "ConsoleTypes.h"
 #include "Element.h"
 #include "FormData.h"
 #include "Frame.h"
 #include "ScriptState.h"
 #include "StorageArea.h"
 #include "WebSocketFrame.h"
+#include <inspector/ConsoleTypes.h>
 #include <wtf/RefPtr.h>
 
 namespace Deprecated {
 class ScriptObject;
 }
 
+namespace Inspector {
+class ScriptArguments;
+class ScriptCallStack;
+}
+
 namespace WebCore {
 
 class CSSRule;
@@ -77,8 +81,6 @@ class RenderLayerBacking;
 class RenderObject;
 class ResourceRequest;
 class ResourceResponse;
-class ScriptArguments;
-class ScriptCallStack;
 class ScriptExecutionContext;
 class ScriptProfile;
 class SecurityOrigin;
@@ -203,18 +205,18 @@ public:
     static void didWriteHTML(const InspectorInstrumentationCookie&, unsigned endLine);
 
     // FIXME: Remove once we no longer generate stacks outside of Inspector.
-    static void addMessageToConsole(Page*, MessageSource, MessageType, MessageLevel, const String& message, PassRefPtr<ScriptCallStack>, unsigned long requestIdentifier = 0);
-    static void addMessageToConsole(Page*, MessageSource, MessageType, MessageLevel, const String& message, JSC::ExecState*, PassRefPtr<ScriptArguments>, unsigned long requestIdentifier = 0);
+    static void addMessageToConsole(Page*, MessageSource, MessageType, MessageLevel, const String& message, PassRefPtr<Inspector::ScriptCallStack>, unsigned long requestIdentifier = 0);
+    static void addMessageToConsole(Page*, MessageSource, MessageType, MessageLevel, const String& message, JSC::ExecState*, PassRefPtr<Inspector::ScriptArguments>, unsigned long requestIdentifier = 0);
     static void addMessageToConsole(Page*, MessageSource, MessageType, MessageLevel, const String& message, const String& scriptID, unsigned lineNumber, unsigned columnNumber, JSC::ExecState* = nullptr, unsigned long requestIdentifier = 0);
 
     // FIXME: Convert to ScriptArguments to match non-worker context.
-    static void addMessageToConsole(WorkerGlobalScope*, MessageSource, MessageType, MessageLevel, const String& message, PassRefPtr<ScriptCallStack>, unsigned long requestIdentifier = 0);
+    static void addMessageToConsole(WorkerGlobalScope*, MessageSource, MessageType, MessageLevel, const String& message, PassRefPtr<Inspector::ScriptCallStack>, unsigned long requestIdentifier = 0);
     static void addMessageToConsole(WorkerGlobalScope*, MessageSource, MessageType, MessageLevel, const String& message, const String& scriptID, unsigned lineNumber, unsigned columnNumber, JSC::ExecState* = nullptr, unsigned long requestIdentifier = 0);
 
-    static void consoleCount(Page*, JSC::ExecState*, PassRefPtr<ScriptArguments>);
+    static void consoleCount(Page*, JSC::ExecState*, PassRefPtr<Inspector::ScriptArguments>);
     static void startConsoleTiming(Frame*, const String& title);
-    static void stopConsoleTiming(Frame*, const String& title, PassRefPtr<ScriptCallStack>);
-    static void consoleTimeStamp(Frame*, PassRefPtr<ScriptArguments>);
+    static void stopConsoleTiming(Frame*, const String& title, PassRefPtr<Inspector::ScriptCallStack>);
+    static void consoleTimeStamp(Frame*, PassRefPtr<Inspector::ScriptArguments>);
 
     static void didRequestAnimationFrame(Document*, int callbackId);
     static void didCancelAnimationFrame(Document*, int callbackId);
@@ -222,7 +224,7 @@ public:
     static void didFireAnimationFrame(const InspectorInstrumentationCookie&);
 
     static void addStartProfilingMessageToConsole(Page*, const String& title, unsigned lineNumber, unsigned columnNumber, const String& sourceURL);
-    static void addProfile(Page*, PassRefPtr<ScriptProfile>, PassRefPtr<ScriptCallStack>);
+    static void addProfile(Page*, PassRefPtr<ScriptProfile>, PassRefPtr<Inspector::ScriptCallStack>);
     static String getCurrentUserInitiatedProfileName(Page*, bool incrementProfileNumber);
     static bool profilerEnabled(Page*);
 
@@ -385,16 +387,16 @@ private:
     static InspectorInstrumentationCookie willWriteHTMLImpl(InstrumentingAgents*, unsigned startLine, Frame*);
     static void didWriteHTMLImpl(const InspectorInstrumentationCookie&, unsigned endLine);
 
-    static void addMessageToConsoleImpl(InstrumentingAgents*, MessageSource, MessageType, MessageLevel, const String& message, JSC::ExecState*, PassRefPtr<ScriptArguments>, unsigned long requestIdentifier);
+    static void addMessageToConsoleImpl(InstrumentingAgents*, MessageSource, MessageType, MessageLevel, const String& message, JSC::ExecState*, PassRefPtr<Inspector::ScriptArguments>, unsigned long requestIdentifier);
     static void addMessageToConsoleImpl(InstrumentingAgents*, MessageSource, MessageType, MessageLevel, const String& message, const String& scriptID, unsigned lineNumber, unsigned columnNumber, JSC::ExecState*, unsigned long requestIdentifier);
 
     // FIXME: Remove once we no longer generate stacks outside of Inspector.
-    static void addMessageToConsoleImpl(InstrumentingAgents*, MessageSource, MessageType, MessageLevel, const String& message, PassRefPtr<ScriptCallStack>, unsigned long requestIdentifier);
+    static void addMessageToConsoleImpl(InstrumentingAgents*, MessageSource, MessageType, MessageLevel, const String& message, PassRefPtr<Inspector::ScriptCallStack>, unsigned long requestIdentifier);
 
-    static void consoleCountImpl(InstrumentingAgents*, JSC::ExecState*, PassRefPtr<ScriptArguments>);
+    static void consoleCountImpl(InstrumentingAgents*, JSC::ExecState*, PassRefPtr<Inspector::ScriptArguments>);
     static void startConsoleTimingImpl(InstrumentingAgents*, Frame*, const String& title);
-    static void stopConsoleTimingImpl(InstrumentingAgents*, Frame*, const String& title, PassRefPtr<ScriptCallStack>);
-    static void consoleTimeStampImpl(InstrumentingAgents*, Frame*, PassRefPtr<ScriptArguments>);
+    static void stopConsoleTimingImpl(InstrumentingAgents*, Frame*, const String& title, PassRefPtr<Inspector::ScriptCallStack>);
+    static void consoleTimeStampImpl(InstrumentingAgents*, Frame*, PassRefPtr<Inspector::ScriptArguments>);
 
     static void didRequestAnimationFrameImpl(InstrumentingAgents*, int callbackId, Frame*);
     static void didCancelAnimationFrameImpl(InstrumentingAgents*, int callbackId, Frame*);
@@ -402,7 +404,7 @@ private:
     static void didFireAnimationFrameImpl(const InspectorInstrumentationCookie&);
 
     static void addStartProfilingMessageToConsoleImpl(InstrumentingAgents*, const String& title, unsigned lineNumber, unsigned columnNumber, const String& sourceURL);
-    static void addProfileImpl(InstrumentingAgents*, RefPtr<ScriptProfile>, PassRefPtr<ScriptCallStack>);
+    static void addProfileImpl(InstrumentingAgents*, RefPtr<ScriptProfile>, PassRefPtr<Inspector::ScriptCallStack>);
     static String getCurrentUserInitiatedProfileNameImpl(InstrumentingAgents*, bool incrementProfileNumber);
     static bool profilerEnabledImpl(InstrumentingAgents*);
 
index 4c1f00609686de97b5bc483cd0cb366432d5b630..33aff85cf7e03c30d80e5697e0d7b9f1e34de0f5 100644 (file)
@@ -34,7 +34,6 @@
 
 #include "InspectorLayerTreeAgent.h"
 
-#include "IdentifiersFactory.h"
 #include "InspectorDOMAgent.h"
 #include "InspectorWebFrontendDispatchers.h"
 #include "InstrumentingAgents.h"
@@ -44,6 +43,7 @@
 #include "RenderLayerBacking.h"
 #include "RenderLayerCompositor.h"
 #include "RenderView.h"
+#include <inspector/IdentifiersFactory.h>
 
 using namespace Inspector;
 
index f27930c7d26f41ae53a11a72408814f0b89509ae..cfee5d8cb312f30b06d2cc12e8c1eba2ad45ab6c 100644 (file)
  */
 
 #include "config.h"
+#include "InspectorPageAgent.h"
 
 #if ENABLE(INSPECTOR)
 
-#include "InspectorPageAgent.h"
-
 #include "CachedCSSStyleSheet.h"
 #include "CachedFont.h"
 #include "CachedImage.h"
@@ -53,7 +52,6 @@
 #include "FrameView.h"
 #include "HTMLFrameOwnerElement.h"
 #include "HTMLNames.h"
-#include "IdentifiersFactory.h"
 #include "ImageBuffer.h"
 #include "InspectorClient.h"
 #include "InspectorDOMAgent.h"
@@ -73,6 +71,7 @@
 #include "UserGestureIndicator.h"
 #include <bindings/ScriptValue.h>
 #include <inspector/ContentSearchUtilities.h>
+#include <inspector/IdentifiersFactory.h>
 #include <inspector/InspectorValues.h>
 #include <wtf/CurrentTime.h>
 #include <wtf/ListHashSet.h>
index e8407eea2702611501116c10a08f9cb85699aa5c..c52c66af624a43b2e9ed437454d946bf0169b95f 100644 (file)
  */
 
 #include "config.h"
+#include "InspectorProfilerAgent.h"
 
 #if ENABLE(INSPECTOR)
 
-#include "InspectorProfilerAgent.h"
-
 #include "CommandLineAPIHost.h"
 #include "Console.h"
-#include "ConsoleAPITypes.h"
-#include "ConsoleTypes.h"
-#include "InspectorConsoleAgent.h"
 #include "InspectorWebFrontendDispatchers.h"
 #include "InstrumentingAgents.h"
-#include "URL.h"
 #include "Page.h"
 #include "PageInjectedScriptManager.h"
 #include "PageScriptDebugServer.h"
 #include "ScriptHeapSnapshot.h"
 #include "ScriptProfile.h"
 #include "ScriptProfiler.h"
+#include "URL.h"
 #include "WorkerScriptDebugServer.h"
 #include <bindings/ScriptObject.h>
+#include <inspector/ConsoleTypes.h>
 #include <inspector/InjectedScript.h>
 #include <inspector/InspectorValues.h>
+#include <inspector/agents/InspectorConsoleAgent.h>
 #include <wtf/CurrentTime.h>
 #include <wtf/OwnPtr.h>
 #include <wtf/text/StringConcatenate.h>
@@ -156,14 +154,14 @@ void InspectorProfilerAgent::addProfileFinishedMessageToConsole(PassRefPtr<Scrip
         return;
     RefPtr<ScriptProfile> profile = prpProfile;
     String message = makeString(profile->title(), '#', String::number(profile->uid()));
-    m_consoleAgent->addMessageToConsole(ConsoleAPIMessageSource, ProfileEndMessageType, DebugMessageLevel, message, sourceURL, lineNumber, columnNumber);
+    m_consoleAgent->addMessageToConsole(MessageSource::ConsoleAPI, MessageType::ProfileEnd, MessageLevel::Debug, message, sourceURL, lineNumber, columnNumber);
 }
 
 void InspectorProfilerAgent::addStartProfilingMessageToConsole(const String& title, unsigned lineNumber, unsigned columnNumber, const String& sourceURL)
 {
     if (!m_frontendDispatcher)
         return;
-    m_consoleAgent->addMessageToConsole(ConsoleAPIMessageSource, ProfileMessageType, DebugMessageLevel, title, sourceURL, lineNumber, columnNumber);
+    m_consoleAgent->addMessageToConsole(MessageSource::ConsoleAPI, MessageType::Profile, MessageLevel::Debug, title, sourceURL, lineNumber, columnNumber);
 }
 
 void InspectorProfilerAgent::collectGarbage(WebCore::ErrorString*)
index b9b60316db6944eb288b15d7675a3aaa9fb8b2c9..7dfe18c1744b7850c4f53a7390d4985266751590 100644 (file)
 
 namespace Inspector {
 class InspectorArray;
+class InspectorConsoleAgent;
 class InspectorObject;
 }
 
 namespace WebCore {
 
-class InspectorConsoleAgent;
 class InstrumentingAgents;
 class Page;
 class PageInjectedScriptManager;
@@ -61,8 +61,8 @@ typedef String ErrorString;
 class InspectorProfilerAgent : public InspectorAgentBase, public Inspector::InspectorProfilerBackendDispatcherHandler {
     WTF_MAKE_NONCOPYABLE(InspectorProfilerAgent); WTF_MAKE_FAST_ALLOCATED;
 public:
-    static std::unique_ptr<InspectorProfilerAgent> create(InstrumentingAgents*, InspectorConsoleAgent*, Page*, PageInjectedScriptManager*);
-    static std::unique_ptr<InspectorProfilerAgent> create(InstrumentingAgents*, InspectorConsoleAgent*, WorkerGlobalScope*, PageInjectedScriptManager*);
+    static std::unique_ptr<InspectorProfilerAgent> create(InstrumentingAgents*, Inspector::InspectorConsoleAgent*, Page*, PageInjectedScriptManager*);
+    static std::unique_ptr<InspectorProfilerAgent> create(InstrumentingAgents*, Inspector::InspectorConsoleAgent*, WorkerGlobalScope*, PageInjectedScriptManager*);
 
     virtual ~InspectorProfilerAgent();
 
@@ -101,7 +101,7 @@ public:
     virtual void getHeapObjectId(ErrorString*, const String& objectId, String* heapSnapshotObjectId) override;
 
 protected:
-    InspectorProfilerAgent(InstrumentingAgents*, InspectorConsoleAgent*, PageInjectedScriptManager*);
+    InspectorProfilerAgent(InstrumentingAgents*, Inspector::InspectorConsoleAgent*, PageInjectedScriptManager*);
     virtual void startProfiling(const String& title) = 0;
     virtual PassRefPtr<ScriptProfile> stopProfiling(const String& title) = 0;
 
@@ -115,7 +115,7 @@ private:
     PassRefPtr<Inspector::TypeBuilder::Profiler::ProfileHeader> createProfileHeader(const ScriptProfile&);
     PassRefPtr<Inspector::TypeBuilder::Profiler::ProfileHeader> createSnapshotHeader(const ScriptHeapSnapshot&);
 
-    InspectorConsoleAgent* m_consoleAgent;
+    Inspector::InspectorConsoleAgent* m_consoleAgent;
     PageInjectedScriptManager* m_injectedScriptManager;
     std::unique_ptr<Inspector::InspectorProfilerFrontendDispatcher> m_frontendDispatcher;
     RefPtr<Inspector::InspectorProfilerBackendDispatcher> m_backendDispatcher;
index 65f8db1b55d829af7ecdeacea081e32dad58a1dd..480bde9047187f508bedd69c130d861975097466 100644 (file)
  */
 
 #include "config.h"
+#include "InspectorResourceAgent.h"
 
 #if ENABLE(INSPECTOR)
 
-#include "InspectorResourceAgent.h"
-
 #include "CachedRawResource.h"
 #include "CachedResource.h"
 #include "CachedResourceLoader.h"
 #include "FrameLoader.h"
 #include "HTTPHeaderMap.h"
 #include "IconController.h"
-#include "IdentifiersFactory.h"
 #include "InspectorClient.h"
 #include "InspectorPageAgent.h"
 #include "InspectorWebFrontendDispatchers.h"
 #include "InstrumentingAgents.h"
+#include "JSMainThreadExecState.h"
 #include "MemoryCache.h"
 #include "NetworkResourcesData.h"
 #include "Page.h"
 #include "ResourceLoader.h"
 #include "ResourceRequest.h"
 #include "ResourceResponse.h"
-#include "ScriptCallStack.h"
-#include "ScriptCallStackFactory.h"
 #include "ScriptableDocumentParser.h"
 #include "Settings.h"
 #include "SubresourceLoader.h"
 #include "URL.h"
 #include "WebSocketFrame.h"
 #include "XMLHttpRequest.h"
+#include <inspector/IdentifiersFactory.h>
 #include <inspector/InspectorValues.h>
+#include <inspector/ScriptCallStack.h>
+#include <inspector/ScriptCallStackFactory.h>
 #include <wtf/CurrentTime.h>
 #include <wtf/HexNumber.h>
 #include <wtf/ListHashSet.h>
@@ -439,7 +439,7 @@ void InspectorResourceAgent::didScheduleStyleRecalculation(Document* document)
 
 PassRefPtr<Inspector::TypeBuilder::Network::Initiator> InspectorResourceAgent::buildInitiatorObject(Document* document)
 {
-    RefPtr<ScriptCallStack> stackTrace = createScriptCallStack(ScriptCallStack::maxCallStackSizeToCapture, true);
+    RefPtr<ScriptCallStack> stackTrace = createScriptCallStack(JSMainThreadExecState::currentState(), ScriptCallStack::maxCallStackSizeToCapture, true);
     if (stackTrace && stackTrace->size() > 0) {
         RefPtr<Inspector::TypeBuilder::Network::Initiator> initiatorObject = Inspector::TypeBuilder::Network::Initiator::create()
             .setType(Inspector::TypeBuilder::Network::Initiator::Type::Script);
index 8aec68eeb97743aef37a4c2fe761d34fa4e02a69..4a0cefb9a09573d4d759709dd58ec488e1a06670 100644 (file)
@@ -37,7 +37,6 @@
 #include "Event.h"
 #include "Frame.h"
 #include "FrameView.h"
-#include "IdentifiersFactory.h"
 #include "InspectorClient.h"
 #include "InspectorCounters.h"
 #include "InspectorInstrumentation.h"
@@ -53,6 +52,7 @@
 #include "ResourceResponse.h"
 #include "ScriptProfiler.h"
 #include "TimelineRecordFactory.h"
+#include <inspector/IdentifiersFactory.h>
 #include <wtf/CurrentTime.h>
 
 using namespace Inspector;
index 98e6bdd0c96a8c5ca669bfbfa34d3252ef317cac..b22c7b5712f562370972b827776a342b21752b09 100644 (file)
@@