| Index: third_party/WebKit/Source/core/instrumentation/CoreProbes.h
|
| diff --git a/third_party/WebKit/Source/core/inspector/InspectorInstrumentation.h b/third_party/WebKit/Source/core/instrumentation/CoreProbes.h
|
| similarity index 46%
|
| rename from third_party/WebKit/Source/core/inspector/InspectorInstrumentation.h
|
| rename to third_party/WebKit/Source/core/instrumentation/CoreProbes.h
|
| index 8656b3fd49208c2ecc1f793cace65618676f0d40..c2cb3e521ff9d67ac50417fe316c4f9bafc9c4ce 100644
|
| --- a/third_party/WebKit/Source/core/inspector/InspectorInstrumentation.h
|
| +++ b/third_party/WebKit/Source/core/instrumentation/CoreProbes.h
|
| @@ -1,35 +1,35 @@
|
| /*
|
| -* 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
|
| -* copyright notice, this list of conditions and the following disclaimer
|
| -* in the documentation and/or other materials provided with the
|
| -* distribution.
|
| -* * 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
|
| -* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
| -* OWNER 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 InspectorInstrumentation_h
|
| -#define InspectorInstrumentation_h
|
| + * 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
|
| + * copyright notice, this list of conditions and the following disclaimer
|
| + * in the documentation and/or other materials provided with the
|
| + * distribution.
|
| + * * 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
|
| + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
| + * OWNER 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 CoreProbes_h
|
| +#define CoreProbes_h
|
|
|
| #include "core/CoreExport.h"
|
| #include "core/dom/Document.h"
|
| @@ -39,7 +39,7 @@
|
|
|
| namespace blink {
|
|
|
| -class InspectorInstrumentationAgents;
|
| +class CoreProbesSink;
|
| class Resource;
|
| class ThreadDebugger;
|
| class WorkerGlobalScope;
|
| @@ -76,47 +76,37 @@ class CORE_EXPORT AsyncTask {
|
| };
|
|
|
| // Called from generated instrumentation code.
|
| -CORE_EXPORT InspectorInstrumentationAgents* instrumentingAgentsFor(
|
| - WorkerGlobalScope*);
|
| -CORE_EXPORT InspectorInstrumentationAgents*
|
| -instrumentingAgentsForNonDocumentContext(ExecutionContext*);
|
| +CORE_EXPORT CoreProbesSink* toCoreProbesSink(WorkerGlobalScope*);
|
| +CORE_EXPORT CoreProbesSink* toCoreProbesSink(ExecutionContext*);
|
|
|
| -inline InspectorInstrumentationAgents* instrumentingAgentsFor(
|
| - LocalFrame* frame) {
|
| +inline CoreProbesSink* toCoreProbesSink(LocalFrame* frame) {
|
| return frame ? frame->instrumentingAgents() : nullptr;
|
| }
|
|
|
| -inline InspectorInstrumentationAgents* instrumentingAgentsFor(
|
| - Document& document) {
|
| +inline CoreProbesSink* toCoreProbesSink(Document& document) {
|
| LocalFrame* frame = document.frame();
|
| if (!frame && document.templateDocumentHost())
|
| frame = document.templateDocumentHost()->frame();
|
| - return instrumentingAgentsFor(frame);
|
| + return toCoreProbesSink(frame);
|
| }
|
|
|
| -inline InspectorInstrumentationAgents* instrumentingAgentsFor(
|
| - Document* document) {
|
| - return document ? instrumentingAgentsFor(*document) : nullptr;
|
| +inline CoreProbesSink* toCoreProbesSink(Document* document) {
|
| + return document ? toCoreProbesSink(*document) : nullptr;
|
| }
|
|
|
| -inline InspectorInstrumentationAgents* instrumentingAgentsFor(
|
| - ExecutionContext* context) {
|
| +inline CoreProbesSink* toCoreProbesSink(ExecutionContext* context) {
|
| if (!context)
|
| return nullptr;
|
| - return context->isDocument()
|
| - ? instrumentingAgentsFor(*toDocument(context))
|
| - : instrumentingAgentsForNonDocumentContext(context);
|
| + return context->isDocument() ? toCoreProbesSink(*toDocument(context))
|
| + : toCoreProbesSink(context);
|
| }
|
|
|
| -inline InspectorInstrumentationAgents* instrumentingAgentsFor(Node* node) {
|
| - return node ? instrumentingAgentsFor(node->document()) : nullptr;
|
| +inline CoreProbesSink* toCoreProbesSink(Node* node) {
|
| + return node ? toCoreProbesSink(node->document()) : nullptr;
|
| }
|
|
|
| -inline InspectorInstrumentationAgents* instrumentingAgentsFor(
|
| - EventTarget* eventTarget) {
|
| - return eventTarget
|
| - ? instrumentingAgentsFor(eventTarget->getExecutionContext())
|
| - : nullptr;
|
| +inline CoreProbesSink* toCoreProbesSink(EventTarget* eventTarget) {
|
| + return eventTarget ? toCoreProbesSink(eventTarget->getExecutionContext()) : nullptr;
|
| }
|
|
|
| CORE_EXPORT void asyncTaskScheduled(ExecutionContext*,
|
| @@ -145,7 +135,7 @@ CORE_EXPORT void continueWithPolicyIgnore(LocalFrame*,
|
| } // namespace probe
|
| } // namespace blink
|
|
|
| -#include "core/InspectorInstrumentationInl.h"
|
| +#include "core/CoreProbesInl.h"
|
| #include "core/InspectorOverridesInl.h"
|
|
|
| -#endif // !defined(InspectorInstrumentation_h)
|
| +#endif // !defined(CoreProbes_h)
|
|
|