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

Unified Diff: trunk/Source/web/WebDevToolsAgentImpl.cpp

Issue 196743008: Revert 169371 "DevTools: defer styles delta calculation to until..." (Closed) Base URL: svn://svn.chromium.org/blink/
Patch Set: Created 6 years, 9 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
« no previous file with comments | « trunk/Source/web/WebDevToolsAgentImpl.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/Source/web/WebDevToolsAgentImpl.cpp
===================================================================
--- trunk/Source/web/WebDevToolsAgentImpl.cpp (revision 169387)
+++ trunk/Source/web/WebDevToolsAgentImpl.cpp (working copy)
@@ -117,11 +117,6 @@
return;
m_running = true;
- // 0. Flush pending frontend messages.
- WebViewImpl* viewImpl = WebViewImpl::fromPage(page);
- WebDevToolsAgentImpl* agent = static_cast<WebDevToolsAgentImpl*>(viewImpl->devToolsAgent());
- agent->flushPendingFrontendMessages();
-
Vector<WebViewImpl*> views;
// 1. Disable input events.
@@ -572,7 +567,9 @@
void WebDevToolsAgentImpl::flush()
{
- flushPendingFrontendMessages();
+ for (size_t i = 0; i < m_frontendMessageQueue.size(); ++i)
+ m_client->sendMessageToInspectorFrontend(m_frontendMessageQueue[i]->toJSONString());
+ m_frontendMessageQueue.clear();
}
void WebDevToolsAgentImpl::updateInspectorStateCookie(const String& state)
@@ -606,31 +603,18 @@
ic->evaluateForTestInFrontend(callId, script);
}
-void WebDevToolsAgentImpl::flushPendingFrontendMessages()
-{
- InspectorController* ic = inspectorController();
- ic->flushPendingFrontendMessages();
-
- for (size_t i = 0; i < m_frontendMessageQueue.size(); ++i)
- m_client->sendMessageToInspectorFrontend(m_frontendMessageQueue[i]->toJSONString());
- m_frontendMessageQueue.clear();
-}
-
void WebDevToolsAgentImpl::willProcessTask()
{
- if (!m_attached)
- return;
if (InspectorController* ic = inspectorController())
ic->willProcessTask();
}
void WebDevToolsAgentImpl::didProcessTask()
{
- if (!m_attached)
- return;
if (InspectorController* ic = inspectorController())
ic->didProcessTask();
- flushPendingFrontendMessages();
+ if (m_attached)
+ flush();
}
WebString WebDevToolsAgent::inspectorProtocolVersion()
« no previous file with comments | « trunk/Source/web/WebDevToolsAgentImpl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698