Skip to content

Commit

Permalink
Added option to specify which element should have mouse events attach…
Browse files Browse the repository at this point in the history
…ed to it. Defaults to the Sketch canvas. Fixes soulwire#68
  • Loading branch information
soulwire committed Sep 11, 2015
1 parent 33cac83 commit 6cae7ed
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions js/sketch.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/* Copyright (C) 2013 Justin Windle, http://soulwire.co.uk */

(function ( root, factory ) {

if ( typeof exports === 'object' ) {

// CommonJS like
Expand Down Expand Up @@ -169,7 +169,7 @@

var eventMap = [

context.element,
context.eventTarget || context.element,

pointer, 'mousedown', 'touchstart',
pointer, 'mousemove', 'touchmove',
Expand Down Expand Up @@ -257,7 +257,7 @@
// Draw

trigger( context.draw );

// Post draw

if ( is2D && context.retina )
Expand Down
2 changes: 1 addition & 1 deletion js/sketch.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 6cae7ed

Please sign in to comment.