Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2427)

Unified Diff: chrome/browser/managed_mode/managed_mode_interstitial.cc

Issue 228293004: InfoBarService inherits from InfoBarManager (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: format Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/managed_mode/managed_mode_interstitial.cc
diff --git a/chrome/browser/managed_mode/managed_mode_interstitial.cc b/chrome/browser/managed_mode/managed_mode_interstitial.cc
index b651c09dffb0849ad1d0c1f58d7043d7505d1351..4163ffb1abac815f483d65ea048fb4834e3aa020 100644
--- a/chrome/browser/managed_mode/managed_mode_interstitial.cc
+++ b/chrome/browser/managed_mode/managed_mode_interstitial.cc
@@ -11,7 +11,6 @@
#include "base/values.h"
#include "chrome/browser/infobars/infobar.h"
#include "chrome/browser/infobars/infobar_delegate.h"
-#include "chrome/browser/infobars/infobar_manager.h"
#include "chrome/browser/infobars/infobar_service.h"
#include "chrome/browser/managed_mode/managed_user_service.h"
#include "chrome/browser/managed_mode/managed_user_service_factory.h"
@@ -53,7 +52,6 @@ ManagedModeInterstitial::ManagedModeInterstitial(
InfoBarService* service = InfoBarService::FromWebContents(web_contents);
if (service) {
- InfoBarManager* infobar_manager = service->infobar_manager();
// Remove all the infobars which are attached to |web_contents| and for
// which ShouldExpire() returns true.
content::LoadCommittedDetails details;
@@ -69,12 +67,12 @@ ManagedModeInterstitial::ManagedModeInterstitial(
details.previous_url = controller.GetLastCommittedEntry()->GetURL();
}
details.type = content::NAVIGATION_TYPE_NEW_PAGE;
- for (int i = infobar_manager->infobar_count() - 1; i >= 0; --i) {
- InfoBar* infobar = infobar_manager->infobar_at(i);
+ for (int i = service->infobar_count() - 1; i >= 0; --i) {
+ InfoBar* infobar = service->infobar_at(i);
if (infobar->delegate()->ShouldExpire(
InfoBarService::NavigationDetailsFromLoadCommittedDetails(
details)))
- infobar_manager->RemoveInfoBar(infobar);
+ service->RemoveInfoBar(infobar);
}
}

Powered by Google App Engine
This is Rietveld 408576698