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

Unified Diff: components/password_manager/core/browser/password_form_manager.h

Issue 2760653002: Add FormFetcher::RemoveConsumer (Closed)
Patch Set: Rebased Created 3 years, 9 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: components/password_manager/core/browser/password_form_manager.h
diff --git a/components/password_manager/core/browser/password_form_manager.h b/components/password_manager/core/browser/password_form_manager.h
index 0f83f152f26e49117002ec292514b84a1c8236dc..b4cf68b064baba0f4e8d657c9e55ec74288dc1f6 100644
--- a/components/password_manager/core/browser/password_form_manager.h
+++ b/components/password_manager/core/browser/password_form_manager.h
@@ -42,7 +42,8 @@ class PasswordFormManager : public FormFetcher::Consumer {
// |password_manager| owns |this|, |client| and |driver| serve to
// communicate with embedder, |observed_form| is the associated form |this|
// is managing, |form_saver| is used to save/update the form and
- // |form_fetcher| to get saved data about the form.
+ // |form_fetcher| to get saved data about the form. |form_fetcher| must not be
+ // destroyed before |this|.
//
// TODO(crbug.com/621355): So far, |form_fetcher| can be null. In that case
// |this| creates an instance of it itself (meant for production code). Once
@@ -243,7 +244,8 @@ class PasswordFormManager : public FormFetcher::Consumer {
// Clears references to matches derived from the associated FormFetcher data.
// After calling this, the PasswordFormManager holds no references to objects
- // owned by the associated FormFetcher.
+ // owned by the associated FormFetcher. This does not cause removing |this| as
+ // a consumer of |form_fetcher_|.
void ResetStoredMatches();
// Takes ownership of |fetcher|.

Powered by Google App Engine
This is Rietveld 408576698