| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "views/ime/input_method_wayland.h" | 5 #include "ui/views/ime/input_method_wayland.h" |
| 6 | 6 |
| 7 #include "views/widget/widget.h" | 7 #include "views/widget/widget.h" |
| 8 | 8 |
| 9 namespace views { | 9 namespace views { |
| 10 | 10 |
| 11 InputMethodWayland::InputMethodWayland( | 11 InputMethodWayland::InputMethodWayland( |
| 12 internal::InputMethodDelegate *delegate) { | 12 internal::InputMethodDelegate *delegate) { |
| 13 set_delegate(delegate); | 13 set_delegate(delegate); |
| 14 } | 14 } |
| 15 | 15 |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 // the key event may still generate a valid character, eg. a control-key | 67 // the key event may still generate a valid character, eg. a control-key |
| 68 // event (ctrl-a, return, tab, etc.). We need to send the character to the | 68 // event (ctrl-a, return, tab, etc.). We need to send the character to the |
| 69 // focused text input client by calling TextInputClient::InsertChar(). | 69 // focused text input client by calling TextInputClient::InsertChar(). |
| 70 char16 ch = key.GetCharacter(); | 70 char16 ch = key.GetCharacter(); |
| 71 ui::TextInputClient* client = GetTextInputClient(); | 71 ui::TextInputClient* client = GetTextInputClient(); |
| 72 if (ch && client) | 72 if (ch && client) |
| 73 client->InsertChar(ch, key.flags()); | 73 client->InsertChar(ch, key.flags()); |
| 74 } | 74 } |
| 75 | 75 |
| 76 } // namespace views | 76 } // namespace views |
| OLD | NEW |