Stop animation in gui on closing