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

Side by Side Diff: Source/core/animation/AnimatableValue.h

Issue 19744002: Web Animations: Add CSSAnimatableValueFactory API (partial implementation) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Move folders and add const to param Created 7 years, 4 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/animation/AnimatableNumber.cpp ('k') | Source/core/animation/AnimatableValue.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) 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 23 matching lines...) Expand all
34 #include "core/css/CSSValue.h" 34 #include "core/css/CSSValue.h"
35 #include "wtf/RefCounted.h" 35 #include "wtf/RefCounted.h"
36 36
37 namespace WebCore { 37 namespace WebCore {
38 38
39 class CSSValue; 39 class CSSValue;
40 40
41 class AnimatableValue : public RefCounted<AnimatableValue> { 41 class AnimatableValue : public RefCounted<AnimatableValue> {
42 public: 42 public:
43 virtual ~AnimatableValue() { } 43 virtual ~AnimatableValue() { }
44 static PassRefPtr<AnimatableValue> create(CSSValue*);
45 virtual PassRefPtr<CSSValue> toCSSValue() const = 0; 44 virtual PassRefPtr<CSSValue> toCSSValue() const = 0;
46 45
47 static const AnimatableValue* neutralValue(); 46 static const AnimatableValue* neutralValue();
48 virtual bool isNeutral() const { return false; } 47 virtual bool isNeutral() const { return false; }
49 48
50 static const AnimatableValue* deferredSnapshotValue(); 49 static const AnimatableValue* deferredSnapshotValue();
51 virtual bool isDeferredSnapshot() const { return false; } 50 virtual bool isDeferredSnapshot() const { return false; }
52 51
53 static PassRefPtr<AnimatableValue> interpolate(const AnimatableValue*, const AnimatableValue*, double fraction); 52 static PassRefPtr<AnimatableValue> interpolate(const AnimatableValue*, const AnimatableValue*, double fraction);
54 // For noncommutative values read add(A, B) to mean the value A with B compo sed onto it. 53 // For noncommutative values read add(A, B) to mean the value A with B compo sed onto it.
(...skipping 24 matching lines...) Expand all
79 78
80 template <class T> 79 template <class T>
81 static PassRefPtr<T> takeConstRef(const T* value) { return PassRefPtr<T>(con st_cast<T*>(value)); } 80 static PassRefPtr<T> takeConstRef(const T* value) { return PassRefPtr<T>(con st_cast<T*>(value)); }
82 81
83 AnimatableType m_type; 82 AnimatableType m_type;
84 }; 83 };
85 84
86 } // namespace WebCore 85 } // namespace WebCore
87 86
88 #endif // AnimatableValue_h 87 #endif // AnimatableValue_h
OLDNEW
« no previous file with comments | « Source/core/animation/AnimatableNumber.cpp ('k') | Source/core/animation/AnimatableValue.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698