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

Side by Side Diff: ash/launcher/launcher.cc

Issue 9332006: ui/gfx: Make the first version of Canvas::TileImageInt take a gfx::Rect. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: put back the Peter's nits Created 8 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/ntp_background_util.cc » ('j') | 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 "ash/launcher/launcher.h" 5 #include "ash/launcher/launcher.h"
6 6
7 #include "ash/launcher/launcher_model.h" 7 #include "ash/launcher/launcher_model.h"
8 #include "ash/launcher/launcher_view.h" 8 #include "ash/launcher/launcher_view.h"
9 #include "ash/shell.h" 9 #include "ash/shell.h"
10 #include "ash/shell_delegate.h" 10 #include "ash/shell_delegate.h"
(...skipping 14 matching lines...) Expand all
25 25
26 // Used to draw the background of the shelf. 26 // Used to draw the background of the shelf.
27 class ShelfPainter : public views::Painter { 27 class ShelfPainter : public views::Painter {
28 public: 28 public:
29 ShelfPainter() { 29 ShelfPainter() {
30 ResourceBundle& rb = ResourceBundle::GetSharedInstance(); 30 ResourceBundle& rb = ResourceBundle::GetSharedInstance();
31 image_ = *rb.GetImageNamed(IDR_AURA_LAUNCHER_BACKGROUND).ToSkBitmap(); 31 image_ = *rb.GetImageNamed(IDR_AURA_LAUNCHER_BACKGROUND).ToSkBitmap();
32 } 32 }
33 33
34 virtual void Paint(int w, int h, gfx::Canvas* canvas) OVERRIDE { 34 virtual void Paint(int w, int h, gfx::Canvas* canvas) OVERRIDE {
35 canvas->TileImageInt(image_, 0, 0, w, h); 35 canvas->TileImage(image_, gfx::Rect(0, 0, w, h));
36 } 36 }
37 37
38 private: 38 private:
39 SkBitmap image_; 39 SkBitmap image_;
40 40
41 DISALLOW_COPY_AND_ASSIGN(ShelfPainter); 41 DISALLOW_COPY_AND_ASSIGN(ShelfPainter);
42 }; 42 };
43 43
44 } // namespace 44 } // namespace
45 45
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 135
136 void Launcher::SetStatusWidth(int width) { 136 void Launcher::SetStatusWidth(int width) {
137 delegate_view_->SetStatusWidth(width); 137 delegate_view_->SetStatusWidth(width);
138 } 138 }
139 139
140 int Launcher::GetStatusWidth() { 140 int Launcher::GetStatusWidth() {
141 return delegate_view_->status_width(); 141 return delegate_view_->status_width();
142 } 142 }
143 143
144 } // namespace ash 144 } // namespace ash
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ntp_background_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698