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

Unified Diff: chrome/browser/chromeos/accessibility/accessibility_manager.cc

Issue 549453005: Run athena on device (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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
« no previous file with comments | « athena/wm/window_list_provider_impl.cc ('k') | chrome/browser/chromeos/dbus/cros_dbus_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/accessibility/accessibility_manager.cc
diff --git a/chrome/browser/chromeos/accessibility/accessibility_manager.cc b/chrome/browser/chromeos/accessibility/accessibility_manager.cc
index 5d12fd41a062b3e6d4accab85b042c3a93775ee8..e311566d52d6308f04c9ee419ea035cbb9907446 100644
--- a/chrome/browser/chromeos/accessibility/accessibility_manager.cc
+++ b/chrome/browser/chromeos/accessibility/accessibility_manager.cc
@@ -454,6 +454,8 @@ void AccessibilityManager::UpdateLargeCursorFromPref() {
ash::A11Y_NOTIFICATION_NONE);
NotifyAccessibilityStatusChanged(details);
+#if !defined(USE_ATHENA)
+ // crbug.com/408733 (and for all USE_ATHENA in this file)
#if defined(USE_ASH)
// Large cursor is implemented only in ash.
@@ -465,6 +467,8 @@ void AccessibilityManager::UpdateLargeCursorFromPref() {
ash::Shell::GetInstance()->SetCursorCompositingEnabled(
ShouldEnableCursorCompositing());
#endif
+
+#endif // !USE_ATHENA
}
bool AccessibilityManager::IsIncognitoAllowed() {
@@ -499,8 +503,7 @@ void AccessibilityManager::UpdateStickyKeysFromPref() {
return;
sticky_keys_enabled_ = enabled;
-#if defined(USE_ASH)
- // Sticky keys is implemented only in ash.
+#if defined(USE_ASH) && !defined(USE_ATHENA)
ash::Shell::GetInstance()->sticky_keys_controller()->Enable(enabled);
#endif
}
@@ -510,10 +513,11 @@ void AccessibilityManager::EnableSpokenFeedback(
ash::AccessibilityNotificationVisibility notify) {
if (!profile_)
return;
-
+#if !defined(USE_ATHENA)
ash::Shell::GetInstance()->metrics()->RecordUserMetricsAction(
enabled ? ash::UMA_STATUS_AREA_ENABLE_SPOKEN_FEEDBACK
: ash::UMA_STATUS_AREA_DISABLE_SPOKEN_FEEDBACK);
+#endif
spoken_feedback_notification_ = notify;
@@ -673,6 +677,8 @@ void AccessibilityManager::UpdateHighContrastFromPref() {
NotifyAccessibilityStatusChanged(details);
+#if !defined(USE_ATHENA)
+
#if defined(USE_ASH)
ash::Shell::GetInstance()->high_contrast_controller()->SetEnabled(enabled);
#endif
@@ -681,6 +687,8 @@ void AccessibilityManager::UpdateHighContrastFromPref() {
ash::Shell::GetInstance()->SetCursorCompositingEnabled(
ShouldEnableCursorCompositing());
#endif
+
+#endif
}
void AccessibilityManager::OnLocaleChanged() {
@@ -727,7 +735,7 @@ void AccessibilityManager::UpdateAutoclickFromPref() {
return;
autoclick_enabled_ = enabled;
-#if defined(USE_ASH)
+#if defined(USE_ASH) && !defined(USE_ATHENA)
ash::Shell::GetInstance()->autoclick_controller()->SetEnabled(enabled);
#endif
}
@@ -753,7 +761,7 @@ void AccessibilityManager::UpdateAutoclickDelayFromPref() {
return;
autoclick_delay_ms_ = autoclick_delay_ms;
-#if defined(USE_ASH)
+#if defined(USE_ASH) && !defined(USE_ATHENA)
ash::Shell::GetInstance()->autoclick_controller()->SetAutoclickDelay(
autoclick_delay_ms_);
#endif
@@ -791,7 +799,7 @@ void AccessibilityManager::UpdateVirtualKeyboardFromPref() {
NotifyAccessibilityStatusChanged(details);
-#if defined(USE_ASH)
+#if defined(USE_ASH) && !defined(USE_ATHENA)
keyboard::SetAccessibilityKeyboardEnabled(enabled);
// Note that there are two versions of the on-screen keyboard. A full layout
// is provided for accessibility, which includes sticky modifier keys to
@@ -966,8 +974,10 @@ base::TimeDelta AccessibilityManager::PlayShutdownSound() {
if (!system_sounds_enabled_)
return base::TimeDelta();
system_sounds_enabled_ = false;
+#if !defined(USE_ATHENA)
if (!ash::PlaySystemSoundIfSpokenFeedback(SOUND_SHUTDOWN))
return base::TimeDelta();
+#endif
return media::SoundsManager::Get()->GetDuration(SOUND_SHUTDOWN);
}
« no previous file with comments | « athena/wm/window_list_provider_impl.cc ('k') | chrome/browser/chromeos/dbus/cros_dbus_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698