| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/download/download_controller.h" | 5 #include "chrome/browser/android/download/download_controller.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/android/context_utils.h" | |
| 11 #include "base/android/jni_android.h" | 10 #include "base/android/jni_android.h" |
| 12 #include "base/android/jni_string.h" | 11 #include "base/android/jni_string.h" |
| 13 #include "base/bind.h" | 12 #include "base/bind.h" |
| 14 #include "base/lazy_instance.h" | 13 #include "base/lazy_instance.h" |
| 15 #include "base/logging.h" | 14 #include "base/logging.h" |
| 16 #include "base/metrics/histogram_macros.h" | 15 #include "base/metrics/histogram_macros.h" |
| 17 #include "base/synchronization/lock.h" | 16 #include "base/synchronization/lock.h" |
| 18 #include "chrome/browser/android/download/chrome_download_delegate.h" | 17 #include "chrome/browser/android/download/chrome_download_delegate.h" |
| 19 #include "chrome/browser/android/download/dangerous_download_infobar_delegate.h" | 18 #include "chrome/browser/android/download/dangerous_download_infobar_delegate.h" |
| 20 #include "chrome/browser/android/download/download_manager_service.h" | 19 #include "chrome/browser/android/download/download_manager_service.h" |
| (...skipping 371 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 392 int routing_id = web_contents->GetRenderViewHost()->GetRoutingID(); | 391 int routing_id = web_contents->GetRenderViewHost()->GetRoutingID(); |
| 393 | 392 |
| 394 const content::ResourceRequestInfo::WebContentsGetter& wc_getter( | 393 const content::ResourceRequestInfo::WebContentsGetter& wc_getter( |
| 395 base::Bind(&GetWebContents, process_id, routing_id)); | 394 base::Bind(&GetWebContents, process_id, routing_id)); |
| 396 | 395 |
| 397 AcquireFileAccessPermission( | 396 AcquireFileAccessPermission( |
| 398 wc_getter, base::Bind(&CreateContextMenuDownload, wc_getter, params, | 397 wc_getter, base::Bind(&CreateContextMenuDownload, wc_getter, params, |
| 399 is_link, extra_headers)); | 398 is_link, extra_headers)); |
| 400 } | 399 } |
| 401 | 400 |
| OLD | NEW |