Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Slideout option to disable touch events #45

Merged
merged 4 commits into from
Apr 1, 2015
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
add touch option. set to false to disable Slideout touch events. touc…
…h is enabled by default.
  • Loading branch information
vrunoa committed Mar 21, 2015
commit c4e0946221240898fc85c92afd8cecb873c1d03f
5 changes: 4 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ function Slideout(options) {
this._moved = false;
this._opened = false;
this._preventOpen = false;
this._touch = options.touch == undefined ? true : options.touch && true;

// Sets panel
this.panel = options.panel;
Expand All @@ -63,7 +64,9 @@ function Slideout(options) {
this._padding = parseInt(options.padding, 10) || 256;

// Init touch events
this._initTouchEvents();
if(this._touch) {
this._initTouchEvents();
}
}

/**
Expand Down