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

Unified Diff: ash/test/screen_orientation_controller_test_api.cc

Issue 2757493002: User orientation lock (Closed)
Patch Set: rebase again Created 3 years, 9 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/screen_orientation_controller_test_api.cc
diff --git a/ash/test/screen_orientation_controller_test_api.cc b/ash/test/screen_orientation_controller_test_api.cc
new file mode 100644
index 0000000000000000000000000000000000000000..16b513755dff74bc5b28cdcf83ddc124f73d5ad9
--- /dev/null
+++ b/ash/test/screen_orientation_controller_test_api.cc
@@ -0,0 +1,32 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "ash/test/screen_orientation_controller_test_api.h"
+
+#include "ash/display/screen_orientation_controller_chromeos.h"
+
+namespace ash {
+namespace test {
+
+ScreenOrientationControllerTestApi::ScreenOrientationControllerTestApi(
+ ScreenOrientationController* controller)
+ : controller_(controller) {}
+
+void ScreenOrientationControllerTestApi::SetDisplayRotation(
+ display::Display::Rotation rotation,
+ display::Display::RotationSource source) {
+ controller_->SetDisplayRotation(rotation, source);
+}
+
+void ScreenOrientationControllerTestApi::SetRotationLocked(bool locked) {
+ controller_->SetRotationLockedInternal(locked);
+}
+
+blink::WebScreenOrientationLockType
+ScreenOrientationControllerTestApi::UserLockedOrientation() const {
+ return controller_->user_locked_orientation_;
+}
+
+} // namespace test
+} // namespace ash
« no previous file with comments | « ash/test/screen_orientation_controller_test_api.h ('k') | chrome/browser/chromeos/display/display_preferences_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698