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

Side by Side Diff: third_party/WebKit/Source/web/WebDevToolsAgentImpl.cpp

Issue 1888673002: [DevTools] Move style sheet content storage from css agent to resource loader. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nits Created 4 years, 8 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
« no previous file with comments | « third_party/WebKit/Source/web/WebDevToolsAgentImpl.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010-2011 Google Inc. All rights reserved. 2 * Copyright (C) 2010-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 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 #include "core/inspector/InspectorDOMDebuggerAgent.h" 43 #include "core/inspector/InspectorDOMDebuggerAgent.h"
44 #include "core/inspector/InspectorDebuggerAgent.h" 44 #include "core/inspector/InspectorDebuggerAgent.h"
45 #include "core/inspector/InspectorHeapProfilerAgent.h" 45 #include "core/inspector/InspectorHeapProfilerAgent.h"
46 #include "core/inspector/InspectorInputAgent.h" 46 #include "core/inspector/InspectorInputAgent.h"
47 #include "core/inspector/InspectorInstrumentation.h" 47 #include "core/inspector/InspectorInstrumentation.h"
48 #include "core/inspector/InspectorLayerTreeAgent.h" 48 #include "core/inspector/InspectorLayerTreeAgent.h"
49 #include "core/inspector/InspectorMemoryAgent.h" 49 #include "core/inspector/InspectorMemoryAgent.h"
50 #include "core/inspector/InspectorPageAgent.h" 50 #include "core/inspector/InspectorPageAgent.h"
51 #include "core/inspector/InspectorProfilerAgent.h" 51 #include "core/inspector/InspectorProfilerAgent.h"
52 #include "core/inspector/InspectorResourceAgent.h" 52 #include "core/inspector/InspectorResourceAgent.h"
53 #include "core/inspector/InspectorResourceContainer.h"
53 #include "core/inspector/InspectorResourceContentLoader.h" 54 #include "core/inspector/InspectorResourceContentLoader.h"
54 #include "core/inspector/InspectorTaskRunner.h" 55 #include "core/inspector/InspectorTaskRunner.h"
55 #include "core/inspector/InspectorTracingAgent.h" 56 #include "core/inspector/InspectorTracingAgent.h"
56 #include "core/inspector/InspectorWorkerAgent.h" 57 #include "core/inspector/InspectorWorkerAgent.h"
57 #include "core/inspector/InstrumentingAgents.h" 58 #include "core/inspector/InstrumentingAgents.h"
58 #include "core/inspector/LayoutEditor.h" 59 #include "core/inspector/LayoutEditor.h"
59 #include "core/inspector/MainThreadDebugger.h" 60 #include "core/inspector/MainThreadDebugger.h"
60 #include "core/inspector/PageConsoleAgent.h" 61 #include "core/inspector/PageConsoleAgent.h"
61 #include "core/inspector/PageDebuggerAgent.h" 62 #include "core/inspector/PageDebuggerAgent.h"
62 #include "core/inspector/PageRuntimeAgent.h" 63 #include "core/inspector/PageRuntimeAgent.h"
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
302 : m_client(client) 303 : m_client(client)
303 , m_webLocalFrameImpl(webLocalFrameImpl) 304 , m_webLocalFrameImpl(webLocalFrameImpl)
304 , m_attached(false) 305 , m_attached(false)
305 #if DCHECK_IS_ON() 306 #if DCHECK_IS_ON()
306 , m_hasBeenDisposed(false) 307 , m_hasBeenDisposed(false)
307 #endif 308 #endif
308 , m_instrumentingAgents(m_webLocalFrameImpl->frame()->instrumentingAgents()) 309 , m_instrumentingAgents(m_webLocalFrameImpl->frame()->instrumentingAgents())
309 , m_resourceContentLoader(InspectorResourceContentLoader::create(m_webLocalF rameImpl->frame())) 310 , m_resourceContentLoader(InspectorResourceContentLoader::create(m_webLocalF rameImpl->frame()))
310 , m_overlay(overlay) 311 , m_overlay(overlay)
311 , m_inspectedFrames(InspectedFrames::create(m_webLocalFrameImpl->frame())) 312 , m_inspectedFrames(InspectedFrames::create(m_webLocalFrameImpl->frame()))
313 , m_resourceContainer(new InspectorResourceContainer(m_inspectedFrames))
312 , m_domAgent(nullptr) 314 , m_domAgent(nullptr)
313 , m_pageAgent(nullptr) 315 , m_pageAgent(nullptr)
314 , m_resourceAgent(nullptr) 316 , m_resourceAgent(nullptr)
315 , m_layerTreeAgent(nullptr) 317 , m_layerTreeAgent(nullptr)
316 , m_tracingAgent(nullptr) 318 , m_tracingAgent(nullptr)
317 , m_agents(m_instrumentingAgents.get()) 319 , m_agents(m_instrumentingAgents.get())
318 , m_deferredAgentsInitialized(false) 320 , m_deferredAgentsInitialized(false)
319 , m_sessionId(0) 321 , m_sessionId(0)
320 , m_stateMuted(false) 322 , m_stateMuted(false)
321 , m_layerTreeId(0) 323 , m_layerTreeId(0)
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
355 ClientMessageLoopAdapter::webFrameWidgetImplClosed(webFrameWidgetImpl); 357 ClientMessageLoopAdapter::webFrameWidgetImplClosed(webFrameWidgetImpl);
356 } 358 }
357 359
358 DEFINE_TRACE(WebDevToolsAgentImpl) 360 DEFINE_TRACE(WebDevToolsAgentImpl)
359 { 361 {
360 visitor->trace(m_webLocalFrameImpl); 362 visitor->trace(m_webLocalFrameImpl);
361 visitor->trace(m_instrumentingAgents); 363 visitor->trace(m_instrumentingAgents);
362 visitor->trace(m_resourceContentLoader); 364 visitor->trace(m_resourceContentLoader);
363 visitor->trace(m_overlay); 365 visitor->trace(m_overlay);
364 visitor->trace(m_inspectedFrames); 366 visitor->trace(m_inspectedFrames);
367 visitor->trace(m_resourceContainer);
365 visitor->trace(m_domAgent); 368 visitor->trace(m_domAgent);
366 visitor->trace(m_pageAgent); 369 visitor->trace(m_pageAgent);
367 visitor->trace(m_resourceAgent); 370 visitor->trace(m_resourceAgent);
368 visitor->trace(m_layerTreeAgent); 371 visitor->trace(m_layerTreeAgent);
369 visitor->trace(m_tracingAgent); 372 visitor->trace(m_tracingAgent);
370 visitor->trace(m_agents); 373 visitor->trace(m_agents);
371 } 374 }
372 375
373 void WebDevToolsAgentImpl::willBeDestroyed() 376 void WebDevToolsAgentImpl::willBeDestroyed()
374 { 377 {
(...skipping 27 matching lines...) Expand all
402 m_agents.append(domAgent); 405 m_agents.append(domAgent);
403 406
404 InspectorLayerTreeAgent* layerTreeAgent = InspectorLayerTreeAgent::create(m_ inspectedFrames.get()); 407 InspectorLayerTreeAgent* layerTreeAgent = InspectorLayerTreeAgent::create(m_ inspectedFrames.get());
405 m_layerTreeAgent = layerTreeAgent; 408 m_layerTreeAgent = layerTreeAgent;
406 m_agents.append(layerTreeAgent); 409 m_agents.append(layerTreeAgent);
407 410
408 InspectorResourceAgent* resourceAgent = InspectorResourceAgent::create(m_ins pectedFrames.get()); 411 InspectorResourceAgent* resourceAgent = InspectorResourceAgent::create(m_ins pectedFrames.get());
409 m_resourceAgent = resourceAgent; 412 m_resourceAgent = resourceAgent;
410 m_agents.append(resourceAgent); 413 m_agents.append(resourceAgent);
411 414
412 InspectorCSSAgent* cssAgent = InspectorCSSAgent::create(m_domAgent, m_inspec tedFrames.get(), m_resourceAgent, m_resourceContentLoader.get()); 415 InspectorCSSAgent* cssAgent = InspectorCSSAgent::create(m_domAgent, m_inspec tedFrames.get(), m_resourceAgent, m_resourceContentLoader.get(), m_resourceConta iner.get());
413 m_agents.append(cssAgent); 416 m_agents.append(cssAgent);
414 417
415 m_agents.append(InspectorAnimationAgent::create(m_inspectedFrames.get(), m_d omAgent, cssAgent, runtimeAgent)); 418 m_agents.append(InspectorAnimationAgent::create(m_inspectedFrames.get(), m_d omAgent, cssAgent, runtimeAgent));
416 419
417 m_agents.append(InspectorMemoryAgent::create()); 420 m_agents.append(InspectorMemoryAgent::create());
418 421
419 m_agents.append(InspectorApplicationCacheAgent::create(m_inspectedFrames.get ())); 422 m_agents.append(InspectorApplicationCacheAgent::create(m_inspectedFrames.get ()));
420 423
421 m_agents.append(InspectorIndexedDBAgent::create(m_inspectedFrames.get())); 424 m_agents.append(InspectorIndexedDBAgent::create(m_inspectedFrames.get()));
422 425
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
512 m_attached = false; 515 m_attached = false;
513 } 516 }
514 517
515 void WebDevToolsAgentImpl::continueProgram() 518 void WebDevToolsAgentImpl::continueProgram()
516 { 519 {
517 ClientMessageLoopAdapter::continueProgram(); 520 ClientMessageLoopAdapter::continueProgram();
518 } 521 }
519 522
520 void WebDevToolsAgentImpl::didCommitLoadForLocalFrame(LocalFrame* frame) 523 void WebDevToolsAgentImpl::didCommitLoadForLocalFrame(LocalFrame* frame)
521 { 524 {
525 m_resourceContainer->didCommitLoadForLocalFrame(frame);
522 m_resourceContentLoader->didCommitLoadForLocalFrame(frame); 526 m_resourceContentLoader->didCommitLoadForLocalFrame(frame);
523 m_agents.didCommitLoadForLocalFrame(frame); 527 m_agents.didCommitLoadForLocalFrame(frame);
524 } 528 }
525 529
526 bool WebDevToolsAgentImpl::screencastEnabled() 530 bool WebDevToolsAgentImpl::screencastEnabled()
527 { 531 {
528 return m_pageAgent && m_pageAgent->screencastEnabled(); 532 return m_pageAgent && m_pageAgent->screencastEnabled();
529 } 533 }
530 534
531 void WebDevToolsAgentImpl::willAddPageOverlay(const GraphicsLayer* layer) 535 void WebDevToolsAgentImpl::willAddPageOverlay(const GraphicsLayer* layer)
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
719 if (!protocol::Dispatcher::getCommandName(message, &commandName)) 723 if (!protocol::Dispatcher::getCommandName(message, &commandName))
720 return false; 724 return false;
721 return commandName == "Debugger.pause" 725 return commandName == "Debugger.pause"
722 || commandName == "Debugger.setBreakpoint" 726 || commandName == "Debugger.setBreakpoint"
723 || commandName == "Debugger.setBreakpointByUrl" 727 || commandName == "Debugger.setBreakpointByUrl"
724 || commandName == "Debugger.removeBreakpoint" 728 || commandName == "Debugger.removeBreakpoint"
725 || commandName == "Debugger.setBreakpointsActive"; 729 || commandName == "Debugger.setBreakpointsActive";
726 } 730 }
727 731
728 } // namespace blink 732 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/WebDevToolsAgentImpl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698