Index: ash/display/display_controller.cc |
diff --git a/ash/display/display_controller.cc b/ash/display/display_controller.cc |
index 35ae9d3ab5215cad0e37542a7dfa385629754f34..22ad0781c0a6265664fadcf4468b8258c453b5b2 100644 |
--- a/ash/display/display_controller.cc |
+++ b/ash/display/display_controller.cc |
@@ -225,11 +225,12 @@ bool DisplayController::DisplayChangeLimiter::IsThrottled() const { |
//////////////////////////////////////////////////////////////////////////////// |
// DisplayController |
-DisplayController::DisplayController() |
- : primary_tree_host_for_replace_(NULL), |
+DisplayController::DisplayController(ui::ContextFactory* context_factory) |
+ : context_factory_(context_factory), |
+ primary_tree_host_for_replace_(NULL), |
focus_activation_store_(new FocusActivationStore()), |
cursor_window_controller_(new CursorWindowController()), |
- mirror_window_controller_(new MirrorWindowController()) { |
+ mirror_window_controller_(new MirrorWindowController(context_factory)) { |
#if defined(OS_CHROMEOS) |
if (base::SysInfo::IsRunningOnChromeOS()) |
limiter_.reset(new DisplayChangeLimiter); |
@@ -246,7 +247,7 @@ void DisplayController::Start() { |
// Created here so that Shell has finished being created. Adds itself |
// as a ShellObserver. |
virtual_keyboard_window_controller_.reset( |
- new VirtualKeyboardWindowController); |
+ new VirtualKeyboardWindowController(context_factory_)); |
Shell::GetScreen()->AddObserver(this); |
Shell::GetInstance()->display_manager()->set_delegate(this); |
} |
@@ -712,6 +713,7 @@ AshWindowTreeHost* DisplayController::AddWindowTreeHostForDisplay( |
GetDisplayManager()->GetDisplayInfo(display.id()); |
AshWindowTreeHostInitParams params_with_bounds(init_params); |
params_with_bounds.initial_bounds = display_info.bounds_in_native(); |
+ params_with_bounds.context_factory = context_factory_; |
AshWindowTreeHost* ash_host = AshWindowTreeHost::Create(params_with_bounds); |
aura::WindowTreeHost* host = ash_host->AsWindowTreeHost(); |