| OLD | NEW |
| 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 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 return ":monitor"; | 74 return ":monitor"; |
| 75 } | 75 } |
| 76 return String(); | 76 return String(); |
| 77 } | 77 } |
| 78 | 78 |
| 79 static String generateBreakpointId(const String& scriptId, int lineNumber, int c
olumnNumber, InspectorDebuggerAgent::BreakpointSource source) | 79 static String generateBreakpointId(const String& scriptId, int lineNumber, int c
olumnNumber, InspectorDebuggerAgent::BreakpointSource source) |
| 80 { | 80 { |
| 81 return scriptId + ':' + String::number(lineNumber) + ':' + String::number(co
lumnNumber) + breakpointIdSuffix(source); | 81 return scriptId + ':' + String::number(lineNumber) + ':' + String::number(co
lumnNumber) + breakpointIdSuffix(source); |
| 82 } | 82 } |
| 83 | 83 |
| 84 InspectorDebuggerAgent::InspectorDebuggerAgent(InstrumentingAgents* instrumentin
gAgents, InspectorCompositeState* inspectorState, InjectedScriptManager* injecte
dScriptManager) | 84 InspectorDebuggerAgent::InspectorDebuggerAgent(InstrumentingAgents* instrumentin
gAgents, InspectorState* inspectorState, InjectedScriptManager* injectedScriptMa
nager) |
| 85 : InspectorBaseAgent<InspectorDebuggerAgent>("Debugger", instrumentingAgents
, inspectorState) | 85 : InspectorBaseAgent(instrumentingAgents, inspectorState) |
| 86 , m_injectedScriptManager(injectedScriptManager) | 86 , m_injectedScriptManager(injectedScriptManager) |
| 87 , m_frontend(0) | 87 , m_frontend(0) |
| 88 , m_pausedScriptState(0) | 88 , m_pausedScriptState(0) |
| 89 , m_javaScriptPauseScheduled(false) | 89 , m_javaScriptPauseScheduled(false) |
| 90 , m_listener(0) | 90 , m_listener(0) |
| 91 { | 91 { |
| 92 // FIXME: make breakReason optional so that there was no need to init it wit
h "other". | 92 // FIXME: make breakReason optional so that there was no need to init it wit
h "other". |
| 93 clearBreakDetails(); | 93 clearBreakDetails(); |
| 94 m_state->setLong(DebuggerAgentState::pauseOnExceptionsState, ScriptDebugServ
er::DontPauseOnExceptions); | 94 m_state->setLong(DebuggerAgentState::pauseOnExceptionsState, ScriptDebugServ
er::DontPauseOnExceptions); |
| 95 } | 95 } |
| (...skipping 717 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 813 | 813 |
| 814 void InspectorDebuggerAgent::clearBreakDetails() | 814 void InspectorDebuggerAgent::clearBreakDetails() |
| 815 { | 815 { |
| 816 m_breakReason = InspectorFrontend::Debugger::Reason::Other; | 816 m_breakReason = InspectorFrontend::Debugger::Reason::Other; |
| 817 m_breakAuxData = 0; | 817 m_breakAuxData = 0; |
| 818 } | 818 } |
| 819 | 819 |
| 820 void InspectorDebuggerAgent::reportMemoryUsage(MemoryObjectInfo* memoryObjectInf
o) const | 820 void InspectorDebuggerAgent::reportMemoryUsage(MemoryObjectInfo* memoryObjectInf
o) const |
| 821 { | 821 { |
| 822 MemoryClassInfo info(memoryObjectInfo, this, WebCoreMemoryTypes::InspectorDe
buggerAgent); | 822 MemoryClassInfo info(memoryObjectInfo, this, WebCoreMemoryTypes::InspectorDe
buggerAgent); |
| 823 InspectorBaseAgent<InspectorDebuggerAgent>::reportMemoryUsage(memoryObjectIn
fo); | 823 InspectorBaseAgent::reportMemoryUsage(memoryObjectInfo); |
| 824 info.addMember(m_injectedScriptManager, "injectedScriptManager"); | 824 info.addMember(m_injectedScriptManager, "injectedScriptManager"); |
| 825 info.addWeakPointer(m_frontend); | 825 info.addWeakPointer(m_frontend); |
| 826 info.addMember(m_pausedScriptState, "pausedScriptState"); | 826 info.addMember(m_pausedScriptState, "pausedScriptState"); |
| 827 info.addMember(m_currentCallStack, "currentCallStack"); | 827 info.addMember(m_currentCallStack, "currentCallStack"); |
| 828 info.addMember(m_scripts, "scripts"); | 828 info.addMember(m_scripts, "scripts"); |
| 829 info.addMember(m_breakpointIdToDebugServerBreakpointIds, "breakpointIdToDebu
gServerBreakpointIds"); | 829 info.addMember(m_breakpointIdToDebugServerBreakpointIds, "breakpointIdToDebu
gServerBreakpointIds"); |
| 830 info.addMember(m_continueToLocationBreakpointId, "continueToLocationBreakpoi
ntId"); | 830 info.addMember(m_continueToLocationBreakpointId, "continueToLocationBreakpoi
ntId"); |
| 831 info.addMember(m_breakAuxData, "breakAuxData"); | 831 info.addMember(m_breakAuxData, "breakAuxData"); |
| 832 info.addWeakPointer(m_listener); | 832 info.addWeakPointer(m_listener); |
| 833 } | 833 } |
| (...skipping 21 matching lines...) Expand all Loading... |
| 855 void InspectorDebuggerAgent::reset() | 855 void InspectorDebuggerAgent::reset() |
| 856 { | 856 { |
| 857 m_scripts.clear(); | 857 m_scripts.clear(); |
| 858 m_breakpointIdToDebugServerBreakpointIds.clear(); | 858 m_breakpointIdToDebugServerBreakpointIds.clear(); |
| 859 if (m_frontend) | 859 if (m_frontend) |
| 860 m_frontend->globalObjectCleared(); | 860 m_frontend->globalObjectCleared(); |
| 861 } | 861 } |
| 862 | 862 |
| 863 } // namespace WebCore | 863 } // namespace WebCore |
| 864 | 864 |
| OLD | NEW |