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

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

Issue 2876009: Re-implement app overlap detection with new extent syntax. (Closed) Base URL: git://codf21.jail/chromium.git
Patch Set: donk Created 10 years, 6 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
« no previous file with comments | « no previous file | chrome/common/extensions/extension_extent.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/extensions_service.cc
diff --git a/chrome/browser/extensions/extensions_service.cc b/chrome/browser/extensions/extensions_service.cc
index 854cecc38b65a44cc3f4bced748f17cf5d9ceda7..ac8ca03b1ab089cfb6f3caee52e9b3443d49a42a 100644
--- a/chrome/browser/extensions/extensions_service.cc
+++ b/chrome/browser/extensions/extensions_service.cc
@@ -968,7 +968,11 @@ Extension* ExtensionsService::GetExtensionByWebExtent(const GURL& url) {
Extension* ExtensionsService::GetExtensionByOverlappingWebExtent(
const ExtensionExtent& extent) {
- // TODO(aa): Make this work for the new extents. http://crbug.com/47445.
+ for (size_t i = 0; i < extensions_.size(); ++i) {
+ if (extensions_[i]->web_extent().OverlapsWith(extent))
+ return extensions_[i];
+ }
+
return NULL;
}
« no previous file with comments | « no previous file | chrome/common/extensions/extension_extent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698