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

Unified Diff: content/child/child_thread_impl.h

Issue 977573002: content: Add an overridable task runner to ChildThreadImpl (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | content/child/child_thread_impl.cc » ('j') | content/public/child/child_thread.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/child/child_thread_impl.h
diff --git a/content/child/child_thread_impl.h b/content/child/child_thread_impl.h
index 529fb0823b3884958bab9d91e71f970985658fc9..e5d4c790130e5e20768e3ae7202fd6e03ecc1966 100644
--- a/content/child/child_thread_impl.h
+++ b/content/child/child_thread_impl.h
@@ -80,6 +80,7 @@ class CONTENT_EXPORT ChildThreadImpl
bool Send(IPC::Message* msg) override;
// ChildThread implementation:
+ scoped_refptr<base::SingleThreadTaskRunner> GetTaskRunner() override;
no sievers 2015/03/04 19:15:02 Is there a way (at least longer term) how we could
Sami 2015/03/04 19:39:28 I agree that it's a mess :( To add on top of the t
#if defined(OS_WIN)
void PreCacheFont(const LOGFONT& log_font) override;
void ReleaseCachedFonts() override;
@@ -253,6 +254,7 @@ class CONTENT_EXPORT ChildThreadImpl
bool on_channel_error_called_;
base::MessageLoop* message_loop_;
+ scoped_refptr<base::SingleThreadTaskRunner> task_runner_;
scoped_ptr<FileSystemDispatcher> file_system_dispatcher_;
@@ -304,6 +306,7 @@ struct ChildThreadImpl::Options {
bool use_mojo_channel;
bool in_browser_process;
std::vector<IPC::MessageFilter*> startup_filters;
+ scoped_refptr<base::SingleThreadTaskRunner> task_runner;
private:
Options();
@@ -317,6 +320,8 @@ class ChildThreadImpl::Options::Builder {
Builder& UseMojoChannel(bool use_mojo_channel);
Builder& WithChannelName(const std::string& channel_name);
Builder& AddStartupFilter(IPC::MessageFilter* filter);
+ Builder& WithTaskRunner(
+ scoped_refptr<base::SingleThreadTaskRunner> task_runner);
Options Build();
« no previous file with comments | « no previous file | content/child/child_thread_impl.cc » ('j') | content/public/child/child_thread.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698