Fixed some issues on webpage.clipRect and webpage.cookies