| 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 SHELL_ANDROID_ANDROID_HANDLER_H_ | 5 #ifndef SHELL_ANDROID_ANDROID_HANDLER_H_ |
| 6 #define SHELL_ANDROID_ANDROID_HANDLER_H_ | 6 #define SHELL_ANDROID_ANDROID_HANDLER_H_ |
| 7 | 7 |
| 8 #include <jni.h> | 8 #include <jni.h> |
| 9 | 9 |
| 10 #include "base/single_thread_task_runner.h" | 10 #include "base/single_thread_task_runner.h" |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 class AndroidHandler : public mojo::ApplicationDelegate, | 22 class AndroidHandler : public mojo::ApplicationDelegate, |
| 23 public mojo::ContentHandlerFactory::Delegate { | 23 public mojo::ContentHandlerFactory::Delegate { |
| 24 public: | 24 public: |
| 25 AndroidHandler(); | 25 AndroidHandler(); |
| 26 ~AndroidHandler(); | 26 ~AndroidHandler(); |
| 27 | 27 |
| 28 private: | 28 private: |
| 29 // mojo::ApplicationDelegate: | 29 // mojo::ApplicationDelegate: |
| 30 void Initialize(mojo::ApplicationImpl* app) override; | 30 void Initialize(mojo::ApplicationImpl* app) override; |
| 31 bool ConfigureIncomingConnection( | 31 bool ConfigureIncomingConnection( |
| 32 mojo::ApplicationConnection* connection) override; | 32 mojo::ServiceProviderImpl* service_provider_impl) override; |
| 33 | 33 |
| 34 // mojo::ContentHandlerFactory::Delegate: | 34 // mojo::ContentHandlerFactory::Delegate: |
| 35 void RunApplication( | 35 void RunApplication( |
| 36 mojo::InterfaceRequest<mojo::Application> application_request, | 36 mojo::InterfaceRequest<mojo::Application> application_request, |
| 37 mojo::URLResponsePtr response) override; | 37 mojo::URLResponsePtr response) override; |
| 38 | 38 |
| 39 void ExtractApplication(base::FilePath* extracted_dir, | 39 void ExtractApplication(base::FilePath* extracted_dir, |
| 40 base::FilePath* cache_dir, | 40 base::FilePath* cache_dir, |
| 41 mojo::URLResponsePtr response, | 41 mojo::URLResponsePtr response, |
| 42 const base::Closure& callback); | 42 const base::Closure& callback); |
| 43 | 43 |
| 44 mojo::ContentHandlerFactory content_handler_factory_; | 44 mojo::ContentHandlerFactory content_handler_factory_; |
| 45 mojo::URLResponseDiskCachePtr url_response_disk_cache_; | 45 mojo::URLResponseDiskCachePtr url_response_disk_cache_; |
| 46 scoped_refptr<base::SingleThreadTaskRunner> handler_task_runner_; | 46 scoped_refptr<base::SingleThreadTaskRunner> handler_task_runner_; |
| 47 | 47 |
| 48 MOJO_DISALLOW_COPY_AND_ASSIGN(AndroidHandler); | 48 MOJO_DISALLOW_COPY_AND_ASSIGN(AndroidHandler); |
| 49 }; | 49 }; |
| 50 | 50 |
| 51 bool RegisterAndroidHandlerJni(JNIEnv* env); | 51 bool RegisterAndroidHandlerJni(JNIEnv* env); |
| 52 | 52 |
| 53 } // namespace shell | 53 } // namespace shell |
| 54 | 54 |
| 55 #endif // SHELL_ANDROID_ANDROID_HANDLER_H_ | 55 #endif // SHELL_ANDROID_ANDROID_HANDLER_H_ |
| OLD | NEW |