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

Unified Diff: ui/views/controls/textfield/textfield.cc

Issue 2877483003: Implements core logic for Pixel Canvas (Closed)
Patch Set: Sync with ToT Created 3 years, 4 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 | « ui/views/controls/menu/submenu_view.cc ('k') | ui/views/paint_info.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/textfield/textfield.cc
diff --git a/ui/views/controls/textfield/textfield.cc b/ui/views/controls/textfield/textfield.cc
index 5c562f17a3797ab1b5f05efff1aa9ae10b34bd8f..422b4f1e6cef101efccdc46f290509d8e09cfd28 100644
--- a/ui/views/controls/textfield/textfield.cc
+++ b/ui/views/controls/textfield/textfield.cc
@@ -1115,8 +1115,11 @@ void Textfield::WriteDragDataForView(View* sender,
if (!ui::XVisualManager::GetInstance()->ArgbVisualAvailable())
color = GetBackgroundColor();
#endif
- label.Paint(
- ui::CanvasPainter(&bitmap, label.size(), raster_scale, color).context());
+ label.Paint(PaintInfo::CreateRootPaintInfo(
+ ui::CanvasPainter(&bitmap, label.size(), raster_scale, color,
+ GetWidget()->GetCompositor()->is_pixel_canvas())
+ .context(),
+ label.size()));
const gfx::Vector2d kOffset(-15, 0);
gfx::ImageSkia image(gfx::ImageSkiaRep(bitmap, raster_scale));
data->provider().SetDragImage(image, kOffset);
« no previous file with comments | « ui/views/controls/menu/submenu_view.cc ('k') | ui/views/paint_info.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698