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

Side by Side Diff: chrome/browser/ui/passwords/password_dialog_controller_impl.cc

Issue 1837043003: Add a title for the account chooser for one credential displayed. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/ui/passwords/manage_passwords_view_utils_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #include "chrome/browser/ui/passwords/password_dialog_controller_impl.h" 5 #include "chrome/browser/ui/passwords/password_dialog_controller_impl.h"
6 6
7 #include "chrome/browser/profiles/profile.h" 7 #include "chrome/browser/profiles/profile.h"
8 #include "chrome/browser/sync/profile_sync_service_factory.h" 8 #include "chrome/browser/sync/profile_sync_service_factory.h"
9 #include "chrome/browser/ui/passwords/manage_passwords_view_utils.h" 9 #include "chrome/browser/ui/passwords/manage_passwords_view_utils.h"
10 #include "chrome/browser/ui/passwords/password_dialog_prompts.h" 10 #include "chrome/browser/ui/passwords/password_dialog_prompts.h"
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 const PasswordDialogController::FormsVector& 70 const PasswordDialogController::FormsVector&
71 PasswordDialogControllerImpl::GetFederationsForms() const { 71 PasswordDialogControllerImpl::GetFederationsForms() const {
72 return federated_credentials_; 72 return federated_credentials_;
73 } 73 }
74 74
75 std::pair<base::string16, gfx::Range> 75 std::pair<base::string16, gfx::Range>
76 PasswordDialogControllerImpl::GetAccoutChooserTitle() const { 76 PasswordDialogControllerImpl::GetAccoutChooserTitle() const {
77 std::pair<base::string16, gfx::Range> result; 77 std::pair<base::string16, gfx::Range> result;
78 GetAccountChooserDialogTitleTextAndLinkRange( 78 GetAccountChooserDialogTitleTextAndLinkRange(
79 IsSmartLockBrandingEnabled(profile_), 79 IsSmartLockBrandingEnabled(profile_),
80 local_credentials_.size() > 1,
80 &result.first, 81 &result.first,
81 &result.second); 82 &result.second);
82 return result; 83 return result;
83 } 84 }
84 85
85 base::string16 PasswordDialogControllerImpl::GetAutoSigninPromoTitle() const { 86 base::string16 PasswordDialogControllerImpl::GetAutoSigninPromoTitle() const {
86 int message_id = IsSyncingAutosignSetting(profile_) 87 int message_id = IsSyncingAutosignSetting(profile_)
87 ? IDS_AUTO_SIGNIN_FIRST_RUN_TITLE_MANY_DEVICES 88 ? IDS_AUTO_SIGNIN_FIRST_RUN_TITLE_MANY_DEVICES
88 : IDS_AUTO_SIGNIN_FIRST_RUN_TITLE_LOCAL_DEVICE; 89 : IDS_AUTO_SIGNIN_FIRST_RUN_TITLE_LOCAL_DEVICE;
89 return l10n_util::GetStringUTF16(message_id); 90 return l10n_util::GetStringUTF16(message_id);
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 void PasswordDialogControllerImpl::ResetDialog() { 136 void PasswordDialogControllerImpl::ResetDialog() {
136 if (account_chooser_dialog_) { 137 if (account_chooser_dialog_) {
137 account_chooser_dialog_->ControllerGone(); 138 account_chooser_dialog_->ControllerGone();
138 account_chooser_dialog_ = nullptr; 139 account_chooser_dialog_ = nullptr;
139 } 140 }
140 if (autosignin_dialog_) { 141 if (autosignin_dialog_) {
141 autosignin_dialog_->ControllerGone(); 142 autosignin_dialog_->ControllerGone();
142 autosignin_dialog_ = nullptr; 143 autosignin_dialog_ = nullptr;
143 } 144 }
144 } 145 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/passwords/manage_passwords_view_utils_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698