Skip to content
This repository has been archived by the owner on Mar 13, 2018. It is now read-only.

Commit

Permalink
add event listeners to parentNode
Browse files Browse the repository at this point in the history
Use new addGesture syntax with handler
  • Loading branch information
dfreedm committed Jul 28, 2014
1 parent 4752217 commit b136f5e
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions core-drag-drop.html
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,7 @@

attached: function() {
var listen = function(event, handler) {
PolymerGestures.addGesture(this, event);
this.parentNode.addEventListener(event, this[handler].bind(this));
PolymerGestures.addGesture(this.parentNode, event, this[handler].bind(this));
}.bind(this);
//
listen('trackstart', 'trackStart');
Expand Down

1 comment on commit b136f5e

@noxer
Copy link

@noxer noxer commented on b136f5e Jul 29, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Triggers "Uncaught TypeError: Cannot read property 'bind' of undefined" in line 58 (#3)!

Please sign in to comment.