diff options
author | Bruno Coudoin <bcoudoin@src.gnome.org> | 2009-03-24 23:39:03 (GMT) |
---|---|---|
committer | Bruno Coudoin <bcoudoin@src.gnome.org> | 2009-03-24 23:39:03 (GMT) |
commit | 17174bc8010a1bab297aad8f7d978bcf990b4f77 (patch) | |
tree | 794e9b67493139e6b48d06baece07ac75bd3e3f3 | |
parent | ad1ed754b9fb6beac7ea25f65f13e01c81d5e1e8 (diff) |
fixed a cased in which the memory sound was in a fuzzy state if the level
* src/boards/memory.c: (start_board), (memory_next_level): fixed a cased in which
the memory sound was in a fuzzy state if the level was changed by the user.
Merged from trunk 3795
By the way in this branch this is not enough, tux play more than he should
when we change the level during the game.
svn path=/branches/GCOMPRIS_8_3/; revision=3797
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | src/boards/memory.c | 17 |
2 files changed, 17 insertions, 8 deletions
@@ -1,3 +1,11 @@ +2009-03-25 Bruno coudoin <bruno.coudoin@free.fr> + + * src/boards/memory.c: (start_board), (memory_next_level): fixed a cased in which + the memory sound was in a fuzzy state if the level was changed by the user. + Merged from trunk 3795 + By the way in this branch this is not enough, tux play more than he should + when we change the level during the game. + 2009-03-24 Bruno coudoin <bruno.coudoin@free.fr> - Replaced a level in memory sound to make the difficulty always increasing diff --git a/src/boards/memory.c b/src/boards/memory.c index 56d6527..037946b 100644 --- a/src/boards/memory.c +++ b/src/boards/memory.c @@ -868,14 +868,6 @@ static void start_board (GcomprisBoard *agcomprisBoard) Paused = FALSE; - to_tux = FALSE; - if (currentUiMode == UIMODE_SOUND){ - playing_sound = TRUE; - gc_sound_play_ogg_cb("sounds/LuneRouge/musique/LRBuddhist_gong_05_by_Lionel_Allorge.ogg", - start_callback); - } else - playing_sound = FALSE; - memory_next_level(); } } @@ -961,6 +953,15 @@ static void memory_next_level() { gc_bar_set_level(gcomprisBoard); + to_tux = FALSE; + if (currentUiMode == UIMODE_SOUND){ + /* We play a sound here to cancel any pending sounds callback from a previous play */ + playing_sound = TRUE; + gc_sound_play_ogg_cb("sounds/LuneRouge/musique/LRBuddhist_gong_05_by_Lionel_Allorge.ogg", + start_callback); + } else + playing_sound = FALSE; + memory_destroy_all_items(); boardRootItem = GNOME_CANVAS_GROUP( |