Index: chrome/browser/ui/passwords/manage_passwords_ui_controller.h |
diff --git a/chrome/browser/ui/passwords/manage_passwords_ui_controller.h b/chrome/browser/ui/passwords/manage_passwords_ui_controller.h |
index 180f9d114e564b8392834ed5ce08a15e3587eeb1..d21cde246583d507974121fc19ac0c2620a71011 100644 |
--- a/chrome/browser/ui/passwords/manage_passwords_ui_controller.h |
+++ b/chrome/browser/ui/passwords/manage_passwords_ui_controller.h |
@@ -67,7 +67,9 @@ class ManagePasswordsUIController |
// without user interaction. |
virtual void UpdateIconAndBubbleState(ManagePasswordsIconView* icon); |
- bool IsAutomaticallyOpeningBubble() const { return should_pop_up_bubble_; } |
+ bool IsAutomaticallyOpeningBubble() const { |
+ return bubble_status_ == SHOULD_POP_UP; |
+ } |
// PasswordsModelDelegate: |
const GURL& GetOrigin() const override; |
@@ -133,6 +135,14 @@ class ManagePasswordsUIController |
private: |
friend class content::WebContentsUserData<ManagePasswordsUIController>; |
+ enum BubbleStatus { |
+ NOT_SHOWN, |
+ // The bubble is to be popped up in the next call to |
+ // UpdateBubbleAndIconVisibility(). |
+ SHOULD_POP_UP, |
+ SHOWN, |
+ }; |
+ |
// Shows the password bubble without user interaction. |
void ShowBubbleWithoutUserInteraction(); |
@@ -149,9 +159,7 @@ class ManagePasswordsUIController |
// The controller for the blocking dialogs. |
scoped_ptr<PasswordDialogControllerImpl> dialog_controller_; |
- // Contains true if the bubble is to be popped up in the next call to |
- // UpdateBubbleAndIconVisibility(). |
- bool should_pop_up_bubble_; |
+ BubbleStatus bubble_status_; |
DISALLOW_COPY_AND_ASSIGN(ManagePasswordsUIController); |
}; |