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

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

Issue 8727024: Save the oauth client id used in App Notification setup (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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 431a4c4fa59c92b9e98f7ac3c48021b5ce171f0c..79490b60580d2823b6d87eddda41de6b58f22c88 100644
--- a/chrome/browser/extensions/extension_service.cc
+++ b/chrome/browser/extensions/extension_service.cc
@@ -677,7 +677,7 @@ bool ExtensionService::UninstallExtension(
*extension,
IsExtensionEnabled(extension_id),
IsIncognitoEnabled(extension_id),
- extension_prefs_->IsAppNotificationSetupDone(extension_id),
+ extension_prefs_->AppNotificationClientId(extension_id),
extension_prefs_->IsAppNotificationDisabled(extension_id));
sync_change = extension_sync_data.GetSyncChange(SyncChange::ACTION_DELETE);
}
@@ -1207,7 +1207,7 @@ void ExtensionService::SyncExtensionChangeIfNeeded(const Extension& extension) {
extension,
IsExtensionEnabled(extension.id()),
IsIncognitoEnabled(extension.id()),
- extension_prefs_->IsAppNotificationSetupDone(extension.id()),
+ extension_prefs_->AppNotificationClientId(extension.id()),
extension_prefs_->IsAppNotificationDisabled(extension.id()));
SyncChangeList sync_change_list(1, extension_sync_data.GetSyncChange(
@@ -1372,7 +1372,7 @@ void ExtensionService::GetSyncDataListHelper(
extension,
IsExtensionEnabled(extension.id()),
IsIncognitoEnabled(extension.id()),
- extension_prefs_->IsAppNotificationSetupDone(extension.id()),
+ extension_prefs_->AppNotificationClientId(extension.id()),
extension_prefs_->IsAppNotificationDisabled(extension.id())));
}
}
@@ -1508,7 +1508,7 @@ void ExtensionService::SetIsIncognitoEnabled(
void ExtensionService::SetAppNotificationSetupDone(
const std::string& extension_id,
- bool value) {
+ const std::string& oauth_client_id) {
const Extension* extension = GetInstalledExtension(extension_id);
// This method is called when the user sets up app notifications.
// So it is not expected to be called until the extension is installed.
@@ -1516,7 +1516,7 @@ void ExtensionService::SetAppNotificationSetupDone(
NOTREACHED();
return;
}
- extension_prefs_->SetAppNotificationSetupDone(extension_id, value);
+ extension_prefs_->SetAppNotificationClientId(extension_id, oauth_client_id);
SyncExtensionChangeIfNeeded(*extension);
}

Powered by Google App Engine
This is Rietveld 408576698