Fixed some Chrome compatibility issues.