Permalink
Browse files

must be touchend event

  • Loading branch information...
Erar Erar
Erar authored and Erar committed Nov 6, 2017
1 parent 3449c99 commit 020c3170bced6a60bf00b34113bfae92675acf8a
Showing with 11 additions and 11 deletions.
  1. +5 −5 gamee/src/core.js
  2. +6 −6 package-lock.json
View
@@ -14,22 +14,22 @@ import { wrapKeyEvent } from "../libs/shims.js"
ctx.resume()
setTimeout(function () {
if (ctx.state === 'running') {
document.body.removeEventListener('touchstart', resume, false)
document.body.removeEventListener('touchend', resume, false)
}
}, 0)
}
document.body.addEventListener('touchstart', resume, false);
document.body.addEventListener('touchend', resume, false);
}
// allowed in JS to return different type of the object in the constructor
return ctx
}
try {
if (typeof AudioContext !== 'undefined') {
AudioContext = overloadedAudioContext.bind(null, AudioContext)
if (typeof window.AudioContext !== 'undefined') {
window.AudioContext = overloadedAudioContext.bind(null, window.AudioContext)
} else if (typeof webkitAudioContext !== 'undefined') {
webkitAudioContext = overloadedAudioContext.bind(null, webkitAudioContext)
window.webkitAudioContext = overloadedAudioContext.bind(null, window.webkitAudioContext)
}
} catch (e) { // throw error in async part
setTimeout(() => {
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

0 comments on commit 020c317

Please sign in to comment.