OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 "chrome/browser/android/offline_pages/prefetch/prefetch_background_task
.h" | 5 #include "chrome/browser/android/offline_pages/prefetch/prefetch_background_task
.h" |
6 | 6 |
| 7 #include "chrome/browser/offline_pages/prefetch/prefetch_service_factory.h" |
7 #include "chrome/browser/profiles/profile.h" | 8 #include "chrome/browser/profiles/profile.h" |
8 #include "chrome/browser/profiles/profile_android.h" | 9 #include "chrome/browser/profiles/profile_android.h" |
9 #include "components/offline_pages/content/prefetch_service_factory.h" | |
10 #include "components/offline_pages/core/prefetch/prefetch_service.h" | 10 #include "components/offline_pages/core/prefetch/prefetch_service.h" |
11 #include "content/public/browser/browser_context.h" | 11 #include "content/public/browser/browser_context.h" |
12 #include "jni/PrefetchBackgroundTask_jni.h" | 12 #include "jni/PrefetchBackgroundTask_jni.h" |
13 | 13 |
14 using base::android::JavaParamRef; | 14 using base::android::JavaParamRef; |
15 using base::android::ScopedJavaGlobalRef; | 15 using base::android::ScopedJavaGlobalRef; |
16 using base::android::ScopedJavaLocalRef; | 16 using base::android::ScopedJavaLocalRef; |
17 | 17 |
18 namespace offline_pages { | 18 namespace offline_pages { |
19 namespace prefetch { | 19 namespace prefetch { |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
75 | 75 |
76 void PrefetchBackgroundTask::SetNeedsReschedule(bool reschedule) { | 76 void PrefetchBackgroundTask::SetNeedsReschedule(bool reschedule) { |
77 needs_reschedule_ = reschedule; | 77 needs_reschedule_ = reschedule; |
78 } | 78 } |
79 | 79 |
80 bool RegisterPrefetchBackgroundTask(JNIEnv* env) { | 80 bool RegisterPrefetchBackgroundTask(JNIEnv* env) { |
81 return prefetch::RegisterNativesImpl(env); | 81 return prefetch::RegisterNativesImpl(env); |
82 } | 82 } |
83 | 83 |
84 } // namespace offline_pages | 84 } // namespace offline_pages |
OLD | NEW |