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

Unified Diff: chrome/browser/ui/cocoa/bookmarks/bookmark_button.h

Issue 2096303003: [Mac][Material Design] Improve bookmark folder menu performance. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2743
Patch Set: Created 4 years, 6 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
« no previous file with comments | « chrome/browser/ui/cocoa/bookmarks/bookmark_bar_folder_controller.mm ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/bookmarks/bookmark_button.h
diff --git a/chrome/browser/ui/cocoa/bookmarks/bookmark_button.h b/chrome/browser/ui/cocoa/bookmarks/bookmark_button.h
index 7fd62e78c552c094d5d9cf08ca5c4b590c3a2023..516a51dccef0c84aed2f8c8c52e8c028a5c32b23 100644
--- a/chrome/browser/ui/cocoa/bookmarks/bookmark_button.h
+++ b/chrome/browser/ui/cocoa/bookmarks/bookmark_button.h
@@ -28,8 +28,13 @@ class BookmarkNode;
// Bookmark buttons pass mouseEntered: and mouseExited: events to
// their delegate. This allows the delegate to decide (for example)
// which one, if any, should perform a hover-open.
-- (void)mouseEnteredButton:(id)button event:(NSEvent*)event;
-- (void)mouseExitedButton:(id)button event:(NSEvent*)event;
+//
+// mouseEnteredButton:event: is optimized to act only if the mouse is actually
+// within the button's bounds at the time of the call (with a fast moving mouse,
+// -isMouseReallyInside might return NO). Passing nil for |event| disables this
+// optimization, useful for unit testing.
+- (void)mouseEnteredButton:(BookmarkButton*)button event:(NSEvent*)event;
+- (void)mouseExitedButton:(BookmarkButton*)button event:(NSEvent*)event;
// Returns YES if a drag operation should lock the fullscreen overlay bar
// visibility before starting. For example, dragging a bookmark button should
« no previous file with comments | « chrome/browser/ui/cocoa/bookmarks/bookmark_bar_folder_controller.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698