mirror of
https://github.com/ClassiCube/ClassiCube.git
synced 2025-09-13 09:35:23 -04:00
fix android version freezing when you try to quit game and music is enabled
This commit is contained in:
parent
9688c2ebd2
commit
8c5cd2f303
@ -510,6 +510,9 @@ cc_result Audio_Play(struct AudioContext* ctx) {
|
|||||||
|
|
||||||
cc_result Audio_Stop(struct AudioContext* ctx) {
|
cc_result Audio_Stop(struct AudioContext* ctx) {
|
||||||
if (!ctx->bqPlayerPlayer) return 0;
|
if (!ctx->bqPlayerPlayer) return 0;
|
||||||
|
|
||||||
|
/* According to OpenSL ES spec, Clear can never fail anyways */
|
||||||
|
(*ctx->bqPlayerQueue)->Clear(ctx->bqPlayerQueue);
|
||||||
return (*ctx->bqPlayerPlayer)->SetPlayState(ctx->bqPlayerPlayer, SL_PLAYSTATE_STOPPED);
|
return (*ctx->bqPlayerPlayer)->SetPlayState(ctx->bqPlayerPlayer, SL_PLAYSTATE_STOPPED);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user