summaryrefslogtreecommitdiffstats
path: root/ui/aura/event.h
diff options
context:
space:
mode:
authoryusukes@chromium.org <yusukes@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-06 17:35:10 +0000
committeryusukes@chromium.org <yusukes@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-06 17:35:10 +0000
commit94228a4720cd72e63bec89df4779ce526c51b540 (patch)
treee829696adbc90808763326aa8fe9d3be5731e794 /ui/aura/event.h
parent97dc7cbe1b802facd4ccf92c6f7da78bd5a8ce51 (diff)
downloadchromium_src-94228a4720cd72e63bec89df4779ce526c51b540.zip
chromium_src-94228a4720cd72e63bec89df4779ce526c51b540.tar.gz
chromium_src-94228a4720cd72e63bec89df4779ce526c51b540.tar.bz2
IME (input method editor) support for Aura, part 3 of 3: Use ui::InputMethod in ui/aura/.
Part 1: http://codereview.chromium.org/8659033/ Part 2: http://codereview.chromium.org/8687027/ The basic design of the feature is that to add an input method object to DesktopHost to feed all KeyPress and KeyRelease events from the system message loop to the input method, and let the input method send IME results (e.g. composition text) to RenderWidgetHostViewAura or NativeWidgetAura as needed. RenderWidgetHostViewAura: - Just like RWHVV, implement ui::TextInputClient interface so that RWHVA could receive an event such as 'SetComposition' and 'InsertChar' from an input method object owned by DesktopHost. - Send a notification to the input method object on focus, blur, text input type change, etc. - OnKeyEvent() handler is now able to handle a non-native key event, e.g. a VKEY_PROCESSKEY event, which is fabricated by the input method editor. NativeWidgetAura: - Use views::InputMethodBridge instead of views::InputMethodIBus. - InputMethodBridge, which implements ui::TextInputClient interface, just receives IME results (e.g. composition text) from ui::InputMethod and forwards them to UI (e.g. a text field). - InputMethodBridge also receives a request like 'CancelComposition' from the UI and forwards the request to ui::InputMethod. DesktopHostLinux: - Creates and owns a ui::InputMethodIBusAura object. If IBus-1.4 is not available (e.g. Goobuntu), creates an instance of ui::MockInputMethod. - In Dispatch(), send a KeyPress and KeyRelease aura event to the input method. - Implement ui::InputMethodDelegate interface so that DesktopHostLinux could receive an key press and key release event which should be sent to NWA or RWHVA. Note that an "is_char" event is always sent directly from the input method to a TextInputClient. the ui::InputMethodDelegate is not used for that purpose. - ShouldSendCharEventForKeyboardCode() is moved to ui::InputMethod since DesktopHostLinux no longer generates a Char event. DesktopHostWin: - IME is not supported yet. Supported platforms: - Aura + Chrome OS (IME works!) - Aura + Chrome OS + TOUCH_UI (compiles, but virtual keyboard is not shown since views::TextInputTypeTracker is not ported to Aura yet.) - Aura + Linux, with and without IBus-1.4 - Aura + Windows (compiles, but IME does not work. views::InputMethodWin is not ported to Aura yet.) BUG=97261 TEST=ran aura_unittests Review URL: http://codereview.chromium.org/8576005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@113224 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/aura/event.h')
-rw-r--r--ui/aura/event.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/ui/aura/event.h b/ui/aura/event.h
index 5dcb726..91e92cb 100644
--- a/ui/aura/event.h
+++ b/ui/aura/event.h
@@ -144,6 +144,7 @@ class AURA_EXPORT TouchEvent : public LocatedEvent {
class AURA_EXPORT KeyEvent : public Event {
public:
+ // TODO(yusukes): Remove |is_char| when IME support for Aura is submitted.
KeyEvent(const base::NativeEvent& native_event, bool is_char);
// Used for synthetic events in testing.