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

Unified Diff: ui/events/blink/web_input_event_traits.cc

Issue 2479123003: WIP Add getCoalescedEvents API using vector of WebInputEvents (Closed)
Patch Set: Creating CoalescedWebInputEvent Created 4 years, 1 month 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: ui/events/blink/web_input_event_traits.cc
diff --git a/ui/events/blink/web_input_event_traits.cc b/ui/events/blink/web_input_event_traits.cc
index 58d95c9e2f3d75c41e38644a9ce096f60c813cea..739fc929133409c4bf10dc6fd2c67fd640a80451 100644
--- a/ui/events/blink/web_input_event_traits.cc
+++ b/ui/events/blink/web_input_event_traits.cc
@@ -126,10 +126,11 @@ struct WebInputEventSize {
struct WebInputEventClone {
template <class EventType>
- bool Execute(const WebInputEvent& event,
- ScopedWebInputEvent* scoped_event) const {
+ bool Execute(
+ const WebInputEvent& event,
+ blink::CoalescedWebInputEvent::ScopedWebInputEvent* scoped_event) const {
DCHECK_EQ(sizeof(EventType), event.size);
- *scoped_event = ScopedWebInputEvent(
+ *scoped_event = blink::CoalescedWebInputEvent::ScopedWebInputEvent(
new EventType(static_cast<const EventType&>(event)));
return true;
}
@@ -180,8 +181,9 @@ size_t WebInputEventTraits::GetSize(WebInputEvent::Type type) {
return size;
}
-ScopedWebInputEvent WebInputEventTraits::Clone(const WebInputEvent& event) {
- ScopedWebInputEvent scoped_event;
+blink::CoalescedWebInputEvent::ScopedWebInputEvent WebInputEventTraits::Clone(
+ const WebInputEvent& event) {
+ blink::CoalescedWebInputEvent::ScopedWebInputEvent scoped_event;
Apply(WebInputEventClone(), event.type, event, &scoped_event);
return scoped_event;
}

Powered by Google App Engine
This is Rietveld 408576698