| Index: chrome/browser/ui/toolbar/back_forward_menu_model.cc
|
| ===================================================================
|
| --- chrome/browser/ui/toolbar/back_forward_menu_model.cc (revision 115900)
|
| +++ chrome/browser/ui/toolbar/back_forward_menu_model.cc (working copy)
|
| @@ -29,6 +29,7 @@
|
| #include "ui/base/text/text_elider.h"
|
| #include "ui/gfx/codec/png_codec.h"
|
|
|
| +using content::NavigationEntry;
|
| using content::UserMetricsAction;
|
|
|
| const int BackForwardMenuModel::kMaxHistoryItems = 12;
|
| @@ -90,7 +91,7 @@
|
|
|
| // Return the entry title, escaping any '&' characters and eliding it if it's
|
| // super long.
|
| - content::NavigationEntry* entry = GetNavigationEntry(index);
|
| + NavigationEntry* entry = GetNavigationEntry(index);
|
| Profile* profile =
|
| Profile::FromBrowserContext(GetTabContents()->GetBrowserContext());
|
| string16 menu_text(entry->GetTitleForDisplay(
|
| @@ -135,7 +136,7 @@
|
| *icon = *ResourceBundle::GetSharedInstance().GetBitmapNamed(
|
| IDR_HISTORY_FAVICON);
|
| } else {
|
| - content::NavigationEntry* entry = GetNavigationEntry(index);
|
| + NavigationEntry* entry = GetNavigationEntry(index);
|
| *icon = entry->GetFavicon().bitmap;
|
| if (!entry->GetFavicon().valid && menu_model_delegate()) {
|
| FetchFavicon(entry);
|
| @@ -223,7 +224,7 @@
|
| menu_model_delegate_ = menu_model_delegate;
|
| }
|
|
|
| -void BackForwardMenuModel::FetchFavicon(content::NavigationEntry* entry) {
|
| +void BackForwardMenuModel::FetchFavicon(NavigationEntry* entry) {
|
| // If the favicon has already been requested for this menu, don't do
|
| // anything.
|
| if (requested_favicons_.find(entry->GetUniqueID()) !=
|
| @@ -248,7 +249,7 @@
|
| if (favicon.is_valid()) {
|
| int unique_id = load_consumer_.GetClientDataForCurrentRequest();
|
| // Find the current model_index for the unique_id.
|
| - content::NavigationEntry* entry = NULL;
|
| + NavigationEntry* entry = NULL;
|
| int model_index = -1;
|
| for (int i = 0; i < GetItemCount() - 1; i++) {
|
| if (IsSeparator(i))
|
| @@ -348,8 +349,7 @@
|
| }
|
| }
|
|
|
| - content::NavigationEntry* start_entry =
|
| - controller.GetEntryAtIndex(start_from);
|
| + NavigationEntry* start_entry = controller.GetEntryAtIndex(start_from);
|
| const GURL& url = start_entry->GetURL();
|
|
|
| if (!forward) {
|
| @@ -440,8 +440,7 @@
|
| return index;
|
| }
|
|
|
| -content::NavigationEntry* BackForwardMenuModel::GetNavigationEntry(
|
| - int index) const {
|
| +NavigationEntry* BackForwardMenuModel::GetNavigationEntry(int index) const {
|
| int controller_index = MenuIndexToNavEntryIndex(index);
|
| NavigationController& controller = GetTabContents()->GetController();
|
| if (controller_index >= 0 && controller_index < controller.entry_count())
|
|
|