Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(268)

Unified Diff: ash/test/ash_test_helper.cc

Issue 2837893002: Wires up InputDeviceClient for mash/mushrome (Closed)
Patch Set: comment Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ash/test/ash_test_helper.cc
diff --git a/ash/test/ash_test_helper.cc b/ash/test/ash_test_helper.cc
index ac80264797a1b23043e93230fedcea56cf35c799..3a48ae33f8f2ba546f02f080ca780615f6804bbd 100644
--- a/ash/test/ash_test_helper.cc
+++ b/ash/test/ash_test_helper.cc
@@ -32,6 +32,7 @@
#include "chromeos/network/network_handler.h"
#include "device/bluetooth/bluetooth_adapter_factory.h"
#include "device/bluetooth/dbus/bluez_dbus_manager.h"
+#include "services/ui/public/cpp/input_devices/input_device_client.h"
#include "ui/aura/env.h"
#include "ui/aura/input_state_lookup.h"
#include "ui/aura/mus/window_tree_client.h"
@@ -82,6 +83,9 @@ AshTestHelper::AshTestHelper(AshTestEnvironment* ash_test_environment)
AshTestHelper::~AshTestHelper() {}
void AshTestHelper::SetUp(bool start_session) {
+ if (config_ == Config::MUS)
+ input_device_client_ = base::MakeUnique<ui::InputDeviceClient>();
+
display::ResetDisplayIdForTest();
if (config_ != Config::CLASSIC)
aura::test::EnvTestHelper().SetAlwaysUseLastMouseLocation(true);
@@ -220,6 +224,8 @@ void AshTestHelper::TearDown() {
test_views_delegate_.reset();
wm_state_.reset();
+ input_device_client_.reset();
+
// WindowManager owns the CaptureController for mus/mash.
CHECK(config_ != Config::CLASSIC || !::wm::CaptureController::Get());
}

Powered by Google App Engine
This is Rietveld 408576698