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

Unified Diff: views/controls/menu/menu_controller.cc

Issue 2862025: Canvas refactoring part 2.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 6 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 | « gfx/gfx.gyp ('k') | views/controls/menu/menu_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/controls/menu/menu_controller.cc
===================================================================
--- views/controls/menu/menu_controller.cc (revision 50452)
+++ views/controls/menu/menu_controller.cc (working copy)
@@ -9,7 +9,7 @@
#include "base/i18n/rtl.h"
#include "base/keyboard_codes.h"
#include "base/time.h"
-#include "gfx/canvas.h"
+#include "gfx/canvas_skia.h"
#include "views/controls/button/menu_button.h"
#include "views/controls/menu/menu_scroll_view_container.h"
#include "views/controls/menu/submenu_view.h"
@@ -469,12 +469,12 @@
gfx::Point press_loc(press_pt_);
View::ConvertPointToScreen(source->GetScrollViewContainer(), &press_loc);
View::ConvertPointToView(NULL, item, &press_loc);
- gfx::Canvas canvas(item->width(), item->height(), false);
- item->Paint(&canvas, true);
+ gfx::CanvasSkia canvas(item->width(), item->height(), false);
+ item->Paint(canvas.AsCanvas(), true);
OSExchangeData data;
item->GetDelegate()->WriteDragData(item, &data);
- drag_utils::SetDragImageOnDataObject(canvas, item->size(), press_loc,
+ drag_utils::SetDragImageOnDataObject(*canvas.AsCanvas(), item->size(), press_loc,
&data);
StopScrolling();
int drag_ops = item->GetDelegate()->GetDragOperations(item);
« no previous file with comments | « gfx/gfx.gyp ('k') | views/controls/menu/menu_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698