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

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

Issue 12316038: Merge 143334 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1410/
Patch Set: Created 7 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
« no previous file with comments | « no previous file | 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) 2010-2011 Google Inc. All rights reserved. 3 * Copyright (C) 2010-2011 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 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 using WebCore::TypeBuilder::Runtime::RemoteObject; 53 using WebCore::TypeBuilder::Runtime::RemoteObject;
54 54
55 namespace WebCore { 55 namespace WebCore {
56 56
57 namespace DebuggerAgentState { 57 namespace DebuggerAgentState {
58 static const char debuggerEnabled[] = "debuggerEnabled"; 58 static const char debuggerEnabled[] = "debuggerEnabled";
59 static const char javaScriptBreakpoints[] = "javaScriptBreakopints"; 59 static const char javaScriptBreakpoints[] = "javaScriptBreakopints";
60 static const char pauseOnExceptionsState[] = "pauseOnExceptionsState"; 60 static const char pauseOnExceptionsState[] = "pauseOnExceptionsState";
61 }; 61 };
62 62
63 const char* InspectorDebuggerAgent::backtraceObjectGroup = "backtrace-object-gro up"; 63 const char* InspectorDebuggerAgent::backtraceObjectGroup = "backtrace";
64 64
65 InspectorDebuggerAgent::InspectorDebuggerAgent(InstrumentingAgents* instrumentin gAgents, InspectorCompositeState* inspectorState, InjectedScriptManager* injecte dScriptManager) 65 InspectorDebuggerAgent::InspectorDebuggerAgent(InstrumentingAgents* instrumentin gAgents, InspectorCompositeState* inspectorState, InjectedScriptManager* injecte dScriptManager)
66 : InspectorBaseAgent<InspectorDebuggerAgent>("Debugger", instrumentingAgents , inspectorState) 66 : InspectorBaseAgent<InspectorDebuggerAgent>("Debugger", instrumentingAgents , inspectorState)
67 , m_injectedScriptManager(injectedScriptManager) 67 , m_injectedScriptManager(injectedScriptManager)
68 , m_frontend(0) 68 , m_frontend(0)
69 , m_pausedScriptState(0) 69 , m_pausedScriptState(0)
70 , m_javaScriptPauseScheduled(false) 70 , m_javaScriptPauseScheduled(false)
71 , m_listener(0) 71 , m_listener(0)
72 { 72 {
73 // FIXME: make breakReason optional so that there was no need to init it wit h "other". 73 // FIXME: make breakReason optional so that there was no need to init it wit h "other".
(...skipping 374 matching lines...) Expand 10 before | Expand all | Expand 10 after
448 if (!assertPaused(errorString)) 448 if (!assertPaused(errorString))
449 return; 449 return;
450 m_injectedScriptManager->releaseObjectGroup(InspectorDebuggerAgent::backtrac eObjectGroup); 450 m_injectedScriptManager->releaseObjectGroup(InspectorDebuggerAgent::backtrac eObjectGroup);
451 scriptDebugServer().continueProgram(); 451 scriptDebugServer().continueProgram();
452 } 452 }
453 453
454 void InspectorDebuggerAgent::stepOver(ErrorString* errorString) 454 void InspectorDebuggerAgent::stepOver(ErrorString* errorString)
455 { 455 {
456 if (!assertPaused(errorString)) 456 if (!assertPaused(errorString))
457 return; 457 return;
458 m_injectedScriptManager->releaseObjectGroup(InspectorDebuggerAgent::backtrac eObjectGroup);
458 scriptDebugServer().stepOverStatement(); 459 scriptDebugServer().stepOverStatement();
459 } 460 }
460 461
461 void InspectorDebuggerAgent::stepInto(ErrorString* errorString) 462 void InspectorDebuggerAgent::stepInto(ErrorString* errorString)
462 { 463 {
463 if (!assertPaused(errorString)) 464 if (!assertPaused(errorString))
464 return; 465 return;
466 m_injectedScriptManager->releaseObjectGroup(InspectorDebuggerAgent::backtrac eObjectGroup);
465 scriptDebugServer().stepIntoStatement(); 467 scriptDebugServer().stepIntoStatement();
466 m_listener->stepInto(); 468 m_listener->stepInto();
467 } 469 }
468 470
469 void InspectorDebuggerAgent::stepOut(ErrorString* errorString) 471 void InspectorDebuggerAgent::stepOut(ErrorString* errorString)
470 { 472 {
471 if (!assertPaused(errorString)) 473 if (!assertPaused(errorString))
472 return; 474 return;
475 m_injectedScriptManager->releaseObjectGroup(InspectorDebuggerAgent::backtrac eObjectGroup);
473 scriptDebugServer().stepOutOfFunction(); 476 scriptDebugServer().stepOutOfFunction();
474 } 477 }
475 478
476 void InspectorDebuggerAgent::setPauseOnExceptions(ErrorString* errorString, cons t String& stringPauseState) 479 void InspectorDebuggerAgent::setPauseOnExceptions(ErrorString* errorString, cons t String& stringPauseState)
477 { 480 {
478 ScriptDebugServer::PauseOnExceptionsState pauseState; 481 ScriptDebugServer::PauseOnExceptionsState pauseState;
479 if (stringPauseState == "none") 482 if (stringPauseState == "none")
480 pauseState = ScriptDebugServer::DontPauseOnExceptions; 483 pauseState = ScriptDebugServer::DontPauseOnExceptions;
481 else if (stringPauseState == "all") 484 else if (stringPauseState == "all")
482 pauseState = ScriptDebugServer::PauseOnAllExceptions; 485 pauseState = ScriptDebugServer::PauseOnAllExceptions;
(...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after
787 { 790 {
788 m_scripts.clear(); 791 m_scripts.clear();
789 m_breakpointIdToDebugServerBreakpointIds.clear(); 792 m_breakpointIdToDebugServerBreakpointIds.clear();
790 if (m_frontend) 793 if (m_frontend)
791 m_frontend->globalObjectCleared(); 794 m_frontend->globalObjectCleared();
792 } 795 }
793 796
794 } // namespace WebCore 797 } // namespace WebCore
795 798
796 #endif // ENABLE(JAVASCRIPT_DEBUGGER) && ENABLE(INSPECTOR) 799 #endif // ENABLE(JAVASCRIPT_DEBUGGER) && ENABLE(INSPECTOR)
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698