|
CC Animation: Expose TargetProperty enum to be aliased in Blink Platform.
AN UNFINISHED DEMO.
AnimationTargetProperty is intended to be used as an alias in
Source/platform/animation/CompositorAnimationTargetProperty.h
It demonstrates all the problems with strongly typed enums:
1) ostream support needed (logging):
DCHECK(animation->target_property() != AnimationTargetProperty::SCROLL_OFFSET) to work.
Pros: it will be logged with its string value instead of integer value for old-style enums.
2) hash support needed.
(See the usage in LayerAnimationController)
(C++14 addresses this with DR2148)
3) array indexing: static_casts or helper functions.
(See the problems in animation_timelines_test_common.*)
Consider an alternative approach:
https://codereview.chromium.org/1700653002
BUG= 577016
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Total comments: 2
Total comments: 2
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+667 lines, -503 lines) |
Patch |
 |
M |
cc/BUILD.gn
|
View
|
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation.h
|
View
|
|
5 chunks |
+5 lines, -14 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation.cc
|
View
|
|
4 chunks |
+4 lines, -19 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation_delegate.h
|
View
|
|
1 chunk |
+5 lines, -6 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation_events.h
|
View
|
|
1 chunk |
+2 lines, -2 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation_events.cc
|
View
|
|
2 chunks |
+2 lines, -3 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation_host.h
|
View
|
|
1 chunk |
+2 lines, -3 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation_host.cc
|
View
|
|
12 chunks |
+31 lines, -19 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation_player.h
|
View
|
|
1 chunk |
+4 lines, -4 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation_player.cc
|
View
|
|
5 chunks |
+6 lines, -6 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation_player_unittest.cc
|
View
|
|
3 chunks |
+15 lines, -15 lines |
0 comments
|
Download
|
 |
A |
cc/animation/animation_target_property.h
|
View
|
1
|
1 chunk |
+39 lines, -0 lines |
1 comment
|
Download
|
 |
A |
cc/animation/animation_target_property.cc
|
View
|
|
1 chunk |
+34 lines, -0 lines |
0 comments
|
Download
|
 |
M |
cc/animation/animation_unittest.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
cc/animation/element_animations.h
|
View
|
|
1 chunk |
+3 lines, -3 lines |
0 comments
|
Download
|
 |
M |
cc/animation/element_animations.cc
|
View
|
|
3 chunks |
+3 lines, -3 lines |
0 comments
|
Download
|
 |
M |
cc/animation/layer_animation_controller.h
|
View
|
1
|
4 chunks |
+6 lines, -5 lines |
1 comment
|
Download
|
 |
M |
cc/animation/layer_animation_controller.cc
|
View
|
|
31 chunks |
+47 lines, -44 lines |
0 comments
|
Download
|
 |
M |
cc/animation/layer_animation_controller_unittest.cc
|
View
|
|
82 chunks |
+260 lines, -185 lines |
0 comments
|
Download
|
 |
M |
cc/blink/web_to_cc_animation_delegate_adapter.h
|
View
|
|
1 chunk |
+3 lines, -3 lines |
0 comments
|
Download
|
 |
M |
cc/blink/web_to_cc_animation_delegate_adapter.cc
|
View
|
|
3 chunks |
+3 lines, -3 lines |
0 comments
|
Download
|
 |
M |
cc/cc.gyp
|
View
|
|
1 chunk |
+2 lines, -0 lines |
0 comments
|
Download
|
 |
M |
cc/layers/layer.h
|
View
|
|
1 chunk |
+1 line, -2 lines |
0 comments
|
Download
|
 |
M |
cc/layers/layer.cc
|
View
|
|
8 chunks |
+11 lines, -8 lines |
0 comments
|
Download
|
 |
M |
cc/layers/layer_impl.h
|
View
|
|
2 chunks |
+4 lines, -5 lines |
0 comments
|
Download
|
 |
M |
cc/layers/layer_impl.cc
|
View
|
|
12 chunks |
+19 lines, -20 lines |
0 comments
|
Download
|
 |
M |
cc/layers/layer_unittest.cc
|
View
|
|
4 chunks |
+5 lines, -5 lines |
0 comments
|
Download
|
 |
M |
cc/test/animation_test_common.h
|
View
|
|
1 chunk |
+3 lines, -4 lines |
0 comments
|
Download
|
 |
M |
cc/test/animation_test_common.cc
|
View
|
|
5 chunks |
+9 lines, -10 lines |
0 comments
|
Download
|
 |
M |
cc/test/animation_timelines_test_common.h
|
View
|
|
4 chunks |
+17 lines, -11 lines |
0 comments
|
Download
|
 |
M |
cc/test/animation_timelines_test_common.cc
|
View
|
|
6 chunks |
+9 lines, -10 lines |
0 comments
|
Download
|
 |
M |
cc/test/test_hooks.h
|
View
|
|
1 chunk |
+3 lines, -3 lines |
0 comments
|
Download
|
 |
M |
cc/trees/layer_tree_host.h
|
View
|
|
1 chunk |
+2 lines, -3 lines |
0 comments
|
Download
|
 |
M |
cc/trees/layer_tree_host.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
cc/trees/layer_tree_host_common_unittest.cc
|
View
|
|
6 chunks |
+13 lines, -13 lines |
0 comments
|
Download
|
 |
M |
cc/trees/layer_tree_host_impl.cc
|
View
|
|
3 chunks |
+4 lines, -3 lines |
0 comments
|
Download
|
 |
M |
cc/trees/layer_tree_host_impl_unittest.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
cc/trees/layer_tree_host_unittest_animation.cc
|
View
|
|
22 chunks |
+41 lines, -31 lines |
0 comments
|
Download
|
 |
M |
cc/trees/layer_tree_host_unittest_animation_timelines.cc
|
View
|
|
16 chunks |
+40 lines, -30 lines |
0 comments
|
Download
|
 |
M |
cc/trees/layer_tree_impl.h
|
View
|
|
1 chunk |
+2 lines, -3 lines |
0 comments
|
Download
|
 |
M |
cc/trees/layer_tree_impl.cc
|
View
|
|
1 chunk |
+1 line, -1 line |
0 comments
|
Download
|
 |
M |
cc/trees/property_tree_builder.cc
|
View
|
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
Total messages: 20 (9 generated)
|