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

Unified Diff: ui/views/controls/table/table_view_win.cc

Issue 10790128: Revert 147915 - Cleanup gfx::Canvas now that 10562027 has landed (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 5 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/native_menu_win.cc ('k') | ui/views/controls/tree/tree_view_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/table/table_view_win.cc
===================================================================
--- ui/views/controls/table/table_view_win.cc (revision 147935)
+++ ui/views/controls/table/table_view_win.cc (working copy)
@@ -809,11 +809,10 @@
// We create 2 phony images because we are going to switch images at every
// refresh in order to force a refresh of the icon area (somehow the clip
// rect does not include the icon).
- gfx::Canvas canvas(gfx::Size(kImageSize, kImageSize), ui::SCALE_FACTOR_100P,
- false);
+ gfx::Canvas canvas(gfx::Size(kImageSize, kImageSize), false);
{
- base::win::ScopedHICON empty_icon(IconUtil::CreateHICONFromSkBitmap(
- canvas.ExtractImageRep().sk_bitmap()));
+ base::win::ScopedHICON empty_icon(
+ IconUtil::CreateHICONFromSkBitmap(canvas.ExtractBitmap()));
ImageList_AddIcon(image_list, empty_icon);
ImageList_AddIcon(image_list, empty_icon);
}
@@ -1155,7 +1154,7 @@
HDC dc = GetDC(GetNativeControlHWND());
gfx::Font font = GetAltTextFont();
gfx::Rect bounds = GetAltTextBounds();
- gfx::Canvas canvas(bounds.size(), ui::SCALE_FACTOR_100P, false);
+ gfx::Canvas canvas(bounds.size(), false);
// Pad by 1 for halo.
canvas.DrawStringWithHalo(alt_text_, font, SK_ColorDKGRAY, SK_ColorWHITE, 1,
1, bounds.width() - 2, bounds.height() - 2,
@@ -1241,7 +1240,6 @@
if (IntersectRect(&intersection, &icon_rect, &client_rect)) {
gfx::Canvas canvas(gfx::Size(icon_rect.right - icon_rect.left,
icon_rect.bottom - icon_rect.top),
- ui::SCALE_FACTOR_100P,
false);
// It seems the state in nmcd.uItemState is not correct.
« no previous file with comments | « ui/views/controls/menu/native_menu_win.cc ('k') | ui/views/controls/tree/tree_view_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698