| OLD | NEW |
| 1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2009 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/browser.h" | 5 #include "chrome/browser/browser.h" |
| 6 | 6 |
| 7 #include "app/animation.h" | 7 #include "app/animation.h" |
| 8 #include "app/l10n_util.h" | 8 #include "app/l10n_util.h" |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/idle_timer.h" | 10 #include "base/idle_timer.h" |
| (...skipping 1259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1270 case IDC_NEW_WINDOW_PROFILE_0: | 1270 case IDC_NEW_WINDOW_PROFILE_0: |
| 1271 case IDC_NEW_WINDOW_PROFILE_1: | 1271 case IDC_NEW_WINDOW_PROFILE_1: |
| 1272 case IDC_NEW_WINDOW_PROFILE_2: | 1272 case IDC_NEW_WINDOW_PROFILE_2: |
| 1273 case IDC_NEW_WINDOW_PROFILE_3: | 1273 case IDC_NEW_WINDOW_PROFILE_3: |
| 1274 case IDC_NEW_WINDOW_PROFILE_4: | 1274 case IDC_NEW_WINDOW_PROFILE_4: |
| 1275 case IDC_NEW_WINDOW_PROFILE_5: | 1275 case IDC_NEW_WINDOW_PROFILE_5: |
| 1276 case IDC_NEW_WINDOW_PROFILE_6: | 1276 case IDC_NEW_WINDOW_PROFILE_6: |
| 1277 case IDC_NEW_WINDOW_PROFILE_7: | 1277 case IDC_NEW_WINDOW_PROFILE_7: |
| 1278 case IDC_NEW_WINDOW_PROFILE_8: | 1278 case IDC_NEW_WINDOW_PROFILE_8: |
| 1279 NewProfileWindowByIndex(id - IDC_NEW_WINDOW_PROFILE_0); break; | 1279 NewProfileWindowByIndex(id - IDC_NEW_WINDOW_PROFILE_0); break; |
| 1280 #if defined(OS_WIN) || defined(OS_LINUX) | |
| 1281 case IDC_CLOSE_WINDOW: CloseWindow(); break; | 1280 case IDC_CLOSE_WINDOW: CloseWindow(); break; |
| 1282 #endif | |
| 1283 case IDC_NEW_TAB: NewTab(); break; | 1281 case IDC_NEW_TAB: NewTab(); break; |
| 1284 case IDC_CLOSE_TAB: CloseTab(); break; | 1282 case IDC_CLOSE_TAB: CloseTab(); break; |
| 1285 case IDC_SELECT_NEXT_TAB: SelectNextTab(); break; | 1283 case IDC_SELECT_NEXT_TAB: SelectNextTab(); break; |
| 1286 case IDC_SELECT_PREVIOUS_TAB: SelectPreviousTab(); break; | 1284 case IDC_SELECT_PREVIOUS_TAB: SelectPreviousTab(); break; |
| 1287 case IDC_SELECT_TAB_0: | 1285 case IDC_SELECT_TAB_0: |
| 1288 case IDC_SELECT_TAB_1: | 1286 case IDC_SELECT_TAB_1: |
| 1289 case IDC_SELECT_TAB_2: | 1287 case IDC_SELECT_TAB_2: |
| 1290 case IDC_SELECT_TAB_3: | 1288 case IDC_SELECT_TAB_3: |
| 1291 case IDC_SELECT_TAB_4: | 1289 case IDC_SELECT_TAB_4: |
| 1292 case IDC_SELECT_TAB_5: | 1290 case IDC_SELECT_TAB_5: |
| (...skipping 1433 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2726 /////////////////////////////////////////////////////////////////////////////// | 2724 /////////////////////////////////////////////////////////////////////////////// |
| 2727 // BrowserToolbarModel (private): | 2725 // BrowserToolbarModel (private): |
| 2728 | 2726 |
| 2729 NavigationController* Browser::BrowserToolbarModel::GetNavigationController() { | 2727 NavigationController* Browser::BrowserToolbarModel::GetNavigationController() { |
| 2730 // This |current_tab| can be NULL during the initialization of the | 2728 // This |current_tab| can be NULL during the initialization of the |
| 2731 // toolbar during window creation (i.e. before any tabs have been added | 2729 // toolbar during window creation (i.e. before any tabs have been added |
| 2732 // to the window). | 2730 // to the window). |
| 2733 TabContents* current_tab = browser_->GetSelectedTabContents(); | 2731 TabContents* current_tab = browser_->GetSelectedTabContents(); |
| 2734 return current_tab ? ¤t_tab->controller() : NULL; | 2732 return current_tab ? ¤t_tab->controller() : NULL; |
| 2735 } | 2733 } |
| OLD | NEW |