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

Side by Side Diff: chrome/browser/views/tab_icon_view.h

Issue 18392: Fix some problems with scaled icons. This allows the TabIconView to automati... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 11 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
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 #ifndef CHROME_BROWSER_VIEW_TAB_ICON_VIEW_H__ 5 #ifndef CHROME_BROWSER_VIEW_TAB_ICON_VIEW_H__
6 #define CHROME_BROWSER_VIEW_TAB_ICON_VIEW_H__ 6 #define CHROME_BROWSER_VIEW_TAB_ICON_VIEW_H__
7 7
8 #include "chrome/views/view.h" 8 #include "chrome/views/view.h"
9 9
10 class TabContents; 10 class TabContents;
(...skipping 26 matching lines...) Expand all
37 // Set the throbber to the light style (for use on dark backgrounds). 37 // Set the throbber to the light style (for use on dark backgrounds).
38 void set_is_light(bool is_light) { is_light_ = is_light; } 38 void set_is_light(bool is_light) { is_light_ = is_light; }
39 39
40 // Overriden from View 40 // Overriden from View
41 virtual void Paint(ChromeCanvas* canvas); 41 virtual void Paint(ChromeCanvas* canvas);
42 virtual gfx::Size GetPreferredSize(); 42 virtual gfx::Size GetPreferredSize();
43 43
44 private: 44 private:
45 void PaintThrobber(ChromeCanvas* canvas); 45 void PaintThrobber(ChromeCanvas* canvas);
46 void PaintFavIcon(ChromeCanvas* canvas, const SkBitmap& bitmap); 46 void PaintFavIcon(ChromeCanvas* canvas, const SkBitmap& bitmap);
47 void PaintIcon(ChromeCanvas* canvas,
48 const SkBitmap& bitmap,
49 int src_x,
50 int src_y,
51 int src_w,
52 int src_h,
53 bool filter);
47 54
48 // Our model. 55 // Our model.
49 TabIconViewModel* model_; 56 TabIconViewModel* model_;
50 57
51 // Whether the throbber is running. 58 // Whether the throbber is running.
52 bool throbber_running_; 59 bool throbber_running_;
53 60
54 // Whether we should display our light or dark style. 61 // Whether we should display our light or dark style.
55 bool is_light_; 62 bool is_light_;
56 63
57 // Current frame of the throbber being painted. This is only used if 64 // Current frame of the throbber being painted. This is only used if
58 // throbber_running_ is true. 65 // throbber_running_ is true.
59 int throbber_frame_; 66 int throbber_frame_;
60 67
61 DISALLOW_EVIL_CONSTRUCTORS(TabIconView); 68 DISALLOW_EVIL_CONSTRUCTORS(TabIconView);
62 }; 69 };
63 70
64 #endif // CHROME_BROWSER_VIEW_TAB_ICON_VIEW_H__ 71 #endif // CHROME_BROWSER_VIEW_TAB_ICON_VIEW_H__
65 72
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/views/tab_icon_view.cc » ('j') | chrome/browser/views/tab_icon_view.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698