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

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

Issue 10543158: Do not toggle Applist with Search key press when accessibility is enabled. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 6 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
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/accelerators/accelerator_controller.h" 5 #include "ash/accelerators/accelerator_controller.h"
6 6
7 #include "ash/accelerators/accelerator_table.h" 7 #include "ash/accelerators/accelerator_table.h"
8 #include "ash/ash_switches.h" 8 #include "ash/ash_switches.h"
9 #include "ash/caps_lock_delegate.h" 9 #include "ash/caps_lock_delegate.h"
10 #include "ash/desktop_background/desktop_background_controller.h" 10 #include "ash/desktop_background/desktop_background_controller.h"
(...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after
352 // Return true to prevent propagation of the key event. 352 // Return true to prevent propagation of the key event.
353 return true; 353 return true;
354 case TAKE_PARTIAL_SCREENSHOT: 354 case TAKE_PARTIAL_SCREENSHOT:
355 if (screenshot_delegate_.get()) 355 if (screenshot_delegate_.get())
356 ash::Shell::GetInstance()->delegate()-> 356 ash::Shell::GetInstance()->delegate()->
357 StartPartialScreenshot(screenshot_delegate_.get()); 357 StartPartialScreenshot(screenshot_delegate_.get());
358 // Return true to prevent propagation of the key event because 358 // Return true to prevent propagation of the key event because
359 // this key combination is reserved for partial screenshot. 359 // this key combination is reserved for partial screenshot.
360 return true; 360 return true;
361 case TOGGLE_APP_LIST: 361 case TOGGLE_APP_LIST:
362 // When spoken feedback is enabled, we should neither toggle the list nor
363 // consume the key since Search+Shift is one of the shortcuts the a11y
364 // feature uses. crbug.com/132296
365 if (Shell::GetInstance()->delegate()->IsSpokenFeedbackEnabled())
Zachary Kuznia 2012/06/14 10:02:22 Perhaps we should DCHECK that the accelerator bein
Yusuke Sato 2012/06/14 11:41:40 Done.
366 return false;
362 ash::Shell::GetInstance()->ToggleAppList(); 367 ash::Shell::GetInstance()->ToggleAppList();
363 return true; 368 return true;
364 case TOGGLE_CAPS_LOCK: 369 case TOGGLE_CAPS_LOCK:
365 if (caps_lock_delegate_.get()) 370 if (caps_lock_delegate_.get())
366 return caps_lock_delegate_->HandleToggleCapsLock(); 371 return caps_lock_delegate_->HandleToggleCapsLock();
367 break; 372 break;
368 case BRIGHTNESS_DOWN: 373 case BRIGHTNESS_DOWN:
369 if (brightness_control_delegate_.get()) 374 if (brightness_control_delegate_.get())
370 return brightness_control_delegate_->HandleBrightnessDown(accelerator); 375 return brightness_control_delegate_->HandleBrightnessDown(accelerator);
371 break; 376 break;
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
589 // Then set this one as active. 594 // Then set this one as active.
590 Shell::GetInstance()->launcher()->ActivateLauncherItem(found_index); 595 Shell::GetInstance()->launcher()->ActivateLauncherItem(found_index);
591 } 596 }
592 } 597 }
593 598
594 bool AcceleratorController::CanHandleAccelerators() const { 599 bool AcceleratorController::CanHandleAccelerators() const {
595 return true; 600 return true;
596 } 601 }
597 602
598 } // namespace ash 603 } // namespace ash
OLDNEW
« no previous file with comments | « no previous file | ash/accelerators/accelerator_controller_unittest.cc » ('j') | ash/shell/shell_delegate_impl.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698