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

Side by Side Diff: chrome/browser/browser_theme_provider.h

Issue 159305: First pass at NNTP theming.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/app/theme/theme_resources.grd ('k') | chrome/browser/browser_theme_provider.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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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_BROWSER_THEME_PROVIDER_H_ 5 #ifndef CHROME_BROWSER_BROWSER_THEME_PROVIDER_H_
6 #define CHROME_BROWSER_BROWSER_THEME_PROVIDER_H_ 6 #define CHROME_BROWSER_BROWSER_THEME_PROVIDER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 static const char* kTintButtons; 50 static const char* kTintButtons;
51 static const char* kTintFrame; 51 static const char* kTintFrame;
52 static const char* kTintFrameInactive; 52 static const char* kTintFrameInactive;
53 static const char* kTintFrameIncognito; 53 static const char* kTintFrameIncognito;
54 static const char* kTintFrameIncognitoInactive; 54 static const char* kTintFrameIncognitoInactive;
55 static const char* kTintBackgroundTab; 55 static const char* kTintBackgroundTab;
56 56
57 // Strings used by themes to identify miscellaneous numerical properties. 57 // Strings used by themes to identify miscellaneous numerical properties.
58 static const char* kDisplayPropertyNTPAlignment; 58 static const char* kDisplayPropertyNTPAlignment;
59 static const char* kDisplayPropertyNTPTiling; 59 static const char* kDisplayPropertyNTPTiling;
60 static const char* kDisplayPropertyNTPInverseLogo;
60 61
61 // Strings used in alignment properties. 62 // Strings used in alignment properties.
62 static const char* kAlignmentTop; 63 static const char* kAlignmentTop;
63 static const char* kAlignmentBottom; 64 static const char* kAlignmentBottom;
64 static const char* kAlignmentLeft; 65 static const char* kAlignmentLeft;
65 static const char* kAlignmentRight; 66 static const char* kAlignmentRight;
66 67
67 // Strings used in tiling properties. 68 // Strings used in tiling properties.
68 static const char* kTilingNoRepeat; 69 static const char* kTilingNoRepeat;
69 static const char* kTilingRepeatX; 70 static const char* kTilingRepeatX;
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 COLOR_NTP_SECTION_LINK, 117 COLOR_NTP_SECTION_LINK,
117 COLOR_CONTROL_BACKGROUND, 118 COLOR_CONTROL_BACKGROUND,
118 COLOR_BUTTON_BACKGROUND, 119 COLOR_BUTTON_BACKGROUND,
119 TINT_BUTTONS, 120 TINT_BUTTONS,
120 TINT_FRAME, 121 TINT_FRAME,
121 TINT_FRAME_INACTIVE, 122 TINT_FRAME_INACTIVE,
122 TINT_FRAME_INCOGNITO, 123 TINT_FRAME_INCOGNITO,
123 TINT_FRAME_INCOGNITO_INACTIVE, 124 TINT_FRAME_INCOGNITO_INACTIVE,
124 TINT_BACKGROUND_TAB, 125 TINT_BACKGROUND_TAB,
125 NTP_BACKGROUND_ALIGNMENT, 126 NTP_BACKGROUND_ALIGNMENT,
126 NTP_BACKGROUND_TILING 127 NTP_BACKGROUND_TILING,
128 NTP_LOGO_ALTERNATE
127 }; 129 };
128 130
129 // A bitfield mask for alignments. 131 // A bitfield mask for alignments.
130 typedef enum { 132 typedef enum {
131 ALIGN_CENTER = 0x0, 133 ALIGN_CENTER = 0x0,
132 ALIGN_LEFT = 0x1, 134 ALIGN_LEFT = 0x1,
133 ALIGN_TOP = 0x2, 135 ALIGN_TOP = 0x2,
134 ALIGN_RIGHT = 0x4, 136 ALIGN_RIGHT = 0x4,
135 ALIGN_BOTTOM = 0x8, 137 ALIGN_BOTTOM = 0x8,
136 } AlignmentMasks; 138 } AlignmentMasks;
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 // Sets an individual tint value. 192 // Sets an individual tint value.
191 void SetTint(const char* id, const skia::HSL& tint); 193 void SetTint(const char* id, const skia::HSL& tint);
192 194
193 // Generate any frame colors that weren't specified. 195 // Generate any frame colors that weren't specified.
194 void GenerateFrameColors(); 196 void GenerateFrameColors();
195 197
196 // Generate any frame images that weren't specified. The resulting images 198 // Generate any frame images that weren't specified. The resulting images
197 // will be stored in our cache. 199 // will be stored in our cache.
198 void GenerateFrameImages(); 200 void GenerateFrameImages();
199 201
202 // Generate any tab images that weren't specified. The resulting images
203 // will be stored in our cache.
204 void GenerateTabImages();
205
200 // Clears all the override fields and saves the dictionary. 206 // Clears all the override fields and saves the dictionary.
201 void ClearAllThemeData(); 207 void ClearAllThemeData();
202 208
203 // Load theme data from preferences. 209 // Load theme data from preferences.
204 virtual void LoadThemePrefs(); 210 virtual void LoadThemePrefs();
205 211
206 // Let all the browser views know that themes have changed. 212 // Let all the browser views know that themes have changed.
207 virtual void NotifyThemeChanged(); 213 virtual void NotifyThemeChanged();
208 214
209 // Loads a bitmap from the theme, which may be tinted or 215 // Loads a bitmap from the theme, which may be tinted or
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 306
301 ImageMap images_; 307 ImageMap images_;
302 ColorMap colors_; 308 ColorMap colors_;
303 TintMap tints_; 309 TintMap tints_;
304 DisplayPropertyMap display_properties_; 310 DisplayPropertyMap display_properties_;
305 311
306 DISALLOW_COPY_AND_ASSIGN(BrowserThemeProvider); 312 DISALLOW_COPY_AND_ASSIGN(BrowserThemeProvider);
307 }; 313 };
308 314
309 #endif // CHROME_BROWSER_BROWSER_THEME_PROVIDER_H_ 315 #endif // CHROME_BROWSER_BROWSER_THEME_PROVIDER_H_
OLDNEW
« no previous file with comments | « chrome/app/theme/theme_resources.grd ('k') | chrome/browser/browser_theme_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698