simpler code for wipe transition