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

Unified Diff: ui/events/latency_info.h

Issue 2040733002: Implement LatencyInfo StructTraits (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Make Windows happier Created 4 years, 6 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
« no previous file with comments | « ui/events/DEPS ('k') | ui/events/mojo/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/events/latency_info.h
diff --git a/ui/events/latency_info.h b/ui/events/latency_info.h
index 43a7d7b7abadca2aa6ed182988aaef6cf3b7c00c..97508a8fe44f727cf9b9a1de32e33d215052b877 100644
--- a/ui/events/latency_info.h
+++ b/ui/events/latency_info.h
@@ -19,10 +19,17 @@
#if !defined(OS_IOS)
#include "ipc/ipc_param_traits.h" // nogncheck
+#include "mojo/public/cpp/bindings/struct_traits.h" // nogncheck
#endif
namespace ui {
+#if !defined(OS_IOS)
+namespace mojom {
+class LatencyInfo;
+}
+#endif
+
// When adding new components, or new metrics based on LatencyInfo,
// please update latency_info.dot.
enum LatencyComponentType {
@@ -129,7 +136,7 @@ class EVENTS_BASE_EXPORT LatencyInfo {
// Empirically determined constant based on a typical scroll sequence.
enum { kTypicalMaxComponentsPerLatencyInfo = 10 };
- enum { kMaxInputCoordinates = 2 };
+ enum : size_t { kMaxInputCoordinates = 2 };
// Map a Latency Component (with a component-specific int64_t id) to a
// component info.
@@ -240,6 +247,7 @@ class EVENTS_BASE_EXPORT LatencyInfo {
#if !defined(OS_IOS)
friend struct IPC::ParamTraits<ui::LatencyInfo>;
+ friend struct mojo::StructTraits<ui::mojom::LatencyInfo, ui::LatencyInfo>;
#endif
};
« no previous file with comments | « ui/events/DEPS ('k') | ui/events/mojo/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698