private void refresh() { bool shouldFire = recalculate(); if (shouldFire) { OnBoundingBoxWithChildrenChanged.Invoke(); } }
public void Unlock() { if (Interlocked.Decrement(ref _pendingLocks) > 0) { return; } if (Interlocked.Exchange(ref _shouldFireOnUnlock, 0) >= 1) { OnBoundingBoxWithChildrenChanged.Invoke(); } }