| 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 "build/build_config.h" | 5 #include "build/build_config.h" |
| 6 | 6 |
| 7 #include "chrome/browser/back_forward_menu_model.h" | 7 #include "chrome/browser/back_forward_menu_model.h" |
| 8 | 8 |
| 9 #include "app/l10n_util.h" | 9 #include "app/l10n_util.h" |
| 10 #include "app/resource_bundle.h" | 10 #include "app/resource_bundle.h" |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 *icon = *ResourceBundle::GetSharedInstance().GetBitmapNamed( | 108 *icon = *ResourceBundle::GetSharedInstance().GetBitmapNamed( |
| 109 IDR_HISTORY_FAVICON); | 109 IDR_HISTORY_FAVICON); |
| 110 } else { | 110 } else { |
| 111 NavigationEntry* entry = GetNavigationEntry(index); | 111 NavigationEntry* entry = GetNavigationEntry(index); |
| 112 *icon = entry->favicon().bitmap(); | 112 *icon = entry->favicon().bitmap(); |
| 113 } | 113 } |
| 114 | 114 |
| 115 return true; | 115 return true; |
| 116 } | 116 } |
| 117 | 117 |
| 118 menus::ButtonMenuItemModel* BackForwardMenuModel::GetButtonMenuItemAt( |
| 119 int index) const { |
| 120 return NULL; |
| 121 } |
| 122 |
| 118 bool BackForwardMenuModel::IsEnabledAt(int index) const { | 123 bool BackForwardMenuModel::IsEnabledAt(int index) const { |
| 119 return index < GetItemCount() && !IsSeparator(index); | 124 return index < GetItemCount() && !IsSeparator(index); |
| 120 } | 125 } |
| 121 | 126 |
| 122 menus::MenuModel* BackForwardMenuModel::GetSubmenuModelAt(int index) const { | 127 menus::MenuModel* BackForwardMenuModel::GetSubmenuModelAt(int index) const { |
| 123 return NULL; | 128 return NULL; |
| 124 } | 129 } |
| 125 | 130 |
| 126 void BackForwardMenuModel::HighlightChangedTo(int index) { | 131 void BackForwardMenuModel::HighlightChangedTo(int index) { |
| 127 } | 132 } |
| (...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 360 metric_string += "ForwardMenu_"; | 365 metric_string += "ForwardMenu_"; |
| 361 else | 366 else |
| 362 metric_string += "BackMenu_"; | 367 metric_string += "BackMenu_"; |
| 363 metric_string += action; | 368 metric_string += action; |
| 364 if (index != -1) { | 369 if (index != -1) { |
| 365 // +1 is for historical reasons (indices used to start at 1). | 370 // +1 is for historical reasons (indices used to start at 1). |
| 366 metric_string += IntToString(index + 1); | 371 metric_string += IntToString(index + 1); |
| 367 } | 372 } |
| 368 return metric_string; | 373 return metric_string; |
| 369 } | 374 } |
| OLD | NEW |