only allow mouse or keys for panning