Medicaid has the right to recover against the recipient's estate, but not against the spouse's, and there is no Medicaid restriction on transfers between spouses. Since the house was transferred during the nursing home resident’s life it was in neither his probate nor non-probate estate and not subject to estate recovery.
That said, there could be local exceptions that we're not aware of, so it would be best to consult an elder law attorney in the state in question to be absolutely sure. Here is a directory of attorneys: http://www.elderlawanswers.com/elder-law-attorneys.
For more information about estate recovery, click here.