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

Side by Side Diff: content/browser/utility_process_host_impl.cc

Issue 121033002: Update uses of UTF conversions in content/ to use the base:: namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 12 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 | Annotate | Revision Log
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/browser/utility_process_host_impl.h" 5 #include "content/browser/utility_process_host_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 if (started_) 135 if (started_)
136 return true; 136 return true;
137 started_ = true; 137 started_ = true;
138 138
139 if (is_batch_mode_) 139 if (is_batch_mode_)
140 return true; 140 return true;
141 141
142 // Name must be set or metrics_service will crash in any test which 142 // Name must be set or metrics_service will crash in any test which
143 // launches a UtilityProcessHost. 143 // launches a UtilityProcessHost.
144 process_.reset(new BrowserChildProcessHostImpl(PROCESS_TYPE_UTILITY, this)); 144 process_.reset(new BrowserChildProcessHostImpl(PROCESS_TYPE_UTILITY, this));
145 process_->SetName(ASCIIToUTF16("utility process")); 145 process_->SetName(base::ASCIIToUTF16("utility process"));
146 146
147 std::string channel_id = process_->GetHost()->CreateChannel(); 147 std::string channel_id = process_->GetHost()->CreateChannel();
148 if (channel_id.empty()) 148 if (channel_id.empty())
149 return false; 149 return false;
150 150
151 if (RenderProcessHost::run_renderer_in_process()) { 151 if (RenderProcessHost::run_renderer_in_process()) {
152 DCHECK(g_utility_main_thread_factory); 152 DCHECK(g_utility_main_thread_factory);
153 // See comment in RenderProcessHostImpl::Init() for the background on why we 153 // See comment in RenderProcessHostImpl::Init() for the background on why we
154 // support single process mode this way. 154 // support single process mode this way.
155 in_process_thread_.reset(g_utility_main_thread_factory(channel_id)); 155 in_process_thread_.reset(g_utility_main_thread_factory(channel_id));
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
241 } 241 }
242 242
243 void UtilityProcessHostImpl::OnProcessCrashed(int exit_code) { 243 void UtilityProcessHostImpl::OnProcessCrashed(int exit_code) {
244 client_task_runner_->PostTask( 244 client_task_runner_->PostTask(
245 FROM_HERE, 245 FROM_HERE,
246 base::Bind(&UtilityProcessHostClient::OnProcessCrashed, client_.get(), 246 base::Bind(&UtilityProcessHostClient::OnProcessCrashed, client_.get(),
247 exit_code)); 247 exit_code));
248 } 248 }
249 249
250 } // namespace content 250 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/speech/speech_recognition_browsertest.cc ('k') | content/browser/web_contents/web_contents_drag_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698