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

Side by Side Diff: chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm

Issue 10885024: Integrate Chrome To Mobile with Action Box UI. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Disable ShowChromeToMobileBubble on GTK. Created 8 years, 3 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 | Annotate | Revision Log
OLDNEW
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
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
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
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698