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

Unified Diff: chrome/browser/automation/testing_automation_provider.cc

Issue 11721003: Eliminate the LinkInfoBar[Delegate] classes entirely. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: kill LinkInfoBar classes Created 8 years 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/automation/testing_automation_provider.cc
diff --git a/chrome/browser/automation/testing_automation_provider.cc b/chrome/browser/automation/testing_automation_provider.cc
index 012fb4922c3121bcfa754f7a63a1ea36ffb120fb..8307065c69038beb69e57d06e5bf7810da5288e4 100644
--- a/chrome/browser/automation/testing_automation_provider.cc
+++ b/chrome/browser/automation/testing_automation_provider.cc
@@ -25,9 +25,9 @@
#include "base/time.h"
#include "base/utf_string_conversions.h"
#include "chrome/app/chrome_command_ids.h"
+#include "chrome/browser/alternate_nav_infobar_delegate.h"
#include "chrome/browser/api/infobars/confirm_infobar_delegate.h"
#include "chrome/browser/api/infobars/infobar_service.h"
-#include "chrome/browser/api/infobars/link_infobar_delegate.h"
#include "chrome/browser/autocomplete/autocomplete_controller.h"
#include "chrome/browser/autocomplete/autocomplete_match.h"
#include "chrome/browser/autocomplete/autocomplete_result.h"
@@ -2163,10 +2163,12 @@ ListValue* TestingAutomationProvider::GetInfobarsInfo(WebContents* wc) {
buttons_list->Append(button_label);
}
infobar_item->Set("buttons", buttons_list);
- } else if (infobar->AsLinkInfoBarDelegate()) {
- infobar_item->SetString("type", "link_infobar");
- LinkInfoBarDelegate* link_infobar = infobar->AsLinkInfoBarDelegate();
- infobar_item->SetString("link_text", link_infobar->GetLinkText());
+ } else if (infobar->AsAlternateNavInfoBarDelegate()) {
+ infobar_item->SetString("type", "alternate_nav_infobar");
+ AlternateNavInfoBarDelegate* alternate_nav_infobar =
+ infobar->AsAlternateNavInfoBarDelegate();
+ infobar_item->SetString("link_text",
+ alternate_nav_infobar->GetLinkText());
} else if (infobar->AsExtensionInfoBarDelegate()) {
infobar_item->SetString("type", "extension_infobar");
} else {

Powered by Google App Engine
This is Rietveld 408576698