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

Side by Side Diff: chrome/browser/ui/cocoa/browser_window_cocoa.mm

Issue 13139004: Deprecate Browser::TYPE_PANEL (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 8 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 #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 431 matching lines...) Expand 10 before | Expand all | Expand 10 after
442 browser_->SupportsWindowFeature(Browser::FEATURE_LOCATIONBAR); 442 browser_->SupportsWindowFeature(Browser::FEATURE_LOCATIONBAR);
443 } 443 }
444 444
445 gfx::Rect BrowserWindowCocoa::GetRootWindowResizerRect() const { 445 gfx::Rect BrowserWindowCocoa::GetRootWindowResizerRect() const {
446 if (IsDownloadShelfVisible()) 446 if (IsDownloadShelfVisible())
447 return gfx::Rect(); 447 return gfx::Rect();
448 NSRect tabRect = [controller_ selectedTabGrowBoxRect]; 448 NSRect tabRect = [controller_ selectedTabGrowBoxRect];
449 return gfx::Rect(NSRectToCGRect(tabRect)); 449 return gfx::Rect(NSRectToCGRect(tabRect));
450 } 450 }
451 451
452 bool BrowserWindowCocoa::IsPanel() const {
453 return false;
454 }
455
456 // This is called from Browser, which in turn is called directly from 452 // This is called from Browser, which in turn is called directly from
457 // a menu option. All we do here is set a preference. The act of 453 // a menu option. All we do here is set a preference. The act of
458 // setting the preference sends notifications to all windows who then 454 // setting the preference sends notifications to all windows who then
459 // know what to do. 455 // know what to do.
460 void BrowserWindowCocoa::ToggleBookmarkBar() { 456 void BrowserWindowCocoa::ToggleBookmarkBar() {
461 chrome::ToggleBookmarkBarWhenVisible(browser_->profile()); 457 chrome::ToggleBookmarkBarWhenVisible(browser_->profile());
462 } 458 }
463 459
464 void BrowserWindowCocoa::AddFindBar( 460 void BrowserWindowCocoa::AddFindBar(
465 FindBarCocoaController* find_bar_cocoa_controller) { 461 FindBarCocoaController* find_bar_cocoa_controller) {
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after
703 PasswordGenerationBubbleController* controller = 699 PasswordGenerationBubbleController* controller =
704 [[PasswordGenerationBubbleController alloc] 700 [[PasswordGenerationBubbleController alloc]
705 initWithWindow:browser_->window()->GetNativeWindow() 701 initWithWindow:browser_->window()->GetNativeWindow()
706 anchoredAt:point 702 anchoredAt:point
707 renderViewHost:web_contents->GetRenderViewHost() 703 renderViewHost:web_contents->GetRenderViewHost()
708 passwordManager:PasswordManager::FromWebContents(web_contents) 704 passwordManager:PasswordManager::FromWebContents(web_contents)
709 usingGenerator:password_generator 705 usingGenerator:password_generator
710 forForm:form]; 706 forForm:form];
711 [controller showWindow:nil]; 707 [controller showWindow:nil];
712 } 708 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698