http://www.leginfo.ca.gov/cgi-bin/displaycode?section=lab...
They can claim ownership if the work was done with the company's property, or the work is related to the company's business. And courts in California have generally held that the relation has to be pretty strong. So a software company can't claim ownership on _all_ software products you create in your spare time, just that which is "substantially similar" to what the company does.
There was a Joel on Software discussion on this a while back:
http://discuss.joelonsoftware.com/default.asp?biz.5.451795.2...
EDIT: The above is not legal advice. Corporate and worker rights vary by country, and the U.S., by state. But I hope the above is informative to Google engineers who work in California.