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

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

Issue 1225763002: Remove debugger id, use local frame id instead. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 #include "core/inspector/InstrumentingAgents.h" 45 #include "core/inspector/InstrumentingAgents.h"
46 #include "core/loader/DocumentLoader.h" 46 #include "core/loader/DocumentLoader.h"
47 #include "core/page/Page.h" 47 #include "core/page/Page.h"
48 48
49 using blink::TypeBuilder::Debugger::ExceptionDetails; 49 using blink::TypeBuilder::Debugger::ExceptionDetails;
50 using blink::TypeBuilder::Debugger::ScriptId; 50 using blink::TypeBuilder::Debugger::ScriptId;
51 using blink::TypeBuilder::Runtime::RemoteObject; 51 using blink::TypeBuilder::Runtime::RemoteObject;
52 52
53 namespace blink { 53 namespace blink {
54 54
55 PassOwnPtrWillBeRawPtr<PageDebuggerAgent> PageDebuggerAgent::create(MainThreadDe bugger* MainThreadDebugger, InspectorPageAgent* pageAgent, InjectedScriptManager * injectedScriptManager, InspectorOverlay* overlay, int debuggerId) 55 PassOwnPtrWillBeRawPtr<PageDebuggerAgent> PageDebuggerAgent::create(MainThreadDe bugger* MainThreadDebugger, InspectorPageAgent* pageAgent, InjectedScriptManager * injectedScriptManager, InspectorOverlay* overlay)
56 { 56 {
57 return adoptPtrWillBeNoop(new PageDebuggerAgent(MainThreadDebugger, pageAgen t, injectedScriptManager, overlay, debuggerId)); 57 return adoptPtrWillBeNoop(new PageDebuggerAgent(MainThreadDebugger, pageAgen t, injectedScriptManager, overlay));
58 } 58 }
59 59
60 PageDebuggerAgent::PageDebuggerAgent(MainThreadDebugger* MainThreadDebugger, Ins pectorPageAgent* pageAgent, InjectedScriptManager* injectedScriptManager, Inspec torOverlay* overlay, int debuggerId) 60 PageDebuggerAgent::PageDebuggerAgent(MainThreadDebugger* MainThreadDebugger, Ins pectorPageAgent* pageAgent, InjectedScriptManager* injectedScriptManager, Inspec torOverlay* overlay)
61 : InspectorDebuggerAgent(injectedScriptManager, MainThreadDebugger->debugger ()->isolate()) 61 : InspectorDebuggerAgent(injectedScriptManager, MainThreadDebugger->debugger ()->isolate())
62 , m_mainThreadDebugger(MainThreadDebugger) 62 , m_mainThreadDebugger(MainThreadDebugger)
63 , m_pageAgent(pageAgent) 63 , m_pageAgent(pageAgent)
64 , m_overlay(overlay) 64 , m_overlay(overlay)
65 , m_debuggerId(debuggerId)
66 { 65 {
67 m_overlay->setListener(this); 66 m_overlay->setListener(this);
68 } 67 }
69 68
70 PageDebuggerAgent::~PageDebuggerAgent() 69 PageDebuggerAgent::~PageDebuggerAgent()
71 { 70 {
72 } 71 }
73 72
74 DEFINE_TRACE(PageDebuggerAgent) 73 DEFINE_TRACE(PageDebuggerAgent)
75 { 74 {
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 108
110 void PageDebuggerAgent::disable() 109 void PageDebuggerAgent::disable()
111 { 110 {
112 InspectorDebuggerAgent::disable(); 111 InspectorDebuggerAgent::disable();
113 m_instrumentingAgents->setPageDebuggerAgent(0); 112 m_instrumentingAgents->setPageDebuggerAgent(0);
114 m_compiledScriptURLs.clear(); 113 m_compiledScriptURLs.clear();
115 } 114 }
116 115
117 void PageDebuggerAgent::startListeningV8Debugger() 116 void PageDebuggerAgent::startListeningV8Debugger()
118 { 117 {
119 m_mainThreadDebugger->addListener(this, m_pageAgent->inspectedFrame(), m_deb uggerId); 118 m_mainThreadDebugger->addListener(this, m_pageAgent->inspectedFrame());
120 } 119 }
121 120
122 void PageDebuggerAgent::stopListeningV8Debugger() 121 void PageDebuggerAgent::stopListeningV8Debugger()
123 { 122 {
124 m_mainThreadDebugger->removeListener(this, m_pageAgent->inspectedFrame()); 123 m_mainThreadDebugger->removeListener(this, m_pageAgent->inspectedFrame());
125 } 124 }
126 125
127 V8Debugger& PageDebuggerAgent::debugger() 126 V8Debugger& PageDebuggerAgent::debugger()
128 { 127 {
129 return *(m_mainThreadDebugger->debugger()); 128 return *(m_mainThreadDebugger->debugger());
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
224 RefPtrWillBeRawPtr<LocalFrame> protect(frame); 223 RefPtrWillBeRawPtr<LocalFrame> protect(frame);
225 InspectorDebuggerAgent::runScript(errorString, scriptId, executionContextId, objectGroup, doNotPauseOnExceptionsAndMuteConsole, result, exceptionDetails); 224 InspectorDebuggerAgent::runScript(errorString, scriptId, executionContextId, objectGroup, doNotPauseOnExceptionsAndMuteConsole, result, exceptionDetails);
226 225
227 if (frame) 226 if (frame)
228 InspectorInstrumentation::didEvaluateScript(cookie); 227 InspectorInstrumentation::didEvaluateScript(cookie);
229 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "Update Counters", TRACE_EVENT_SCOPE_THREAD, "data", InspectorUpdateCountersEvent::data( )); 228 TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "Update Counters", TRACE_EVENT_SCOPE_THREAD, "data", InspectorUpdateCountersEvent::data( ));
230 229
231 } 230 }
232 231
233 } // namespace blink 232 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698