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

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

Issue 568363003: Speculative Layout Test fix for inspector/sources/debugger/promise-tracker.html (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 3 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
« no previous file with comments | « LayoutTests/inspector/sources/debugger/promise-tracker.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2010 Apple Inc. All rights reserved.
3 * Copyright (C) 2013 Google Inc. All rights reserved. 3 * Copyright (C) 2013 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 1165 matching lines...) Expand 10 before | Expand all | Expand 10 after
1176 m_state->setBoolean(DebuggerAgentState::promiseTrackerEnabled, true); 1176 m_state->setBoolean(DebuggerAgentState::promiseTrackerEnabled, true);
1177 promiseTracker().setEnabled(true); 1177 promiseTracker().setEnabled(true);
1178 } 1178 }
1179 1179
1180 void InspectorDebuggerAgent::disablePromiseTracker(ErrorString*) 1180 void InspectorDebuggerAgent::disablePromiseTracker(ErrorString*)
1181 { 1181 {
1182 m_state->setBoolean(DebuggerAgentState::promiseTrackerEnabled, false); 1182 m_state->setBoolean(DebuggerAgentState::promiseTrackerEnabled, false);
1183 promiseTracker().setEnabled(false); 1183 promiseTracker().setEnabled(false);
1184 } 1184 }
1185 1185
1186 void InspectorDebuggerAgent::getPromises(ErrorString*, RefPtr<Array<PromiseDetai ls> >& promises) 1186 void InspectorDebuggerAgent::getPromises(ErrorString* errorString, RefPtr<Array< PromiseDetails> >& promises)
1187 { 1187 {
1188 if (!promiseTracker().isEnabled()) 1188 if (!promiseTracker().isEnabled()) {
1189 *errorString = "Promise tracking is disabled";
1189 return; 1190 return;
1191 }
1190 promises = promiseTracker().promises(); 1192 promises = promiseTracker().promises();
1191 } 1193 }
1192 1194
1193 void InspectorDebuggerAgent::scriptExecutionBlockedByCSP(const String& directive Text) 1195 void InspectorDebuggerAgent::scriptExecutionBlockedByCSP(const String& directive Text)
1194 { 1196 {
1195 if (scriptDebugServer().pauseOnExceptionsState() != ScriptDebugServer::DontP auseOnExceptions) { 1197 if (scriptDebugServer().pauseOnExceptionsState() != ScriptDebugServer::DontP auseOnExceptions) {
1196 RefPtr<JSONObject> directive = JSONObject::create(); 1198 RefPtr<JSONObject> directive = JSONObject::create();
1197 directive->setString("directiveText", directiveText); 1199 directive->setString("directiveText", directiveText);
1198 breakProgram(InspectorFrontend::Debugger::Reason::CSPViolation, directiv e.release()); 1200 breakProgram(InspectorFrontend::Debugger::Reason::CSPViolation, directiv e.release());
1199 } 1201 }
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after
1505 visitor->trace(m_injectedScriptManager); 1507 visitor->trace(m_injectedScriptManager);
1506 visitor->trace(m_listener); 1508 visitor->trace(m_listener);
1507 visitor->trace(m_asyncCallStackTracker); 1509 visitor->trace(m_asyncCallStackTracker);
1508 #if ENABLE(OILPAN) 1510 #if ENABLE(OILPAN)
1509 visitor->trace(m_promiseTracker); 1511 visitor->trace(m_promiseTracker);
1510 #endif 1512 #endif
1511 InspectorBaseAgent::trace(visitor); 1513 InspectorBaseAgent::trace(visitor);
1512 } 1514 }
1513 1515
1514 } // namespace blink 1516 } // namespace blink
OLDNEW
« no previous file with comments | « LayoutTests/inspector/sources/debugger/promise-tracker.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698