| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #import "chrome/browser/ui/cocoa/toolbar/toolbar_controller.h" | 5 #import "chrome/browser/ui/cocoa/toolbar/toolbar_controller.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/mac/bundle_locations.h" | 9 #include "base/mac/bundle_locations.h" |
| 10 #include "base/mac/mac_util.h" | 10 #include "base/mac/mac_util.h" |
| (...skipping 699 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 710 [NSAnimationContext beginGrouping]; | 710 [NSAnimationContext beginGrouping]; |
| 711 [[NSAnimationContext currentContext] setDuration:kAnimationDuration]; | 711 [[NSAnimationContext currentContext] setDuration:kAnimationDuration]; |
| 712 [[locationBar_ animator] setFrame:locationFrame]; | 712 [[locationBar_ animator] setFrame:locationFrame]; |
| 713 [NSAnimationContext endGrouping]; | 713 [NSAnimationContext endGrouping]; |
| 714 } | 714 } |
| 715 | 715 |
| 716 - (NSPoint)bookmarkBubblePoint { | 716 - (NSPoint)bookmarkBubblePoint { |
| 717 return locationBarView_->GetBookmarkBubblePoint(); | 717 return locationBarView_->GetBookmarkBubblePoint(); |
| 718 } | 718 } |
| 719 | 719 |
| 720 - (NSPoint)chromeToMobileBubblePoint { | |
| 721 return locationBarView_->GetChromeToMobileBubblePoint(); | |
| 722 } | |
| 723 | |
| 724 - (CGFloat)desiredHeightForCompression:(CGFloat)compressByHeight { | 720 - (CGFloat)desiredHeightForCompression:(CGFloat)compressByHeight { |
| 725 // With no toolbar, just ignore the compression. | 721 // With no toolbar, just ignore the compression. |
| 726 return hasToolbar_ ? kBaseToolbarHeight - compressByHeight : | 722 return hasToolbar_ ? kBaseToolbarHeight - compressByHeight : |
| 727 NSHeight([locationBar_ frame]); | 723 NSHeight([locationBar_ frame]); |
| 728 } | 724 } |
| 729 | 725 |
| 730 - (void)setDividerOpacity:(CGFloat)opacity { | 726 - (void)setDividerOpacity:(CGFloat)opacity { |
| 731 BackgroundGradientView* view = [self backgroundGradientView]; | 727 BackgroundGradientView* view = [self backgroundGradientView]; |
| 732 [view setShowsDivider:(opacity > 0 ? YES : NO)]; | 728 [view setShowsDivider:(opacity > 0 ? YES : NO)]; |
| 733 | 729 |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 800 - (void)hideDropURLsIndicatorInView:(NSView*)view { | 796 - (void)hideDropURLsIndicatorInView:(NSView*)view { |
| 801 // Do nothing. | 797 // Do nothing. |
| 802 } | 798 } |
| 803 | 799 |
| 804 // (URLDropTargetController protocol) | 800 // (URLDropTargetController protocol) |
| 805 - (BOOL)isUnsupportedDropData:(id<NSDraggingInfo>)info { | 801 - (BOOL)isUnsupportedDropData:(id<NSDraggingInfo>)info { |
| 806 return drag_util::IsUnsupportedDropData(profile_, info); | 802 return drag_util::IsUnsupportedDropData(profile_, info); |
| 807 } | 803 } |
| 808 | 804 |
| 809 @end | 805 @end |
| OLD | NEW |