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

Side by Side Diff: third_party/WebKit/Source/bindings/core/v8/ScriptController.cpp

Issue 2035653006: [DevTools] Move Console to v8 inspector. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: improved api a bit 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 /* 1 /*
2 * Copyright (C) 2008, 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2008, 2009 Google Inc. All rights reserved.
3 * Copyright (C) 2009 Apple Inc. All rights reserved. 3 * Copyright (C) 2009 Apple Inc. All rights reserved.
4 * Copyright (C) 2014 Opera Software ASA. All rights reserved. 4 * Copyright (C) 2014 Opera Software ASA. All rights reserved.
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions are 7 * modification, are permitted provided that the following conditions are
8 * met: 8 * met:
9 * 9 *
10 * * Redistributions of source code must retain the above copyright 10 * * Redistributions of source code must retain the above copyright
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 } 263 }
264 264
265 void ScriptController::clearWindowProxy() 265 void ScriptController::clearWindowProxy()
266 { 266 {
267 // V8 binding expects ScriptController::clearWindowProxy only be called 267 // V8 binding expects ScriptController::clearWindowProxy only be called
268 // when a frame is loading a new page. This creates a new context for the ne w page. 268 // when a frame is loading a new page. This creates a new context for the ne w page.
269 m_windowProxyManager->clearForNavigation(); 269 m_windowProxyManager->clearForNavigation();
270 MainThreadDebugger::instance()->didClearContextsForFrame(frame()); 270 MainThreadDebugger::instance()->didClearContextsForFrame(frame());
271 } 271 }
272 272
273 void ScriptController::setCaptureCallStackForUncaughtExceptions(v8::Isolate* iso late, bool value)
274 {
275 isolate->SetCaptureStackTraceForUncaughtExceptions(value, V8StackTrace::maxC allStackSizeToCapture, stackTraceOptions);
276 }
277
278 void ScriptController::collectIsolatedContexts(Vector<std::pair<ScriptState*, Se curityOrigin*>>& result) 273 void ScriptController::collectIsolatedContexts(Vector<std::pair<ScriptState*, Se curityOrigin*>>& result)
279 { 274 {
280 m_windowProxyManager->collectIsolatedContexts(result); 275 m_windowProxyManager->collectIsolatedContexts(result);
281 } 276 }
282 277
283 void ScriptController::updateDocument() 278 void ScriptController::updateDocument()
284 { 279 {
285 // For an uninitialized main window windowProxy, do not incur the cost of co ntext initialization. 280 // For an uninitialized main window windowProxy, do not incur the cost of co ntext initialization.
286 if (!m_windowProxyManager->mainWorldProxy()->isGlobalInitialized()) 281 if (!m_windowProxyManager->mainWorldProxy()->isGlobalInitialized())
287 return; 282 return;
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
445 for (size_t i = 0; i < resultArray->Length(); ++i) { 440 for (size_t i = 0; i < resultArray->Length(); ++i) {
446 v8::Local<v8::Value> value; 441 v8::Local<v8::Value> value;
447 if (!resultArray->Get(scriptState->context(), i).ToLocal(&value)) 442 if (!resultArray->Get(scriptState->context(), i).ToLocal(&value))
448 return; 443 return;
449 results->append(value); 444 results->append(value);
450 } 445 }
451 } 446 }
452 } 447 }
453 448
454 } // namespace blink 449 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698