Resonant effects in a SQUID qubit subjected to nonadiabatic changes