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

Side by Side Diff: mojo/public/cpp/application/lib/application_test_base.cc

Issue 943053003: Simple multi-url support for mojo apps (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: rebase + fix android 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
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/public/cpp/application/application_test_base.h" 5 #include "mojo/public/cpp/application/application_test_base.h"
6 6
7 #include "mojo/public/cpp/application/application_impl.h" 7 #include "mojo/public/cpp/application/application_impl.h"
8 #include "mojo/public/cpp/bindings/binding.h" 8 #include "mojo/public/cpp/bindings/binding.h"
9 #include "mojo/public/cpp/environment/environment.h" 9 #include "mojo/public/cpp/environment/environment.h"
10 #include "mojo/public/cpp/system/message_pipe.h" 10 #include "mojo/public/cpp/system/message_pipe.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 void Initialize(ShellPtr shell, 50 void Initialize(ShellPtr shell,
51 Array<String> args, 51 Array<String> args,
52 const mojo::String& url) override { 52 const mojo::String& url) override {
53 *args_ = args.Pass(); 53 *args_ = args.Pass();
54 g_application_request = binding_.Unbind(); 54 g_application_request = binding_.Unbind();
55 g_shell = shell.Pass(); 55 g_shell = shell.Pass();
56 } 56 }
57 57
58 void AcceptConnection(const String& requestor_url, 58 void AcceptConnection(const String& requestor_url,
59 InterfaceRequest<ServiceProvider> services, 59 InterfaceRequest<ServiceProvider> services,
60 ServiceProviderPtr exposed_services) override { 60 ServiceProviderPtr exposed_services,
61 const String& url) override {
61 MOJO_CHECK(false); 62 MOJO_CHECK(false);
62 } 63 }
63 64
64 void RequestQuit() override { MOJO_CHECK(false); } 65 void RequestQuit() override { MOJO_CHECK(false); }
65 66
66 Array<String>* args_; 67 Array<String>* args_;
67 Binding<Application> binding_; 68 Binding<Application> binding_;
68 }; 69 };
69 70
70 } // namespace 71 } // namespace
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
151 if (ShouldCreateDefaultRunLoop()) 152 if (ShouldCreateDefaultRunLoop())
152 Environment::DestroyDefaultRunLoop(); 153 Environment::DestroyDefaultRunLoop();
153 } 154 }
154 155
155 bool ApplicationTestBase::ShouldCreateDefaultRunLoop() { 156 bool ApplicationTestBase::ShouldCreateDefaultRunLoop() {
156 return true; 157 return true;
157 } 158 }
158 159
159 } // namespace test 160 } // namespace test
160 } // namespace mojo 161 } // namespace mojo
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698