| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 51 #include "core/inspector/InspectorInspectorAgent.h" | 51 #include "core/inspector/InspectorInspectorAgent.h" |
| 52 #include "core/inspector/InspectorInstrumentation.h" | 52 #include "core/inspector/InspectorInstrumentation.h" |
| 53 #include "core/inspector/InspectorLayerTreeAgent.h" | 53 #include "core/inspector/InspectorLayerTreeAgent.h" |
| 54 #include "core/inspector/InspectorMemoryAgent.h" | 54 #include "core/inspector/InspectorMemoryAgent.h" |
| 55 #include "core/inspector/InspectorOverlay.h" | 55 #include "core/inspector/InspectorOverlay.h" |
| 56 #include "core/inspector/InspectorPageAgent.h" | 56 #include "core/inspector/InspectorPageAgent.h" |
| 57 #include "core/inspector/InspectorProfilerAgent.h" | 57 #include "core/inspector/InspectorProfilerAgent.h" |
| 58 #include "core/inspector/InspectorResourceAgent.h" | 58 #include "core/inspector/InspectorResourceAgent.h" |
| 59 #include "core/inspector/InspectorState.h" | 59 #include "core/inspector/InspectorState.h" |
| 60 #include "core/inspector/InspectorTimelineAgent.h" | 60 #include "core/inspector/InspectorTimelineAgent.h" |
| 61 #include "core/inspector/InspectorTracingAgent.h" |
| 61 #include "core/inspector/InspectorWorkerAgent.h" | 62 #include "core/inspector/InspectorWorkerAgent.h" |
| 62 #include "core/inspector/InstrumentingAgents.h" | 63 #include "core/inspector/InstrumentingAgents.h" |
| 63 #include "core/inspector/PageConsoleAgent.h" | 64 #include "core/inspector/PageConsoleAgent.h" |
| 64 #include "core/inspector/PageDebuggerAgent.h" | 65 #include "core/inspector/PageDebuggerAgent.h" |
| 65 #include "core/inspector/PageRuntimeAgent.h" | 66 #include "core/inspector/PageRuntimeAgent.h" |
| 66 #include "core/page/Page.h" | 67 #include "core/page/Page.h" |
| 67 #include "core/rendering/RenderLayer.h" | 68 #include "core/rendering/RenderLayer.h" |
| 68 #include "platform/PlatformMouseEvent.h" | 69 #include "platform/PlatformMouseEvent.h" |
| 69 | 70 |
| 70 namespace WebCore { | 71 namespace WebCore { |
| (...skipping 21 matching lines...) Expand all Loading... |
| 92 | 93 |
| 93 OwnPtr<InspectorDOMAgent> domAgentPtr(InspectorDOMAgent::create(m_pageAgent,
injectedScriptManager, overlay)); | 94 OwnPtr<InspectorDOMAgent> domAgentPtr(InspectorDOMAgent::create(m_pageAgent,
injectedScriptManager, overlay)); |
| 94 m_domAgent = domAgentPtr.get(); | 95 m_domAgent = domAgentPtr.get(); |
| 95 m_agents.append(domAgentPtr.release()); | 96 m_agents.append(domAgentPtr.release()); |
| 96 | 97 |
| 97 | 98 |
| 98 OwnPtr<InspectorLayerTreeAgent> layerTreeAgentPtr(InspectorLayerTreeAgent::c
reate(m_domAgent, m_page)); | 99 OwnPtr<InspectorLayerTreeAgent> layerTreeAgentPtr(InspectorLayerTreeAgent::c
reate(m_domAgent, m_page)); |
| 99 m_layerTreeAgent = layerTreeAgentPtr.get(); | 100 m_layerTreeAgent = layerTreeAgentPtr.get(); |
| 100 m_agents.append(layerTreeAgentPtr.release()); | 101 m_agents.append(layerTreeAgentPtr.release()); |
| 101 | 102 |
| 102 OwnPtr<InspectorTimelineAgent> timelineAgentPtr(InspectorTimelineAgent::crea
te(m_pageAgent, m_domAgent, m_layerTreeAgent, | 103 OwnPtr<InspectorTracingAgent> tracingAgentPtr = InspectorTracingAgent::creat
e(inspectorClient); |
| 104 m_tracingAgent = tracingAgentPtr.get(); |
| 105 m_agents.append(tracingAgentPtr.release()); |
| 106 |
| 107 OwnPtr<InspectorTimelineAgent> timelineAgentPtr(InspectorTimelineAgent::crea
te(m_pageAgent, m_domAgent, m_layerTreeAgent, m_tracingAgent, |
| 103 overlay, InspectorTimelineAgent::PageInspector, inspectorClient)); | 108 overlay, InspectorTimelineAgent::PageInspector, inspectorClient)); |
| 104 m_timelineAgent = timelineAgentPtr.get(); | 109 m_timelineAgent = timelineAgentPtr.get(); |
| 105 m_agents.append(timelineAgentPtr.release()); | 110 m_agents.append(timelineAgentPtr.release()); |
| 106 | 111 |
| 107 PageScriptDebugServer* pageScriptDebugServer = &PageScriptDebugServer::share
d(); | 112 PageScriptDebugServer* pageScriptDebugServer = &PageScriptDebugServer::share
d(); |
| 108 | 113 |
| 109 m_agents.append(PageRuntimeAgent::create(injectedScriptManager, pageScriptDe
bugServer, m_page, m_pageAgent)); | 114 m_agents.append(PageRuntimeAgent::create(injectedScriptManager, pageScriptDe
bugServer, m_page, m_pageAgent)); |
| 110 | 115 |
| 111 m_agents.append(PageConsoleAgent::create(injectedScriptManager, m_domAgent,
m_timelineAgent)); | 116 m_agents.append(PageConsoleAgent::create(injectedScriptManager, m_domAgent,
m_timelineAgent)); |
| 112 | 117 |
| (...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 262 } | 267 } |
| 263 | 268 |
| 264 void InspectorController::setProcessId(long processId) | 269 void InspectorController::setProcessId(long processId) |
| 265 { | 270 { |
| 266 IdentifiersFactory::setProcessId(processId); | 271 IdentifiersFactory::setProcessId(processId); |
| 267 } | 272 } |
| 268 | 273 |
| 269 void InspectorController::setLayerTreeId(int id) | 274 void InspectorController::setLayerTreeId(int id) |
| 270 { | 275 { |
| 271 m_timelineAgent->setLayerTreeId(id); | 276 m_timelineAgent->setLayerTreeId(id); |
| 277 m_tracingAgent->setLayerTreeId(id); |
| 272 } | 278 } |
| 273 | 279 |
| 274 void InspectorController::webViewResized(const IntSize& size) | 280 void InspectorController::webViewResized(const IntSize& size) |
| 275 { | 281 { |
| 276 if (InspectorPageAgent* pageAgent = m_instrumentingAgents->inspectorPageAgen
t()) | 282 if (InspectorPageAgent* pageAgent = m_instrumentingAgents->inspectorPageAgen
t()) |
| 277 pageAgent->webViewResized(size); | 283 pageAgent->webViewResized(size); |
| 278 } | 284 } |
| 279 | 285 |
| 280 bool InspectorController::isUnderTest() | 286 bool InspectorController::isUnderTest() |
| 281 { | 287 { |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 483 m_layerTreeAgent->willAddPageOverlay(layer); | 489 m_layerTreeAgent->willAddPageOverlay(layer); |
| 484 } | 490 } |
| 485 | 491 |
| 486 void InspectorController::didRemovePageOverlay(const GraphicsLayer* layer) | 492 void InspectorController::didRemovePageOverlay(const GraphicsLayer* layer) |
| 487 { | 493 { |
| 488 if (m_layerTreeAgent) | 494 if (m_layerTreeAgent) |
| 489 m_layerTreeAgent->didRemovePageOverlay(layer); | 495 m_layerTreeAgent->didRemovePageOverlay(layer); |
| 490 } | 496 } |
| 491 | 497 |
| 492 } // namespace WebCore | 498 } // namespace WebCore |
| OLD | NEW |