Index: chrome/browser/ui/gtk/location_bar_view_gtk.cc |
diff --git a/chrome/browser/ui/gtk/location_bar_view_gtk.cc b/chrome/browser/ui/gtk/location_bar_view_gtk.cc |
index a270455f1618b99819db0d6f7701bbbd0c482856..c18547eb964070723728fa00c5b90079e1af7e67 100644 |
--- a/chrome/browser/ui/gtk/location_bar_view_gtk.cc |
+++ b/chrome/browser/ui/gtk/location_bar_view_gtk.cc |
@@ -1793,9 +1793,9 @@ void LocationBarViewGtk::PageActionViewGtk::UpdateVisibility( |
page_action_->GetTitle(current_tab_id_).c_str()); |
// Set the image. |
- gfx::Image icon = page_action_->GetIcon(current_tab_id_); |
- if (!icon.IsEmpty()) { |
- GdkPixbuf* pixbuf = icon.ToGdkPixbuf(); |
+ gfx::ImageSkia icon = page_action_->GetIcon(current_tab_id_); |
+ if (!icon.empty()) { |
+ GdkPixbuf* pixbuf = gfx::GdkPixbufFromSkBitmap(*icon.bitmap()); |
DCHECK(pixbuf); |
gtk_image_set_from_pixbuf(GTK_IMAGE(image_.get()), pixbuf); |
} |
@@ -1828,10 +1828,13 @@ void LocationBarViewGtk::PageActionViewGtk::OnImageLoaded( |
// Map the index of the loaded image back to its name. If we ever get an |
// index greater than the number of icons, it must be the default icon. |
- if (index < static_cast<int>(page_action_->icon_paths()->size())) |
- page_action_->CacheIcon(page_action_->icon_paths()->at(index), image); |
- else |
- page_action_->CacheIcon(page_action_->default_icon_path(), image); |
+ if (index < static_cast<int>(page_action_->icon_paths()->size())) { |
+ page_action_->CacheIcon(page_action_->icon_paths()->at(index), |
+ *image.ToImageSkia()); |
+ } else { |
+ page_action_->CacheIcon(page_action_->default_icon_path(), |
+ *image.ToImageSkia()); |
+ } |
// If we have no owner, that means this class is still being constructed. |
TabContents* tab_contents = owner_ ? owner_->GetTabContents() : NULL; |