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

Unified Diff: chrome/browser/chromeos/display/display_preferences.cc

Issue 289583002: Lock rotation when screen is manually rotated. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Define sources for rotation Created 6 years, 7 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: chrome/browser/chromeos/display/display_preferences.cc
diff --git a/chrome/browser/chromeos/display/display_preferences.cc b/chrome/browser/chromeos/display/display_preferences.cc
index 25a2356da281844bc83f32edb45890943f17cc67..8a450df5676438967ffbaee993d52530e6955848 100644
--- a/chrome/browser/chromeos/display/display_preferences.cc
+++ b/chrome/browser/chromeos/display/display_preferences.cc
@@ -21,6 +21,7 @@
#include "chrome/browser/chromeos/login/user_manager.h"
#include "chrome/common/pref_names.h"
#include "third_party/cros_system_api/dbus/service_constants.h"
+#include "ui/display/types/display_constants.h"
#include "ui/gfx/display.h"
#include "ui/gfx/insets.h"
#include "ui/gfx/screen.h"
@@ -229,7 +230,8 @@ void StoreCurrentDisplayProperties() {
scoped_ptr<base::DictionaryValue> property_value(
new base::DictionaryValue());
- property_value->SetInteger("rotation", static_cast<int>(info.rotation()));
+ property_value->SetInteger("rotation", static_cast<int>(info.GetRotation(
+ ui::USER)));
property_value->SetInteger(
"ui-scale",
static_cast<int>(info.configured_ui_scale() * 1000));

Powered by Google App Engine
This is Rietveld 408576698