| OLD | NEW |
| 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 "chrome/browser/ui/views/ash/chrome_shell_delegate.h" | 5 #include "chrome/browser/ui/views/ash/chrome_shell_delegate.h" |
| 6 | 6 |
| 7 #include "ash/launcher/launcher_types.h" | 7 #include "ash/launcher/launcher_types.h" |
| 8 #include "ash/system/tray/system_tray_delegate.h" | 8 #include "ash/system/tray/system_tray_delegate.h" |
| 9 #include "ash/wm/partial_screenshot_view.h" | 9 #include "ash/wm/partial_screenshot_view.h" |
| 10 #include "ash/wm/window_util.h" | 10 #include "ash/wm/window_util.h" |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 #include "grit/generated_resources.h" | 31 #include "grit/generated_resources.h" |
| 32 #include "ui/aura/client/user_action_client.h" | 32 #include "ui/aura/client/user_action_client.h" |
| 33 #include "ui/aura/window.h" | 33 #include "ui/aura/window.h" |
| 34 | 34 |
| 35 #if defined(OS_CHROMEOS) | 35 #if defined(OS_CHROMEOS) |
| 36 #include "base/chromeos/chromeos_version.h" | 36 #include "base/chromeos/chromeos_version.h" |
| 37 #include "chrome/browser/chromeos/accessibility/accessibility_util.h" | 37 #include "chrome/browser/chromeos/accessibility/accessibility_util.h" |
| 38 #include "chrome/browser/chromeos/background/ash_user_wallpaper_delegate.h" | 38 #include "chrome/browser/chromeos/background/ash_user_wallpaper_delegate.h" |
| 39 #include "chrome/browser/chromeos/extensions/file_manager_util.h" | 39 #include "chrome/browser/chromeos/extensions/file_manager_util.h" |
| 40 #include "chrome/browser/chromeos/kiosk_mode/kiosk_mode_settings.h" | 40 #include "chrome/browser/chromeos/kiosk_mode/kiosk_mode_settings.h" |
| 41 #include "chrome/browser/chromeos/login/user_manager.h" |
| 41 #include "chrome/browser/chromeos/login/webui_login_display_host.h" | 42 #include "chrome/browser/chromeos/login/webui_login_display_host.h" |
| 42 #include "chrome/browser/chromeos/login/user_manager.h" | |
| 43 #include "chrome/browser/chromeos/system/ash_system_tray_delegate.h" | 43 #include "chrome/browser/chromeos/system/ash_system_tray_delegate.h" |
| 44 #include "chrome/browser/ui/views/keyboard_overlay_dialog_view.h" | 44 #include "chrome/browser/ui/views/keyboard_overlay_dialog_view.h" |
| 45 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" | 45 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" |
| 46 #include "chrome/browser/ui/webui/chromeos/mobile_setup_dialog.h" | 46 #include "chrome/browser/ui/webui/chromeos/mobile_setup_dialog.h" |
| 47 #include "chromeos/dbus/dbus_thread_manager.h" | 47 #include "chromeos/dbus/dbus_thread_manager.h" |
| 48 #include "chromeos/dbus/power_manager_client.h" | 48 #include "chromeos/dbus/power_manager_client.h" |
| 49 #endif | 49 #endif |
| 50 | 50 |
| 51 namespace { | 51 namespace { |
| 52 | 52 |
| (...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 263 content::WebUI* login_screen_web_ui = NULL; | 263 content::WebUI* login_screen_web_ui = NULL; |
| 264 chromeos::WebUILoginDisplayHost* host = | 264 chromeos::WebUILoginDisplayHost* host = |
| 265 static_cast<chromeos::WebUILoginDisplayHost*>( | 265 static_cast<chromeos::WebUILoginDisplayHost*>( |
| 266 chromeos::BaseLoginDisplayHost::default_host()); | 266 chromeos::BaseLoginDisplayHost::default_host()); |
| 267 if (host && host->GetOobeUI()) | 267 if (host && host->GetOobeUI()) |
| 268 login_screen_web_ui = host->GetOobeUI()->web_ui(); | 268 login_screen_web_ui = host->GetOobeUI()->web_ui(); |
| 269 chromeos::accessibility::ToggleSpokenFeedback(login_screen_web_ui); | 269 chromeos::accessibility::ToggleSpokenFeedback(login_screen_web_ui); |
| 270 #endif | 270 #endif |
| 271 } | 271 } |
| 272 | 272 |
| 273 bool ChromeShellDelegate::IsSpokenFeedbackEnabled() const { |
| 274 #if defined(OS_CHROMEOS) |
| 275 return chromeos::accessibility::IsSpokenFeedbackEnabled(); |
| 276 #else |
| 277 return false; |
| 278 #endif |
| 279 } |
| 280 |
| 273 app_list::AppListViewDelegate* | 281 app_list::AppListViewDelegate* |
| 274 ChromeShellDelegate::CreateAppListViewDelegate() { | 282 ChromeShellDelegate::CreateAppListViewDelegate() { |
| 275 // Shell will own the created delegate. | 283 // Shell will own the created delegate. |
| 276 return new AppListViewDelegate; | 284 return new AppListViewDelegate; |
| 277 } | 285 } |
| 278 | 286 |
| 279 void ChromeShellDelegate::StartPartialScreenshot( | 287 void ChromeShellDelegate::StartPartialScreenshot( |
| 280 ash::ScreenshotDelegate* screenshot_delegate) { | 288 ash::ScreenshotDelegate* screenshot_delegate) { |
| 281 ash::PartialScreenshotView::StartPartialScreenshot(screenshot_delegate); | 289 ash::PartialScreenshotView::StartPartialScreenshot(screenshot_delegate); |
| 282 } | 290 } |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 319 ash::Shell::GetInstance()->CreateLauncher(); | 327 ash::Shell::GetInstance()->CreateLauncher(); |
| 320 break; | 328 break; |
| 321 default: | 329 default: |
| 322 NOTREACHED() << "Unexpected notification " << type; | 330 NOTREACHED() << "Unexpected notification " << type; |
| 323 } | 331 } |
| 324 #else | 332 #else |
| 325 // MSVC++ warns about switch statements without any cases. | 333 // MSVC++ warns about switch statements without any cases. |
| 326 NOTREACHED() << "Unexpected notification " << type; | 334 NOTREACHED() << "Unexpected notification " << type; |
| 327 #endif | 335 #endif |
| 328 } | 336 } |
| OLD | NEW |