OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/browser/tab_contents/tab_contents.h" | 5 #include "content/browser/tab_contents/tab_contents.h" |
6 | 6 |
7 #include <cmath> | 7 #include <cmath> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
(...skipping 2448 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2459 post_id = entry->GetPostID(); | 2459 post_id = entry->GetPostID(); |
2460 } | 2460 } |
2461 DownloadSaveInfo save_info; | 2461 DownloadSaveInfo save_info; |
2462 save_info.prompt_for_save_location = true; | 2462 save_info.prompt_for_save_location = true; |
2463 dlm->DownloadUrl(url, | 2463 dlm->DownloadUrl(url, |
2464 referrer, | 2464 referrer, |
2465 "", | 2465 "", |
2466 true, // prefer_cache | 2466 true, // prefer_cache |
2467 post_id, | 2467 post_id, |
2468 save_info, | 2468 save_info, |
2469 this); | 2469 this, |
| 2470 DownloadManager::OnStartedCallback()); |
2470 } | 2471 } |
2471 | 2472 |
2472 void TabContents::CreateViewAndSetSizeForRVH(RenderViewHost* rvh) { | 2473 void TabContents::CreateViewAndSetSizeForRVH(RenderViewHost* rvh) { |
2473 RenderWidgetHostView* rwh_view = GetView()->CreateViewForWidget(rvh); | 2474 RenderWidgetHostView* rwh_view = GetView()->CreateViewForWidget(rvh); |
2474 // Can be NULL during tests. | 2475 // Can be NULL during tests. |
2475 if (rwh_view) | 2476 if (rwh_view) |
2476 rwh_view->SetSize(GetView()->GetContainerSize()); | 2477 rwh_view->SetSize(GetView()->GetContainerSize()); |
2477 } | 2478 } |
OLD | NEW |