[go: nahoru, domu]

[animation] Increase the capacity of TargetProperties

This list of target properties in cc (defined in
cc/trees/target_property.h), is cc-specific and unrelated to the
generic animation system currently housed in cc/animation. As such,
other clients of this system may define their own list of target
properties, and the number of target properties used by these other
clients may well exceed the number of properties used by cc.

Unfortunately, the capacity of the TargetProperties type is tied to
cc's list of target properties. With this change, the maximum
capacity has been switched to an arbitrary constant. Corresponding
static_asserts have been added to ensure that this limit is not
exceeded.

Depressingly, this is still housed in cc/trees; it's not yet
possible to move TargetProperties cc/animation because it's used by
code in cc/trees which is not allowed to depend on cc/animation.
Once cc/animation no longer depends on cc we can break the
circularity and move this elsewhere.

Bug: 747185
Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel
Change-Id: I89c8df0b08fe4729389295b6271c6e1f2b23074e
Reviewed-on: https://chromium-review.googlesource.com/720066
Commit-Queue: Ian Vollick <vollick@chromium.org>
Reviewed-by: Robert Flack <flackr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#509139}
diff --git a/cc/BUILD.gn b/cc/BUILD.gn
index 5c1b29be..1ee79dd 100644
--- a/cc/BUILD.gn
+++ b/cc/BUILD.gn
@@ -326,6 +326,7 @@
     "trees/swap_promise_manager.h",
     "trees/swap_promise_monitor.cc",
     "trees/swap_promise_monitor.h",
+    "trees/target_property.cc",
     "trees/target_property.h",
     "trees/task_runner_provider.cc",
     "trees/task_runner_provider.h",