DescriptionDecouple EventWithLatencyInfo from WebInputEventTraits
Only EventWithLatencyInfo uses [Can]Coalesce() from WebInputEventTraits.
WebInputEventTraits gets used for IPC stuff so is kinda sensitive, but
EventWithLatencyInfo isn't involved with IPC. So, coupling these
together also makes refactoring unnecessarily difficult.
E.g. the coupling means that if we want to move EventWithLatencyInfo to
a component, then WebInputEventTraits and a bunch of dependencies that
EventWithLatencyInfo doesn't care about need to come as well.
To decouple, the guts of [Can]Coalesce() moves to a new .cc file for
EventWithLatencyInfo. The types are known, so we get some added type
safety versus WebInputEventTraits which isn't templatized in the .h. The
instantiations in the .cc become a bit simpler and the runtime type
checks and static casts behind in web_input_event_trait.cc's Apply(..)
are not required.
BUG=615948
TBR=jochen@chromium.org (iwyu)
Committed: https://crrev.com/85282366fed27efe2e19a686b1376ad9eca37d84
Cr-Commit-Position: refs/heads/master@{#403402}
Patch Set 1 : Baseline version from crrev/2091213002 using extern templates #Patch Set 2 : rebase #Patch Set 3 : Ditch the template externs #Patch Set 4 : lint diff #Patch Set 5 : lint, iwyu #Patch Set 6 : lint, iwyu #
Total comments: 5
Patch Set 7 : why did I need that web_contents_impl change again? #Patch Set 8 : Bug reference + web_contents_impl iwyu to .cc #
Total comments: 1
Messages
Total messages: 20 (14 generated)
|