diff options
author | avi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-02-24 01:22:15 +0000 |
---|---|---|
committer | avi@chromium.org <avi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-02-24 01:22:15 +0000 |
commit | 8c3ba4d09e4d94decf1cb1759a0c58fa7459e6ef (patch) | |
tree | 678f0426ae32e7dc48c8572fa4e8d3c1cf360d80 /chrome/browser/cocoa/infobar_gradient_view.mm | |
parent | 9492e4abf1be2910ab72f300abb7e0f28118b434 (diff) | |
download | chromium_src-8c3ba4d09e4d94decf1cb1759a0c58fa7459e6ef.zip chromium_src-8c3ba4d09e4d94decf1cb1759a0c58fa7459e6ef.tar.gz chromium_src-8c3ba4d09e4d94decf1cb1759a0c58fa7459e6ef.tar.bz2 |
Next batch of changes to kill GTMTheme.
BUG=http://crbug.com/35554
TEST=no visible change in normal mode; incognito mode still being worked on
Review URL: http://codereview.chromium.org/652179
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@39825 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/cocoa/infobar_gradient_view.mm')
-rw-r--r-- | chrome/browser/cocoa/infobar_gradient_view.mm | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/chrome/browser/cocoa/infobar_gradient_view.mm b/chrome/browser/cocoa/infobar_gradient_view.mm index cba6574..6af8fbb 100644 --- a/chrome/browser/cocoa/infobar_gradient_view.mm +++ b/chrome/browser/cocoa/infobar_gradient_view.mm @@ -3,7 +3,9 @@ // found in the LICENSE file. #include "chrome/browser/cocoa/infobar_gradient_view.h" -#import "chrome/browser/cocoa/GTMTheme.h" + +#import "chrome/browser/browser_theme_provider.h" +#import "chrome/browser/cocoa/themed_window.h" const double kBackgroundColorTop[3] = {255.0 / 255.0, 242.0 / 255.0, 183.0 / 255.0}; @@ -43,8 +45,15 @@ const double kBackgroundColorBottom[3] = } - (NSColor*)strokeColor { - return [[self gtm_theme] strokeColorForStyle:GTMThemeStyleToolBar - state:[[self window] isKeyWindow]]; + ThemeProvider* themeProvider = [[self window] themeProvider]; + if (!themeProvider) + return [NSColor blackColor]; + + BOOL active = [[self window] isMainWindow]; + return themeProvider->GetNSColor( + active ? BrowserThemeProvider::COLOR_TOOLBAR_STROKE : + BrowserThemeProvider::COLOR_TOOLBAR_STROKE_INACTIVE, + true); } - (void)drawRect:(NSRect)rect { |