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 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
169 } | 169 } |
170 | 170 |
171 void PageDebuggerAgent::didClearDocumentOfWindowObject(LocalFrame* frame) | 171 void PageDebuggerAgent::didClearDocumentOfWindowObject(LocalFrame* frame) |
172 { | 172 { |
173 // FIXME: what about nested objects? | 173 // FIXME: what about nested objects? |
174 if (frame != m_pageAgent->inspectedFrame()) | 174 if (frame != m_pageAgent->inspectedFrame()) |
175 return; | 175 return; |
176 reset(); | 176 reset(); |
177 } | 177 } |
178 | 178 |
179 void PageDebuggerAgent::didCommitLoadForLocalFrame(LocalFrame*) | |
180 { | |
181 resetModifiedSources(); | |
182 } | |
183 | |
184 void PageDebuggerAgent::compileScript(ErrorString* errorString, const String& ex
pression, const String& sourceURL, bool persistScript, const int* executionConte
xtId, TypeBuilder::OptOutput<ScriptId>* scriptId, RefPtr<ExceptionDetails>& exce
ptionDetails) | 179 void PageDebuggerAgent::compileScript(ErrorString* errorString, const String& ex
pression, const String& sourceURL, bool persistScript, const int* executionConte
xtId, TypeBuilder::OptOutput<ScriptId>* scriptId, RefPtr<ExceptionDetails>& exce
ptionDetails) |
185 { | 180 { |
186 InjectedScript injectedScript = injectedScriptForEval(errorString, execution
ContextId); | 181 InjectedScript injectedScript = injectedScriptForEval(errorString, execution
ContextId); |
187 if (injectedScript.isEmpty()) { | 182 if (injectedScript.isEmpty()) { |
188 *errorString = "Inspected frame has gone"; | 183 *errorString = "Inspected frame has gone"; |
189 return; | 184 return; |
190 } | 185 } |
191 ExecutionContext* executionContext = injectedScript.scriptState()->execution
Context(); | 186 ExecutionContext* executionContext = injectedScript.scriptState()->execution
Context(); |
192 RefPtrWillBeRawPtr<LocalFrame> protect(toDocument(executionContext)->frame()
); | 187 RefPtrWillBeRawPtr<LocalFrame> protect(toDocument(executionContext)->frame()
); |
193 InspectorDebuggerAgent::compileScript(errorString, expression, sourceURL, pe
rsistScript, executionContextId, scriptId, exceptionDetails); | 188 InspectorDebuggerAgent::compileScript(errorString, expression, sourceURL, pe
rsistScript, executionContextId, scriptId, exceptionDetails); |
(...skipping 24 matching lines...) Expand all Loading... |
218 RefPtrWillBeRawPtr<LocalFrame> protect(frame); | 213 RefPtrWillBeRawPtr<LocalFrame> protect(frame); |
219 InspectorDebuggerAgent::runScript(errorString, scriptId, executionContextId,
objectGroup, doNotPauseOnExceptionsAndMuteConsole, result, exceptionDetails); | 214 InspectorDebuggerAgent::runScript(errorString, scriptId, executionContextId,
objectGroup, doNotPauseOnExceptionsAndMuteConsole, result, exceptionDetails); |
220 | 215 |
221 if (frame) | 216 if (frame) |
222 InspectorInstrumentation::didEvaluateScript(cookie); | 217 InspectorInstrumentation::didEvaluateScript(cookie); |
223 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "Update
Counters", TRACE_EVENT_SCOPE_THREAD, "data", InspectorUpdateCountersEvent::data(
)); | 218 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "Update
Counters", TRACE_EVENT_SCOPE_THREAD, "data", InspectorUpdateCountersEvent::data(
)); |
224 | 219 |
225 } | 220 } |
226 | 221 |
227 } // namespace blink | 222 } // namespace blink |
OLD | NEW |