Browse Source

Don't transitively activate server objects, only objects directly attached to a composition target should receive updates

pull/8105/head
Nikita Tsukanov 4 years ago
parent
commit
f772e5fb5a
  1. 6
      src/Avalonia.Base/Rendering/Composition/Server/ServerObject.cs

6
src/Avalonia.Base/Rendering/Composition/Server/ServerObject.cs

@ -92,15 +92,13 @@ namespace Avalonia.Rendering.Composition.Server
public void SubscribeToInvalidation(int member, IAnimationInstance animation)
{
ref var store = ref GetStoreFromOffset(member);
if (store.Subscribers.AddRef(animation))
Activate();
store.Subscribers.AddRef(animation);
}
public void UnsubscribeFromInvalidation(int member, IAnimationInstance animation)
{
ref var store = ref GetStoreFromOffset(member);
if (store.Subscribers.ReleaseRef(animation))
Deactivate();
store.Subscribers.ReleaseRef(animation);
}
public virtual int? GetFieldOffset(string fieldName) => null;

Loading…
Cancel
Save