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

Unified Diff: ash/display/display_change_observer_chromeos.cc

Issue 562413002: Adds (native) annotation to the display settings. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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/display/display_change_observer_chromeos_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/display/display_change_observer_chromeos.cc
diff --git a/ash/display/display_change_observer_chromeos.cc b/ash/display/display_change_observer_chromeos.cc
index 1df63bde4077daa23ac49c71c0b65a5a4fb49cd4..3f1f87a786cf1554c97dd1fea55bc2990cae34e6 100644
--- a/ash/display/display_change_observer_chromeos.cc
+++ b/ash/display/display_change_observer_chromeos.cc
@@ -84,7 +84,11 @@ std::vector<DisplayMode> DisplayChangeObserver::GetInternalDisplayModeList(
for (size_t i = 0; i < ui_scales.size(); ++i) {
DisplayMode mode = native_mode;
mode.ui_scale = ui_scales[i];
- mode.native = (ui_scales[i] == 1.0f);
+ if (display_info.device_scale_factor() == 2.0f) {
+ mode.native = (ui_scales[i] == 2.0f);
+ } else {
+ mode.native = (ui_scales[i] == 1.0f);
+ }
oshima 2014/09/12 17:23:49 this should be mode.native = (ui_scales[i] == dev
Jun Mukai 2014/09/12 18:50:55 right, done. also added the test case of dsf == 1
display_mode_list.push_back(mode);
}
« no previous file with comments | « no previous file | ash/display/display_change_observer_chromeos_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698