System-level reduced-motion preferences. More...
#include <functional>#include <mutex>#include <optional>#include <string>#include <string_view>Go to the source code of this file.
Classes | |
| class | pulp::view::MotionPreferences |
| Process-wide reduced-motion preference tracker. More... | |
Namespaces | |
| namespace | pulp |
| namespace | pulp::view |
| Hover-cursor tracking for platform window hosts. | |
Enumerations | |
| enum class | pulp::view::MotionPolicy { pulp::view::Full , pulp::view::Reduced , pulp::view::Off } |
| Reduced-motion policy. More... | |
Functions | |
| float | pulp::view::apply_motion_policy_to_duration (float configured_seconds) |
| Apply the current MotionPolicy to a configured duration. | |
| bool | pulp::view::motion_policy_is_off () |
| Returns true when the current policy says "do not animate" — i.e. | |
| const char * | pulp::view::motion_policy_to_string (MotionPolicy p) |
| Returns the current policy string for fixture headers. | |
| MotionPolicy | pulp::view::motion_policy_from_string (const std::string_view s) |
| Parse a policy string (case-sensitive). Returns Full on unknown. | |
System-level reduced-motion preferences.
Sibling of AppearanceTracker: reads the OS accessibility setting on first use, exposes a polling + callback surface, and accepts a test override that wins over the OS value. Animation primitives (Tween, ValueAnimation, TransitionSpec, AnimatorSet) read this at construction / reset to honor the policy:
Off by default in the sense that nothing reads it unless an animation primitive starts; the singleton lives behind current().