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

Unified Diff: ash/accelerators/accelerator_controller_delegate_aura.cc

Issue 2355063002: Separate ash::test::DisplayManagerTestApi from ash (Closed)
Patch Set: review comment Created 4 years, 2 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
« no previous file with comments | « no previous file | ash/content/display/screen_orientation_controller_chromeos_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/accelerators/accelerator_controller_delegate_aura.cc
diff --git a/ash/accelerators/accelerator_controller_delegate_aura.cc b/ash/accelerators/accelerator_controller_delegate_aura.cc
index f8c755b48aa5271ffb998c1331b3f20ade5601c7..aa2bb2b270edd97e47f586c61cd2d818c4bd4668 100644
--- a/ash/accelerators/accelerator_controller_delegate_aura.cc
+++ b/ash/accelerators/accelerator_controller_delegate_aura.cc
@@ -31,7 +31,6 @@
#include "ash/root_window_controller.h"
#include "ash/rotator/screen_rotation_animator.h"
#include "ash/rotator/window_rotation.h"
-#include "ash/screen_util.h"
#include "ash/screenshot_delegate.h"
#include "ash/shell.h"
#include "ash/touch/touch_hud_debug.h"
@@ -236,8 +235,13 @@ bool CanHandleUnpin() {
#if defined(OS_CHROMEOS)
void HandleSwapPrimaryDisplay() {
base::RecordAction(UserMetricsAction("Accel_Swap_Primary_Display"));
+
+ // TODO(rjkroege): This is not correct behaviour on devices with more than
+ // two screens. Behave the same as mirroring: fail and notify if there are
+ // three or more screens.
Shell::GetInstance()->display_configuration_controller()->SetPrimaryDisplayId(
- ScreenUtil::GetSecondaryDisplay().id(), true /* user_action */);
+ Shell::GetInstance()->display_manager()->GetSecondaryDisplay().id(),
+ true /* user_action */);
}
void HandleToggleMirrorMode() {
« no previous file with comments | « no previous file | ash/content/display/screen_orientation_controller_chromeos_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698