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

Unified Diff: chrome/browser/chrome_browser_main_extra_parts_ash.cc

Issue 9854025: Automatically remap Command key on an Apple keyboard to Control [part 2 of 2 - Chrome part] (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 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 | « no previous file | chrome/browser/chromeos/device_hierarchy_observer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chrome_browser_main_extra_parts_ash.cc
diff --git a/chrome/browser/chrome_browser_main_extra_parts_ash.cc b/chrome/browser/chrome_browser_main_extra_parts_ash.cc
index 1b751543b2bdf07e8186a149b47d166e424b28df..698bbf65d6a918dbb679105470338bea87bdafe1 100644
--- a/chrome/browser/chrome_browser_main_extra_parts_ash.cc
+++ b/chrome/browser/chrome_browser_main_extra_parts_ash.cc
@@ -7,11 +7,13 @@
#include "ash/accelerators/accelerator_controller.h"
#include "ash/ash_switches.h"
#include "ash/shell.h"
+#include "ash/wm/key_rewriter_event_filter.h"
#include "base/command_line.h"
#include "chrome/common/chrome_switches.h"
#include "chrome/browser/ui/browser_list.h"
#include "chrome/browser/ui/views/ash/caps_lock_handler.h"
#include "chrome/browser/ui/views/ash/chrome_shell_delegate.h"
+#include "chrome/browser/ui/views/ash/key_rewriter.h"
#include "chrome/browser/ui/views/ash/screen_orientation_listener.h"
#include "chrome/browser/ui/views/ash/screenshot_taker.h"
#include "chrome/browser/ui/views/ash/status_area_host_aura.h"
@@ -49,6 +51,8 @@ void ChromeBrowserMainExtraPartsAsh::PreProfileInit() {
// Shell takes ownership of ChromeShellDelegate.
ash::Shell* shell = ash::Shell::CreateInstance(new ChromeShellDelegate);
+ shell->key_rewriter_filter()->SetKeyRewriterDelegate(
+ scoped_ptr<ash::KeyRewriterDelegate>(new KeyRewriter).Pass());
shell->accelerator_controller()->SetScreenshotDelegate(
scoped_ptr<ash::ScreenshotDelegate>(new ScreenshotTaker).Pass());
#if defined(OS_CHROMEOS)
« no previous file with comments | « no previous file | chrome/browser/chromeos/device_hierarchy_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698