RefreshRect used to force a screen update instantly, which is how it has worked in the past. "Invalidate" would mark an area of a view as 'dirty' and then when the current method completes, the window server would ask the 'dirty' views to redraw.
I wouldn't be surprised if refreshRect either no longer works like it used to, or perhaps it never worked this way in 64-Bit. Either way I would suggest considering an alternative animation solution.
An oversimplified version is to use a timer. When you want to animate, you store the object, start value, end value, startTime and duration for the animation. You set the timer's period based upon 1000 / framesPerSecond ( 30 fps is 33 ).
In the action event you calculate how far into the animation the current time is, then use that to calculate the correct values for the object, update the object (and canvas, use invalidate( left, top, width, height)).
Once your currentTime exceeds startTime + duration, your animation is over and you can stop the timer.
Edit: Just want to add that a lot of functions in the recent macOS versions has to be 'scheduled' nowadays, I believe this is because of triple buffering.