why can't I assign properties to a new Image object?
foo = new Image()
foo.x = 500
foo.x => 0开发者_开发问答
var image = new Image();
image.foo = 100;
alert(image.foo);
works perfectly, you can't change x because it's predefined and has only a getter Method
精彩评论