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

Side by Side Diff: chrome/browser/automation/automation_provider.cc

Issue 9443020: Use SequencedWorkerPool for disk operations in TraceSubscriberStdio. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 years, 10 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 | « chrome/browser/automation/automation_provider.h ('k') | chrome/browser/ui/webui/tracing_ui.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/automation/automation_provider.h" 5 #include "chrome/browser/automation/automation_provider.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 388 matching lines...) Expand 10 before | Expand all | Expand 10 after
399 void AutomationProvider::OnEndTracingComplete() { 399 void AutomationProvider::OnEndTracingComplete() {
400 IPC::Message* reply_message = tracing_data_.reply_message.release(); 400 IPC::Message* reply_message = tracing_data_.reply_message.release();
401 if (reply_message) { 401 if (reply_message) {
402 AutomationMsg_EndTracing::WriteReplyParams( 402 AutomationMsg_EndTracing::WriteReplyParams(
403 reply_message, tracing_data_.trace_output.size(), true); 403 reply_message, tracing_data_.trace_output.size(), true);
404 Send(reply_message); 404 Send(reply_message);
405 } 405 }
406 } 406 }
407 407
408 void AutomationProvider::OnTraceDataCollected( 408 void AutomationProvider::OnTraceDataCollected(
409 const std::string& trace_fragment) { 409 const scoped_refptr<base::RefCountedString>& trace_fragment) {
410 tracing_data_.trace_output.push_back(trace_fragment); 410 tracing_data_.trace_output.push_back(trace_fragment->data());
411 } 411 }
412 412
413 bool AutomationProvider::OnMessageReceived(const IPC::Message& message) { 413 bool AutomationProvider::OnMessageReceived(const IPC::Message& message) {
414 bool handled = true; 414 bool handled = true;
415 bool deserialize_success = true; 415 bool deserialize_success = true;
416 IPC_BEGIN_MESSAGE_MAP_EX(AutomationProvider, message, deserialize_success) 416 IPC_BEGIN_MESSAGE_MAP_EX(AutomationProvider, message, deserialize_success)
417 #if !defined(OS_MACOSX) 417 #if !defined(OS_MACOSX)
418 IPC_MESSAGE_HANDLER_DELAY_REPLY(AutomationMsg_WindowDrag, 418 IPC_MESSAGE_HANDLER_DELAY_REPLY(AutomationMsg_WindowDrag,
419 WindowSimulateDrag) 419 WindowSimulateDrag)
420 #endif // !defined(OS_MACOSX) 420 #endif // !defined(OS_MACOSX)
(...skipping 590 matching lines...) Expand 10 before | Expand all | Expand 10 after
1011 } 1011 }
1012 } 1012 }
1013 } 1013 }
1014 1014
1015 void AutomationProvider::SaveAsAsync(int tab_handle) { 1015 void AutomationProvider::SaveAsAsync(int tab_handle) {
1016 NavigationController* tab = NULL; 1016 NavigationController* tab = NULL;
1017 WebContents* web_contents = GetWebContentsForHandle(tab_handle, &tab); 1017 WebContents* web_contents = GetWebContentsForHandle(tab_handle, &tab);
1018 if (web_contents) 1018 if (web_contents)
1019 web_contents->OnSavePage(); 1019 web_contents->OnSavePage();
1020 } 1020 }
OLDNEW
« no previous file with comments | « chrome/browser/automation/automation_provider.h ('k') | chrome/browser/ui/webui/tracing_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698