OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_PASSWORD_MANAGER_SAVE_PASSWORD_INFOBAR_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_PASSWORD_MANAGER_SAVE_PASSWORD_INFOBAR_DELEGATE_H_ |
6 #define CHROME_BROWSER_PASSWORD_MANAGER_SAVE_PASSWORD_INFOBAR_DELEGATE_H_ | 6 #define CHROME_BROWSER_PASSWORD_MANAGER_SAVE_PASSWORD_INFOBAR_DELEGATE_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/timer/elapsed_timer.h" | 10 #include "base/timer/elapsed_timer.h" |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 void InfoBarDismissed() override; | 57 void InfoBarDismissed() override; |
58 base::string16 GetMessageText() const override; | 58 base::string16 GetMessageText() const override; |
59 base::string16 GetButtonLabel(InfoBarButton button) const override; | 59 base::string16 GetButtonLabel(InfoBarButton button) const override; |
60 bool LinkClicked(WindowOpenDisposition disposition) override; | 60 bool LinkClicked(WindowOpenDisposition disposition) override; |
61 bool Accept() override; | 61 bool Accept() override; |
62 bool Cancel() override; | 62 bool Cancel() override; |
63 | 63 |
64 protected: | 64 protected: |
65 // Makes a ctor available in tests. | 65 // Makes a ctor available in tests. |
66 SavePasswordInfoBarDelegate( | 66 SavePasswordInfoBarDelegate( |
| 67 content::WebContents* web_contents, |
67 scoped_ptr<password_manager::PasswordFormManager> form_to_save, | 68 scoped_ptr<password_manager::PasswordFormManager> form_to_save, |
68 const std::string& uma_histogram_suffix, | 69 const std::string& uma_histogram_suffix, |
69 password_manager::CredentialSourceType source_type, | 70 password_manager::CredentialSourceType source_type, |
70 bool is_smartlock_branding_enabled); | 71 bool is_smartlock_branding_enabled); |
71 | 72 |
72 private: | 73 private: |
73 // The PasswordFormManager managing the form we're asking the user about, | 74 // The PasswordFormManager managing the form we're asking the user about, |
74 // and should update as per her decision. | 75 // and should update as per her decision. |
75 scoped_ptr<password_manager::PasswordFormManager> form_to_save_; | 76 scoped_ptr<password_manager::PasswordFormManager> form_to_save_; |
76 | 77 |
(...skipping 17 matching lines...) Expand all Loading... |
94 base::string16 title_; | 95 base::string16 title_; |
95 | 96 |
96 // If set, describes the location of the link to the help center article for | 97 // If set, describes the location of the link to the help center article for |
97 // Smart Lock. | 98 // Smart Lock. |
98 gfx::Range title_link_range_; | 99 gfx::Range title_link_range_; |
99 | 100 |
100 DISALLOW_COPY_AND_ASSIGN(SavePasswordInfoBarDelegate); | 101 DISALLOW_COPY_AND_ASSIGN(SavePasswordInfoBarDelegate); |
101 }; | 102 }; |
102 | 103 |
103 #endif // CHROME_BROWSER_PASSWORD_MANAGER_SAVE_PASSWORD_INFOBAR_DELEGATE_H_ | 104 #endif // CHROME_BROWSER_PASSWORD_MANAGER_SAVE_PASSWORD_INFOBAR_DELEGATE_H_ |
OLD | NEW |