summaryrefslogtreecommitdiffstats
path: root/ios/public
diff options
context:
space:
mode:
Diffstat (limited to 'ios/public')
-rw-r--r--ios/public/provider/chrome/browser/signin/chrome_identity_service.h3
-rw-r--r--ios/public/provider/chrome/browser/signin/chrome_identity_service.mm5
2 files changed, 7 insertions, 1 deletions
diff --git a/ios/public/provider/chrome/browser/signin/chrome_identity_service.h b/ios/public/provider/chrome/browser/signin/chrome_identity_service.h
index 1f13ced..cb45e1b 100644
--- a/ios/public/provider/chrome/browser/signin/chrome_identity_service.h
+++ b/ios/public/provider/chrome/browser/signin/chrome_identity_service.h
@@ -61,6 +61,9 @@ class ChromeIdentityService {
// Called when profile information or the profile image is updated.
virtual void OnProfileUpdate(ChromeIdentity* identity) {}
+ // Called when the ChromeIdentityService will be destroyed.
+ virtual void OnChromeIdentityServiceWillBeDestroyed() {}
+
private:
DISALLOW_COPY_AND_ASSIGN(Observer);
};
diff --git a/ios/public/provider/chrome/browser/signin/chrome_identity_service.mm b/ios/public/provider/chrome/browser/signin/chrome_identity_service.mm
index dce36f4..55a228c 100644
--- a/ios/public/provider/chrome/browser/signin/chrome_identity_service.mm
+++ b/ios/public/provider/chrome/browser/signin/chrome_identity_service.mm
@@ -8,7 +8,10 @@ namespace ios {
ChromeIdentityService::ChromeIdentityService() {}
-ChromeIdentityService::~ChromeIdentityService() {}
+ChromeIdentityService::~ChromeIdentityService() {
+ FOR_EACH_OBSERVER(Observer, observer_list_,
+ OnChromeIdentityServiceWillBeDestroyed());
+}
bool ChromeIdentityService::IsValidIdentity(ChromeIdentity* identity) const {
return false;