OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_PASSWORDS_MANAGE_PASSWORDS_VIEW_UTILS_H_ | 5 #ifndef CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_VIEW_UTILS_H_ |
6 #define CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_VIEW_UTILS_H_ | 6 #define CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_VIEW_UTILS_H_ |
7 | 7 |
8 #include "base/strings/string16.h" | 8 #include "base/strings/string16.h" |
9 | 9 |
10 namespace autofill { | 10 namespace autofill { |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 // Sets the formatted |title| in the Account Chooser UI. | 63 // Sets the formatted |title| in the Account Chooser UI. |
64 // If |is_smartlock_branding_enabled| is true, sets the |title_link_range| for | 64 // If |is_smartlock_branding_enabled| is true, sets the |title_link_range| for |
65 // the "Google Smart Lock" text range to be set visibly as a hyperlink in the | 65 // the "Google Smart Lock" text range to be set visibly as a hyperlink in the |
66 // dialog bubble otherwise chooses the title which doesn't contain Smart Lock | 66 // dialog bubble otherwise chooses the title which doesn't contain Smart Lock |
67 // branding. | 67 // branding. |
68 void GetAccountChooserDialogTitleTextAndLinkRange( | 68 void GetAccountChooserDialogTitleTextAndLinkRange( |
69 bool is_smartlock_branding_enabled, | 69 bool is_smartlock_branding_enabled, |
70 base::string16* title, | 70 base::string16* title, |
71 gfx::Range* title_link_range); | 71 gfx::Range* title_link_range); |
72 | 72 |
73 // TODO(melandory): remove as obsolete. http://crbug.com/532876 | |
74 void GetAutoSigninPromptFirstRunExperienceExplanation( | |
75 bool is_smartlock_branding_enabled, | |
76 base::string16* explanation, | |
77 gfx::Range* explanation_link_range); | |
78 | |
79 // Loads |smartlock_string_id| or |default_string_id| string from the resources | 73 // Loads |smartlock_string_id| or |default_string_id| string from the resources |
80 // and substitutes the placeholder with the correct password manager branding | 74 // and substitutes the placeholder with the correct password manager branding |
81 // (Google Smart Lock, Google Chrome or Chromium) according to | 75 // (Google Smart Lock, Google Chrome or Chromium) according to |
82 // |is_smartlock_branding_enabled|. If |is_smartlock_branding_enabled| is true | 76 // |is_smartlock_branding_enabled|. If |is_smartlock_branding_enabled| is true |
83 // then |link_range| contains the link range for the brand name. | 77 // then |link_range| contains the link range for the brand name. |
84 void GetBrandedTextAndLinkRange( | 78 void GetBrandedTextAndLinkRange( |
85 bool is_smartlock_branding_enabled, | 79 bool is_smartlock_branding_enabled, |
86 int smartlock_string_id, | 80 int smartlock_string_id, |
87 int default_string_id, | 81 int default_string_id, |
88 base::string16* out_string, | 82 base::string16* out_string, |
89 gfx::Range* link_range); | 83 gfx::Range* link_range); |
90 | 84 |
91 // Returns an username in the form that should be shown in the bubble. | 85 // Returns an username in the form that should be shown in the bubble. |
92 base::string16 GetDisplayUsername(const autofill::PasswordForm& form); | 86 base::string16 GetDisplayUsername(const autofill::PasswordForm& form); |
93 | 87 |
94 #endif // CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_VIEW_UTILS_H_ | 88 #endif // CHROME_BROWSER_UI_PASSWORDS_MANAGE_PASSWORDS_VIEW_UTILS_H_ |
OLD | NEW |