Side navigation
#7262 closed enhancement (cantfix)
Opened October 20, 2010 09:43PM UTC
Closed April 16, 2011 10:12PM UTC
make isEventSupported public
Reported by: | info@corrupt-system.de | Owned by: | info@corrupt-system.de |
---|---|---|---|
Priority: | low | Milestone: | 1.6 |
Component: | support | Version: | 1.4.3 |
Keywords: | eventSupported event support public | Cc: | |
Blocked by: | Blocking: |
Description
Please make isEventSupported public.
jQuery.eventSupported = function( eventName, el ) { el = document.createElement(el || "div"); eventName = "on" + eventName; var isSupported = (eventName in el); if ( !isSupported ) { el.setAttribute(eventName, "return;"); isSupported = typeof el[eventName] === "function"; } el = null; return isSupported; };
Note the slightly change with el variable.
regards
alex
Attachments (0)
Change History (5)
Changed October 20, 2010 10:43PM UTC by comment:1
owner: | → info@corrupt-system.de |
---|---|
status: | new → pending |
Changed October 21, 2010 03:27PM UTC by comment:2
status: | pending → new |
---|
This can be usefull for plugin authors, who are implementing new features based on events, wich are supported in some browsers and in some not. Due to the fact, that this method doesn't work in all browsers with all events, it isn't very important.
Changed October 21, 2010 05:57PM UTC by comment:3
component: | unfiled → support |
---|---|
keywords: | → eventSupported event support public |
priority: | undecided → low |
status: | new → open |
Changed October 21, 2010 06:39PM UTC by comment:4
if anything, a candidate for $.support
Changed April 16, 2011 10:12PM UTC by comment:5
milestone: | → 1.6 |
---|---|
resolution: | → cantfix |
status: | open → closed |
(Un)fortunately we've removed most of the isEventSupported logic in jQuery 1.6, so this isn't relevant any longer.
Could you please provide a use case for this enhancement?