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

Side by Side Diff: content/utility/utility_thread_impl.cc

Issue 974933002: content: Refactor ChildThreadImpl::Options (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Review comments. Created 5 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 unified diff | Download patch
« no previous file with comments | « content/renderer/render_thread_impl.cc ('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 // 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 "content/utility/utility_thread_impl.h" 5 #include "content/utility/utility_thread_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/memory/scoped_vector.h" 10 #include "base/memory/scoped_vector.h"
(...skipping 22 matching lines...) Expand all
33 dest->push_back(typename DEST::value_type(*i)); 33 dest->push_back(typename DEST::value_type(*i));
34 } 34 }
35 35
36 } // namespace 36 } // namespace
37 37
38 UtilityThreadImpl::UtilityThreadImpl() : single_process_(false) { 38 UtilityThreadImpl::UtilityThreadImpl() : single_process_(false) {
39 Init(); 39 Init();
40 } 40 }
41 41
42 UtilityThreadImpl::UtilityThreadImpl(const std::string& channel_name) 42 UtilityThreadImpl::UtilityThreadImpl(const std::string& channel_name)
43 : ChildThreadImpl(Options(channel_name, false)), 43 : ChildThreadImpl(Options::Builder()
44 .InBrowserProcess(true)
45 .WithChannelName(channel_name)
46 .Build()),
44 single_process_(true) { 47 single_process_(true) {
45 Init(); 48 Init();
46 } 49 }
47 50
48 UtilityThreadImpl::~UtilityThreadImpl() { 51 UtilityThreadImpl::~UtilityThreadImpl() {
49 } 52 }
50 53
51 void UtilityThreadImpl::Shutdown() { 54 void UtilityThreadImpl::Shutdown() {
52 ChildThreadImpl::Shutdown(); 55 ChildThreadImpl::Shutdown();
53 56
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 Send(new UtilityHostMsg_LoadPluginFailed(i, plugin_paths[i])); 128 Send(new UtilityHostMsg_LoadPluginFailed(i, plugin_paths[i]));
126 else 129 else
127 Send(new UtilityHostMsg_LoadedPlugin(i, plugin)); 130 Send(new UtilityHostMsg_LoadedPlugin(i, plugin));
128 } 131 }
129 132
130 ReleaseProcessIfNeeded(); 133 ReleaseProcessIfNeeded();
131 } 134 }
132 #endif 135 #endif
133 136
134 } // namespace content 137 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/render_thread_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698