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

Side by Side Diff: ash/accelerators/debug_commands.cc

Issue 1261693004: Allow dynamic enabling/disabling of unified desktop (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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/accelerators/accelerator_table.cc ('k') | ash/ash_switches.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/accelerators/debug_commands.h" 5 #include "ash/accelerators/debug_commands.h"
6 6
7 #include "ash/accelerators/accelerator_commands.h" 7 #include "ash/accelerators/accelerator_commands.h"
8 #include "ash/ash_switches.h" 8 #include "ash/ash_switches.h"
9 #include "ash/debug.h" 9 #include "ash/debug.h"
10 #include "ash/desktop_background/desktop_background_controller.h" 10 #include "ash/desktop_background/desktop_background_controller.h"
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 141
142 void PerformDebugActionIfEnabled(AcceleratorAction action) { 142 void PerformDebugActionIfEnabled(AcceleratorAction action) {
143 if (!DebugAcceleratorsEnabled()) 143 if (!DebugAcceleratorsEnabled())
144 return; 144 return;
145 145
146 switch (action) { 146 switch (action) {
147 #if defined(OS_CHROMEOS) 147 #if defined(OS_CHROMEOS)
148 case DEBUG_ADD_REMOVE_DISPLAY: 148 case DEBUG_ADD_REMOVE_DISPLAY:
149 Shell::GetInstance()->display_manager()->AddRemoveDisplay(); 149 Shell::GetInstance()->display_manager()->AddRemoveDisplay();
150 break; 150 break;
151 case DEBUG_TOGGLE_UNIFIED_DESKTOP:
152 Shell::GetInstance()->display_manager()->SetUnifiedDesktopEnabled(
153 !Shell::GetInstance()->display_manager()->unified_desktop_enabled());
154 break;
151 #endif 155 #endif
152 case DEBUG_PRINT_LAYER_HIERARCHY: 156 case DEBUG_PRINT_LAYER_HIERARCHY:
153 HandlePrintLayerHierarchy(); 157 HandlePrintLayerHierarchy();
154 break; 158 break;
155 case DEBUG_PRINT_VIEW_HIERARCHY: 159 case DEBUG_PRINT_VIEW_HIERARCHY:
156 HandlePrintViewHierarchy(); 160 HandlePrintViewHierarchy();
157 break; 161 break;
158 case DEBUG_PRINT_WINDOW_HIERARCHY: 162 case DEBUG_PRINT_WINDOW_HIERARCHY:
159 HandlePrintWindowHierarchy(); 163 HandlePrintWindowHierarchy();
160 break; 164 break;
(...skipping 15 matching lines...) Expand all
176 case DEBUG_TOGGLE_SHOW_PAINT_RECTS: 180 case DEBUG_TOGGLE_SHOW_PAINT_RECTS:
177 ToggleShowPaintRects(); 181 ToggleShowPaintRects();
178 break; 182 break;
179 default: 183 default:
180 break; 184 break;
181 } 185 }
182 } 186 }
183 187
184 } // namespace debug 188 } // namespace debug
185 } // namespace ash 189 } // namespace ash
OLDNEW
« no previous file with comments | « ash/accelerators/accelerator_table.cc ('k') | ash/ash_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698