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

Side by Side Diff: ash/wm/sticky_keys.cc

Issue 37733003: Make GetRootWindow() return a Window instead of a RootWindow. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 2 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
« no previous file with comments | « ash/wm/stacking_controller.cc ('k') | ash/wm/system_gesture_event_filter_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "ash/wm/sticky_keys.h" 5 #include "ash/wm/sticky_keys.h"
6 6
7 #include <X11/Xlib.h> 7 #include <X11/Xlib.h>
8 #undef RootWindow 8 #undef RootWindow
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 22 matching lines...) Expand all
33 33
34 StickyKeysHandlerDelegateImpl::StickyKeysHandlerDelegateImpl() { 34 StickyKeysHandlerDelegateImpl::StickyKeysHandlerDelegateImpl() {
35 } 35 }
36 36
37 StickyKeysHandlerDelegateImpl::~StickyKeysHandlerDelegateImpl() { 37 StickyKeysHandlerDelegateImpl::~StickyKeysHandlerDelegateImpl() {
38 } 38 }
39 39
40 void StickyKeysHandlerDelegateImpl::DispatchKeyEvent(ui::KeyEvent* event, 40 void StickyKeysHandlerDelegateImpl::DispatchKeyEvent(ui::KeyEvent* event,
41 aura::Window* target) { 41 aura::Window* target) {
42 DCHECK(target); 42 DCHECK(target);
43 target->GetRootWindow()->AsRootWindowHostDelegate()->OnHostKeyEvent(event); 43 target->GetDispatcher()->AsRootWindowHostDelegate()->OnHostKeyEvent(event);
44 } 44 }
45 45
46 } // namespace 46 } // namespace
47 47
48 /////////////////////////////////////////////////////////////////////////////// 48 ///////////////////////////////////////////////////////////////////////////////
49 // StickyKeys 49 // StickyKeys
50 StickyKeys::StickyKeys() 50 StickyKeys::StickyKeys()
51 : shift_sticky_key_( 51 : shift_sticky_key_(
52 new StickyKeysHandler(ui::EF_SHIFT_DOWN, 52 new StickyKeysHandler(ui::EF_SHIFT_DOWN,
53 new StickyKeysHandlerDelegateImpl())), 53 new StickyKeysHandlerDelegateImpl())),
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 default: 223 default:
224 NOTREACHED(); 224 NOTREACHED();
225 } 225 }
226 event->set_flags(event->flags() | modifier_flag_); 226 event->set_flags(event->flags() | modifier_flag_);
227 event->set_character(ui::GetCharacterFromKeyCode(event->key_code(), 227 event->set_character(ui::GetCharacterFromKeyCode(event->key_code(),
228 event->flags())); 228 event->flags()));
229 event->NormalizeFlags(); 229 event->NormalizeFlags();
230 } 230 }
231 231
232 } // namespace ash 232 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/stacking_controller.cc ('k') | ash/wm/system_gesture_event_filter_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698