| 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 #include "chrome/browser/ui/cocoa/browser_window_cocoa.h" | 5 #include "chrome/browser/ui/cocoa/browser_window_cocoa.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #import "base/mac/sdk_forward_declarations.h" | 10 #import "base/mac/sdk_forward_declarations.h" |
| (...skipping 832 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 843 const signin::ManageAccountsParams& manage_accounts_params) { | 843 const signin::ManageAccountsParams& manage_accounts_params) { |
| 844 AvatarBaseController* controller = [controller_ avatarButtonController]; | 844 AvatarBaseController* controller = [controller_ avatarButtonController]; |
| 845 NSView* anchor = [controller buttonView]; | 845 NSView* anchor = [controller buttonView]; |
| 846 if ([anchor isHiddenOrHasHiddenAncestor]) | 846 if ([anchor isHiddenOrHasHiddenAncestor]) |
| 847 anchor = [[controller_ toolbarController] wrenchButton]; | 847 anchor = [[controller_ toolbarController] wrenchButton]; |
| 848 [controller showAvatarBubbleAnchoredAt:anchor | 848 [controller showAvatarBubbleAnchoredAt:anchor |
| 849 withMode:mode | 849 withMode:mode |
| 850 withServiceType:manage_accounts_params.service_type]; | 850 withServiceType:manage_accounts_params.service_type]; |
| 851 } | 851 } |
| 852 | 852 |
| 853 void BrowserWindowCocoa::ShowModalSigninWindow(AvatarBubbleMode mode) { |
| 854 NOTREACHED(); |
| 855 } |
| 856 void BrowserWindowCocoa::CloseModalSigninWindow() { |
| 857 NOTREACHED(); |
| 858 } |
| 859 |
| 853 int | 860 int |
| 854 BrowserWindowCocoa::GetRenderViewHeightInsetWithDetachedBookmarkBar() { | 861 BrowserWindowCocoa::GetRenderViewHeightInsetWithDetachedBookmarkBar() { |
| 855 if (browser_->bookmark_bar_state() != BookmarkBar::DETACHED) | 862 if (browser_->bookmark_bar_state() != BookmarkBar::DETACHED) |
| 856 return 0; | 863 return 0; |
| 857 return 40; | 864 return 40; |
| 858 } | 865 } |
| 859 | 866 |
| 860 void BrowserWindowCocoa::ExecuteExtensionCommand( | 867 void BrowserWindowCocoa::ExecuteExtensionCommand( |
| 861 const extensions::Extension* extension, | 868 const extensions::Extension* extension, |
| 862 const extensions::Command& command) { | 869 const extensions::Command& command) { |
| (...skipping 15 matching lines...) Expand all Loading... |
| 878 void BrowserWindowCocoa::UnhideDownloadShelf() { | 885 void BrowserWindowCocoa::UnhideDownloadShelf() { |
| 879 GetDownloadShelf()->Unhide(); | 886 GetDownloadShelf()->Unhide(); |
| 880 } | 887 } |
| 881 | 888 |
| 882 void BrowserWindowCocoa::HideDownloadShelf() { | 889 void BrowserWindowCocoa::HideDownloadShelf() { |
| 883 GetDownloadShelf()->Hide(); | 890 GetDownloadShelf()->Hide(); |
| 884 StatusBubble* statusBubble = GetStatusBubble(); | 891 StatusBubble* statusBubble = GetStatusBubble(); |
| 885 if (statusBubble) | 892 if (statusBubble) |
| 886 statusBubble->Hide(); | 893 statusBubble->Hide(); |
| 887 } | 894 } |
| OLD | NEW |