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

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

Issue 1495403002: Observe adding external extensions via windows registry. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: cleaned up, removed logs Created 4 years, 11 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/extensions/extension_service.cc
diff --git a/chrome/browser/extensions/extension_service.cc b/chrome/browser/extensions/extension_service.cc
index 4a4b216b3af5124b6d277c37dd72a47e6d66efbc..23454c55c5792082a3ffafcee64cbbdddfb2638b 100644
--- a/chrome/browser/extensions/extension_service.cc
+++ b/chrome/browser/extensions/extension_service.cc
@@ -194,7 +194,8 @@ bool ExtensionService::OnExternalExtensionUpdateUrlFound(
const GURL& update_url,
Manifest::Location location,
int creation_flags,
- bool mark_acknowledged) {
+ bool mark_acknowledged,
+ bool is_initial_load) {
CHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
CHECK(crx_file::id_util::IdIsValid(id));
@@ -228,10 +229,27 @@ bool ExtensionService::OnExternalExtensionUpdateUrlFound(
return false;
}
- update_once_all_providers_are_ready_ = true;
+ if (is_initial_load)
+ update_once_all_providers_are_ready_ = true;
return true;
}
+void ExtensionService::OnExternalProviderUpdateComplete(
+ const extensions::ExternalProviderInterface* provider,
+ const std::set<std::string>& removed_extensions) {
+ if (updater_) {
+ // Empty params will cause pending extensions to be updated.
+ extensions::ExtensionUpdater::CheckParams empty_params;
+ updater_->CheckNow(empty_params);
asargent_no_longer_on_chrome 2016/01/20 22:49:00 It seems a little unfortunate to kick off an updat
lazyboy 2016/01/21 21:02:12 This should not kick off update check for all curr
+ }
+
+ for (const std::string& id : removed_extensions)
+ CheckExternalUninstall(id);
+
+ error_controller_->ShowErrorIfNeeded();
+ external_install_manager_->UpdateExternalExtensionAlert();
+}
+
// static
// This function is used to uninstall an extension via sync. The LOG statements
// within this function are used to inform the user if the uninstall cannot be

Powered by Google App Engine
This is Rietveld 408576698