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

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

Issue 181002: Reverting 24700. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 4 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/cocoa/toolbar_controller.h ('k') | chrome/browser/cocoa/toolbar_controller_unittest.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/cocoa/toolbar_controller.mm
===================================================================
--- chrome/browser/cocoa/toolbar_controller.mm (revision 24707)
+++ chrome/browser/cocoa/toolbar_controller.mm (working copy)
@@ -27,10 +27,10 @@
static NSString* const kStarredImageName = @"starred.pdf";
// Height of the toolbar in pixels when the bookmark bar is closed.
-static const float kBaseToolbarHeight = 36.0;
+static const float kBaseToolbarHeight = 39.0;
// Overlap (in pixels) between the toolbar and the bookmark bar.
-static const float kBookmarkBarOverlap = 7.0;
+static const float kBookmarkBarOverlap = 5.0;
@interface ToolbarController(Private)
- (void)initCommandStatus:(CommandUpdater*)commands;
@@ -113,8 +113,6 @@
// the "parent" view continues to work.
hasToolbar_ = YES;
- if (trackingArea_.get())
- [[self view] removeTrackingArea:trackingArea_.get()];
[super dealloc];
}
@@ -177,37 +175,8 @@
// the retain count of the location bar; use of the scoped object
// helps us remember to release it.
locationBarRetainer_.reset([locationBar_ retain]);
- trackingArea_.reset(
- [[NSTrackingArea alloc] initWithRect:NSZeroRect // Ignored
- options:NSTrackingMouseMoved |
- NSTrackingInVisibleRect |
- NSTrackingMouseEnteredAndExited |
- NSTrackingActiveAlways
- owner:self
- userInfo:nil]);
- [[self view] addTrackingArea:trackingArea_.get()];
}
-- (void)mouseExited:(NSEvent*)theEvent {
- [[hoveredButton_ cell] setMouseInside:NO animate:YES];
- hoveredButton_ = nil;
-}
-
-- (void)mouseMoved:(NSEvent *)theEvent {
- NSButton *targetView = (NSButton *)[[self view]
- hitTest:[theEvent locationInWindow]];
- if (![targetView isKindOfClass:[NSButton class]]) targetView = nil;
- if (hoveredButton_ != targetView) {
- [[hoveredButton_ cell] setMouseInside:NO animate:YES];
- [[targetView cell] setMouseInside:YES animate:YES];
- hoveredButton_ = targetView;
- }
-}
-
-- (void)mouseEntered:(NSEvent*)event {
- [self mouseMoved:event];
-}
-
- (void)resizeView:(NSView*)view newHeight:(float)height {
DCHECK(view == [bookmarkBarController_ view]);
« no previous file with comments | « chrome/browser/cocoa/toolbar_controller.h ('k') | chrome/browser/cocoa/toolbar_controller_unittest.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698