OLD | NEW |
---|---|
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 CONTENT_COMMON_INPUT_WEB_INPUT_EVENT_TRAITS_H_ | 5 #ifndef CONTENT_COMMON_INPUT_WEB_INPUT_EVENT_TRAITS_H_ |
6 #define CONTENT_COMMON_INPUT_WEB_INPUT_EVENT_TRAITS_H_ | 6 #define CONTENT_COMMON_INPUT_WEB_INPUT_EVENT_TRAITS_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "content/common/input/scoped_web_input_event.h" | 9 #include "content/common/input/scoped_web_input_event.h" |
10 #include "third_party/WebKit/public/web/WebInputEvent.h" | 10 #include "third_party/WebKit/public/web/WebInputEvent.h" |
11 | 11 |
12 namespace content { | 12 namespace content { |
13 | 13 |
14 // Utility class for performing operations on and with WebInputEvents. | 14 // Utility class for performing operations on and with WebInputEvents. |
15 class WebInputEventTraits { | 15 class WebInputEventTraits { |
16 public: | 16 public: |
17 static size_t GetSize(WebKit::WebInputEvent::Type type); | 17 static size_t GetSize(WebKit::WebInputEvent::Type type); |
18 static ScopedWebInputEvent Clone(const WebKit::WebInputEvent& event); | 18 static ScopedWebInputEvent Clone(const WebKit::WebInputEvent& event); |
19 static void Delete(WebKit::WebInputEvent* event); | 19 static void Delete(WebKit::WebInputEvent* event); |
20 static bool TryCoalesce(const WebKit::WebInputEvent& event_to_coalesce, | |
jdduke (slow)
2013/10/10 21:21:26
Any guidance on arg ordering here? I prefer "TryCo
| |
21 WebKit::WebInputEvent* event); | |
20 }; | 22 }; |
21 | 23 |
22 } // namespace content | 24 } // namespace content |
23 | 25 |
24 #endif // CONTENT_COMMON_INPUT_WEB_INPUT_EVENT_TRAITS_H_ | 26 #endif // CONTENT_COMMON_INPUT_WEB_INPUT_EVENT_TRAITS_H_ |
OLD | NEW |