OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef DocumentAnimation_h | 5 #ifndef DocumentAnimation_h |
6 #define DocumentAnimation_h | 6 #define DocumentAnimation_h |
7 | 7 |
| 8 #include "core/animation/Animation.h" |
| 9 #include "core/animation/DocumentTimeline.h" |
8 #include "core/dom/Document.h" | 10 #include "core/dom/Document.h" |
9 #include "platform/wtf/Allocator.h" | 11 #include "platform/wtf/Allocator.h" |
10 | 12 |
11 namespace blink { | 13 namespace blink { |
12 | 14 |
13 class DocumentAnimation { | 15 class DocumentAnimation { |
14 STATIC_ONLY(DocumentAnimation); | 16 STATIC_ONLY(DocumentAnimation); |
15 | 17 |
16 public: | 18 public: |
17 static DocumentTimeline* timeline(Document& document) { | 19 static DocumentTimeline* timeline(Document& document) { |
18 return &document.Timeline(); | 20 return &document.Timeline(); |
19 } | 21 } |
| 22 |
| 23 static HeapVector<Member<Animation>> getAnimations(Document& document) { |
| 24 return document.Timeline().getAnimations(); |
| 25 } |
20 }; | 26 }; |
21 | 27 |
22 } // namespace blink | 28 } // namespace blink |
23 | 29 |
24 #endif // DocumentAnimation_h | 30 #endif // DocumentAnimation_h |
OLD | NEW |