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

Unified Diff: chrome/browser/ui/views/ash/balloon_view_ash.h

Issue 11411180: move favicon download code from chrome/ into content/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix order Created 8 years 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/metro_pin_tab_helper_win.cc ('k') | chrome/browser/ui/views/ash/balloon_view_ash.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/ash/balloon_view_ash.h
diff --git a/chrome/browser/ui/views/ash/balloon_view_ash.h b/chrome/browser/ui/views/ash/balloon_view_ash.h
index ff56d34e62b76f500092ca11c23c82602a3e73ce..097a93ca50a8e90c30c33ae70a64f2239d5e714b 100644
--- a/chrome/browser/ui/views/ash/balloon_view_ash.h
+++ b/chrome/browser/ui/views/ash/balloon_view_ash.h
@@ -5,16 +5,16 @@
#ifndef CHROME_BROWSER_UI_VIEWS_ASH_BALLOON_VIEW_ASH_H_
#define CHROME_BROWSER_UI_VIEWS_ASH_BALLOON_VIEW_ASH_H_
-#include <map>
+#include <vector>
-#include "chrome/browser/favicon/favicon_download_helper_delegate.h"
+#include "base/memory/weak_ptr.h"
#include "chrome/browser/notifications/balloon.h"
-class FaviconDownloadHelper;
+class GURL;
+class SkBitmap;
// On Ash, a "BalloonView" is just a wrapper for ash notification entries.
-class BalloonViewAsh : public BalloonView,
- public FaviconDownloadHelperDelegate {
+class BalloonViewAsh : public BalloonView {
public:
explicit BalloonViewAsh(BalloonCollection* collection);
virtual ~BalloonViewAsh();
@@ -27,27 +27,26 @@ class BalloonViewAsh : public BalloonView,
virtual gfx::Size GetSize() const OVERRIDE;
virtual BalloonHost* GetHost() const OVERRIDE;
- // FaviconDownloadHelperDelegate interface:
- virtual void OnDidDownloadFavicon(
+ private:
+ // Favicon download callback.
+ void DidDownloadFavicon(
int id,
const GURL& image_url,
bool errored,
int requested_size,
- const std::vector<SkBitmap>& bitmaps) OVERRIDE;
-
- private:
+ const std::vector<SkBitmap>& bitmaps);
void FetchIcon(const Notification& notification);
std::string GetExtensionId(Balloon* balloon);
BalloonCollection* collection_;
Balloon* balloon_;
- scoped_ptr<FaviconDownloadHelper> icon_fetcher_;
// Track the current notification id and download id so that it can be updated
// properly.
int current_download_id_;
std::string current_notification_id_;
std::string cached_notification_id_;
+ base::WeakPtrFactory<BalloonViewAsh> weak_ptr_factory_;
DISALLOW_COPY_AND_ASSIGN(BalloonViewAsh);
};
« no previous file with comments | « chrome/browser/ui/metro_pin_tab_helper_win.cc ('k') | chrome/browser/ui/views/ash/balloon_view_ash.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698