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

Side by Side Diff: ash/host/ash_window_tree_host_unified.cc

Issue 1209913002: InputMethod should stop TextInputClient::InsertChar/InsertText calls when the event is stopped prop… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixed test failures. Created 5 years, 5 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/host/ash_window_tree_host_unified.h" 5 #include "ash/host/ash_window_tree_host_unified.h"
6 #include "ash/host/root_window_transformer.h" 6 #include "ash/host/root_window_transformer.h"
7 #include "ash/ime/input_method_event_handler.h" 7 #include "ash/ime/input_method_event_handler.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "ui/aura/window.h" 9 #include "ui/aura/window.h"
10 #include "ui/aura/window_event_dispatcher.h" 10 #include "ui/aura/window_event_dispatcher.h"
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
181 window->RemoveObserver(this); 181 window->RemoveObserver(this);
182 mirroring_hosts_.erase(iter); 182 mirroring_hosts_.erase(iter);
183 } 183 }
184 184
185 bool AshWindowTreeHostUnified::DispatchKeyEventPostIME( 185 bool AshWindowTreeHostUnified::DispatchKeyEventPostIME(
186 const ui::KeyEvent& event) { 186 const ui::KeyEvent& event) {
187 ui::KeyEvent event_copy(event); 187 ui::KeyEvent event_copy(event);
188 input_method_handler()->SetPostIME(true); 188 input_method_handler()->SetPostIME(true);
189 ui::EventSource::DeliverEventToProcessor(&event_copy); 189 ui::EventSource::DeliverEventToProcessor(&event_copy);
190 input_method_handler()->SetPostIME(false); 190 input_method_handler()->SetPostIME(false);
191 return event_copy.handled(); 191 return event_copy.stopped_propagation();
192 } 192 }
193 193
194 ui::EventDispatchDetails AshWindowTreeHostUnified::DeliverEventToProcessor( 194 ui::EventDispatchDetails AshWindowTreeHostUnified::DeliverEventToProcessor(
195 ui::Event* event) { 195 ui::Event* event) {
196 return ui::EventSource::DeliverEventToProcessor(event); 196 return ui::EventSource::DeliverEventToProcessor(event);
197 } 197 }
198 198
199 } // namespace ash 199 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698