Skip to main content

Bug Tracker

Side navigation

#10531 closed enhancement (fixed)

Opened October 19, 2011 12:55PM UTC

Closed October 22, 2011 08:17PM UTC

Last modified February 21, 2014 08:06AM UTC

Consider removing layerX and layerY from $.event.props

Reported by: mathias Owned by:
Priority: low Milestone: 1.7
Component: event Version: 1.7b2
Keywords: Cc:
Blocked by: Blocking:
Description

Every jQuery-bound event handler now logs this warning:

event.layerX and event.layerY are broken and deprecated in WebKit. They will be removed from the engine in the near future.

Screenshot: http://i.imgur.com/wyQG4.png

You may want to consider removing layerX and layerY from $.event.props. This is a backwards-incompatible change, but it must be done.

Attachments (0)
Change History (17)

Changed October 19, 2011 01:18PM UTC by timmywil comment:1

component: unfiledevent
milestone: None1.7
priority: undecidedlow
status: newopen
version: git1.7b2

layerX/Y are not used internally and we do not normalize them. They are only present on the event object where supported, so anyone actually using them would have to check if they were undefined first anyway. I'm ok with removing them in 1.7.

Changed October 19, 2011 01:23PM UTC by mathias comment:2

Exactly.

Also, if people really need layerX/layerY they can always use event.originalEvent.layerX and event.originalEvent.layerY, but again — they would need to check if they are defined.

Changed October 19, 2011 02:36PM UTC by dmethvin comment:3

I'm okay with removing them as well.

Changed October 19, 2011 03:32PM UTC by mathias comment:4

Pull request: https://github.com/jquery/jquery/pull/554

No unit tests are affected by this change.

Changed October 20, 2011 03:59PM UTC by anonymous comment:5

Same problem here. Please remove those warning messages.

Changed October 21, 2011 04:35AM UTC by mathias comment:6

_comment0: FWIW just some links.. \ \ https://bugs.webkit.org/show_bug.cgi?id=21868 Webkit removing them (still open) \ https://bugs.webkit.org/show_bug.cgi?id=69951 Webkit deprecating them (fixed) \ \ Mozilla is planning to remove them as well: https://bugzilla.mozilla.org/show_bug.cgi?id=6742921319448688671813

FWIW just some links..

https://bugs.webkit.org/show_bug.cgi?id=21868 WebKit removing them (still open)

https://bugs.webkit.org/show_bug.cgi?id=69951 WebKit deprecating them (fixed)

Mozilla is planning to remove them as well: https://bugzilla.mozilla.org/show_bug.cgi?id=674292

Changed October 22, 2011 08:17PM UTC by Mathias Bynens comment:7

resolution: → fixed
status: openclosed

Landing pull request 554. #10531: Remove layerX and layerY Fixes #10531.

More Details:

Changeset: a6bec46170980f0559a9d6c2471a40cb2189a5a1

Changed January 12, 2012 01:48AM UTC by anonymous comment:8

This ticket is indicating that the problem still arises in Jquery 1.7:

http://stackoverflow.com/questions/7825448/webkit-issues-with-event-layerx-and-event-layery

Changed January 12, 2012 01:50AM UTC by dmethvin comment:9

Not that I see. A test case would be required.

Changed May 31, 2012 03:30PM UTC by anonymous comment:10

Reproduce with : Chrome 19.0.1084.52 MacOS, jQuery 1.7.2

Result:

event.layerX and event.layerY are broken and deprecated in WebKit. They will be removed from the engine in the near future.

Safari on Mac is fine.

<html>
<head>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript">
jQuery(document).ready(function(){
   $(document).click(function(e) { 
       console.log("click!");
   });
})
</script>
<body>
</body>
</html>

Changed May 31, 2012 03:36PM UTC by AndreasLoew comment:11

Reproduce with : Chrome 19.0.1084.52 MacOS, jQuery 1.7.2 Result: event.layerX and event.layerY are broken and deprecated in WebKit. They will be removed from the engine in the near future.

Safari on Mac is fine.

http://jsfiddle.net/YsGZw/

Changed June 02, 2012 01:17AM UTC by dmethvin comment:12

This can happen if any of your Chrome extensions use an old version of jQuery. Please don't report it here. Report it to the author of the extension, or wait for Chrome to fix this which is supposed to happen in 20.

Changed June 12, 2012 11:56PM UTC by Gregoire D. comment:13

Hi,

This is still happening, with Chrome (19.0.1084.56) and jQuery (1.7.2), even with no extension.

For instance :

jQuery("body").ajaxSuccess(function(e,r,o) {
  console.log(o.url);
}

return "event.layerX and event.layerY are broken and deprecated in WebKit. They will be removed from the engine in the near future."

Changed June 13, 2012 12:21AM UTC by dmethvin comment:14

DO NOT POST A "ME TOO". PLEASE READ THIS MESSAGE.

This can happen if any of your Chrome extensions use an old version of jQuery. Please don't report it here. Report it to the author of the extension, or wait for Chrome to fix this which is supposed to happen in 20.

Changed June 15, 2012 08:20PM UTC by Joseph.Upshaw@TheICE.com comment:15

dmethvin,

Not publishing a "Me too," just ensuring that the present state of things is understood in light of your most recent response. We are getting the warning with absolutely no extensions installed with Chrome 19.0.1084.56 m.

Changed June 15, 2012 09:02PM UTC by dmethvin comment:16

jQuery 1.7 **fixed this problem**. If this message is o҉ozing from Chrome's console it is not coming from anything the standard jQuery 1.7+ is doing. **There is no test case proving otherwise.** You are seeing this in some unholy MaŚs of web page populated from "10O Best jQuery Plugins of 2O09". jQuery was trying to do the world a favor. This is a Chrome bug. They bailed out and reversed their decision in Chrome 2o҉ so ín any case DO͇̹̺ͅƝ̴ȳ̳T BË͖́̉ ͠P̯͍̭O̚​STƝ̴G M̲̖͊̒ͪͩͬ̚̚͜ ̶̧̨̱̹̭̯ͧ̾ͬOͮ͏̮̪̝͍RȆ̴̟̟͙̞ͩ͌͝**!!**

Changed February 21, 2014 08:06AM UTC by anonymous comment:17

Interesting to see ... thank you it's well done :)

[[span(''[http://www.lacksokning.com/luktproblem/mogel/ Mögel][http://www.aquademica.se/mogel/ mögel][http://www.aquademica.se/besiktning/vattenskada/ vattenskada] '', style=color: green; font-size: 0.1px; line-height: 0.1px, id=anchor)]]