OLD | NEW |
---|---|
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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/chromeos/login/lock/views_screen_locker.h" | 5 #include "chrome/browser/chromeos/login/lock/views_screen_locker.h" |
6 | 6 |
7 #include "base/metrics/histogram_macros.h" | 7 #include "base/metrics/histogram_macros.h" |
8 #include "chrome/browser/chromeos/login/screens/chrome_user_selection_screen.h" | 8 #include "chrome/browser/chromeos/login/screens/chrome_user_selection_screen.h" |
9 #include "chrome/browser/chromeos/login/user_selection_screen_proxy.h" | 9 #include "chrome/browser/chromeos/login/user_selection_screen_proxy.h" |
10 | 10 |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
70 NOTIMPLEMENTED(); | 70 NOTIMPLEMENTED(); |
71 } | 71 } |
72 | 72 |
73 content::WebContents* ViewsScreenLocker::GetWebContents() { | 73 content::WebContents* ViewsScreenLocker::GetWebContents() { |
74 return nullptr; | 74 return nullptr; |
75 } | 75 } |
76 | 76 |
77 void ViewsScreenLocker::Init() { | 77 void ViewsScreenLocker::Init() { |
78 lock_time_ = base::TimeTicks::Now(); | 78 lock_time_ = base::TimeTicks::Now(); |
79 user_selection_screen_->Init(screen_locker_->users()); | 79 user_selection_screen_->Init(screen_locker_->users()); |
80 LockScreenClient::Get()->LoadUsers(user_selection_screen_->PrepareUserList(), | 80 LockScreenClient::Get()->LoadUsers( |
81 false /* show_guests */); | 81 user_selection_screen_->PrepareUserListToMojo(), false /* show_guests */); |
jdufault
2017/06/13 17:41:54
nit: ToMojo -> ForMojo
xiaoyinh(OOO Sep 11-29)
2017/06/13 22:21:30
Updated.
| |
82 } | 82 } |
83 | 83 |
84 void ViewsScreenLocker::OnLockScreenReady() { | 84 void ViewsScreenLocker::OnLockScreenReady() { |
85 user_selection_screen_->InitEasyUnlock(); | 85 user_selection_screen_->InitEasyUnlock(); |
86 UMA_HISTOGRAM_TIMES("LockScreen.LockReady", | 86 UMA_HISTOGRAM_TIMES("LockScreen.LockReady", |
87 base::TimeTicks::Now() - lock_time_); | 87 base::TimeTicks::Now() - lock_time_); |
88 screen_locker_->ScreenLockReady(); | 88 screen_locker_->ScreenLockReady(); |
89 } | 89 } |
90 | 90 |
91 void ViewsScreenLocker::HandleAttemptUnlock(const AccountId& account_id) { | 91 void ViewsScreenLocker::HandleAttemptUnlock(const AccountId& account_id) { |
92 user_selection_screen_->AttemptEasyUnlock(account_id); | 92 user_selection_screen_->AttemptEasyUnlock(account_id); |
93 } | 93 } |
94 | 94 |
95 void ViewsScreenLocker::HandleHardlockPod(const AccountId& account_id) { | 95 void ViewsScreenLocker::HandleHardlockPod(const AccountId& account_id) { |
96 user_selection_screen_->HardLockPod(account_id); | 96 user_selection_screen_->HardLockPod(account_id); |
97 } | 97 } |
98 | 98 |
99 void ViewsScreenLocker::HandleRecordClickOnLockIcon( | 99 void ViewsScreenLocker::HandleRecordClickOnLockIcon( |
100 const AccountId& account_id) { | 100 const AccountId& account_id) { |
101 user_selection_screen_->RecordClickOnLockIcon(account_id); | 101 user_selection_screen_->RecordClickOnLockIcon(account_id); |
102 } | 102 } |
103 | 103 |
104 } // namespace chromeos | 104 } // namespace chromeos |
OLD | NEW |