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

Unified Diff: chrome/browser/cocoa/gradient_button_cell.mm

Issue 155151: Hook up the prefs for the optional home buttons and page/wrench buttons. Move... (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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/cocoa/gradient_button_cell.mm
===================================================================
--- chrome/browser/cocoa/gradient_button_cell.mm (revision 20018)
+++ chrome/browser/cocoa/gradient_button_cell.mm (working copy)
@@ -58,11 +58,18 @@
endingColor:end] autorelease];
}
+ // Stroke the borders and appropriate fill gradient. If we're borderless,
+ // the only time we want to draw the inner gradient is if we're highlighted.
[[NSColor colorWithCalibratedWhite:1.0 alpha:0.25] set];
- [outerPath stroke];
- [gradient drawInBezierPath:path angle:90.0];
- [[NSColor colorWithCalibratedWhite:0.0 alpha:0.15] set];
- [path stroke];
+ if ([self isBordered]) {
+ [outerPath stroke];
+ [gradient drawInBezierPath:path angle:90.0];
+ [[NSColor colorWithCalibratedWhite:0.0 alpha:0.15] set];
+ [path stroke];
+ } else {
+ if (highlighted)
+ [gradient drawInBezierPath:path angle:90.0];
+ }
if (type == kLeftButtonWithShadowType) {
NSRect borderRect, contentRect;
Property changes on: chrome/browser/cocoa/gradient_button_cell.mm
___________________________________________________________________
Name: svn:eol-style
+ LF

Powered by Google App Engine
This is Rietveld 408576698