Fix canvas save and restore between frames