summaryrefslogtreecommitdiffstats
path: root/ash/shell.cc
diff options
context:
space:
mode:
authorjonross@chromium.org <jonross@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-05-27 19:53:43 +0000
committerjonross@chromium.org <jonross@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-05-27 19:53:43 +0000
commitda285851ecc61ed9c3cdb35cd5c4e8f73ce1d6b2 (patch)
tree4e727a61b5a00faa0772f8c564850e9f392dcd1f /ash/shell.cc
parent9b40de9a316ef1dc739277a5cecc407320cc7e06 (diff)
downloadchromium_src-da285851ecc61ed9c3cdb35cd5c4e8f73ce1d6b2.zip
chromium_src-da285851ecc61ed9c3cdb35cd5c4e8f73ce1d6b2.tar.gz
chromium_src-da285851ecc61ed9c3cdb35cd5c4e8f73ce1d6b2.tar.bz2
Lock rotation when screen is manually rotated.
Lock Rotation when screen is manually rotated. This re-lands: https://codereview.chromium.org/261163004 which was reverted by: https://codereview.chromium.org/271133002 640650531fbd87578ea969b3a7f8d8a9c915bcc4. Additionally DisplayManager now accepts a source of display rotations. Those triggered by explicit user input (display settins, ctrl+shift+f3) will be stored as a part of display settings. Those triggered by rotation will not. Upon exiting maximize mode the display will be returned to the last rotation explicitly set by a user. TEST=MaximizeControllerModeTest TEST=DisplayPreferencesTest BUG=371426 BUG=369505 Review URL: https://codereview.chromium.org/289583002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@273011 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ash/shell.cc')
-rw-r--r--ash/shell.cc8
1 files changed, 8 insertions, 0 deletions
diff --git a/ash/shell.cc b/ash/shell.cc
index c0a1765..b8a69de 100644
--- a/ash/shell.cc
+++ b/ash/shell.cc
@@ -477,6 +477,14 @@ bool Shell::IsMaximizeModeWindowManagerEnabled() {
return maximize_mode_window_manager_.get() != NULL;
}
+#if defined(OS_CHROMEOS)
+bool Shell::ShouldSaveDisplaySettings() {
+ return !((IsMaximizeModeWindowManagerEnabled() &&
+ maximize_mode_controller_->in_set_screen_rotation()) ||
+ resolution_notification_controller_->DoesNotificationTimeout());
+}
+#endif
+
void Shell::UpdateShelfVisibility() {
RootWindowControllerList controllers = GetAllRootWindowControllers();
for (RootWindowControllerList::iterator iter = controllers.begin();