Port of http://chromium.googlecode.com/svn/trunk/