| Index: Source/core/inspector/InspectorInstrumentation.h
|
| diff --git a/Source/core/inspector/InspectorInstrumentation.h b/Source/core/inspector/InspectorInstrumentation.h
|
| index c0362806872208a3ece8be2c366cd087e5b36dc1..724a727857863e1f36f6cdf80c89773b2504a00e 100644
|
| --- a/Source/core/inspector/InspectorInstrumentation.h
|
| +++ b/Source/core/inspector/InspectorInstrumentation.h
|
| @@ -54,6 +54,7 @@
|
| class Document;
|
| class EventTarget;
|
| class ExecutionContext;
|
| +class FrameHost;
|
| class InspectorTimelineAgent;
|
| class InstrumentingAgents;
|
| class ThreadableLoaderClient;
|
| @@ -100,6 +101,7 @@
|
| InspectorTimelineAgent* retrieveTimelineAgent(const InspectorInstrumentationCookie&);
|
|
|
| // Called from generated instrumentation code.
|
| +InstrumentingAgents* instrumentingAgentsFor(Page*);
|
| InstrumentingAgents* instrumentingAgentsFor(LocalFrame*);
|
| InstrumentingAgents* instrumentingAgentsFor(EventTarget*);
|
| InstrumentingAgents* instrumentingAgentsFor(ExecutionContext*);
|
| @@ -108,6 +110,7 @@
|
| InstrumentingAgents* instrumentingAgentsFor(RenderObject*);
|
| InstrumentingAgents* instrumentingAgentsFor(Node*);
|
| InstrumentingAgents* instrumentingAgentsFor(WorkerGlobalScope*);
|
| +InstrumentingAgents* instrumentingAgentsFor(FrameHost*);
|
|
|
| // Helper for the one above.
|
| InstrumentingAgents* instrumentingAgentsForNonDocumentContext(ExecutionContext*);
|
| @@ -142,12 +145,17 @@
|
| return context->isDocument() ? instrumentingAgentsFor(*toDocument(context)) : instrumentingAgentsForNonDocumentContext(context);
|
| }
|
|
|
| +inline InstrumentingAgents* instrumentingAgentsFor(LocalFrame* frame)
|
| +{
|
| + return frame ? instrumentingAgentsFor(frame->page()) : 0;
|
| +}
|
| +
|
| inline InstrumentingAgents* instrumentingAgentsFor(Document& document)
|
| {
|
| - LocalFrame* frame = document.frame();
|
| - if (!frame && document.templateDocumentHost())
|
| - frame = document.templateDocumentHost()->frame();
|
| - return instrumentingAgentsFor(frame);
|
| + Page* page = document.page();
|
| + if (!page && document.templateDocumentHost())
|
| + page = document.templateDocumentHost()->page();
|
| + return instrumentingAgentsFor(page);
|
| }
|
|
|
| inline InstrumentingAgents* instrumentingAgentsFor(Document* document)
|
| @@ -172,6 +180,8 @@
|
|
|
| } // namespace InspectorInstrumentation
|
|
|
| +InstrumentingAgents* instrumentationForPage(Page*);
|
| +
|
| InstrumentingAgents* instrumentationForWorkerGlobalScope(WorkerGlobalScope*);
|
|
|
| } // namespace blink
|
|
|