Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(280)

Side by Side Diff: Source/core/inspector/InspectorInstrumentation.cpp

Issue 114033002: DevTools: Capture async stacks for event listeners. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: addressed Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 13 matching lines...) Expand all
24 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 24 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 */ 29 */
30 30
31 #include "config.h" 31 #include "config.h"
32 #include "core/inspector/InspectorInstrumentation.h" 32 #include "core/inspector/InspectorInstrumentation.h"
33 33
34 #include "core/events/EventTarget.h"
34 #include "core/fetch/FetchInitiatorInfo.h" 35 #include "core/fetch/FetchInitiatorInfo.h"
35 #include "core/inspector/InspectorAgent.h" 36 #include "core/inspector/InspectorAgent.h"
36 #include "core/inspector/InspectorCSSAgent.h" 37 #include "core/inspector/InspectorCSSAgent.h"
37 #include "core/inspector/InspectorConsoleAgent.h" 38 #include "core/inspector/InspectorConsoleAgent.h"
38 #include "core/inspector/InspectorController.h" 39 #include "core/inspector/InspectorController.h"
39 #include "core/inspector/InspectorDebuggerAgent.h" 40 #include "core/inspector/InspectorDebuggerAgent.h"
40 #include "core/inspector/InspectorProfilerAgent.h" 41 #include "core/inspector/InspectorProfilerAgent.h"
41 #include "core/inspector/InspectorResourceAgent.h" 42 #include "core/inspector/InspectorResourceAgent.h"
42 #include "core/inspector/InspectorTimelineAgent.h" 43 #include "core/inspector/InspectorTimelineAgent.h"
43 #include "core/inspector/InstrumentingAgents.h" 44 #include "core/inspector/InstrumentingAgents.h"
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
199 return 0; 200 return 0;
200 } 201 }
201 202
202 InstrumentingAgents* instrumentingAgentsFor(Page* page) 203 InstrumentingAgents* instrumentingAgentsFor(Page* page)
203 { 204 {
204 if (!page) 205 if (!page)
205 return 0; 206 return 0;
206 return instrumentationForPage(page); 207 return instrumentationForPage(page);
207 } 208 }
208 209
210 InstrumentingAgents* instrumentingAgentsFor(EventTarget* eventTarget)
211 {
212 if (!eventTarget)
213 return 0;
214 return instrumentingAgentsFor(eventTarget->executionContext());
215 }
216
209 InstrumentingAgents* instrumentingAgentsFor(RenderObject* renderer) 217 InstrumentingAgents* instrumentingAgentsFor(RenderObject* renderer)
210 { 218 {
211 return instrumentingAgentsFor(renderer->frame()); 219 return instrumentingAgentsFor(renderer->frame());
212 } 220 }
213 221
214 InstrumentingAgents* instrumentingAgentsFor(WorkerGlobalScope* workerGlobalScope ) 222 InstrumentingAgents* instrumentingAgentsFor(WorkerGlobalScope* workerGlobalScope )
215 { 223 {
216 if (!workerGlobalScope) 224 if (!workerGlobalScope)
217 return 0; 225 return 0;
218 return instrumentationForWorkerGlobalScope(workerGlobalScope); 226 return instrumentationForWorkerGlobalScope(workerGlobalScope);
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
251 259
252 InstrumentingAgents* instrumentationForWorkerGlobalScope(WorkerGlobalScope* work erGlobalScope) 260 InstrumentingAgents* instrumentationForWorkerGlobalScope(WorkerGlobalScope* work erGlobalScope)
253 { 261 {
254 if (WorkerInspectorController* controller = workerGlobalScope->workerInspect orController()) 262 if (WorkerInspectorController* controller = workerGlobalScope->workerInspect orController())
255 return controller->m_instrumentingAgents.get(); 263 return controller->m_instrumentingAgents.get();
256 return 0; 264 return 0;
257 } 265 }
258 266
259 } // namespace WebCore 267 } // namespace WebCore
260 268
OLDNEW
« no previous file with comments | « Source/core/inspector/InspectorInstrumentation.h ('k') | Source/core/inspector/InspectorInstrumentation.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698