switch buffer with right/left