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

Side by Side Diff: ash/touch/touch_hud_debug.cc

Issue 224113005: Eliminate ash::internal namespace (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « ash/touch/touch_hud_debug.h ('k') | ash/touch/touch_hud_projection.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/touch/touch_hud_debug.h" 5 #include "ash/touch/touch_hud_debug.h"
6 6
7 #include "ash/display/display_manager.h" 7 #include "ash/display/display_manager.h"
8 #include "ash/root_window_controller.h" 8 #include "ash/root_window_controller.h"
9 #include "ash/shell.h" 9 #include "ash/shell.h"
10 #include "base/json/json_string_value_serializer.h" 10 #include "base/json/json_string_value_serializer.h"
(...skipping 13 matching lines...) Expand all
24 #include "ui/views/widget/widget.h" 24 #include "ui/views/widget/widget.h"
25 25
26 #if defined(USE_X11) 26 #if defined(USE_X11)
27 #include <X11/extensions/XInput2.h> 27 #include <X11/extensions/XInput2.h>
28 #include <X11/Xlib.h> 28 #include <X11/Xlib.h>
29 29
30 #include "ui/events/x/device_data_manager.h" 30 #include "ui/events/x/device_data_manager.h"
31 #endif 31 #endif
32 32
33 namespace ash { 33 namespace ash {
34 namespace internal {
35 34
36 const int kPointRadius = 20; 35 const int kPointRadius = 20;
37 const SkColor kColors[] = { 36 const SkColor kColors[] = {
38 SK_ColorYELLOW, 37 SK_ColorYELLOW,
39 SK_ColorGREEN, 38 SK_ColorGREEN,
40 SK_ColorRED, 39 SK_ColorRED,
41 SK_ColorBLUE, 40 SK_ColorBLUE,
42 SK_ColorGRAY, 41 SK_ColorGRAY,
43 SK_ColorMAGENTA, 42 SK_ColorMAGENTA,
44 SK_ColorCYAN, 43 SK_ColorCYAN,
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after
367 366
368 TouchHudDebug::~TouchHudDebug() { 367 TouchHudDebug::~TouchHudDebug() {
369 } 368 }
370 369
371 // static 370 // static
372 scoped_ptr<base::DictionaryValue> TouchHudDebug::GetAllAsDictionary() { 371 scoped_ptr<base::DictionaryValue> TouchHudDebug::GetAllAsDictionary() {
373 scoped_ptr<base::DictionaryValue> value(new base::DictionaryValue()); 372 scoped_ptr<base::DictionaryValue> value(new base::DictionaryValue());
374 aura::Window::Windows roots = Shell::GetInstance()->GetAllRootWindows(); 373 aura::Window::Windows roots = Shell::GetInstance()->GetAllRootWindows();
375 for (aura::Window::Windows::iterator iter = roots.begin(); 374 for (aura::Window::Windows::iterator iter = roots.begin();
376 iter != roots.end(); ++iter) { 375 iter != roots.end(); ++iter) {
377 internal::RootWindowController* controller = GetRootWindowController(*iter); 376 RootWindowController* controller = GetRootWindowController(*iter);
378 internal::TouchHudDebug* hud = controller->touch_hud_debug(); 377 TouchHudDebug* hud = controller->touch_hud_debug();
379 if (hud) { 378 if (hud) {
380 scoped_ptr<base::ListValue> list = hud->GetLogAsList(); 379 scoped_ptr<base::ListValue> list = hud->GetLogAsList();
381 if (!list->empty()) 380 if (!list->empty())
382 value->Set(base::Int64ToString(hud->display_id()), list.release()); 381 value->Set(base::Int64ToString(hud->display_id()), list.release());
383 } 382 }
384 } 383 }
385 return value.Pass(); 384 return value.Pass();
386 } 385 }
387 386
388 void TouchHudDebug::ChangeToNextMode() { 387 void TouchHudDebug::ChangeToNextMode() {
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
479 void TouchHudDebug::SetHudForRootWindowController( 478 void TouchHudDebug::SetHudForRootWindowController(
480 RootWindowController* controller) { 479 RootWindowController* controller) {
481 controller->set_touch_hud_debug(this); 480 controller->set_touch_hud_debug(this);
482 } 481 }
483 482
484 void TouchHudDebug::UnsetHudForRootWindowController( 483 void TouchHudDebug::UnsetHudForRootWindowController(
485 RootWindowController* controller) { 484 RootWindowController* controller) {
486 controller->set_touch_hud_debug(NULL); 485 controller->set_touch_hud_debug(NULL);
487 } 486 }
488 487
489 } // namespace internal
490 } // namespace ash 488 } // namespace ash
OLDNEW
« no previous file with comments | « ash/touch/touch_hud_debug.h ('k') | ash/touch/touch_hud_projection.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698