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

Side by Side Diff: chrome/browser/android/offline_pages/downloads/offline_page_download_bridge.cc

Issue 2721553004: Remove auto raw pointer deduction from non-linux specific code. (Closed)
Patch Set: rebase Created 3 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 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/offline_pages/downloads/offline_page_download_b ridge.h" 5 #include "chrome/browser/android/offline_pages/downloads/offline_page_download_b ridge.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/android/jni_string.h" 9 #include "base/android/jni_string.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 Profile::FromBrowserContext(web_contents->GetBrowserContext()) 212 Profile::FromBrowserContext(web_contents->GetBrowserContext())
213 ->GetOriginalProfile(), 213 ->GetOriginalProfile(),
214 kDownloadNamespace, url, base::Bind(&RequestQueueDuplicateCheckDone, url, 214 kDownloadNamespace, url, base::Bind(&RequestQueueDuplicateCheckDone, url,
215 original_url, j_tab_ref)); 215 original_url, j_tab_ref));
216 } 216 }
217 217
218 void ToJavaOfflinePageDownloadItemList( 218 void ToJavaOfflinePageDownloadItemList(
219 JNIEnv* env, 219 JNIEnv* env,
220 jobject j_result_obj, 220 jobject j_result_obj,
221 const std::vector<const DownloadUIItem*>& items) { 221 const std::vector<const DownloadUIItem*>& items) {
222 for (const auto item : items) { 222 for (const auto* item : items) {
223 Java_OfflinePageDownloadBridge_createDownloadItemAndAddToList( 223 Java_OfflinePageDownloadBridge_createDownloadItemAndAddToList(
224 env, j_result_obj, ConvertUTF8ToJavaString(env, item->guid), 224 env, j_result_obj, ConvertUTF8ToJavaString(env, item->guid),
225 ConvertUTF8ToJavaString(env, item->url.spec()), item->download_state, 225 ConvertUTF8ToJavaString(env, item->url.spec()), item->download_state,
226 item->download_progress_bytes, 226 item->download_progress_bytes,
227 ConvertUTF16ToJavaString(env, item->title), 227 ConvertUTF16ToJavaString(env, item->title),
228 ConvertUTF8ToJavaString(env, item->target_path.value()), 228 ConvertUTF8ToJavaString(env, item->target_path.value()),
229 item->start_time.ToJavaTime(), item->total_bytes); 229 item->start_time.ToJavaTime(), item->total_bytes);
230 } 230 }
231 } 231 }
232 232
(...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after
497 base::MakeUnique<DownloadUIAdapterDelegate>(offline_page_model)); 497 base::MakeUnique<DownloadUIAdapterDelegate>(offline_page_model));
498 DownloadUIAdapter::AttachToOfflinePageModel(adapter, offline_page_model); 498 DownloadUIAdapter::AttachToOfflinePageModel(adapter, offline_page_model);
499 } 499 }
500 500
501 return reinterpret_cast<jlong>( 501 return reinterpret_cast<jlong>(
502 new OfflinePageDownloadBridge(env, obj, adapter, browser_context)); 502 new OfflinePageDownloadBridge(env, obj, adapter, browser_context));
503 } 503 }
504 504
505 } // namespace android 505 } // namespace android
506 } // namespace offline_pages 506 } // namespace offline_pages
OLDNEW
« no previous file with comments | « chrome/browser/android/instantapps/instant_apps_infobar_delegate.cc ('k') | chrome/browser/android/vr_shell/vr_shell_gl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698