| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_UI_VIEWS_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_VIEW_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_VIEW_H_ |
| 7 | 7 |
| 8 #include "chrome/browser/ui/passwords/manage_passwords_bubble.h" | 8 #include "chrome/browser/ui/passwords/manage_passwords_bubble.h" |
| 9 #include "ui/views/bubble/bubble_delegate.h" | 9 #include "ui/views/bubble/bubble_delegate.h" |
| 10 | 10 |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 80 | 80 |
| 81 // Called from ConfirmNeverView if the user confirms her intention to never | 81 // Called from ConfirmNeverView if the user confirms her intention to never |
| 82 // save passwords, and remove existing passwords, for a site. | 82 // save passwords, and remove existing passwords, for a site. |
| 83 void NotifyConfirmedNeverForThisSite(); | 83 void NotifyConfirmedNeverForThisSite(); |
| 84 | 84 |
| 85 // Called from ConfirmNeverView if the user clicks on "Undo" in order to | 85 // Called from ConfirmNeverView if the user clicks on "Undo" in order to |
| 86 // undo the action and refresh to PendingView. | 86 // undo the action and refresh to PendingView. |
| 87 void NotifyUndoNeverForThisSite(); | 87 void NotifyUndoNeverForThisSite(); |
| 88 | 88 |
| 89 // views::BubbleDelegateView: | 89 // views::BubbleDelegateView: |
| 90 virtual void Init() OVERRIDE; | 90 virtual void Init() override; |
| 91 virtual void WindowClosing() OVERRIDE; | 91 virtual void WindowClosing() override; |
| 92 | 92 |
| 93 // views::WidgetDelegate | 93 // views::WidgetDelegate |
| 94 virtual views::View* GetInitiallyFocusedView() OVERRIDE; | 94 virtual views::View* GetInitiallyFocusedView() override; |
| 95 | 95 |
| 96 void set_initially_focused_view(views::View* view) { | 96 void set_initially_focused_view(views::View* view) { |
| 97 DCHECK(!initially_focused_view_); | 97 DCHECK(!initially_focused_view_); |
| 98 initially_focused_view_ = view; | 98 initially_focused_view_ = view; |
| 99 } | 99 } |
| 100 | 100 |
| 101 // Singleton instance of the Password bubble. The Password bubble can only be | 101 // Singleton instance of the Password bubble. The Password bubble can only be |
| 102 // shown on the active browser window, so there is no case in which it will be | 102 // shown on the active browser window, so there is no case in which it will be |
| 103 // shown twice at the same time. The instance is owned by the Bubble and will | 103 // shown twice at the same time. The instance is owned by the Bubble and will |
| 104 // be deleted when the bubble closes. | 104 // be deleted when the bubble closes. |
| 105 static ManagePasswordsBubbleView* manage_passwords_bubble_; | 105 static ManagePasswordsBubbleView* manage_passwords_bubble_; |
| 106 | 106 |
| 107 ManagePasswordsIconView* anchor_view_; | 107 ManagePasswordsIconView* anchor_view_; |
| 108 | 108 |
| 109 // If true upon destruction, the user has confirmed that she never wants to | 109 // If true upon destruction, the user has confirmed that she never wants to |
| 110 // save passwords for a particular site. | 110 // save passwords for a particular site. |
| 111 bool never_save_passwords_; | 111 bool never_save_passwords_; |
| 112 | 112 |
| 113 views::View* initially_focused_view_; | 113 views::View* initially_focused_view_; |
| 114 | 114 |
| 115 // A helper to intercept mouse click events on the web contents. | 115 // A helper to intercept mouse click events on the web contents. |
| 116 class WebContentMouseHandler; | 116 class WebContentMouseHandler; |
| 117 scoped_ptr<WebContentMouseHandler> mouse_handler_; | 117 scoped_ptr<WebContentMouseHandler> mouse_handler_; |
| 118 | 118 |
| 119 DISALLOW_COPY_AND_ASSIGN(ManagePasswordsBubbleView); | 119 DISALLOW_COPY_AND_ASSIGN(ManagePasswordsBubbleView); |
| 120 }; | 120 }; |
| 121 | 121 |
| 122 #endif // CHROME_BROWSER_UI_VIEWS_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_VIEW_H_ | 122 #endif // CHROME_BROWSER_UI_VIEWS_PASSWORDS_MANAGE_PASSWORDS_BUBBLE_VIEW_H_ |
| OLD | NEW |