OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/chromeos/frame/browser_view.h" | 5 #include "chrome/browser/chromeos/frame/browser_view.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 437 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
448 | 448 |
449 gfx::NativeWindow BrowserView::GetNativeWindow() const { | 449 gfx::NativeWindow BrowserView::GetNativeWindow() const { |
450 return GetWindow()->GetNativeWindow(); | 450 return GetWindow()->GetNativeWindow(); |
451 } | 451 } |
452 | 452 |
453 bool BrowserView::ShouldOpenButtonOptions( | 453 bool BrowserView::ShouldOpenButtonOptions( |
454 const views::View* button_view) const { | 454 const views::View* button_view) const { |
455 return true; | 455 return true; |
456 } | 456 } |
457 | 457 |
| 458 void BrowserView::ExecuteBrowserCommand(int id) const { |
| 459 browser()->ExecuteCommand(id); |
| 460 } |
| 461 |
458 void BrowserView::OpenButtonOptions(const views::View* button_view) const { | 462 void BrowserView::OpenButtonOptions(const views::View* button_view) const { |
459 if (button_view == status_area_->network_view()) { | 463 if (button_view == status_area_->network_view()) { |
460 browser()->OpenInternetOptionsDialog(); | 464 browser()->OpenInternetOptionsDialog(); |
461 } else if (button_view == status_area_->language_view()) { | 465 } else if (button_view == status_area_->language_view()) { |
462 LanguageConfigView::Show(GetProfile(), | 466 LanguageConfigView::Show(GetProfile(), |
463 frame()->GetWindow()->GetNativeWindow()); | 467 frame()->GetWindow()->GetNativeWindow()); |
464 } else { | 468 } else { |
465 browser()->OpenSystemOptionsDialog(); | 469 browser()->OpenSystemOptionsDialog(); |
466 } | 470 } |
467 } | 471 } |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
506 BrowserWindow* BrowserWindow::CreateBrowserWindow(Browser* browser) { | 510 BrowserWindow* BrowserWindow::CreateBrowserWindow(Browser* browser) { |
507 // Create a browser view for chromeos. | 511 // Create a browser view for chromeos. |
508 BrowserView* view; | 512 BrowserView* view; |
509 if (browser->type() & Browser::TYPE_POPUP) | 513 if (browser->type() & Browser::TYPE_POPUP) |
510 view = new chromeos::PanelBrowserView(browser); | 514 view = new chromeos::PanelBrowserView(browser); |
511 else | 515 else |
512 view = new chromeos::BrowserView(browser); | 516 view = new chromeos::BrowserView(browser); |
513 BrowserFrame::Create(view, browser->profile()); | 517 BrowserFrame::Create(view, browser->profile()); |
514 return view; | 518 return view; |
515 } | 519 } |
OLD | NEW |