Ah, i forgot that i used even more overkilling but working solution: element.observe('selectstart', Event.stop);
Anyway i got your point. On Sat, 26 Sep 2009 19:10:34 +0400, kangax <kan...@gmail.com> wrote: > > > > On Sep 26, 6:30 am, "artemy tregubenko" <m...@arty.name> wrote: >> Why don't you use element.onselectstart = Event.stop; ? > > Because `Event.stop` expects first argument to be an event object, and > MSHTML does not supply that argument to event handler attached as a > property of an element. When assigned to a property, `Event.stop` will > try to operate on an undefined value and eventually throw error. > > Even if `Event.stop` accounted for IE-proprietary `window.event`, it > would be kind of an overkill to 1) extend event, 2) prevent its > default action, 3) stop propagation, and 4) extend it with "stopped" > property - when all that's needed is plain and simple - `return > false`. > > [...] > > -- > kangax > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Prototype: Core" group. To post to this group, send email to prototype-core@googlegroups.com To unsubscribe from this group, send email to prototype-core-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/prototype-core?hl=en -~----------~----~----~----~------~----~------~--~---