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

Side by Side Diff: chrome/browser/ui/cocoa/gradient_button_cell.h

Issue 1987203003: [Mac][Material Design] Add MD hover to bookmark items in menus. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@uploaded__bookmark_title_baseline_fix
Patch Set: Created 4 years, 7 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_UI_COCOA_GRADIENT_BUTTON_CELL_H_ 5 #ifndef CHROME_BROWSER_UI_COCOA_GRADIENT_BUTTON_CELL_H_
6 #define CHROME_BROWSER_UI_COCOA_GRADIENT_BUTTON_CELL_H_ 6 #define CHROME_BROWSER_UI_COCOA_GRADIENT_BUTTON_CELL_H_
7 7
8 #import <Cocoa/Cocoa.h> 8 #import <Cocoa/Cocoa.h>
9 9
10 #include "base/mac/scoped_nsobject.h" 10 #include "base/mac/scoped_nsobject.h"
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 // Actually fetches current mouse position and does a hit test. 107 // Actually fetches current mouse position and does a hit test.
108 - (BOOL)isMouseReallyInside; 108 - (BOOL)isMouseReallyInside;
109 109
110 // Returns the offset of the start of the text in the cell. 110 // Returns the offset of the start of the text in the cell.
111 - (CGFloat)textStartXOffset; 111 - (CGFloat)textStartXOffset;
112 112
113 // Defines the top offset of text within the cell. Used by drawTitle and can 113 // Defines the top offset of text within the cell. Used by drawTitle and can
114 // be overriden by objects that inherit this class for placement of text. 114 // be overriden by objects that inherit this class for placement of text.
115 - (int)verticalTextOffset; 115 - (int)verticalTextOffset;
116 116
117 // The amount by which the gradient button cell should nudge the path used to
118 // draw the hover (and pressed) state background path.
119 - (CGFloat)hoverBackgroundVerticalOffsetInControlView:(NSView*)controlView;
120
117 @property(assign, nonatomic) CGFloat hoverAlpha; 121 @property(assign, nonatomic) CGFloat hoverAlpha;
118 122
119 // An image that will be drawn after the normal content of the button cell, 123 // An image that will be drawn after the normal content of the button cell,
120 // overlaying it. Never themed. 124 // overlaying it. Never themed.
121 @property(retain, nonatomic) NSImage* overlayImage; 125 @property(retain, nonatomic) NSImage* overlayImage;
122 126
123 @end 127 @end
124 128
125 @interface GradientButtonCell(TestingAPI) 129 @interface GradientButtonCell(TestingAPI)
126 - (BOOL)isMouseInside; 130 - (BOOL)isMouseInside;
127 - (BOOL)pulsing; 131 - (BOOL)pulsing;
128 - (gradient_button_cell::PulseState)pulseState; 132 - (gradient_button_cell::PulseState)pulseState;
129 - (void)setPulseState:(gradient_button_cell::PulseState)pstate; 133 - (void)setPulseState:(gradient_button_cell::PulseState)pstate;
130 @end 134 @end
131 135
132 #endif // CHROME_BROWSER_UI_COCOA_GRADIENT_BUTTON_CELL_H_ 136 #endif // CHROME_BROWSER_UI_COCOA_GRADIENT_BUTTON_CELL_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/bookmarks/bookmark_button_cell.mm ('k') | chrome/browser/ui/cocoa/gradient_button_cell.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698