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

Side by Side Diff: mojo/application_manager/application_manager.cc

Issue 506103002: Rename ApplicationLoader::OnServiceError to OnApplicationError (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merge nits Created 6 years, 3 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "mojo/application_manager/application_manager.h" 5 #include "mojo/application_manager/application_manager.h"
6 6
7 #include <stdio.h> 7 #include <stdio.h>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after
281 281
282 void ApplicationManager::OnShellImplError(ShellImpl* shell_impl) { 282 void ApplicationManager::OnShellImplError(ShellImpl* shell_impl) {
283 // Called from ~ShellImpl, so we do not need to call Destroy here. 283 // Called from ~ShellImpl, so we do not need to call Destroy here.
284 const GURL url = shell_impl->url(); 284 const GURL url = shell_impl->url();
285 URLToShellImplMap::iterator it = url_to_shell_impl_.find(url); 285 URLToShellImplMap::iterator it = url_to_shell_impl_.find(url);
286 DCHECK(it != url_to_shell_impl_.end()); 286 DCHECK(it != url_to_shell_impl_.end());
287 delete it->second; 287 delete it->second;
288 url_to_shell_impl_.erase(it); 288 url_to_shell_impl_.erase(it);
289 ApplicationLoader* loader = GetLoaderForURL(url); 289 ApplicationLoader* loader = GetLoaderForURL(url);
290 if (loader) 290 if (loader)
291 loader->OnServiceError(this, url); 291 loader->OnApplicationError(this, url);
292 if (delegate_) 292 if (delegate_)
293 delegate_->OnApplicationError(url); 293 delegate_->OnApplicationError(url);
294 } 294 }
295 295
296 ScopedMessagePipeHandle ApplicationManager::ConnectToServiceByName( 296 ScopedMessagePipeHandle ApplicationManager::ConnectToServiceByName(
297 const GURL& application_url, 297 const GURL& application_url,
298 const std::string& interface_name) { 298 const std::string& interface_name) {
299 StubServiceProvider* stub_sp = new StubServiceProvider; 299 StubServiceProvider* stub_sp = new StubServiceProvider;
300 ServiceProviderPtr spp; 300 ServiceProviderPtr spp;
301 BindToProxy(stub_sp, &spp); 301 BindToProxy(stub_sp, &spp);
302 ConnectToApplication(application_url, GURL(), spp.Pass()); 302 ConnectToApplication(application_url, GURL(), spp.Pass());
303 MessagePipe pipe; 303 MessagePipe pipe;
304 stub_sp->GetRemoteServiceProvider()->ConnectToService(interface_name, 304 stub_sp->GetRemoteServiceProvider()->ConnectToService(interface_name,
305 pipe.handle1.Pass()); 305 pipe.handle1.Pass());
306 return pipe.handle0.Pass(); 306 return pipe.handle0.Pass();
307 } 307 }
308 } // namespace mojo 308 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/application_manager/application_loader.h ('k') | mojo/application_manager/application_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698