| 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 "chrome/browser/ui/webui/md_downloads/md_downloads_ui.h" | 5 #include "chrome/browser/ui/webui/md_downloads/md_downloads_ui.h" |
| 6 | 6 |
| 7 #include "base/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.h" |
| 8 #include "base/memory/ref_counted_memory.h" | 8 #include "base/memory/ref_counted_memory.h" |
| 9 #include "base/memory/singleton.h" | 9 #include "base/memory/singleton.h" |
| 10 #include "base/strings/string_piece.h" | 10 #include "base/strings/string_piece.h" |
| 11 #include "base/threading/thread.h" | 11 #include "base/threading/thread.h" |
| 12 #include "base/values.h" | 12 #include "base/values.h" |
| 13 #include "chrome/browser/defaults.h" | 13 #include "chrome/browser/defaults.h" |
| 14 #include "chrome/browser/download/download_service.h" | |
| 15 #include "chrome/browser/download/download_service_factory.h" | |
| 16 #include "chrome/browser/profiles/profile.h" | 14 #include "chrome/browser/profiles/profile.h" |
| 17 #include "chrome/browser/ui/webui/md_downloads/md_downloads_dom_handler.h" | 15 #include "chrome/browser/ui/webui/md_downloads/md_downloads_dom_handler.h" |
| 18 #include "chrome/browser/ui/webui/metrics_handler.h" | 16 #include "chrome/browser/ui/webui/metrics_handler.h" |
| 19 #include "chrome/browser/ui/webui/theme_source.h" | 17 #include "chrome/browser/ui/webui/theme_source.h" |
| 20 #include "chrome/common/chrome_switches.h" | 18 #include "chrome/common/chrome_switches.h" |
| 21 #include "chrome/common/features.h" | 19 #include "chrome/common/features.h" |
| 22 #include "chrome/common/pref_names.h" | 20 #include "chrome/common/pref_names.h" |
| 23 #include "chrome/common/url_constants.h" | 21 #include "chrome/common/url_constants.h" |
| 24 #include "chrome/grit/browser_resources.h" | 22 #include "chrome/grit/browser_resources.h" |
| 25 #include "chrome/grit/chromium_strings.h" | 23 #include "chrome/grit/chromium_strings.h" |
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 ThemeSource* theme = new ThemeSource(profile); | 159 ThemeSource* theme = new ThemeSource(profile); |
| 162 content::URLDataSource::Add(profile, theme); | 160 content::URLDataSource::Add(profile, theme); |
| 163 } | 161 } |
| 164 | 162 |
| 165 // static | 163 // static |
| 166 base::RefCountedMemory* MdDownloadsUI::GetFaviconResourceBytes( | 164 base::RefCountedMemory* MdDownloadsUI::GetFaviconResourceBytes( |
| 167 ui::ScaleFactor scale_factor) { | 165 ui::ScaleFactor scale_factor) { |
| 168 return ResourceBundle::GetSharedInstance(). | 166 return ResourceBundle::GetSharedInstance(). |
| 169 LoadDataResourceBytesForScale(IDR_DOWNLOADS_FAVICON, scale_factor); | 167 LoadDataResourceBytesForScale(IDR_DOWNLOADS_FAVICON, scale_factor); |
| 170 } | 168 } |
| OLD | NEW |