| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
| 10 #include "base/sys_string_conversions.h" | 10 #include "base/sys_string_conversions.h" |
| (...skipping 310 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 321 DownloadShelf* BrowserWindowCocoa::GetDownloadShelf() { | 321 DownloadShelf* BrowserWindowCocoa::GetDownloadShelf() { |
| 322 DownloadShelfController* shelfController = [controller_ downloadShelf]; | 322 DownloadShelfController* shelfController = [controller_ downloadShelf]; |
| 323 return [shelfController bridge]; | 323 return [shelfController bridge]; |
| 324 } | 324 } |
| 325 | 325 |
| 326 void BrowserWindowCocoa::ShowRepostFormWarningDialog( | 326 void BrowserWindowCocoa::ShowRepostFormWarningDialog( |
| 327 TabContents* tab_contents) { | 327 TabContents* tab_contents) { |
| 328 RepostFormWarningMac::Create(GetNativeHandle(), tab_contents); | 328 RepostFormWarningMac::Create(GetNativeHandle(), tab_contents); |
| 329 } | 329 } |
| 330 | 330 |
| 331 void BrowserWindowCocoa::ShowContentSettingsWindow( | |
| 332 ContentSettingsType settings_type, | |
| 333 Profile* profile) { | |
| 334 NOTIMPLEMENTED(); | |
| 335 } | |
| 336 | |
| 337 void BrowserWindowCocoa::ShowCollectedCookiesDialog(TabContents* tab_contents) { | 331 void BrowserWindowCocoa::ShowCollectedCookiesDialog(TabContents* tab_contents) { |
| 338 // Deletes itself on close. | 332 // Deletes itself on close. |
| 339 new CollectedCookiesMac(GetNativeHandle(), tab_contents); | 333 new CollectedCookiesMac(GetNativeHandle(), tab_contents); |
| 340 } | 334 } |
| 341 | 335 |
| 342 void BrowserWindowCocoa::ShowProfileErrorDialog(int message_id) { | 336 void BrowserWindowCocoa::ShowProfileErrorDialog(int message_id) { |
| 343 scoped_nsobject<NSAlert> alert([[NSAlert alloc] init]); | 337 scoped_nsobject<NSAlert> alert([[NSAlert alloc] init]); |
| 344 [alert addButtonWithTitle:l10n_util::GetNSStringWithFixup(IDS_OK)]; | 338 [alert addButtonWithTitle:l10n_util::GetNSStringWithFixup(IDS_OK)]; |
| 345 [alert setMessageText:l10n_util::GetNSStringWithFixup(IDS_PRODUCT_NAME)]; | 339 [alert setMessageText:l10n_util::GetNSStringWithFixup(IDS_PRODUCT_NAME)]; |
| 346 [alert setInformativeText:l10n_util::GetNSStringWithFixup(message_id)]; | 340 [alert setInformativeText:l10n_util::GetNSStringWithFixup(message_id)]; |
| (...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 604 | 598 |
| 605 NSWindow* BrowserWindowCocoa::window() const { | 599 NSWindow* BrowserWindowCocoa::window() const { |
| 606 return [controller_ window]; | 600 return [controller_ window]; |
| 607 } | 601 } |
| 608 | 602 |
| 609 void BrowserWindowCocoa::UpdateSidebarForContents(TabContents* tab_contents) { | 603 void BrowserWindowCocoa::UpdateSidebarForContents(TabContents* tab_contents) { |
| 610 if (tab_contents == browser_->GetSelectedTabContents()) { | 604 if (tab_contents == browser_->GetSelectedTabContents()) { |
| 611 [controller_ updateSidebarForContents:tab_contents]; | 605 [controller_ updateSidebarForContents:tab_contents]; |
| 612 } | 606 } |
| 613 } | 607 } |
| OLD | NEW |