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

Side by Side Diff: third_party/WebKit/Source/platform/v8_inspector/V8DebuggerAgentImpl.cpp

Issue 2146333003: [DevTools] Replace SetScriptSourceError with ExceptionDetails in protocol (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: a Created 4 years, 5 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 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "platform/v8_inspector/V8DebuggerAgentImpl.h" 5 #include "platform/v8_inspector/V8DebuggerAgentImpl.h"
6 6
7 #include "platform/inspector_protocol/String16.h" 7 #include "platform/inspector_protocol/String16.h"
8 #include "platform/inspector_protocol/Values.h" 8 #include "platform/inspector_protocol/Values.h"
9 #include "platform/v8_inspector/InjectedScript.h" 9 #include "platform/v8_inspector/InjectedScript.h"
10 #include "platform/v8_inspector/InspectedContext.h" 10 #include "platform/v8_inspector/InspectedContext.h"
(...skipping 512 matching lines...) Expand 10 before | Expand all | Expand 10 after
523 *error = String16("No script for id: " + scriptId); 523 *error = String16("No script for id: " + scriptId);
524 } 524 }
525 525
526 void V8DebuggerAgentImpl::setScriptSource(ErrorString* errorString, 526 void V8DebuggerAgentImpl::setScriptSource(ErrorString* errorString,
527 const String16& scriptId, 527 const String16& scriptId,
528 const String16& newContent, 528 const String16& newContent,
529 const Maybe<bool>& preview, 529 const Maybe<bool>& preview,
530 Maybe<protocol::Array<protocol::Debugger::CallFrame>>* newCallFrames, 530 Maybe<protocol::Array<protocol::Debugger::CallFrame>>* newCallFrames,
531 Maybe<bool>* stackChanged, 531 Maybe<bool>* stackChanged,
532 Maybe<StackTrace>* asyncStackTrace, 532 Maybe<StackTrace>* asyncStackTrace,
533 Maybe<protocol::Debugger::SetScriptSourceError>* optOutCompileError) 533 Maybe<protocol::Runtime::ExceptionDetails>* optOutCompileError)
534 { 534 {
535 if (!checkEnabled(errorString)) 535 if (!checkEnabled(errorString))
536 return; 536 return;
537 537
538 v8::HandleScope handles(m_isolate); 538 v8::HandleScope handles(m_isolate);
539 v8::Local<v8::String> newSource = toV8String(m_isolate, newContent); 539 v8::Local<v8::String> newSource = toV8String(m_isolate, newContent);
540 if (!debugger().setScriptSource(scriptId, newSource, preview.fromMaybe(false ), errorString, optOutCompileError, &m_pausedCallFrames, stackChanged)) 540 if (!debugger().setScriptSource(scriptId, newSource, preview.fromMaybe(false ), errorString, optOutCompileError, &m_pausedCallFrames, stackChanged))
541 return; 541 return;
542 542
543 ScriptsMap::iterator it = m_scripts.find(scriptId); 543 ScriptsMap::iterator it = m_scripts.find(scriptId);
(...skipping 637 matching lines...) Expand 10 before | Expand all | Expand 10 after
1181 { 1181 {
1182 if (!enabled()) 1182 if (!enabled())
1183 return; 1183 return;
1184 m_scheduledDebuggerStep = NoStep; 1184 m_scheduledDebuggerStep = NoStep;
1185 m_scripts.clear(); 1185 m_scripts.clear();
1186 m_blackboxedPositions.clear(); 1186 m_blackboxedPositions.clear();
1187 m_breakpointIdToDebuggerBreakpointIds.clear(); 1187 m_breakpointIdToDebuggerBreakpointIds.clear();
1188 } 1188 }
1189 1189
1190 } // namespace blink 1190 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698