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

Unified Diff: chrome/browser/ui/webui/fileicon_source.h

Issue 9167019: Consolidate icon loading on ChromeOS (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add comment. Created 8 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/webui/downloads_dom_handler.cc ('k') | chrome/browser/ui/webui/fileicon_source.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/fileicon_source.h
diff --git a/chrome/browser/ui/webui/fileicon_source.h b/chrome/browser/ui/webui/fileicon_source.h
index f42fabf4bde323edb623b5f6d85c05bd506b4448..84858c78de00b7fc6be5a423ef78bbaa34a50a70 100644
--- a/chrome/browser/ui/webui/fileicon_source.h
+++ b/chrome/browser/ui/webui/fileicon_source.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -8,6 +8,7 @@
#include <string>
+#include "base/file_path.h"
#include "chrome/browser/icon_manager.h"
#include "chrome/browser/ui/webui/chrome_url_data_manager.h"
@@ -36,14 +37,18 @@ class FileIconSource : public ChromeURLDataManager::DataSource {
IconManager::Handle request_handle,
gfx::Image* icon);
- private:
+ protected:
virtual ~FileIconSource();
- CancelableRequestConsumerT<int, 0> cancelable_consumer_;
+ // Once the |path| and |icon_size| has been determined from the request, this
+ // function is called to perform the actual fetch. Declared as virtual for
+ // testing.
+ virtual void FetchFileIcon(const FilePath& path,
+ IconLoader::IconSize icon_size,
+ int request_id);
- // Raw PNG representation of the favicon to show when the favicon
- // database doesn't have a favicon for a webpage.
- scoped_refptr<RefCountedBytes> default_favicon_;
+ private:
+ CancelableRequestConsumerT<int, 0> cancelable_consumer_;
DISALLOW_COPY_AND_ASSIGN(FileIconSource);
};
« no previous file with comments | « chrome/browser/ui/webui/downloads_dom_handler.cc ('k') | chrome/browser/ui/webui/fileicon_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698