sendEvent replaced by sendMessage