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

Unified Diff: ui/gfx/compositor/layer_animation_element.h

Issue 8362006: Reland r107720 - Enable the new layer animation framework. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge Created 9 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/gfx/compositor/layer_animation_delegate.h ('k') | ui/gfx/compositor/layer_animation_element.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/compositor/layer_animation_element.h
diff --git a/ui/gfx/compositor/layer_animation_element.h b/ui/gfx/compositor/layer_animation_element.h
index 12697b0531ea6d67330daba8d9c1fa64b394fdb0..d38bc42375c40c162be6d55a84418edeb3329e6e 100644
--- a/ui/gfx/compositor/layer_animation_element.h
+++ b/ui/gfx/compositor/layer_animation_element.h
@@ -10,10 +10,8 @@
#include "base/time.h"
#include "ui/gfx/compositor/compositor_export.h"
-
-namespace gfx {
-class Rect;
-} // gfx
+#include "ui/gfx/rect.h"
+#include "ui/gfx/transform.h"
namespace ui {
@@ -31,6 +29,14 @@ class COMPOSITOR_EXPORT LayerAnimationElement {
OPACITY
};
+ struct TargetValue {
+ public:
+ TargetValue();
+ gfx::Rect bounds;
+ Transform transform;
+ float opacity;
+ };
+
typedef std::set<AnimatableProperty> AnimatableProperties;
LayerAnimationElement(const AnimatableProperties& properties,
@@ -71,6 +77,9 @@ class COMPOSITOR_EXPORT LayerAnimationElement {
// before OnStarted or Progress.
void Abort();
+ // Assigns the target value to |target|.
+ void GetTargetValue(TargetValue* target) const;
+
// The properties that the element modifies.
const AnimatableProperties& properties() const { return properties_; }
@@ -82,6 +91,7 @@ class COMPOSITOR_EXPORT LayerAnimationElement {
// OnProgress.
virtual void OnStart(LayerAnimationDelegate* delegate) = 0;
virtual void OnProgress(double t, LayerAnimationDelegate* delegate) = 0;
+ virtual void OnGetTarget(TargetValue* target) const = 0;
virtual void OnAbort() = 0;
private:
« no previous file with comments | « ui/gfx/compositor/layer_animation_delegate.h ('k') | ui/gfx/compositor/layer_animation_element.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698