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

Side by Side Diff: Source/WebCore/inspector/InstrumentingAgents.cpp

Issue 12077053: Merge 140127 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1364/
Patch Set: Created 7 years, 10 months 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
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 24 matching lines...) Expand all
35 #include "InstrumentingAgents.h" 35 #include "InstrumentingAgents.h"
36 36
37 #include "InspectorController.h" 37 #include "InspectorController.h"
38 #include "Page.h" 38 #include "Page.h"
39 #include "WorkerContext.h" 39 #include "WorkerContext.h"
40 #include "WorkerInspectorController.h" 40 #include "WorkerInspectorController.h"
41 #include <wtf/MainThread.h> 41 #include <wtf/MainThread.h>
42 42
43 namespace WebCore { 43 namespace WebCore {
44 44
45 InstrumentingAgents::InstrumentingAgents()
46 : m_inspectorAgent(0)
47 , m_inspectorPageAgent(0)
48 , m_inspectorCSSAgent(0)
49 #if USE(ACCELERATED_COMPOSITING)
50 , m_inspectorLayerTreeAgent(0)
51 #endif
52 , m_inspectorConsoleAgent(0)
53 , m_inspectorDOMAgent(0)
54 , m_inspectorResourceAgent(0)
55 , m_pageRuntimeAgent(0)
56 , m_workerRuntimeAgent(0)
57 , m_inspectorTimelineAgent(0)
58 , m_inspectorDOMStorageAgent(0)
59 #if ENABLE(SQL_DATABASE)
60 , m_inspectorDatabaseAgent(0)
61 #endif
62 #if ENABLE(FILE_SYSTEM)
63 , m_inspectorFileSystemAgent(0)
64 #endif
65 , m_inspectorApplicationCacheAgent(0)
66 #if ENABLE(JAVASCRIPT_DEBUGGER)
67 , m_inspectorDebuggerAgent(0)
68 , m_pageDebuggerAgent(0)
69 , m_inspectorDOMDebuggerAgent(0)
70 , m_inspectorProfilerAgent(0)
71 #endif
72 #if ENABLE(WORKERS)
73 , m_inspectorWorkerAgent(0)
74 #endif
75 , m_inspectorCanvasAgent(0)
76 {
77 }
78
79 void InstrumentingAgents::reset()
80 {
81 m_inspectorAgent = 0;
82 m_inspectorPageAgent = 0;
83 m_inspectorCSSAgent = 0;
84 #if USE(ACCELERATED_COMPOSITING)
85 m_inspectorLayerTreeAgent = 0;
86 #endif
87 m_inspectorConsoleAgent = 0;
88 m_inspectorDOMAgent = 0;
89 m_inspectorResourceAgent = 0;
90 m_pageRuntimeAgent = 0;
91 m_workerRuntimeAgent = 0;
92 m_inspectorTimelineAgent = 0;
93 m_inspectorDOMStorageAgent = 0;
94 #if ENABLE(SQL_DATABASE)
95 m_inspectorDatabaseAgent = 0;
96 #endif
97 #if ENABLE(FILE_SYSTEM)
98 m_inspectorFileSystemAgent = 0;
99 #endif
100 m_inspectorApplicationCacheAgent = 0;
101 #if ENABLE(JAVASCRIPT_DEBUGGER)
102 m_inspectorDebuggerAgent = 0;
103 m_pageDebuggerAgent = 0;
104 m_inspectorDOMDebuggerAgent = 0;
105 m_inspectorProfilerAgent = 0;
106 #endif
107 #if ENABLE(WORKERS)
108 m_inspectorWorkerAgent = 0;
109 #endif
110 m_inspectorCanvasAgent = 0;
111 }
112
45 InstrumentingAgents* instrumentationForPage(Page* page) 113 InstrumentingAgents* instrumentationForPage(Page* page)
46 { 114 {
47 ASSERT(isMainThread()); 115 ASSERT(isMainThread());
48 if (InspectorController* controller = page->inspectorController()) 116 if (InspectorController* controller = page->inspectorController())
49 return controller->m_instrumentingAgents.get(); 117 return controller->m_instrumentingAgents.get();
50 return 0; 118 return 0;
51 } 119 }
52 120
53 #if ENABLE(WORKERS) 121 #if ENABLE(WORKERS)
54 InstrumentingAgents* instrumentationForWorkerContext(WorkerContext* workerContex t) 122 InstrumentingAgents* instrumentationForWorkerContext(WorkerContext* workerContex t)
55 { 123 {
56 if (WorkerInspectorController* controller = workerContext->workerInspectorCo ntroller()) 124 if (WorkerInspectorController* controller = workerContext->workerInspectorCo ntroller())
57 return controller->m_instrumentingAgents.get(); 125 return controller->m_instrumentingAgents.get();
58 return 0; 126 return 0;
59 } 127 }
60 #endif 128 #endif
61 129
62 } // namespace WebCore 130 } // namespace WebCore
63 131
64 #endif // ENABLE(INSPECTOR) 132 #endif // ENABLE(INSPECTOR)
OLDNEW
« no previous file with comments | « Source/WebCore/inspector/InstrumentingAgents.h ('k') | Source/WebCore/inspector/WorkerInspectorController.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698