mirror of
https://github.com/photonstorm/phaser
synced 2025-02-25 20:07:08 +00:00
Replaced touchstart with touchend event when unlocking Web Audio
This commit is contained in:
parent
5f3156e2b8
commit
f692aad1b1
1 changed files with 2 additions and 2 deletions
|
@ -67,10 +67,10 @@ var WebAudioSoundManager = new Class({
|
||||||
var _this = this;
|
var _this = this;
|
||||||
if (this.context.state === 'suspended') {
|
if (this.context.state === 'suspended') {
|
||||||
var unlock_1 = function () {
|
var unlock_1 = function () {
|
||||||
document.body.removeEventListener('touchstart', unlock_1);
|
document.body.removeEventListener('touchend', unlock_1);
|
||||||
_this.context.resume();
|
_this.context.resume();
|
||||||
};
|
};
|
||||||
document.body.addEventListener('touchstart', unlock_1, false);
|
document.body.addEventListener('touchend', unlock_1, false);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onBlur: function () {
|
onBlur: function () {
|
||||||
|
|
Loading…
Add table
Reference in a new issue