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

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

Issue 280833002: Re-land "Issue 191223007: Move touch CTM from X into Chrome" (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: adding missing file again 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 unified diff | Download patch
« no previous file with comments | « ash/ash.gyp ('k') | ash/display/display_info.h » ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/display_change_observer_chromeos.h" 5 #include "ash/display/display_change_observer_chromeos.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 #include <vector> 10 #include <vector>
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 145
146 displays.push_back(DisplayInfo(id, name, has_overscan)); 146 displays.push_back(DisplayInfo(id, name, has_overscan));
147 DisplayInfo& new_info = displays.back(); 147 DisplayInfo& new_info = displays.back();
148 new_info.set_device_scale_factor(device_scale_factor); 148 new_info.set_device_scale_factor(device_scale_factor);
149 new_info.SetBounds(display_bounds); 149 new_info.SetBounds(display_bounds);
150 new_info.set_native(true); 150 new_info.set_native(true);
151 new_info.set_display_modes(display_modes); 151 new_info.set_display_modes(display_modes);
152 new_info.set_touch_support(state.touch_device_id == 0 ? 152 new_info.set_touch_support(state.touch_device_id == 0 ?
153 gfx::Display::TOUCH_SUPPORT_UNAVAILABLE : 153 gfx::Display::TOUCH_SUPPORT_UNAVAILABLE :
154 gfx::Display::TOUCH_SUPPORT_AVAILABLE); 154 gfx::Display::TOUCH_SUPPORT_AVAILABLE);
155 new_info.set_touch_device_id(state.touch_device_id);
155 new_info.set_available_color_profiles( 156 new_info.set_available_color_profiles(
156 Shell::GetInstance() 157 Shell::GetInstance()
157 ->display_configurator() 158 ->display_configurator()
158 ->GetAvailableColorCalibrationProfiles(id)); 159 ->GetAvailableColorCalibrationProfiles(id));
159 } 160 }
160 161
161 // DisplayManager can be null during the boot. 162 // DisplayManager can be null during the boot.
162 Shell::GetInstance()->display_manager()->OnNativeDisplaysChanged(displays); 163 Shell::GetInstance()->display_manager()->OnNativeDisplaysChanged(displays);
163 } 164 }
164 165
165 void DisplayChangeObserver::OnAppTerminating() { 166 void DisplayChangeObserver::OnAppTerminating() {
166 #if defined(USE_ASH) 167 #if defined(USE_ASH)
167 // Stop handling display configuration events once the shutdown 168 // Stop handling display configuration events once the shutdown
168 // process starts. crbug.com/177014. 169 // process starts. crbug.com/177014.
169 Shell::GetInstance()->display_configurator()->PrepareForExit(); 170 Shell::GetInstance()->display_configurator()->PrepareForExit();
170 #endif 171 #endif
171 } 172 }
172 173
173 } // namespace ash 174 } // namespace ash
OLDNEW
« no previous file with comments | « ash/ash.gyp ('k') | ash/display/display_info.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698