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

Unified Diff: chrome/browser/ui/passwords/manage_passwords_bubble_model.h

Issue 2033713002: Implement the Chrome Sign-in promo bubble for password manager on Views. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments Created 4 years, 7 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 | « chrome/app/generated_resources.grd ('k') | chrome/browser/ui/passwords/manage_passwords_bubble_model.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/passwords/manage_passwords_bubble_model.h
diff --git a/chrome/browser/ui/passwords/manage_passwords_bubble_model.h b/chrome/browser/ui/passwords/manage_passwords_bubble_model.h
index 667f6e9dc5f4781901125ee5c18af85af074701e..2b01a57bad5df1acde14ed157fd853e8ecb69a82 100644
--- a/chrome/browser/ui/passwords/manage_passwords_bubble_model.h
+++ b/chrome/browser/ui/passwords/manage_passwords_bubble_model.h
@@ -73,6 +73,14 @@ class ManagePasswordsBubbleModel : public content::WebContentsObserver {
void OnPasswordAction(const autofill::PasswordForm& password_form,
PasswordAction action);
+ // Called by the view when the "Sign in" button in the promo bubble is
+ // clicked.
+ void OnSignInToChromeClicked();
+
+ // Called by the view when the "No thanks" button in the promo bubble is
+ // clicked.
+ void OnSkipSignInClicked();
+
password_manager::ui::State state() const { return state_; }
const base::string16& title() const { return title_; }
@@ -105,6 +113,11 @@ class ManagePasswordsBubbleModel : public content::WebContentsObserver {
// Lock.
bool ShouldShowGoogleSmartLockWelcome() const;
+ // Returns true and updates the internal state iff the Save bubble should
+ // switch to the Chrome Sign In promo after the password was saved. Otherwise,
+ // returns false and leaves the current state.
+ bool ReplaceToShowSignInPromoIfNeeded();
+
void SetClockForTesting(std::unique_ptr<base::Clock> clock);
private:
« no previous file with comments | « chrome/app/generated_resources.grd ('k') | chrome/browser/ui/passwords/manage_passwords_bubble_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698