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

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

Issue 138903025: Read compositor VSync information from platform, when possible (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 287efe04 Rebase, oshima@ nits. Created 6 years, 10 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 ab7697bde0ae4358ad98519c06c7b3670951d484..b41f056f351ed237873523a2a3b842aeace0e256 100644
--- a/chrome/browser/chromeos/display/display_preferences.cc
+++ b/chrome/browser/chromeos/display/display_preferences.cc
@@ -199,11 +199,12 @@ void StoreCurrentDisplayProperties() {
property_value->SetInteger(
"ui-scale",
static_cast<int>(info.configured_ui_scale() * 1000));
- gfx::Size resolution;
+ ash::internal::DisplayMode mode;
if (!display.IsInternal() &&
- display_manager->GetSelectedResolutionForDisplayId(id, &resolution)) {
- property_value->SetInteger("width", resolution.width());
- property_value->SetInteger("height", resolution.height());
+ display_manager->GetSelectedModeForDisplayId(id, &mode) &&
+ !mode.native) {
+ property_value->SetInteger("width", mode.size.width());
+ property_value->SetInteger("height", mode.size.height());
}
if (!info.overscan_insets_in_dip().empty())
« no previous file with comments | « cc/output/output_surface_unittest.cc ('k') | chrome/browser/chromeos/display/display_preferences_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698