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

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

Issue 761143003: DevTools: remove ScriptPreprocessor (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 5 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 | 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 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 } 118 }
119 } 119 }
120 120
121 bool collectingHTMLParseErrorsImpl(InstrumentingAgents* instrumentingAgents) 121 bool collectingHTMLParseErrorsImpl(InstrumentingAgents* instrumentingAgents)
122 { 122 {
123 if (InspectorInspectorAgent* inspectorAgent = instrumentingAgents->inspector InspectorAgent()) 123 if (InspectorInspectorAgent* inspectorAgent = instrumentingAgents->inspector InspectorAgent())
124 return inspectorAgent->hasFrontend(); 124 return inspectorAgent->hasFrontend();
125 return false; 125 return false;
126 } 126 }
127 127
128 ScriptSourceCode preprocessImpl(InstrumentingAgents* instrumentingAgents, LocalF rame* frame, const ScriptSourceCode& sourceCode)
129 {
130 if (InspectorDebuggerAgent* debuggerAgent = instrumentingAgents->inspectorDe buggerAgent())
131 return debuggerAgent->preprocess(frame, sourceCode);
132 return ScriptSourceCode();
133 }
134
135 String preprocessEventListenerImpl(InstrumentingAgents* instrumentingAgents, Loc alFrame* frame, const String& source, const String& url, const String& functionN ame)
136 {
137 if (InspectorDebuggerAgent* debuggerAgent = instrumentingAgents->inspectorDe buggerAgent())
138 return debuggerAgent->preprocessEventListener(frame, source, url, functi onName);
139 return source;
140 }
141
142 void appendAsyncCallStack(ExecutionContext* executionContext, ScriptCallStack* c allStack) 128 void appendAsyncCallStack(ExecutionContext* executionContext, ScriptCallStack* c allStack)
143 { 129 {
144 InstrumentingAgents* instrumentingAgents = instrumentingAgentsFor(executionC ontext); 130 InstrumentingAgents* instrumentingAgents = instrumentingAgentsFor(executionC ontext);
145 if (!instrumentingAgents) 131 if (!instrumentingAgents)
146 return; 132 return;
147 if (InspectorDebuggerAgent* debuggerAgent = instrumentingAgents->inspectorDe buggerAgent()) 133 if (InspectorDebuggerAgent* debuggerAgent = instrumentingAgents->inspectorDe buggerAgent())
148 callStack->setAsyncCallStack(debuggerAgent->currentAsyncStackTraceForCon sole()); 134 callStack->setAsyncCallStack(debuggerAgent->currentAsyncStackTraceForCon sole());
149 } 135 }
150 136
151 bool canvasAgentEnabled(ExecutionContext* executionContext) 137 bool canvasAgentEnabled(ExecutionContext* executionContext)
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
233 219
234 InstrumentingAgents* instrumentationForWorkerGlobalScope(WorkerGlobalScope* work erGlobalScope) 220 InstrumentingAgents* instrumentationForWorkerGlobalScope(WorkerGlobalScope* work erGlobalScope)
235 { 221 {
236 if (WorkerInspectorController* controller = workerGlobalScope->workerInspect orController()) 222 if (WorkerInspectorController* controller = workerGlobalScope->workerInspect orController())
237 return controller->m_instrumentingAgents.get(); 223 return controller->m_instrumentingAgents.get();
238 return 0; 224 return 0;
239 } 225 }
240 226
241 } // namespace blink 227 } // namespace blink
242 228
OLDNEW
« no previous file with comments | « Source/core/inspector/InspectorDebuggerAgent.cpp ('k') | Source/core/inspector/InspectorInstrumentationCustomInl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698