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

Unified Diff: chrome/browser/ui/gtk/download/download_item_gtk.cc

Issue 6879013: skia::PlatformCanvas is being deprecated. Going forward we will use gfx::Canvas wherever we need ... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 8 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/gtk/browser_toolbar_gtk.cc ('k') | chrome/browser/ui/gtk/gtk_theme_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/gtk/download/download_item_gtk.cc
===================================================================
--- chrome/browser/ui/gtk/download/download_item_gtk.cc (revision 82144)
+++ chrome/browser/ui/gtk/download/download_item_gtk.cc (working copy)
@@ -859,21 +859,22 @@
gboolean DownloadItemGtk::OnProgressAreaExpose(GtkWidget* widget,
GdkEventExpose* event) {
// Create a transparent canvas.
- gfx::CanvasSkiaPaint canvas(event, false);
+ gfx::CanvasSkiaPaint canvas_paint(event, false);
+ gfx::Canvas* canvas = canvas_paint.AsCanvas();
if (complete_animation_.is_animating()) {
if (get_download()->IsInterrupted()) {
- download_util::PaintDownloadInterrupted(&canvas,
+ download_util::PaintDownloadInterrupted(canvas,
widget->allocation.x, widget->allocation.y,
complete_animation_.GetCurrentValue(),
download_util::SMALL);
} else {
- download_util::PaintDownloadComplete(&canvas,
+ download_util::PaintDownloadComplete(canvas,
widget->allocation.x, widget->allocation.y,
complete_animation_.GetCurrentValue(),
download_util::SMALL);
}
} else if (!get_download()->IsCancelled()) {
- download_util::PaintDownloadProgress(&canvas,
+ download_util::PaintDownloadProgress(canvas,
widget->allocation.x, widget->allocation.y,
progress_angle_,
get_download()->PercentComplete(),
@@ -885,7 +886,7 @@
// there is no need to use the chromium-specific default download item icon.
if (icon_small_) {
const int offset = download_util::kSmallProgressIconOffset;
- canvas.DrawBitmapInt(*icon_small_,
+ canvas->DrawBitmapInt(*icon_small_,
widget->allocation.x + offset, widget->allocation.y + offset);
}
« no previous file with comments | « chrome/browser/ui/gtk/browser_toolbar_gtk.cc ('k') | chrome/browser/ui/gtk/gtk_theme_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698