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

Side by Side Diff: mojo/shell/run.cc

Issue 617503003: Mojo: MOJO_OVERRIDE -> override in mojo/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebased Created 6 years, 2 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/shell/run.h" 5 #include "mojo/shell/run.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "mojo/application_manager/application_manager.h" 8 #include "mojo/application_manager/application_manager.h"
9 #include "mojo/shell/context.h" 9 #include "mojo/shell/context.h"
10 10
11 namespace mojo { 11 namespace mojo {
12 namespace shell { 12 namespace shell {
13 13
14 class StubServiceProvider : public InterfaceImpl<ServiceProvider> { 14 class StubServiceProvider : public InterfaceImpl<ServiceProvider> {
15 private: 15 private:
16 virtual void ConnectToService(const mojo::String& service_name, 16 virtual void ConnectToService(
17 ScopedMessagePipeHandle client_handle) 17 const mojo::String& service_name,
18 MOJO_OVERRIDE { 18 ScopedMessagePipeHandle client_handle) override {}
19 }
20 }; 19 };
21 20
22 21
23 void Run(Context* context, const std::vector<GURL>& app_urls) { 22 void Run(Context* context, const std::vector<GURL>& app_urls) {
24 if (app_urls.empty()) { 23 if (app_urls.empty()) {
25 LOG(ERROR) << "No app path specified"; 24 LOG(ERROR) << "No app path specified";
26 return; 25 return;
27 } 26 }
28 27
29 for (std::vector<GURL>::const_iterator it = app_urls.begin(); 28 for (std::vector<GURL>::const_iterator it = app_urls.begin();
30 it != app_urls.end(); 29 it != app_urls.end();
31 ++it) { 30 ++it) {
32 // TODO(davemoore): These leak...need refs to them. 31 // TODO(davemoore): These leak...need refs to them.
33 StubServiceProvider* stub_sp = new StubServiceProvider; 32 StubServiceProvider* stub_sp = new StubServiceProvider;
34 ServiceProviderPtr spp; 33 ServiceProviderPtr spp;
35 BindToProxy(stub_sp, &spp); 34 BindToProxy(stub_sp, &spp);
36 35
37 context->application_manager()->ConnectToApplication( 36 context->application_manager()->ConnectToApplication(
38 *it, GURL(), spp.Pass()); 37 *it, GURL(), spp.Pass());
39 } 38 }
40 } 39 }
41 40
42 } // namespace shell 41 } // namespace shell
43 } // namespace mojo 42 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/shell/incoming_connection_listener_unittest.cc ('k') | mojo/tools/package_manager/package_manager_application.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698