OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
218 if (!endTransform->transformOperations().blendedBoundsForBox(origina
lBox, startTransform->transformOperations(), min, max, &bounds)) | 218 if (!endTransform->transformOperations().blendedBoundsForBox(origina
lBox, startTransform->transformOperations(), min, max, &bounds)) |
219 return false; | 219 return false; |
220 box.expandTo(bounds); | 220 box.expandTo(bounds); |
221 } | 221 } |
222 } | 222 } |
223 return true; | 223 return true; |
224 } | 224 } |
225 | 225 |
226 bool CompositorAnimations::isCandidateForAnimationOnCompositor(const Timing& tim
ing, const Element& targetElement, const Animation* animationToAdd, const Effect
Model& effect, double animationPlaybackRate) | 226 bool CompositorAnimations::isCandidateForAnimationOnCompositor(const Timing& tim
ing, const Element& targetElement, const Animation* animationToAdd, const Effect
Model& effect, double animationPlaybackRate) |
227 { | 227 { |
| 228 // TODO(alancutter): Make transitions work on the compositor |
| 229 if (!effect.isKeyframeEffectModel()) |
| 230 return false; |
| 231 |
228 const KeyframeEffectModelBase& keyframeEffect = toKeyframeEffectModelBase(ef
fect); | 232 const KeyframeEffectModelBase& keyframeEffect = toKeyframeEffectModelBase(ef
fect); |
229 | 233 |
230 PropertyHandleSet properties = keyframeEffect.properties(); | 234 PropertyHandleSet properties = keyframeEffect.properties(); |
231 if (properties.isEmpty()) | 235 if (properties.isEmpty()) |
232 return false; | 236 return false; |
233 | 237 |
234 unsigned transformPropertyCount = 0; | 238 unsigned transformPropertyCount = 0; |
235 for (const auto& property : properties) { | 239 for (const auto& property : properties) { |
236 if (!property.isCSSProperty()) | 240 if (!property.isCSSProperty()) |
237 return false; | 241 return false; |
(...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
576 break; | 580 break; |
577 default: | 581 default: |
578 NOTREACHED(); | 582 NOTREACHED(); |
579 } | 583 } |
580 animations.append(std::move(animation)); | 584 animations.append(std::move(animation)); |
581 } | 585 } |
582 ASSERT(!animations.isEmpty()); | 586 ASSERT(!animations.isEmpty()); |
583 } | 587 } |
584 | 588 |
585 } // namespace blink | 589 } // namespace blink |
OLD | NEW |