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

Side by Side Diff: components/user_manager/user_info_impl.cc

Issue 2450183002: Rename UserInfo method GetEmail to GetDisplayEmail. (Closed)
Patch Set: Update comment Created 4 years, 1 month 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 | « components/user_manager/user_info_impl.h ('k') | components/user_manager/user_names.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "components/user_manager/user_info_impl.h" 5 #include "components/user_manager/user_info_impl.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/strings/utf_string_conversions.h" 8 #include "base/strings/utf_string_conversions.h"
9 #include "components/signin/core/account_id/account_id.h" 9 #include "components/signin/core/account_id/account_id.h"
10 #include "components/user_manager/user_names.h"
10 11
11 namespace user_manager { 12 namespace user_manager {
12 13
13 UserInfoImpl::UserInfoImpl() 14 UserInfoImpl::UserInfoImpl() : account_id_(StubAccountId()) {}
14 : account_id_(AccountId::FromUserEmail("stub-user@domain.com")) {}
15 15
16 UserInfoImpl::~UserInfoImpl() { 16 UserInfoImpl::~UserInfoImpl() {
17 } 17 }
18 18
19 base::string16 UserInfoImpl::GetDisplayName() const { 19 base::string16 UserInfoImpl::GetDisplayName() const {
20 return base::UTF8ToUTF16("stub-user"); 20 return base::UTF8ToUTF16("stub-user");
21 } 21 }
22 22
23 base::string16 UserInfoImpl::GetGivenName() const { 23 base::string16 UserInfoImpl::GetGivenName() const {
24 return base::UTF8ToUTF16("Stub"); 24 return base::UTF8ToUTF16("Stub");
25 } 25 }
26 26
27 std::string UserInfoImpl::GetEmail() const { 27 std::string UserInfoImpl::GetDisplayEmail() const {
28 return account_id_.GetUserEmail(); 28 return account_id_.GetUserEmail(); // Migrated
29 } 29 }
30 30
31 const AccountId& UserInfoImpl::GetAccountId() const { 31 const AccountId& UserInfoImpl::GetAccountId() const {
32 return account_id_; 32 return account_id_;
33 } 33 }
34 34
35 const gfx::ImageSkia& UserInfoImpl::GetImage() const { 35 const gfx::ImageSkia& UserInfoImpl::GetImage() const {
36 return user_image_; 36 return user_image_;
37 } 37 }
38 38
39 } // namespace user_manager 39 } // namespace user_manager
OLDNEW
« no previous file with comments | « components/user_manager/user_info_impl.h ('k') | components/user_manager/user_names.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698