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

Side by Side Diff: chrome/browser/chromeos/login/screens/user_selection_screen.h

Issue 833893003: Move UserActivityDetector to ui/base/user_activity/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: don't build test on android Created 5 years, 11 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
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 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_USER_SELECTION_SCREEN_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_USER_SELECTION_SCREEN_H_
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_USER_SELECTION_SCREEN_H_ 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_USER_SELECTION_SCREEN_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
11 11
12 #include "base/compiler_specific.h" 12 #include "base/compiler_specific.h"
13 #include "base/timer/timer.h" 13 #include "base/timer/timer.h"
14 #include "base/values.h" 14 #include "base/values.h"
15 #include "chrome/browser/chromeos/login/ui/login_display.h" 15 #include "chrome/browser/chromeos/login/ui/login_display.h"
16 #include "chrome/browser/chromeos/login/ui/models/user_board_model.h" 16 #include "chrome/browser/chromeos/login/ui/models/user_board_model.h"
17 #include "chrome/browser/signin/screenlock_bridge.h" 17 #include "chrome/browser/signin/screenlock_bridge.h"
18 #include "components/user_manager/user.h" 18 #include "components/user_manager/user.h"
19 #include "ui/wm/core/user_activity_observer.h" 19 #include "ui/base/user_activity/user_activity_observer.h"
20 20
21 class EasyUnlockService; 21 class EasyUnlockService;
22 22
23 namespace chromeos { 23 namespace chromeos {
24 24
25 class LoginDisplayWebUIHandler; 25 class LoginDisplayWebUIHandler;
26 class UserBoardView; 26 class UserBoardView;
27 27
28 // This class represents User Selection screen: user pod-based login screen. 28 // This class represents User Selection screen: user pod-based login screen.
29 class UserSelectionScreen : public wm::UserActivityObserver, 29 class UserSelectionScreen : public ui::UserActivityObserver,
30 public ScreenlockBridge::LockHandler, 30 public ScreenlockBridge::LockHandler,
31 public UserBoardModel { 31 public UserBoardModel {
32 public: 32 public:
33 explicit UserSelectionScreen(const std::string& display_type); 33 explicit UserSelectionScreen(const std::string& display_type);
34 virtual ~UserSelectionScreen(); 34 virtual ~UserSelectionScreen();
35 35
36 void SetLoginDisplayDelegate(LoginDisplay::Delegate* login_display_delegate); 36 void SetLoginDisplayDelegate(LoginDisplay::Delegate* login_display_delegate);
37 void SetHandler(LoginDisplayWebUIHandler* handler); 37 void SetHandler(LoginDisplayWebUIHandler* handler);
38 void SetView(UserBoardView* view); 38 void SetView(UserBoardView* view);
39 39
40 static const user_manager::UserList PrepareUserListForSending( 40 static const user_manager::UserList PrepareUserListForSending(
41 const user_manager::UserList& users, 41 const user_manager::UserList& users,
42 std::string owner, 42 std::string owner,
43 bool is_signin_to_add); 43 bool is_signin_to_add);
44 44
45 45
46 virtual void Init(const user_manager::UserList& users, bool show_guest); 46 virtual void Init(const user_manager::UserList& users, bool show_guest);
47 const user_manager::UserList& GetUsers() const; 47 const user_manager::UserList& GetUsers() const;
48 void OnUserImageChanged(const user_manager::User& user); 48 void OnUserImageChanged(const user_manager::User& user);
49 void OnBeforeUserRemoved(const std::string& username); 49 void OnBeforeUserRemoved(const std::string& username);
50 void OnUserRemoved(const std::string& username); 50 void OnUserRemoved(const std::string& username);
51 51
52 void OnPasswordClearTimerExpired(); 52 void OnPasswordClearTimerExpired();
53 53
54 void HandleGetUsers(); 54 void HandleGetUsers();
55 55
56 // wm::UserActivityDetector implementation: 56 // ui::UserActivityDetector implementation:
57 virtual void OnUserActivity(const ui::Event* event) override; 57 virtual void OnUserActivity(const ui::Event* event) override;
58 58
59 void InitEasyUnlock(); 59 void InitEasyUnlock();
60 60
61 // ScreenlockBridge::LockHandler implementation: 61 // ScreenlockBridge::LockHandler implementation:
62 virtual void ShowBannerMessage(const base::string16& message) override; 62 virtual void ShowBannerMessage(const base::string16& message) override;
63 virtual void ShowUserPodCustomIcon( 63 virtual void ShowUserPodCustomIcon(
64 const std::string& user_email, 64 const std::string& user_email,
65 const ScreenlockBridge::UserPodCustomIconOptions& icon) override; 65 const ScreenlockBridge::UserPodCustomIconOptions& icon) override;
66 virtual void HideUserPodCustomIcon(const std::string& user_email) override; 66 virtual void HideUserPodCustomIcon(const std::string& user_email) override;
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 123
124 // Timer for measuring idle state duration before password clear. 124 // Timer for measuring idle state duration before password clear.
125 base::OneShotTimer<UserSelectionScreen> password_clear_timer_; 125 base::OneShotTimer<UserSelectionScreen> password_clear_timer_;
126 126
127 DISALLOW_COPY_AND_ASSIGN(UserSelectionScreen); 127 DISALLOW_COPY_AND_ASSIGN(UserSelectionScreen);
128 }; 128 };
129 129
130 } // namespace chromeos 130 } // namespace chromeos
131 131
132 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_USER_SELECTION_SCREEN_H_ 132 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SCREENS_USER_SELECTION_SCREEN_H_
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/idle_detector.cc ('k') | chrome/browser/chromeos/login/screens/user_selection_screen.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698