| OLD | NEW |
| 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 #ifndef MOJO_PUBLIC_APPLICATION_APPLICATION_IMPL_H_ | 5 #ifndef MOJO_PUBLIC_APPLICATION_APPLICATION_IMPL_H_ |
| 6 #define MOJO_PUBLIC_APPLICATION_APPLICATION_IMPL_H_ | 6 #define MOJO_PUBLIC_APPLICATION_APPLICATION_IMPL_H_ |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "mojo/public/cpp/application/application_connection.h" | 9 #include "mojo/public/cpp/application/application_connection.h" |
| 10 #include "mojo/public/cpp/application/lib/service_connector.h" | 10 #include "mojo/public/cpp/application/lib/service_connector.h" |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 81 void ClearConnections(); | 81 void ClearConnections(); |
| 82 void OnShellError() { | 82 void OnShellError() { |
| 83 ClearConnections(); | 83 ClearConnections(); |
| 84 Terminate(); | 84 Terminate(); |
| 85 }; | 85 }; |
| 86 | 86 |
| 87 // Quits the main run loop for this application. | 87 // Quits the main run loop for this application. |
| 88 static void Terminate(); | 88 static void Terminate(); |
| 89 | 89 |
| 90 // Application implementation. | 90 // Application implementation. |
| 91 virtual void Initialize(Array<String> args) MOJO_OVERRIDE; | 91 virtual void Initialize(Array<String> args) override; |
| 92 virtual void AcceptConnection(const String& requestor_url, | 92 virtual void AcceptConnection(const String& requestor_url, |
| 93 ServiceProviderPtr provider) MOJO_OVERRIDE; | 93 ServiceProviderPtr provider) override; |
| 94 | 94 |
| 95 typedef std::vector<internal::ServiceRegistry*> ServiceRegistryList; | 95 typedef std::vector<internal::ServiceRegistry*> ServiceRegistryList; |
| 96 | 96 |
| 97 bool initialized_; | 97 bool initialized_; |
| 98 ServiceRegistryList incoming_service_registries_; | 98 ServiceRegistryList incoming_service_registries_; |
| 99 ServiceRegistryList outgoing_service_registries_; | 99 ServiceRegistryList outgoing_service_registries_; |
| 100 ApplicationDelegate* delegate_; | 100 ApplicationDelegate* delegate_; |
| 101 ShellPtr shell_; | 101 ShellPtr shell_; |
| 102 ShellPtrWatcher* shell_watch_; | 102 ShellPtrWatcher* shell_watch_; |
| 103 Array<String> args_; | 103 Array<String> args_; |
| 104 | 104 |
| 105 MOJO_DISALLOW_COPY_AND_ASSIGN(ApplicationImpl); | 105 MOJO_DISALLOW_COPY_AND_ASSIGN(ApplicationImpl); |
| 106 }; | 106 }; |
| 107 | 107 |
| 108 } // namespace mojo | 108 } // namespace mojo |
| 109 | 109 |
| 110 #endif // MOJO_PUBLIC_APPLICATION_APPLICATION_IMPL_H_ | 110 #endif // MOJO_PUBLIC_APPLICATION_APPLICATION_IMPL_H_ |
| OLD | NEW |