Roll src/third_party/WebKit d9c6159:8139f33 (svn 201974:201975)
[chromium-blink-merge.git] / chrome / browser / chromeos / login / ui / user_adding_screen_input_methods_controller.h
blobd3af00ed915b78c14c48ad049d95b79794649fac
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
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_UI_USER_ADDING_SCREEN_INPUT_METHODS_CONTROLLER_H_
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_UI_USER_ADDING_SCREEN_INPUT_METHODS_CONTROLLER_H_
8 #include "base/memory/ref_counted.h"
9 #include "chrome/browser/chromeos/login/ui/user_adding_screen.h"
10 #include "ui/base/ime/chromeos/input_method_manager.h"
12 namespace user_manager {
13 class User;
16 namespace chromeos {
18 // Ensure a set of "Login keyboard layouts" is used at UserAddingScreen.
19 class UserAddingScreenInputMethodsController
20 : public UserAddingScreen::Observer {
21 public:
22 explicit UserAddingScreenInputMethodsController(UserAddingScreen* screen);
23 ~UserAddingScreenInputMethodsController() override;
25 // UserAddingScreen::Observer implementation:
26 void OnUserAddingStarted() override;
27 void OnUserAddingFinished() override;
29 private:
30 UserAddingScreen* screen_;
32 scoped_refptr<input_method::InputMethodManager::State> saved_ime_state_;
33 user_manager::User* active_user_on_show_;
35 DISALLOW_COPY_AND_ASSIGN(UserAddingScreenInputMethodsController);
38 } // namespace chromeos
40 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_UI_USER_ADDING_SCREEN_INPUT_METHODS_CONTROLLER_H_