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

Side by Side Diff: chrome/browser/chromeos/input_method/input_method_engine.cc

Issue 184903003: Window ownership -> WindowTreeHost (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 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 unified diff | Download patch | Annotate | Revision Log
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 "chrome/browser/chromeos/input_method/input_method_engine.h" 5 #include "chrome/browser/chromeos/input_method/input_method_engine.h"
6 6
7 #define XK_MISCELLANY 7 #define XK_MISCELLANY
8 #include <X11/keysymdef.h> 8 #include <X11/keysymdef.h>
9 #include <X11/X.h> 9 #include <X11/X.h>
10 #include <X11/Xlib.h> 10 #include <X11/Xlib.h>
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 int context_id, 215 int context_id,
216 const std::vector<KeyboardEvent>& events) { 216 const std::vector<KeyboardEvent>& events) {
217 if (!active_) { 217 if (!active_) {
218 return false; 218 return false;
219 } 219 }
220 if (context_id != context_id_ || context_id_ == -1) { 220 if (context_id != context_id_ || context_id_ == -1) {
221 return false; 221 return false;
222 } 222 }
223 223
224 aura::WindowEventDispatcher* dispatcher = 224 aura::WindowEventDispatcher* dispatcher =
225 ash::Shell::GetPrimaryRootWindow()->GetDispatcher(); 225 ash::Shell::GetPrimaryRootWindow()->GetHost()->dispatcher();
226 226
227 for (size_t i = 0; i < events.size(); ++i) { 227 for (size_t i = 0; i < events.size(); ++i) {
228 const KeyboardEvent& event = events[i]; 228 const KeyboardEvent& event = events[i];
229 const ui::EventType type = 229 const ui::EventType type =
230 (event.type == "keyup") ? ui::ET_KEY_RELEASED : ui::ET_KEY_PRESSED; 230 (event.type == "keyup") ? ui::ET_KEY_RELEASED : ui::ET_KEY_PRESSED;
231 231
232 // KeyboardCodeFromXKyeSym assumes US keyboard layout. 232 // KeyboardCodeFromXKyeSym assumes US keyboard layout.
233 ui::KeycodeConverter* conv = ui::KeycodeConverter::GetInstance(); 233 ui::KeycodeConverter* conv = ui::KeycodeConverter::GetInstance();
234 DCHECK(conv); 234 DCHECK(conv);
235 235
(...skipping 396 matching lines...) Expand 10 before | Expand all | Expand 10 after
632 // TODO(nona): Implement it. 632 // TODO(nona): Implement it.
633 break; 633 break;
634 } 634 }
635 } 635 }
636 } 636 }
637 637
638 // TODO(nona): Support item.children. 638 // TODO(nona): Support item.children.
639 } 639 }
640 640
641 } // namespace chromeos 641 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/events/event_rewriter.cc ('k') | chrome/browser/extensions/api/input/input.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698