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

Side by Side Diff: ash/display/screen_ash.cc

Issue 2207043002: SetDeviceScaleFactorForTest Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: SetDeviceScaleFactorForTest Created 4 years, 4 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 unified diff | Download patch
« no previous file with comments | « ash/display/screen_ash.h ('k') | ash/display/screen_ash_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ash/display/screen_ash.h" 5 #include "ash/display/screen_ash.h"
6 6
7 #include "ash/aura/wm_window_aura.h" 7 #include "ash/aura/wm_window_aura.h"
8 #include "ash/common/wm/root_window_finder.h" 8 #include "ash/common/wm/root_window_finder.h"
9 #include "ash/display/display_manager.h" 9 #include "ash/display/display_manager.h"
10 #include "ash/display/window_tree_host_manager.h" 10 #include "ash/display/window_tree_host_manager.h"
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
180 } 180 }
181 181
182 void ScreenAsh::AddObserver(display::DisplayObserver* observer) { 182 void ScreenAsh::AddObserver(display::DisplayObserver* observer) {
183 observers_.AddObserver(observer); 183 observers_.AddObserver(observer);
184 } 184 }
185 185
186 void ScreenAsh::RemoveObserver(display::DisplayObserver* observer) { 186 void ScreenAsh::RemoveObserver(display::DisplayObserver* observer) {
187 observers_.RemoveObserver(observer); 187 observers_.RemoveObserver(observer);
188 } 188 }
189 189
190 void ScreenAsh::SetDeviceScaleFactorForTest(float scale_factor) {
191 display::Display::SetForceDeviceScaleFactorForTesting(scale_factor);
192 GetDisplayManager()->UpdateDisplays();
193 }
194
190 display::Screen* ScreenAsh::CloneForShutdown() { 195 display::Screen* ScreenAsh::CloneForShutdown() {
191 return new ScreenForShutdown(this); 196 return new ScreenForShutdown(this);
192 } 197 }
193 198
194 } // namespace ash 199 } // namespace ash
OLDNEW
« no previous file with comments | « ash/display/screen_ash.h ('k') | ash/display/screen_ash_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698