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

Unified Diff: ash/common/accelerators/debug_commands.cc

Issue 2323863002: Separate debugging and developer accelerators (Closed)
Patch Set: Oshima's comments AND Rebase Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: ash/common/accelerators/debug_commands.cc
diff --git a/ash/common/accelerators/debug_commands.cc b/ash/common/accelerators/debug_commands.cc
index c7746650f398ab9c913be9051bb96afc2d47fa9d..60ca954b81ebfcbcca32dac3c12b8eec7d8388b8 100644
--- a/ash/common/accelerators/debug_commands.cc
+++ b/ash/common/accelerators/debug_commands.cc
@@ -11,7 +11,6 @@
#include "ash/common/system/toast/toast_manager.h"
#include "ash/common/wallpaper/wallpaper_controller.h"
#include "ash/common/wallpaper/wallpaper_delegate.h"
-#include "ash/common/wm/maximize_mode/maximize_mode_controller.h"
#include "ash/common/wm_root_window_controller.h"
#include "ash/common/wm_shell.h"
#include "ash/common/wm_window.h"
@@ -131,13 +130,6 @@ void HandleToggleTouchscreen() {
ash::WmShell::Get()->delegate()->ToggleTouchscreen();
}
-void HandleToggleToggleTouchView() {
- MaximizeModeController* controller =
- WmShell::Get()->maximize_mode_controller();
- controller->EnableMaximizeModeWindowManager(
- !controller->IsMaximizeModeWindowManagerEnabled());
-}
-
#endif // defined(OS_CHROMEOS)
} // namespace
@@ -156,6 +148,11 @@ bool DebugAcceleratorsEnabled() {
switches::kAshDebugShortcuts);
}
+bool DeveloperAcceleratorsEnabled() {
+ return base::CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kAshDeveloperShortcuts);
+}
+
void PerformDebugActionIfEnabled(AcceleratorAction action) {
if (!DebugAcceleratorsEnabled())
return;
@@ -173,9 +170,6 @@ void PerformDebugActionIfEnabled(AcceleratorAction action) {
case DEBUG_TOGGLE_TOUCH_SCREEN:
HandleToggleTouchscreen();
break;
- case DEBUG_TOGGLE_TOUCH_VIEW:
- HandleToggleToggleTouchView();
- break;
#endif
case DEBUG_TOGGLE_WALLPAPER_MODE:
HandleToggleWallpaperMode();

Powered by Google App Engine
This is Rietveld 408576698