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 ASH_DISPLAY_VIRTUAL_KEYBOARD_WINDOW_CONTROLLER_H_
6 #define ASH_DISPLAY_VIRTUAL_KEYBOARD_WINDOW_CONTROLLER_H_
8 #include "ash/ash_export.h"
9 #include "ash/shell_observer.h"
10 #include "base/compiler_specific.h"
11 #include "base/memory/scoped_ptr.h"
12 #include "ui/gfx/display.h"
15 class KeyboardController
;
20 class RootWindowController
;
23 class VirtualKeyboardWindowControllerTest
;
26 // This class maintains the RootWindowController dedicated for
28 class ASH_EXPORT VirtualKeyboardWindowController
: public ShellObserver
{
30 VirtualKeyboardWindowController();
31 virtual ~VirtualKeyboardWindowController();
33 void ActivateKeyboard(keyboard::KeyboardController
* keyboard_controller
);
35 // Updates the root window's bounds using |display_info|.
36 // Creates the new root window if one doesn't exist.
37 void UpdateWindow(const DisplayInfo
& display_info
);
39 // Close the mirror window.
43 virtual void OnMaximizeModeStarted() OVERRIDE
;
44 virtual void OnMaximizeModeEnded() OVERRIDE
;
47 friend class test::VirtualKeyboardWindowControllerTest
;
49 // Rotates virtual keyboard display by 180 degrees.
52 RootWindowController
* root_window_controller_for_test() {
53 return root_window_controller_
.get();
56 scoped_ptr
<RootWindowController
> root_window_controller_
;
58 DISALLOW_COPY_AND_ASSIGN(VirtualKeyboardWindowController
);
63 #endif // ASH_DISPLAY_VIRTUAL_KEYBOARD_WINDOW_CONTROLLER_H_