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

Unified Diff: third_party/WebKit/Source/core/events/InputEvent.h

Issue 1752933002: [InputEvent] Fire 'beforeinput' during typing, pressing hot keys and IME composition (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: dtapuska's review, also add layout tests Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/events/InputEvent.h
diff --git a/third_party/WebKit/Source/core/events/InputEvent.h b/third_party/WebKit/Source/core/events/InputEvent.h
index f6c46ae58d23d1c655b4c72059353d8d97b9a273..6fbda80c91fec23dad7f17378b150fd8735d7a72 100644
--- a/third_party/WebKit/Source/core/events/InputEvent.h
+++ b/third_party/WebKit/Source/core/events/InputEvent.h
@@ -24,6 +24,12 @@ public:
return adoptRefWillBeNoop(new InputEvent(type, initializer));
}
+ static PassRefPtrWillBeRawPtr<InputEvent> createBeforeInput(const String& inputType, const String& data);
+ static PassRefPtrWillBeRawPtr<InputEvent> createCancelableBeforeInput(const String& inputType, const String& data);
+
+ const String& inputType() const { return m_inputType; }
+ const String& data() const { return m_data; }
+
bool isInputEvent() const override;
DECLARE_VIRTUAL_TRACE();
@@ -31,6 +37,9 @@ public:
private:
InputEvent();
InputEvent(const AtomicString&, const InputEventInit&);
+
+ String m_inputType;
+ String m_data;
};
DEFINE_EVENT_TYPE_CASTS(InputEvent);

Powered by Google App Engine
This is Rietveld 408576698