1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_UI_WEBUI_SIGNIN_USER_MANAGER_SCREEN_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_SIGNIN_USER_MANAGER_SCREEN_HANDLER_H_
8 #include "base/compiler_specific.h"
9 #include "base/memory/scoped_ptr.h"
10 #include "chrome/browser/ui/host_desktop.h"
11 #include "content/public/browser/web_ui_message_handler.h"
14 class DictionaryValue;
19 class UserManagerScreenHandler : public content::WebUIMessageHandler {
21 UserManagerScreenHandler();
22 virtual ~UserManagerScreenHandler();
24 // WebUIMessageHandler implementation.
25 virtual void RegisterMessages() OVERRIDE;
27 void GetLocalizedValues(base::DictionaryValue* localized_strings);
30 // An observer for any changes to Profiles in the ProfileInfoCache so that
31 // all the visible user manager screens can be updated.
32 class ProfileUpdateObserver;
34 void HandleInitialize(const base::ListValue* args);
35 void HandleAddUser(const base::ListValue* args);
36 void HandleLaunchGuest(const base::ListValue* args);
37 void HandleLaunchUser(const base::ListValue* args);
38 void HandleRemoveUser(const base::ListValue* args);
40 // Sends user list to account chooser.
43 // Observes the ProfileInfoCache and gets notified when a profile has been
44 // modified, so that the displayed user pods can be updated.
45 scoped_ptr<ProfileUpdateObserver> profileInfoCacheObserver_;
47 // The host desktop type this user manager belongs to.
48 chrome::HostDesktopType desktop_type_;
50 DISALLOW_COPY_AND_ASSIGN(UserManagerScreenHandler);
53 #endif // CHROME_BROWSER_UI_WEBUI_SIGNIN_USER_MANAGER_SCREEN_HANDLER_H_