Index: chrome/browser/translate/translate_infobar_delegate.cc |
diff --git a/chrome/browser/translate/translate_infobar_delegate.cc b/chrome/browser/translate/translate_infobar_delegate.cc |
index bafb6f14797c55169cca704d8c8a359865721c55..e8137095df6b9bdbe18f159ec4fa1f84b0da95f3 100644 |
--- a/chrome/browser/translate/translate_infobar_delegate.cc |
+++ b/chrome/browser/translate/translate_infobar_delegate.cc |
@@ -11,6 +11,7 @@ |
#include "base/prefs/pref_service.h" |
#include "chrome/browser/browser_process.h" |
#include "chrome/browser/infobars/infobar.h" |
+#include "chrome/browser/infobars/infobar_manager.h" |
#include "chrome/browser/infobars/infobar_service.h" |
#include "chrome/browser/profiles/profile.h" |
#include "chrome/browser/translate/translate_manager.h" |
@@ -89,9 +90,10 @@ void TranslateInfoBarDelegate::Create(bool replace_existing_infobar, |
InfoBar* old_infobar = NULL; |
InfoBarService* infobar_service = |
InfoBarService::FromWebContents(web_contents); |
+ InfoBarManager* infobar_manager = infobar_service->infobar_manager(); |
TranslateInfoBarDelegate* old_delegate = NULL; |
- for (size_t i = 0; i < infobar_service->infobar_count(); ++i) { |
- old_infobar = infobar_service->infobar_at(i); |
+ for (size_t i = 0; i < infobar_manager->infobar_count(); ++i) { |
+ old_infobar = infobar_manager->infobar_at(i); |
old_delegate = old_infobar->delegate()->AsTranslateInfoBarDelegate(); |
if (old_delegate) { |
if (!replace_existing_infobar) |