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

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

Issue 307943002: Oilpan: Prepare moving InspectorController and InspectorAgents to oilpan. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 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) 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.
3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com>
4 * Copyright (C) 2010 Google Inc. All rights reserved. 4 * Copyright (C) 2010 Google Inc. All rights reserved.
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 9 *
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 25 matching lines...) Expand all
36 #include "core/inspector/InspectorDebuggerAgent.h" 36 #include "core/inspector/InspectorDebuggerAgent.h"
37 #include "core/inspector/InspectorInspectorAgent.h" 37 #include "core/inspector/InspectorInspectorAgent.h"
38 #include "core/inspector/InstrumentingAgents.h" 38 #include "core/inspector/InstrumentingAgents.h"
39 #include "platform/JSONValues.h" 39 #include "platform/JSONValues.h"
40 40
41 #include "wtf/RefPtr.h" 41 #include "wtf/RefPtr.h"
42 #include "wtf/text/StringBuilder.h" 42 #include "wtf/text/StringBuilder.h"
43 43
44 namespace blink { 44 namespace blink {
45 45
46 PassRefPtr<InjectedScriptHost> InjectedScriptHost::create() 46 PassRefPtrWillBeRawPtr<InjectedScriptHost> InjectedScriptHost::create()
47 { 47 {
48 return adoptRef(new InjectedScriptHost()); 48 return adoptRefWillBeNoop(new InjectedScriptHost());
49 } 49 }
50 50
51 InjectedScriptHost::InjectedScriptHost() 51 InjectedScriptHost::InjectedScriptHost()
52 : m_instrumentingAgents(0) 52 : m_instrumentingAgents(nullptr)
53 , m_scriptDebugServer(0) 53 , m_scriptDebugServer(0)
54 { 54 {
55 ScriptWrappable::init(this); 55 ScriptWrappable::init(this);
56 m_defaultInspectableObject = adoptPtr(new InspectableObject()); 56 m_defaultInspectableObject = adoptPtr(new InspectableObject());
57 } 57 }
58 58
59 InjectedScriptHost::~InjectedScriptHost() 59 InjectedScriptHost::~InjectedScriptHost()
60 { 60 {
61 } 61 }
62 62
63 void InjectedScriptHost::trace(Visitor* visitor)
64 {
65 visitor->trace(m_instrumentingAgents);
66 }
67
63 void InjectedScriptHost::disconnect() 68 void InjectedScriptHost::disconnect()
64 { 69 {
65 m_instrumentingAgents = 0; 70 m_instrumentingAgents = nullptr;
66 m_scriptDebugServer = 0; 71 m_scriptDebugServer = 0;
67 } 72 }
68 73
69 void InjectedScriptHost::inspectImpl(PassRefPtr<JSONValue> object, PassRefPtr<JS ONValue> hints) 74 void InjectedScriptHost::inspectImpl(PassRefPtr<JSONValue> object, PassRefPtr<JS ONValue> hints)
70 { 75 {
71 if (InspectorInspectorAgent* inspectorAgent = m_instrumentingAgents ? m_inst rumentingAgents->inspectorInspectorAgent() : 0) { 76 if (InspectorInspectorAgent* inspectorAgent = m_instrumentingAgents ? m_inst rumentingAgents->inspectorInspectorAgent() : 0) {
72 RefPtr<TypeBuilder::Runtime::RemoteObject> remoteObject = TypeBuilder::R untime::RemoteObject::runtimeCast(object); 77 RefPtr<TypeBuilder::Runtime::RemoteObject> remoteObject = TypeBuilder::R untime::RemoteObject::runtimeCast(object);
73 inspectorAgent->inspect(remoteObject, hints->asObject()); 78 inspectorAgent->inspect(remoteObject, hints->asObject());
74 } 79 }
75 } 80 }
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 } 142 }
138 143
139 void InjectedScriptHost::unmonitorFunction(const String& scriptId, int lineNumbe r, int columnNumber) 144 void InjectedScriptHost::unmonitorFunction(const String& scriptId, int lineNumbe r, int columnNumber)
140 { 145 {
141 if (InspectorDebuggerAgent* debuggerAgent = m_instrumentingAgents ? m_instru mentingAgents->inspectorDebuggerAgent() : 0) 146 if (InspectorDebuggerAgent* debuggerAgent = m_instrumentingAgents ? m_instru mentingAgents->inspectorDebuggerAgent() : 0)
142 debuggerAgent->removeBreakpoint(scriptId, lineNumber, columnNumber, Insp ectorDebuggerAgent::MonitorCommandBreakpointSource); 147 debuggerAgent->removeBreakpoint(scriptId, lineNumber, columnNumber, Insp ectorDebuggerAgent::MonitorCommandBreakpointSource);
143 } 148 }
144 149
145 } // namespace blink 150 } // namespace blink
146 151
OLDNEW
« no previous file with comments | « Source/core/inspector/InjectedScriptHost.h ('k') | Source/core/inspector/InjectedScriptHost.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698