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

Unified Diff: chrome/browser/ui/panels/panel.h

Issue 11886029: Use ImageLoader instead of ImageLoadingTracker (Part 9) (Closed) Base URL: https://git.chromium.org/chromium/src.git@Issue_163929
Patch Set: Rebasing Created 7 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/extensions/image_loading_tracker.h ('k') | chrome/browser/ui/panels/panel.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/panels/panel.h
diff --git a/chrome/browser/ui/panels/panel.h b/chrome/browser/ui/panels/panel.h
index 981914151c9af41fb0ce8d42fe22326e36d47d38..1e2fd5e88af304628a7cc3b4a31795f4ffb10b3a 100644
--- a/chrome/browser/ui/panels/panel.h
+++ b/chrome/browser/ui/panels/panel.h
@@ -9,10 +9,10 @@
#include "base/gtest_prod_util.h"
#include "base/memory/scoped_ptr.h"
+#include "base/memory/weak_ptr.h"
#include "base/string16.h"
#include "chrome/browser/command_updater.h"
#include "chrome/browser/command_updater_delegate.h"
-#include "chrome/browser/extensions/image_loading_tracker.h"
#include "chrome/browser/sessions/session_id.h"
#include "chrome/browser/ui/base_window.h"
#include "chrome/browser/ui/panels/panel_constants.h"
@@ -50,8 +50,7 @@ class WindowController;
// other Panels. For example deleting a panel would rearrange other panels.
class Panel : public BaseWindow,
public CommandUpdaterDelegate,
- public content::NotificationObserver,
- public ImageLoadingTracker::Observer {
+ public content::NotificationObserver {
public:
enum ExpansionState {
// The panel is fully expanded with both title-bar and the client-area.
@@ -322,10 +321,7 @@ class Panel : public BaseWindow,
CUSTOM_MAX_SIZE
};
- // ImageLoadingTracker::Observer implementation.
- virtual void OnImageLoaded(const gfx::Image& image,
- const std::string& extension_id,
- int index) OVERRIDE;
+ void OnImageLoaded(const gfx::Image& image);
// Initialize state for all supported commands.
void InitCommandState();
@@ -390,12 +386,11 @@ class Panel : public BaseWindow,
scoped_ptr<extensions::WindowController> extension_window_controller_;
scoped_ptr<PanelHost> panel_host_;
- // Used for loading app_icon_.
- scoped_ptr<ImageLoadingTracker> app_icon_loader_;
-
// Icon showed in the task bar.
gfx::Image app_icon_;
+ base::WeakPtrFactory<Panel> image_loader_ptr_factory_;
+
DISALLOW_COPY_AND_ASSIGN(Panel);
};
« no previous file with comments | « chrome/browser/extensions/image_loading_tracker.h ('k') | chrome/browser/ui/panels/panel.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698