Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(225)

Side by Side Diff: Source/core/rendering/style/KeyframeList.h

Issue 899163003: Move rendering/RenderObject to layout/LayoutObject. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/rendering/style/FillLayer.cpp ('k') | Source/core/rendering/style/KeyframeList.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org)
3 * (C) 2000 Antti Koivisto (koivisto@kde.org) 3 * (C) 2000 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2003, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. 5 * Copyright (C) 2003, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved.
6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com) 6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com)
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 16 matching lines...) Expand all
27 27
28 #include "core/CSSPropertyNames.h" 28 #include "core/CSSPropertyNames.h"
29 #include "core/rendering/style/StyleInheritedData.h" 29 #include "core/rendering/style/StyleInheritedData.h"
30 #include "wtf/HashSet.h" 30 #include "wtf/HashSet.h"
31 #include "wtf/RefPtr.h" 31 #include "wtf/RefPtr.h"
32 #include "wtf/Vector.h" 32 #include "wtf/Vector.h"
33 #include "wtf/text/AtomicString.h" 33 #include "wtf/text/AtomicString.h"
34 34
35 namespace blink { 35 namespace blink {
36 36
37 class RenderObject; 37 class LayoutObject;
38 class RenderStyle; 38 class RenderStyle;
39 39
40 class KeyframeValue { 40 class KeyframeValue {
41 public: 41 public:
42 KeyframeValue(double key, PassRefPtr<RenderStyle> style) 42 KeyframeValue(double key, PassRefPtr<RenderStyle> style)
43 : m_key(key) 43 : m_key(key)
44 , m_style(style) 44 , m_style(style)
45 { 45 {
46 } 46 }
47 47
48 void addProperty(CSSPropertyID prop) { m_properties.add(prop); } 48 void addProperty(CSSPropertyID prop) { m_properties.add(prop); }
49 bool containsProperty(CSSPropertyID prop) const { return m_properties.contai ns(prop); } 49 bool containsProperty(CSSPropertyID prop) const { return m_properties.contai ns(prop); }
50 const HashSet<CSSPropertyID>& properties() const { return m_properties; } 50 const HashSet<CSSPropertyID>& properties() const { return m_properties; }
51 51
52 double key() const { return m_key; } 52 double key() const { return m_key; }
53 void setKey(double key) { m_key = key; } 53 void setKey(double key) { m_key = key; }
54 54
55 const RenderStyle* style() const { return m_style.get(); } 55 const RenderStyle* style() const { return m_style.get(); }
56 void setStyle(PassRefPtr<RenderStyle> style) { m_style = style; } 56 void setStyle(PassRefPtr<RenderStyle> style) { m_style = style; }
57 57
58 private: 58 private:
59 double m_key; 59 double m_key;
60 HashSet<CSSPropertyID> m_properties; // The properties specified in this key frame. 60 HashSet<CSSPropertyID> m_properties; // The properties specified in this key frame.
61 RefPtr<RenderStyle> m_style; 61 RefPtr<RenderStyle> m_style;
62 }; 62 };
63 63
64 class KeyframeList { 64 class KeyframeList {
65 public: 65 public:
66 KeyframeList(RenderObject&, const AtomicString& animationName) 66 KeyframeList(LayoutObject&, const AtomicString& animationName)
67 : m_animationName(animationName) 67 : m_animationName(animationName)
68 { 68 {
69 insert(KeyframeValue(0, nullptr)); 69 insert(KeyframeValue(0, nullptr));
70 insert(KeyframeValue(1, nullptr)); 70 insert(KeyframeValue(1, nullptr));
71 } 71 }
72 ~KeyframeList(); 72 ~KeyframeList();
73 73
74 const AtomicString& animationName() const { return m_animationName; } 74 const AtomicString& animationName() const { return m_animationName; }
75 75
76 void insert(const KeyframeValue& keyframe); 76 void insert(const KeyframeValue& keyframe);
(...skipping 10 matching lines...) Expand all
87 87
88 private: 88 private:
89 AtomicString m_animationName; 89 AtomicString m_animationName;
90 Vector<KeyframeValue> m_keyframes; // Kept sorted by key. 90 Vector<KeyframeValue> m_keyframes; // Kept sorted by key.
91 HashSet<CSSPropertyID> m_properties; // The properties being animated. 91 HashSet<CSSPropertyID> m_properties; // The properties being animated.
92 }; 92 };
93 93
94 } // namespace blink 94 } // namespace blink
95 95
96 #endif // KeyframeList_h 96 #endif // KeyframeList_h
OLDNEW
« no previous file with comments | « Source/core/rendering/style/FillLayer.cpp ('k') | Source/core/rendering/style/KeyframeList.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698