diff --git a/src/Avalonia.Base/Media/MediaContext.Compositor.cs b/src/Avalonia.Base/Media/MediaContext.Compositor.cs index 69663d33b9..984e4205e5 100644 --- a/src/Avalonia.Base/Media/MediaContext.Compositor.cs +++ b/src/Avalonia.Base/Media/MediaContext.Compositor.cs @@ -49,24 +49,12 @@ partial class MediaContext { _animationsAreWaitingForComposition = false; - // Check if we have uncommited changes - if (_requestedCommits.Count != 0) - { - if (!CommitCompositorsWithThrottling()) - ScheduleRenderForAnimationsIfNeeded(); - - } - // Check if there are active animations and schedule the next render - else - ScheduleRenderForAnimationsIfNeeded(); + // Check if we have requested commits or active animations and schedule a new render pass + if (_requestedCommits.Count != 0 || _clock.HasSubscriptions) + ScheduleRender(false); } } - void ScheduleRenderForAnimationsIfNeeded() - { - if (_clock.HasSubscriptions) - ScheduleRender(false); - } /// /// Triggers a composition commit if any batches are waiting to be sent,