pub struct ServerObject { /* private fields */ }Expand description
Server-side CompositionObject counterpart. Is responsible for
animation activation and invalidation.
Implementations§
Source§impl ServerObject
impl ServerObject
Sourcepub fn new(
compositor: &Rc<ServerCompositor>,
owner: Weak<dyn IAnimatedServerObject>,
) -> Self
pub fn new( compositor: &Rc<ServerCompositor>, owner: Weak<dyn IAnimatedServerObject>, ) -> Self
owner is the object that embeds this part.
Sourcepub fn compositor(&self) -> Option<Rc<ServerCompositor>>
pub fn compositor(&self) -> Option<Rc<ServerCompositor>>
The compositor of the object, while it is alive.
pub fn animations(&self) -> Option<Rc<ServerObjectAnimations>>
pub fn get_or_create_animations(&self) -> Rc<ServerObjectAnimations>
pub fn is_active(&self) -> bool
pub fn activate(&self)
pub fn deactivate(&self)
Sourcepub fn set_value(
&self,
property: &'static CompositionProperty,
change: ServerValueChange<'_>,
)
pub fn set_value( &self, property: &'static CompositionProperty, change: ServerValueChange<'_>, )
SetValue(prop, ref field, value) of an animatable object: assigns
and invalidates the subscriptions of the property.
Sourcepub fn set_animated_value(
&self,
property: &'static CompositionProperty,
current_value: ExpressionVariant,
committed_at: Duration,
animation: Rc<dyn IAnimationInstance>,
)
pub fn set_animated_value( &self, property: &'static CompositionProperty, current_value: ExpressionVariant, committed_at: Duration, animation: Rc<dyn IAnimationInstance>, )
SetAnimatedValue(prop, ref field, committedAt, animation).
Sourcepub fn remove_animation_for_property(
&self,
property: &'static CompositionProperty,
)
pub fn remove_animation_for_property( &self, property: &'static CompositionProperty, )
The tail of SetAnimatedValue(prop, out field, value).
Sourcepub fn get_property(&self, name: &str) -> ExpressionVariant
pub fn get_property(&self, name: &str) -> ExpressionVariant
IExpressionObject.GetProperty of the owner.
Auto Trait Implementations§
impl !Freeze for ServerObject
impl !RefUnwindSafe for ServerObject
impl !Send for ServerObject
impl !Sync for ServerObject
impl !UnwindSafe for ServerObject
impl Unpin for ServerObject
impl UnsafeUnpin for ServerObject
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> ClassDefaults for Twhere
T: ?Sized,
impl<T> ClassDefaults for Twhere
T: ?Sized,
Source§fn static_constructor()
fn static_constructor()
The static constructor of a type: work done once per thread, after
the properties of the type are registered and before its first
instance exists (class handlers,
affects_render, metadata
overrides). Read more