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

Side by Side Diff: ui/base/ime/input_method_auralinux.h

Issue 1801363005: Fix bug of input.ime.onKeyEvent on Linux. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
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 #ifndef UI_BASE_IME_INPUT_METHOD_AURALINUX_H_ 5 #ifndef UI_BASE_IME_INPUT_METHOD_AURALINUX_H_
6 #define UI_BASE_IME_INPUT_METHOD_AURALINUX_H_ 6 #define UI_BASE_IME_INPUT_METHOD_AURALINUX_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "ui/base/ime/composition_text.h" 10 #include "ui/base/ime/composition_text.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 TextInputClient* focused) override; 50 TextInputClient* focused) override;
51 51
52 private: 52 private:
53 bool HasInputMethodResult(); 53 bool HasInputMethodResult();
54 bool NeedInsertChar() const; 54 bool NeedInsertChar() const;
55 ui::EventDispatchDetails SendFakeProcessKeyEvent(ui::KeyEvent* event) const; 55 ui::EventDispatchDetails SendFakeProcessKeyEvent(ui::KeyEvent* event) const;
56 void ConfirmCompositionText(); 56 void ConfirmCompositionText();
57 void UpdateContextFocusState(); 57 void UpdateContextFocusState();
58 void ResetContext(); 58 void ResetContext();
59 59
60 // Processes the key event after passing to extension.
61 void ProcessKeyEventDone(ui::KeyEvent* event, bool filtered, bool is_handled);
62
60 // Callback function for IMEEngineHandlerInterface::ProcessKeyEvent. 63 // Callback function for IMEEngineHandlerInterface::ProcessKeyEvent.
61 void ProcessKeyEventDone(ui::KeyEvent* event, bool filtered, bool is_handled); 64 void ProcessKeyEventByEngineDone(ui::KeyEvent* event,
Shu Chen 2016/03/17 06:37:08 please add comment why this method is necessary.
Azure Wei 2016/03/17 07:02:37 Done.
65 bool filtered,
66 bool composition_changed,
67 const ui::CompositionText& composition,
68 const base::string16& result_text,
69 bool is_handled);
62 70
63 scoped_ptr<LinuxInputMethodContext> context_; 71 scoped_ptr<LinuxInputMethodContext> context_;
64 scoped_ptr<LinuxInputMethodContext> context_simple_; 72 scoped_ptr<LinuxInputMethodContext> context_simple_;
65 73
66 base::string16 result_text_; 74 base::string16 result_text_;
67 75
68 ui::CompositionText composition_; 76 ui::CompositionText composition_;
69 77
70 // The current text input type used to indicates if |context_| and 78 // The current text input type used to indicates if |context_| and
71 // |context_simple_| are focused or not. 79 // |context_simple_| are focused or not.
(...skipping 12 matching lines...) Expand all
84 92
85 // Used for making callbacks. 93 // Used for making callbacks.
86 base::WeakPtrFactory<InputMethodAuraLinux> weak_ptr_factory_; 94 base::WeakPtrFactory<InputMethodAuraLinux> weak_ptr_factory_;
87 95
88 DISALLOW_COPY_AND_ASSIGN(InputMethodAuraLinux); 96 DISALLOW_COPY_AND_ASSIGN(InputMethodAuraLinux);
89 }; 97 };
90 98
91 } // namespace ui 99 } // namespace ui
92 100
93 #endif // UI_BASE_IME_INPUT_METHOD_AURALINUX_H_ 101 #endif // UI_BASE_IME_INPUT_METHOD_AURALINUX_H_
OLDNEW
« no previous file with comments | « no previous file | ui/base/ime/input_method_auralinux.cc » ('j') | ui/base/ime/input_method_auralinux.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698