Home | History | Annotate | Download | only in login
      1 // Copyright (c) 2010 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.
      4 
      5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_USER_INPUT_H_
      6 #define CHROME_BROWSER_CHROMEOS_LOGIN_USER_INPUT_H_
      7 
      8 #include "ui/gfx/rect.h"
      9 
     10 namespace chromeos {
     11 
     12 // Interface that is used to manage the state of the user input controls.
     13 class UserInput {
     14  public:
     15   virtual ~UserInput() {}
     16 
     17   // Enables/Disables the input controls.
     18   virtual void EnableInputControls(bool enabled) = 0;
     19 
     20   // Clears and focuses the controls.
     21   virtual void ClearAndFocusControls() = 0;
     22 
     23   // Clears and focuses the password field.
     24   virtual void ClearAndFocusPassword() = 0;
     25 
     26   // Returns bounds of the main input field in the screen coordinates (e.g.
     27   // these bounds could be used to choose positions for the error bubble).
     28   virtual gfx::Rect GetMainInputScreenBounds() const = 0;
     29 };
     30 
     31 }  // namespace chromeos
     32 
     33 #endif  // CHROME_BROWSER_CHROMEOS_LOGIN_USER_INPUT_H_
     34