[Metrics] Make MetricsStateManager take a callback param to check if UMA is enabled.
[chromium-blink-merge.git] / chrome / browser / ui / cocoa / new_tab_button.h
blob97b8482274516d98ef3fd1bb386602547c73512d
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
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_COCOA_NEW_TAB_BUTTON
6 #define CHROME_BROWSER_UI_COCOA_NEW_TAB_BUTTON
8 #import <Cocoa/Cocoa.h>
10 // Overrides hit-test behavior to only accept clicks inside the image of the
11 // button, not just inside the bounding box. This could be abstracted to general
12 // use, but no other buttons are so irregularly shaped with respect to their
13 // bounding box.
15 @interface NewTabButton : NSButton
17 // Returns YES if the given point is over the button. |point| is in the
18 // superview's coordinate system.
19 - (BOOL)pointIsOverButton:(NSPoint)point;
20 @end
22 #endif // CHROME_BROWSER_UI_COCOA_NEW_TAB_BUTTON