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

Side by Side Diff: ui/views/painter.cc

Issue 1971463002: Get rid of some lingering MD-specific raster assets. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: msw review Created 4 years, 7 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 unified diff | Download patch
« no previous file with comments | « chrome/chrome_browser_ui.gypi ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/views/painter.h" 5 #include "ui/views/painter.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after
251 Painter::Painter() { 251 Painter::Painter() {
252 } 252 }
253 253
254 Painter::~Painter() { 254 Painter::~Painter() {
255 } 255 }
256 256
257 // static 257 // static
258 void Painter::PaintPainterAt(gfx::Canvas* canvas, 258 void Painter::PaintPainterAt(gfx::Canvas* canvas,
259 Painter* painter, 259 Painter* painter,
260 const gfx::Rect& rect) { 260 const gfx::Rect& rect) {
261 DCHECK(canvas && painter); 261 DCHECK(canvas);
262 DCHECK(painter);
262 canvas->Save(); 263 canvas->Save();
263 canvas->Translate(rect.OffsetFromOrigin()); 264 canvas->Translate(rect.OffsetFromOrigin());
264 painter->Paint(canvas, rect.size()); 265 painter->Paint(canvas, rect.size());
265 canvas->Restore(); 266 canvas->Restore();
266 } 267 }
267 268
268 // static 269 // static
269 void Painter::PaintFocusPainter(View* view, 270 void Painter::PaintFocusPainter(View* view,
270 gfx::Canvas* canvas, 271 gfx::Canvas* canvas,
271 Painter* focus_painter) { 272 Painter* focus_painter) {
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
358 canvas->DrawImageInt(*images_[LEFT], 0, 0); 359 canvas->DrawImageInt(*images_[LEFT], 0, 0);
359 canvas->DrawImageInt(*images_[RIGHT], size.width() - images_[RIGHT]->width(), 360 canvas->DrawImageInt(*images_[RIGHT], size.width() - images_[RIGHT]->width(),
360 0); 361 0);
361 canvas->TileImageInt( 362 canvas->TileImageInt(
362 *images_[CENTER], images_[LEFT]->width(), 0, 363 *images_[CENTER], images_[LEFT]->width(), 0,
363 size.width() - images_[LEFT]->width() - images_[RIGHT]->width(), 364 size.width() - images_[LEFT]->width() - images_[RIGHT]->width(),
364 images_[LEFT]->height()); 365 images_[LEFT]->height());
365 } 366 }
366 367
367 } // namespace views 368 } // namespace views
OLDNEW
« no previous file with comments | « chrome/chrome_browser_ui.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698