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

Unified Diff: cc/animation/property_animation_state.h

Issue 2349643003: CC Animation: Extract PropertyAnimationState as a non-nested struct. (Closed)
Patch Set: Created 4 years, 3 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
Index: cc/animation/property_animation_state.h
diff --git a/cc/animation/property_animation_state.h b/cc/animation/property_animation_state.h
new file mode 100644
index 0000000000000000000000000000000000000000..74fbb699780fbed4671ad81fecefafb1e3e96dad
--- /dev/null
+++ b/cc/animation/property_animation_state.h
@@ -0,0 +1,34 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CC_ANIMATION_PROPERTY_ANIMATION_STATE_H_
+#define CC_ANIMATION_PROPERTY_ANIMATION_STATE_H_
+
+#include "cc/base/cc_export.h"
+
+namespace cc {
+
+struct CC_EXPORT PropertyAnimationState {
+ bool currently_running_for_active_elements = false;
+ bool currently_running_for_pending_elements = false;
+ bool potentially_animating_for_active_elements = false;
+ bool potentially_animating_for_pending_elements = false;
+
+ bool operator==(const PropertyAnimationState& other) const;
+ bool operator!=(const PropertyAnimationState& other) const;
+
+ PropertyAnimationState& operator|=(const PropertyAnimationState& other);
+ PropertyAnimationState& operator^=(const PropertyAnimationState& other);
+
+ bool IsValid() const;
+
+ void Clear();
+};
+
+PropertyAnimationState operator^(const PropertyAnimationState& lhs,
+ const PropertyAnimationState& rhs);
+
+} // namespace cc
+
+#endif // CC_ANIMATION_PROPERTY_ANIMATION_STATE_H_

Powered by Google App Engine
This is Rietveld 408576698