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 #include "base/mac/mac_util.h" | 10 #include "base/mac/mac_util.h" |
(...skipping 481 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
492 } | 492 } |
493 | 493 |
494 void BrowserWindowCocoa::ShowBookmarkBubble(const GURL& url, | 494 void BrowserWindowCocoa::ShowBookmarkBubble(const GURL& url, |
495 bool already_bookmarked) { | 495 bool already_bookmarked) { |
496 [controller_ showBookmarkBubbleForURL:url | 496 [controller_ showBookmarkBubbleForURL:url |
497 alreadyBookmarked:(already_bookmarked ? YES : NO)]; | 497 alreadyBookmarked:(already_bookmarked ? YES : NO)]; |
498 } | 498 } |
499 | 499 |
500 void BrowserWindowCocoa::ShowTranslateBubble( | 500 void BrowserWindowCocoa::ShowTranslateBubble( |
501 content::WebContents* contents, | 501 content::WebContents* contents, |
502 TranslateBubbleModel::ViewState view_state) { | 502 TranslateBubbleModel::ViewState view_state, |
| 503 TranslateErrors::Type error_type) { |
| 504 NOTIMPLEMENTED(); |
503 } | 505 } |
504 | 506 |
505 #if defined(ENABLE_ONE_CLICK_SIGNIN) | 507 #if defined(ENABLE_ONE_CLICK_SIGNIN) |
506 void BrowserWindowCocoa::ShowOneClickSigninBubble( | 508 void BrowserWindowCocoa::ShowOneClickSigninBubble( |
507 OneClickSigninBubbleType type, | 509 OneClickSigninBubbleType type, |
508 const string16& email, | 510 const string16& email, |
509 const string16& error_message, | 511 const string16& error_message, |
510 const StartSyncCallback& start_sync_callback) { | 512 const StartSyncCallback& start_sync_callback) { |
511 WebContents* web_contents = | 513 WebContents* web_contents = |
512 browser_->tab_strip_model()->GetActiveWebContents(); | 514 browser_->tab_strip_model()->GetActiveWebContents(); |
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
762 // further, both by another H, i.e. WebContentsView's height becomes | 764 // further, both by another H, i.e. WebContentsView's height becomes |
763 // A.height() + H and RenderWidgetHostView's height becomes A.height() + 2H. | 765 // A.height() + H and RenderWidgetHostView's height becomes A.height() + 2H. |
764 // Strangely, the RenderWidgetHostView for the previous navigation entry also | 766 // Strangely, the RenderWidgetHostView for the previous navigation entry also |
765 // gets enlarged by H. | 767 // gets enlarged by H. |
766 // I believe these "automatic" resizing are caused by setAutoresizingMask of | 768 // I believe these "automatic" resizing are caused by setAutoresizingMask of |
767 // of the cocoa view in WebContentsViewMac, which defeats the purpose of | 769 // of the cocoa view in WebContentsViewMac, which defeats the purpose of |
768 // WebContentsDelegate::GetSizeForNewRenderView i.e. to prevent resizing of | 770 // WebContentsDelegate::GetSizeForNewRenderView i.e. to prevent resizing of |
769 // RenderWidgetHostView in (2) and (3). | 771 // RenderWidgetHostView in (2) and (3). |
770 return 0; | 772 return 0; |
771 } | 773 } |
OLD | NEW |