OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "chrome/browser/cocoa/gradient_button_cell.h" | 5 #include "chrome/browser/cocoa/gradient_button_cell.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #import "base/scoped_nsobject.h" | 8 #import "base/scoped_nsobject.h" |
9 #import "chrome/browser/browser_theme_provider.h" | |
10 #import "chrome/browser/cocoa/image_utils.h" | 9 #import "chrome/browser/cocoa/image_utils.h" |
11 #import "chrome/browser/cocoa/themed_window.h" | 10 #import "chrome/browser/cocoa/themed_window.h" |
| 11 #import "chrome/browser/themes/browser_theme_provider.h" |
12 #include "grit/theme_resources.h" | 12 #include "grit/theme_resources.h" |
13 #import "third_party/GTM/AppKit/GTMNSColor+Luminance.h" | 13 #import "third_party/GTM/AppKit/GTMNSColor+Luminance.h" |
14 | 14 |
15 @interface GradientButtonCell (Private) | 15 @interface GradientButtonCell (Private) |
16 - (void)sharedInit; | 16 - (void)sharedInit; |
17 | 17 |
18 // Get drawing parameters for a given cell frame in a given view. The inner | 18 // Get drawing parameters for a given cell frame in a given view. The inner |
19 // frame is the one required by |-drawInteriorWithFrame:inView:|. The inner and | 19 // frame is the one required by |-drawInteriorWithFrame:inView:|. The inner and |
20 // outer paths are the ones required by |-drawBorderAndFillForTheme:...|. The | 20 // outer paths are the ones required by |-drawBorderAndFillForTheme:...|. The |
21 // outer path also gives the area in which to clip. Any of the |return...| | 21 // outer path also gives the area in which to clip. Any of the |return...| |
(...skipping 684 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
706 NSBezierPath* boundingPath = nil; | 706 NSBezierPath* boundingPath = nil; |
707 [self getDrawParamsForFrame:cellFrame | 707 [self getDrawParamsForFrame:cellFrame |
708 inView:controlView | 708 inView:controlView |
709 innerFrame:NULL | 709 innerFrame:NULL |
710 innerPath:NULL | 710 innerPath:NULL |
711 clipPath:&boundingPath]; | 711 clipPath:&boundingPath]; |
712 return boundingPath; | 712 return boundingPath; |
713 } | 713 } |
714 | 714 |
715 @end | 715 @end |
OLD | NEW |