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

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

Issue 12087124: Disable touch calibration on external touchscreen. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix Win compilation take 2 + rebase Created 7 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 unified diff | Download patch
« no previous file with comments | « no previous file | ash/host/root_window_host_factory.h » ('j') | ui/aura/root_window.h » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_manager.h" 5 #include "ash/display/display_manager.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "ash/display/display_controller.h" 10 #include "ash/display/display_controller.h"
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after
327 #if defined(USE_X11) && defined(OS_CHROMEOS) 327 #if defined(USE_X11) && defined(OS_CHROMEOS)
328 if (!changed_display_indices.empty() && base::chromeos::IsRunningOnChromeOS()) 328 if (!changed_display_indices.empty() && base::chromeos::IsRunningOnChromeOS())
329 ui::ClearX11DefaultRootWindow(); 329 ui::ClearX11DefaultRootWindow();
330 #endif 330 #endif
331 } 331 }
332 332
333 RootWindow* DisplayManager::CreateRootWindowForDisplay( 333 RootWindow* DisplayManager::CreateRootWindowForDisplay(
334 const gfx::Display& display) { 334 const gfx::Display& display) {
335 static int root_window_count = 0; 335 static int root_window_count = 0;
336 336
337 RootWindow::CreateParams params(display.bounds_in_pixel()); 337 RootWindow::CreateParams params(display.bounds_in_pixel(),
338 IsInternalDisplayId(display.id()));
338 params.host = Shell::GetInstance()->root_window_host_factory()-> 339 params.host = Shell::GetInstance()->root_window_host_factory()->
339 CreateRootWindowHost(display.bounds_in_pixel()); 340 CreateRootWindowHost(display.bounds_in_pixel(),
341 IsInternalDisplayId(display.id()));
340 aura::RootWindow* root_window = new aura::RootWindow(params); 342 aura::RootWindow* root_window = new aura::RootWindow(params);
341 root_window->SetName(StringPrintf("RootWindow-%d", root_window_count++)); 343 root_window->SetName(StringPrintf("RootWindow-%d", root_window_count++));
342 344
343 // No need to remove RootWindowObserver because 345 // No need to remove RootWindowObserver because
344 // the DisplayManager object outlives RootWindow objects. 346 // the DisplayManager object outlives RootWindow objects.
345 root_window->AddRootWindowObserver(this); 347 root_window->AddRootWindowObserver(this);
346 root_window->SetProperty(kDisplayIdKey, display.id()); 348 root_window->SetProperty(kDisplayIdKey, display.id());
347 root_window->Init(); 349 root_window->Init();
348 return root_window; 350 return root_window;
349 } 351 }
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after
606 (*iter_to_update).set_id((*iter).id()); 608 (*iter_to_update).set_id((*iter).id());
607 } 609 }
608 } 610 }
609 611
610 void DisplayManager::SetHasOverscanFlagForTest(int64 id, bool has_overscan) { 612 void DisplayManager::SetHasOverscanFlagForTest(int64 id, bool has_overscan) {
611 display_info_[id].has_overscan = has_overscan; 613 display_info_[id].has_overscan = has_overscan;
612 } 614 }
613 615
614 } // namespace internal 616 } // namespace internal
615 } // namespace ash 617 } // namespace ash
OLDNEW
« no previous file with comments | « no previous file | ash/host/root_window_host_factory.h » ('j') | ui/aura/root_window.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698