From the AMVIC website:
"Q. I just bought a vehicle but have changed my mind. Can I cancel the deal and get my deposit back?
* Under normal circumstances, no. Your car purchase agreement is a legal contract.
* The only exception is if the agreement was signed with conditions: e.g. the vehicle must pass an inspection first or suitable financing had to be available.
* Speak to the dealer. They may be willing to work out an arrangement concerning the agreement but will probably keep the deposit.
"
http://www.amvic.org/consumer_issues.htm
If a sales contract had been written up and signed without "conditions" then there is no argument for a refund.
It is up to the dealer to refund a deposit unless terms and conditions on the invoice stated specific "conditions" being met prior to a sale being completed - ie) Financing, Inspections, etc.
If the dealer had taken the car off the lot and had considered it sold he may have potentially lost a serious buyer.
Under most circumstances the dealer will allow the deposit to be applied to another purchase but a refund is not required - as stated directly by AMVIC above. Generally speaking, we give refunds but if it cost the dealer a sale he might not.