OLD | NEW |
(Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "content/browser/mojo/mojo_app_connection_impl.h" |
| 6 |
| 7 #include "content/browser/mojo/mojo_shell_context.h" |
| 8 |
| 9 namespace content { |
| 10 |
| 11 scoped_ptr<MojoAppConnection> MojoAppConnection::Create(const GURL& url) { |
| 12 return scoped_ptr<MojoAppConnection>(new MojoAppConnectionImpl(url)); |
| 13 } |
| 14 |
| 15 MojoAppConnectionImpl::MojoAppConnectionImpl(const GURL& url) { |
| 16 MojoShellContext::ConnectToApplication(url, mojo::GetProxy(&services_)); |
| 17 } |
| 18 |
| 19 MojoAppConnectionImpl::~MojoAppConnectionImpl() { |
| 20 } |
| 21 |
| 22 void MojoAppConnectionImpl::ConnectToService( |
| 23 const std::string& service_name, |
| 24 mojo::ScopedMessagePipeHandle handle) { |
| 25 services_->ConnectToService(service_name, handle.Pass()); |
| 26 } |
| 27 |
| 28 } // namespace content |
OLD | NEW |