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

Unified Diff: chrome/browser/views/location_bar_view.h

Issue 195050: Linux: implement Page Actions support. (Closed)
Patch Set: comment clarification Created 11 years, 3 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/image_loading_tracker.cc ('k') | chrome/browser/views/location_bar_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/views/location_bar_view.h
diff --git a/chrome/browser/views/location_bar_view.h b/chrome/browser/views/location_bar_view.h
index 919821f845385746e81d9cce57ef1658505a44cd..3fdfcdcead11aab2ed2bbe0a29562c1768400d2c 100644
--- a/chrome/browser/views/location_bar_view.h
+++ b/chrome/browser/views/location_bar_view.h
@@ -11,6 +11,7 @@
#include "app/gfx/font.h"
#include "base/gfx/rect.h"
#include "chrome/browser/autocomplete/autocomplete_edit.h"
+#include "chrome/browser/image_loading_tracker.h"
#include "chrome/browser/location_bar.h"
#include "chrome/browser/tab_contents/tab_contents.h"
#include "chrome/browser/toolbar_model.h"
@@ -333,7 +334,8 @@ class LocationBarView : public LocationBar,
// PageActionImageView is used to display the icon for a given PageAction
// and notify the extension when the icon is clicked.
- class PageActionImageView : public LocationBarImageView {
+ class PageActionImageView : public LocationBarImageView,
+ public ImageLoadingTracker::Observer {
public:
PageActionImageView(
LocationBarView* owner, Profile* profile,
@@ -346,20 +348,15 @@ class LocationBarView : public LocationBar,
// Overridden from LocationBarImageView.
virtual void ShowInfoBubble();
+ // Overridden from ImageLoadingTracker.
+ virtual void OnImageLoaded(SkBitmap* image, size_t index);
+
// Called to notify the PageAction that it should determine whether to be
// visible or hidden. |contents| is the TabContents that is active, |url|
// is the current page URL.
void UpdateVisibility(TabContents* contents, GURL url);
- // A callback for when the image has loaded.
- void OnImageLoaded(SkBitmap* image, size_t index);
-
private:
- // We load the images for the PageActions on the file thread. These tasks
- // help with that.
- class LoadImageTask;
- class ImageLoadingTracker;
-
// The location bar view that owns us.
LocationBarView* owner_;
@@ -431,10 +428,6 @@ class LocationBarView : public LocationBar,
// Delete all page action views that we have created.
void DeletePageActionViews();
- // Retrieves a vector of all page actions, irrespective of which
- // extension they belong to.
- std::vector<PageAction*> GetPageActions();
-
// Update the views for the Page Actions, to reflect state changes for
// PageActions.
void RefreshPageActionViews();
« no previous file with comments | « chrome/browser/image_loading_tracker.cc ('k') | chrome/browser/views/location_bar_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698