title: NSView Frame Origin Get Reset After Animation Completed (Animator Proxy)
body: <p>Animation proxy <code>setFrameOrigin</code> makes the view flashback to the origin position after animation completed. I use the code below to animate the <code>NSView</code> to move down <code>-50</code> points, however, when the animation completed the frame position seems get reset to the <code>0</code> and result in a flash of the view. </p>
  
  <p>I have auto-layout constraints set up for this view, I think this position reset might cause by the auto-layout.</p>
  
  <pre><code>  NSAnimationContext.beginGrouping()
    NSAnimationContext.current.duration = 0.5
    barVersionFree.animator().setFrameOrigin(NSPoint(x: 0, y: -50))
    NSAnimationContext.endGrouping()
  </code></pre>
  
  <p>I try to set it again using the code below but the result is the same.</p>
  
  <pre><code>  NSAnimationContext.beginGrouping()
    NSAnimationContext.current.duration = 0.5
    barVersionFree.animator().setFrameOrigin(NSPoint(x: 0, y: -50))
    NSAnimationContext.endGrouping()
    barVersionFree.setFrameOrigin(NSPoint(x:0, y: -50))
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/RPBAq.gif" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/RPBAq.gif" alt="enter image description here"></a></p>