bdoin/GCompris — pull request #6 by palbr (2012-09-18 11:50:39+00:00)
Title: note_names: alternate solution for same-sound-bug

Thanks for fixing the same-sound-bug.

Looking at your fix, I came to following idea:

This commit reverts a2828a2ba35246c2c479a9d57ead58cbb815183b and
provides an alternate solution for the same-sound-bug in the note_names
activity.

We keep "show only one C-button" and just fix the same-sound-bug in
lines 363 following.

Reason:
At level 4 you don't get sounds, when clicking on the buttons.
So children don't have a chance do identify the correct solution.
Their only chance is to try one with a 50:50 chance of success. This
might be a little bit frustrating.

I have tested this
- with the notes c', g' and c"
- in levels 2, 3, 4, 5, 6, 12, 13, 15 and 16
- with and without the sharp notes, where applicable (there is no #c")
- checking for
- button sound matches asked note's sound
- other buttons play different sounds
- wrong answer detected as wrong answer
- correct answer detected as correct answer

It seems to work quite well and children won't have to guess answers in
the case mentioned above.
But we have the nasty "if note == 8" again in the source.

What do you think?