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

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

Issue 16934003: Inspector: replace generic discardAgents logic with explicit call to discard a listener. (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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2009 Apple Inc. All rights reserved.
3 * Copyright (C) 2011 Google Inc. All rights reserved. 3 * Copyright (C) 2011 Google Inc. All rights reserved.
4 * Copyright (C) 2009 Joseph Pecoraro 4 * Copyright (C) 2009 Joseph Pecoraro
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 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 , m_domListener(0) 231 , m_domListener(0)
232 , m_lastNodeId(1) 232 , m_lastNodeId(1)
233 , m_lastBackendNodeId(-1) 233 , m_lastBackendNodeId(-1)
234 , m_searchingForNode(false) 234 , m_searchingForNode(false)
235 , m_suppressAttributeModifiedEvent(false) 235 , m_suppressAttributeModifiedEvent(false)
236 { 236 {
237 } 237 }
238 238
239 InspectorDOMAgent::~InspectorDOMAgent() 239 InspectorDOMAgent::~InspectorDOMAgent()
240 { 240 {
241 if (m_domListener)
242 m_domListener->discardListener();
241 reset(); 243 reset();
242 ASSERT(!m_searchingForNode); 244 ASSERT(!m_searchingForNode);
243 } 245 }
244 246
245 void InspectorDOMAgent::setFrontend(InspectorFrontend* frontend) 247 void InspectorDOMAgent::setFrontend(InspectorFrontend* frontend)
246 { 248 {
247 ASSERT(!m_frontend); 249 ASSERT(!m_frontend);
248 m_history = adoptPtr(new InspectorHistory()); 250 m_history = adoptPtr(new InspectorHistory());
249 m_domEditor = adoptPtr(new DOMEditor(m_history.get())); 251 m_domEditor = adoptPtr(new DOMEditor(m_history.get()));
250 252
(...skipping 1575 matching lines...) Expand 10 before | Expand all | Expand 10 after
1826 1828
1827 InjectedScript injectedScript = m_injectedScriptManager->injectedScriptFor(m ainWorldScriptState(frame)); 1829 InjectedScript injectedScript = m_injectedScriptManager->injectedScriptFor(m ainWorldScriptState(frame));
1828 if (injectedScript.hasNoValue()) 1830 if (injectedScript.hasNoValue())
1829 return 0; 1831 return 0;
1830 1832
1831 return injectedScript.wrapNode(node, objectGroup); 1833 return injectedScript.wrapNode(node, objectGroup);
1832 } 1834 }
1833 1835
1834 } // namespace WebCore 1836 } // namespace WebCore
1835 1837
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698