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

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

Issue 2738133003: Promotes a handful of members from WmShell to Shell (Closed)
Patch Set: merge Created 3 years, 9 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
« no previous file with comments | « ash/common/DEPS ('k') | ash/common/accelerators/debug_commands.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/accelerators/accelerator_controller.cc
diff --git a/ash/common/accelerators/accelerator_controller.cc b/ash/common/accelerators/accelerator_controller.cc
index 46abdd953c7f59d78ed835912256131bbe1b85ec..944245ee496d9660c0917be4f1bc1182deac569c 100644
--- a/ash/common/accelerators/accelerator_controller.cc
+++ b/ash/common/accelerators/accelerator_controller.cc
@@ -263,7 +263,9 @@ bool CanHandleToggleAppList(const ui::Accelerator& accelerator,
// When spoken feedback is enabled, we should neither toggle the list nor
// consume the key since Search+Shift is one of the shortcuts the a11y
// feature uses. crbug.com/132296
- if (WmShell::Get()->accessibility_delegate()->IsSpokenFeedbackEnabled())
+ if (Shell::GetInstance()
+ ->accessibility_delegate()
+ ->IsSpokenFeedbackEnabled())
return false;
}
return true;
@@ -402,8 +404,8 @@ void HandleShowStylusTools() {
}
bool CanHandleShowStylusTools() {
- return WmShell::Get()->palette_delegate() &&
- WmShell::Get()->palette_delegate()->ShouldShowPalette();
+ return Shell::GetInstance()->palette_delegate() &&
+ Shell::GetInstance()->palette_delegate()->ShouldShowPalette();
}
void HandleSuspend() {
@@ -491,13 +493,13 @@ void HandleToggleHighContrast() {
message_center::MessageCenter::Get()->AddNotification(
std::move(notification));
- WmShell::Get()->accessibility_delegate()->ToggleHighContrast();
+ Shell::GetInstance()->accessibility_delegate()->ToggleHighContrast();
}
void HandleToggleSpokenFeedback() {
base::RecordAction(UserMetricsAction("Accel_Toggle_Spoken_Feedback"));
- WmShell::Get()->accessibility_delegate()->ToggleSpokenFeedback(
+ Shell::GetInstance()->accessibility_delegate()->ToggleSpokenFeedback(
A11Y_NOTIFICATION_SHOW);
}
@@ -1124,7 +1126,7 @@ AcceleratorController::GetAcceleratorProcessingRestriction(int action) {
}
if (wm_shell->mru_window_tracker()->BuildMruWindowList().empty() &&
actions_needing_window_.find(action) != actions_needing_window_.end()) {
- wm_shell->accessibility_delegate()->TriggerAccessibilityAlert(
+ Shell::GetInstance()->accessibility_delegate()->TriggerAccessibilityAlert(
A11Y_ALERT_WINDOW_NEEDED);
return RESTRICTION_PREVENT_PROCESSING_AND_PROPAGATION;
}
« no previous file with comments | « ash/common/DEPS ('k') | ash/common/accelerators/debug_commands.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698