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

Unified Diff: chrome/browser/extensions/extension_tab_helper.cc

Issue 8733004: Make ExtensionService use ExtensionSet. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: + Created 9 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/extensions/extension_tab_helper.cc
diff --git a/chrome/browser/extensions/extension_tab_helper.cc b/chrome/browser/extensions/extension_tab_helper.cc
index 1853360ae223acfe14e616a0ace4e7b1a86d45b7..7fe6986b3e61fdb36928cea03ff54c612b65c6a1 100644
--- a/chrome/browser/extensions/extension_tab_helper.cc
+++ b/chrome/browser/extensions/extension_tab_helper.cc
@@ -98,9 +98,9 @@ void ExtensionTabHelper::DidNavigateMainFrame(
if (!service)
return;
- for (size_t i = 0; i < service->extensions()->size(); ++i) {
- ExtensionAction* browser_action =
- service->extensions()->at(i)->browser_action();
+ for (ExtensionSet::const_iterator it = service->extensions()->begin();
+ it != service->extensions()->end(); ++it) {
+ ExtensionAction* browser_action = (*it)->browser_action();
if (browser_action) {
browser_action->ClearAllValuesForTab(
wrapper_->restore_tab_helper()->session_id().id());
@@ -110,8 +110,7 @@ void ExtensionTabHelper::DidNavigateMainFrame(
content::NotificationService::NoDetails());
}
- ExtensionAction* page_action =
- service->extensions()->at(i)->page_action();
+ ExtensionAction* page_action = (*it)->page_action();
if (page_action) {
page_action->ClearAllValuesForTab(
wrapper_->restore_tab_helper()->session_id().id());
« no previous file with comments | « chrome/browser/extensions/extension_startup_browsertest.cc ('k') | chrome/browser/extensions/extension_toolbar_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698