On 1/9/07, Andreas Wahlin <[EMAIL PROTECTED]> wrote:

Does this hold true for this.click() and this.offsetTop etc?


$(this).blur() = this.blur()
$(this).focus() = this.focus()
$(this).load() = this.load()
$(this).resize() = this.resize()
$(this).scroll() = this.scroll()
$(this).unload() = this.unload()
$(this).click() = this.click()
$(this).dblclick() = this.dblclick()
$(this).mousedown() = this.mousedown()
$(this).mouseup() = this.mouseup()
$(this).mousemove() = this.mousemove()
$(this).mouseover() = this.mouseover()
$(this).mouseout() = this.mouseout()
$(this).change() = this.change()
$(this).select() = this.select()
$(this).submit() = this.submit()
$(this).keydown() = this.keydown()
$(this).keypress() = this.keypress()
$(this).keyup() = this.keyup()
$(this).error() = this.error()

$(this).offsetTop != this.offsetTop (because it simply isn't possible in
JavaScript currently (at least not cross-browser). Maybe in JavaScript 2.0[1],
but I dunno. And anyway, the jQuery API was cleaned up precisely to get rid
of these kinds of shortcuts because they ended being little more than
clutter).

[1] It would be easy if it had some sort of equivalent to PHP's __get and
__set (http://www.php.net/manual/en/language.oop5.overloading.php), which
are basically "property not found" handlers and could be used to actually
map $("a").offsetTop to say $("a")[0].offsetTop.

--
Aaron Heimlich
Web Developer
[EMAIL PROTECTED]
http://aheimlich.freepgs.com
_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to