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

Side by Side Diff: chrome/browser/ui/views/ash/chrome_shell_delegate.cc

Issue 10823017: Revert 148383 - Move the keyboard overlay view to ash. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 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 "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/window_util.h" 9 #include "ash/wm/window_util.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 16 matching lines...) Expand all
27 #include "chrome/common/chrome_switches.h" 27 #include "chrome/common/chrome_switches.h"
28 #include "chrome/common/url_constants.h" 28 #include "chrome/common/url_constants.h"
29 #include "content/public/browser/notification_service.h" 29 #include "content/public/browser/notification_service.h"
30 #include "content/public/browser/user_metrics.h" 30 #include "content/public/browser/user_metrics.h"
31 #include "content/public/browser/web_contents.h" 31 #include "content/public/browser/web_contents.h"
32 #include "grit/generated_resources.h" 32 #include "grit/generated_resources.h"
33 #include "ui/aura/client/user_action_client.h" 33 #include "ui/aura/client/user_action_client.h"
34 #include "ui/aura/window.h" 34 #include "ui/aura/window.h"
35 35
36 #if defined(OS_CHROMEOS) 36 #if defined(OS_CHROMEOS)
37 #include "ash/keyboard_overlay/keyboard_overlay_view.h"
38 #include "base/chromeos/chromeos_version.h" 37 #include "base/chromeos/chromeos_version.h"
39 #include "chrome/browser/chromeos/accessibility/accessibility_util.h" 38 #include "chrome/browser/chromeos/accessibility/accessibility_util.h"
40 #include "chrome/browser/chromeos/background/ash_user_wallpaper_delegate.h" 39 #include "chrome/browser/chromeos/background/ash_user_wallpaper_delegate.h"
41 #include "chrome/browser/chromeos/extensions/file_manager_util.h" 40 #include "chrome/browser/chromeos/extensions/file_manager_util.h"
42 #include "chrome/browser/chromeos/kiosk_mode/kiosk_mode_settings.h" 41 #include "chrome/browser/chromeos/kiosk_mode/kiosk_mode_settings.h"
43 #include "chrome/browser/chromeos/login/user_manager.h" 42 #include "chrome/browser/chromeos/login/user_manager.h"
44 #include "chrome/browser/chromeos/login/webui_login_display_host.h" 43 #include "chrome/browser/chromeos/login/webui_login_display_host.h"
45 #include "chrome/browser/chromeos/system/ash_system_tray_delegate.h" 44 #include "chrome/browser/chromeos/system/ash_system_tray_delegate.h"
45 #include "chrome/browser/ui/views/keyboard_overlay_dialog_view.h"
46 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" 46 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h"
47 #include "chrome/browser/ui/webui/chromeos/mobile_setup_dialog.h" 47 #include "chrome/browser/ui/webui/chromeos/mobile_setup_dialog.h"
48 #include "chromeos/dbus/dbus_thread_manager.h" 48 #include "chromeos/dbus/dbus_thread_manager.h"
49 #include "chromeos/dbus/power_manager_client.h" 49 #include "chromeos/dbus/power_manager_client.h"
50 #include "chromeos/dbus/session_manager_client.h" 50 #include "chromeos/dbus/session_manager_client.h"
51 #endif 51 #endif
52 52
53 namespace { 53 namespace {
54 54
55 // Returns the browser that should handle accelerators. 55 // Returns the browser that should handle accelerators.
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after
255 break; 255 break;
256 case ash::Shell::BACKWARD: 256 case ash::Shell::BACKWARD:
257 chrome::FocusPreviousPane(browser); 257 chrome::FocusPreviousPane(browser);
258 break; 258 break;
259 } 259 }
260 return true; 260 return true;
261 } 261 }
262 262
263 void ChromeShellDelegate::ShowKeyboardOverlay() { 263 void ChromeShellDelegate::ShowKeyboardOverlay() {
264 #if defined(OS_CHROMEOS) 264 #if defined(OS_CHROMEOS)
265 // TODO(mazda): Move the show logic to ash (http://crbug.com/124222).
266 Profile* profile = ProfileManager::GetDefaultProfileOrOffTheRecord(); 265 Profile* profile = ProfileManager::GetDefaultProfileOrOffTheRecord();
267 std::string url(chrome::kChromeUIKeyboardOverlayURL); 266 KeyboardOverlayDialogView::ShowDialog(profile, new ChromeWebContentsHandler);
268 KeyboardOverlayView::ShowDialog(profile,
269 new ChromeWebContentsHandler,
270 GURL(url));
271 #endif 267 #endif
272 } 268 }
273 269
274 void ChromeShellDelegate::ShowTaskManager() { 270 void ChromeShellDelegate::ShowTaskManager() {
275 Browser* browser = browser::FindOrCreateTabbedBrowser( 271 Browser* browser = browser::FindOrCreateTabbedBrowser(
276 ProfileManager::GetDefaultProfileOrOffTheRecord()); 272 ProfileManager::GetDefaultProfileOrOffTheRecord());
277 chrome::OpenTaskManager(browser, false); 273 chrome::OpenTaskManager(browser, false);
278 } 274 }
279 275
280 content::BrowserContext* ChromeShellDelegate::GetCurrentBrowserContext() { 276 content::BrowserContext* ChromeShellDelegate::GetCurrentBrowserContext() {
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
376 ash::Shell::GetInstance()->ShowLauncher(); 372 ash::Shell::GetInstance()->ShowLauncher();
377 break; 373 break;
378 default: 374 default:
379 NOTREACHED() << "Unexpected notification " << type; 375 NOTREACHED() << "Unexpected notification " << type;
380 } 376 }
381 #else 377 #else
382 // MSVC++ warns about switch statements without any cases. 378 // MSVC++ warns about switch statements without any cases.
383 NOTREACHED() << "Unexpected notification " << type; 379 NOTREACHED() << "Unexpected notification " << type;
384 #endif 380 #endif
385 } 381 }
OLDNEW
« no previous file with comments | « ash/keyboard_overlay/keyboard_overlay_view.cc ('k') | chrome/browser/ui/views/keyboard_overlay_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698