OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/download/download_manager.h" | 5 #include "chrome/browser/download/download_manager.h" |
6 | 6 |
7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
8 #include "app/resource_bundle.h" | |
9 #include "base/callback.h" | 8 #include "base/callback.h" |
10 #include "base/file_util.h" | 9 #include "base/file_util.h" |
11 #include "base/logging.h" | 10 #include "base/logging.h" |
12 #include "base/path_service.h" | 11 #include "base/path_service.h" |
13 #include "base/rand_util.h" | 12 #include "base/rand_util.h" |
14 #include "base/stl_util-inl.h" | 13 #include "base/stl_util-inl.h" |
15 #include "base/stringprintf.h" | 14 #include "base/stringprintf.h" |
16 #include "base/sys_string_conversions.h" | 15 #include "base/sys_string_conversions.h" |
17 #include "base/task.h" | 16 #include "base/task.h" |
18 #include "base/utf_string_conversions.h" | 17 #include "base/utf_string_conversions.h" |
(...skipping 20 matching lines...) Expand all Loading... |
39 #include "chrome/browser/tab_contents/tab_contents.h" | 38 #include "chrome/browser/tab_contents/tab_contents.h" |
40 #include "chrome/browser/tab_contents/tab_util.h" | 39 #include "chrome/browser/tab_contents/tab_util.h" |
41 #include "chrome/browser/ui/browser.h" | 40 #include "chrome/browser/ui/browser.h" |
42 #include "chrome/common/chrome_paths.h" | 41 #include "chrome/common/chrome_paths.h" |
43 #include "chrome/common/notification_type.h" | 42 #include "chrome/common/notification_type.h" |
44 #include "googleurl/src/gurl.h" | 43 #include "googleurl/src/gurl.h" |
45 #include "grit/generated_resources.h" | 44 #include "grit/generated_resources.h" |
46 #include "grit/theme_resources.h" | 45 #include "grit/theme_resources.h" |
47 #include "net/base/mime_util.h" | 46 #include "net/base/mime_util.h" |
48 #include "net/base/net_util.h" | 47 #include "net/base/net_util.h" |
| 48 #include "ui/base/resource/resource_bundle.h" |
49 | 49 |
50 DownloadManager::DownloadManager(DownloadStatusUpdater* status_updater) | 50 DownloadManager::DownloadManager(DownloadStatusUpdater* status_updater) |
51 : shutdown_needed_(false), | 51 : shutdown_needed_(false), |
52 profile_(NULL), | 52 profile_(NULL), |
53 file_manager_(NULL), | 53 file_manager_(NULL), |
54 status_updater_(status_updater->AsWeakPtr()) { | 54 status_updater_(status_updater->AsWeakPtr()) { |
55 if (status_updater_) | 55 if (status_updater_) |
56 status_updater_->AddDelegate(this); | 56 status_updater_->AddDelegate(this); |
57 } | 57 } |
58 | 58 |
(...skipping 1051 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1110 observed_download_manager_->RemoveObserver(this); | 1110 observed_download_manager_->RemoveObserver(this); |
1111 } | 1111 } |
1112 | 1112 |
1113 void DownloadManager::OtherDownloadManagerObserver::ModelChanged() { | 1113 void DownloadManager::OtherDownloadManagerObserver::ModelChanged() { |
1114 observing_download_manager_->NotifyModelChanged(); | 1114 observing_download_manager_->NotifyModelChanged(); |
1115 } | 1115 } |
1116 | 1116 |
1117 void DownloadManager::OtherDownloadManagerObserver::ManagerGoingDown() { | 1117 void DownloadManager::OtherDownloadManagerObserver::ManagerGoingDown() { |
1118 observed_download_manager_ = NULL; | 1118 observed_download_manager_ = NULL; |
1119 } | 1119 } |
OLD | NEW |