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

Unified Diff: Source/core/inspector/InspectorDebuggerAgent.h

Issue 14294004: Implementing console command 'debug'. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: Source/core/inspector/InspectorDebuggerAgent.h
diff --git a/Source/core/inspector/InspectorDebuggerAgent.h b/Source/core/inspector/InspectorDebuggerAgent.h
index cc5b6767a0fcab7274c547f5ea7498c2ee34a41e..d16333fd9075ea4965d40d476d370708e1020df9 100644
--- a/Source/core/inspector/InspectorDebuggerAgent.h
+++ b/Source/core/inspector/InspectorDebuggerAgent.h
@@ -64,6 +64,11 @@ typedef String ErrorString;
class InspectorDebuggerAgent : public InspectorBaseAgent<InspectorDebuggerAgent>, public ScriptDebugListener, public InspectorBackendDispatcher::DebuggerCommandHandler {
WTF_MAKE_NONCOPYABLE(InspectorDebuggerAgent); WTF_MAKE_FAST_ALLOCATED;
public:
+ enum BreakpointSource {
+ UserBreakpointSource,
+ DebugCommandBreakpointSource
+ };
+
static const char* backtraceObjectGroup;
virtual ~InspectorDebuggerAgent();
@@ -135,6 +140,9 @@ public:
virtual void reportMemoryUsage(MemoryObjectInfo*) const;
+ void setBreakpoint(const String& scriptId, int lineNumber, int columnNumber, BreakpointSource);
+ void removeBreakpoint(const String& scriptId, int lineNumber, int columnNumber, BreakpointSource);
+
protected:
InspectorDebuggerAgent(InstrumentingAgents*, InspectorCompositeState*, InjectedScriptManager*);
@@ -165,7 +173,8 @@ private:
void setPauseOnExceptionsImpl(ErrorString*, int);
- PassRefPtr<TypeBuilder::Debugger::Location> resolveBreakpoint(const String& breakpointId, const String& scriptId, const ScriptBreakpoint&);
+ PassRefPtr<TypeBuilder::Debugger::Location> resolveBreakpoint(const String& breakpointId, const String& scriptId, const ScriptBreakpoint&, BreakpointSource);
+ void removeBreakpoint(const String& breakpointId);
void clear();
bool assertPaused(ErrorString*);
void clearBreakDetails();
@@ -174,7 +183,7 @@ private:
typedef HashMap<String, Script> ScriptsMap;
typedef HashMap<String, Vector<String> > BreakpointIdToDebugServerBreakpointIdsMap;
- typedef HashMap<String, String> DebugServerBreakpointIdToBreakpointIdMap;
+ typedef HashMap<String, std::pair<String, BreakpointSource> > DebugServerBreakpointToBreakpointIdAndSourceMap;
InjectedScriptManager* m_injectedScriptManager;
InspectorFrontend::Debugger* m_frontend;
@@ -182,7 +191,7 @@ private:
ScriptValue m_currentCallStack;
ScriptsMap m_scripts;
BreakpointIdToDebugServerBreakpointIdsMap m_breakpointIdToDebugServerBreakpointIds;
- DebugServerBreakpointIdToBreakpointIdMap m_serverBreakpointIdToBreakpointId;
+ DebugServerBreakpointToBreakpointIdAndSourceMap m_serverBreakpoints;
String m_continueToLocationBreakpointId;
InspectorFrontend::Debugger::Reason::Enum m_breakReason;
RefPtr<InspectorObject> m_breakAuxData;

Powered by Google App Engine
This is Rietveld 408576698