mirror of
https://github.com/photonstorm/phaser
synced 2024-11-26 22:52:14 +00:00
Added resume method implementation that calls super method and dispatches resume event
This commit is contained in:
parent
5e8d0dcaee
commit
196258b8ac
1 changed files with 9 additions and 0 deletions
|
@ -44,6 +44,15 @@ var HTML5AudioSound = new Class({
|
|||
// TODO implement pause method
|
||||
this.events.dispatch(new SoundEvent(this, 'SOUND_PAUSE'));
|
||||
return true;
|
||||
},
|
||||
resume: function () {
|
||||
if (!BaseSound.prototype.resume.call(this)) {
|
||||
return false;
|
||||
}
|
||||
// \/\/\/ isPlaying = true, isPaused = false \/\/\/
|
||||
// TODO implement resume method
|
||||
this.events.dispatch(new SoundEvent(this, 'SOUND_RESUME'));
|
||||
return true;
|
||||
}
|
||||
});
|
||||
module.exports = HTML5AudioSound;
|
||||
|
|
Loading…
Reference in a new issue