Bug 503573

Summary: after changing language, memory-enumerate keeps number voices of previous language
Product: [Applications] gcompris Reporter: animtim
Component: generalAssignee: Jazeix Johnny <jazeix>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description animtim 2025-04-30 11:24:10 UTC
After changing language, memory-enumerate keeps playing the number voices of language which was selected on application start.

I could only reproduce this issue in this specific activity...

STEPS TO REPRODUCE
1. Start application with English language.
2. Open settings, select French language, and save changes.
3. Open memory-enumerate and start playing: when turning a number-card it'll play the English voice of the number.

Reproduced both on Linux and Android, so probably not platform-specific.
Comment 1 Jazeix Johnny 2025-04-30 13:11:11 UTC
Git commit e5bdab667f5bb579eedac25f4d304230ef9b8d11 by Johnny Jazeix.
Committed on 30/04/2025 at 13:10.
Pushed by jjazeix into branch 'master'.

memory-enumerate, play correct audio when changing locale

M  +2    -2    src/activities/memory-enumerate/resource/1/Data.qml
M  +3    -3    src/activities/memory-enumerate/resource/2/Data.qml
M  +4    -4    src/activities/memory-enumerate/resource/3/Data.qml
M  +6    -6    src/activities/memory-enumerate/resource/4/Data.qml
M  +7    -7    src/activities/memory-enumerate/resource/5/Data.qml
M  +8    -8    src/activities/memory-enumerate/resource/6/Data.qml
M  +9    -9    src/activities/memory-enumerate/resource/7/Data.qml
M  +10   -10   src/activities/memory-enumerate/resource/8/Data.qml
M  +3    -1    src/activities/memory/memory.js

https://invent.kde.org/education/gcompris/-/commit/e5bdab667f5bb579eedac25f4d304230ef9b8d11
Comment 2 Jazeix Johnny 2025-04-30 13:12:01 UTC
Git commit 7bbe87196491bd2f04124b33dd7127b3e6e2b341 by Johnny Jazeix.
Committed on 30/04/2025 at 13:11.
Pushed by jjazeix into branch 'KDE/25.0'.

memory-enumerate, play correct audio when changing locale

M  +2    -2    src/activities/memory-enumerate/resource/1/Data.qml
M  +3    -3    src/activities/memory-enumerate/resource/2/Data.qml
M  +4    -4    src/activities/memory-enumerate/resource/3/Data.qml
M  +6    -6    src/activities/memory-enumerate/resource/4/Data.qml
M  +7    -7    src/activities/memory-enumerate/resource/5/Data.qml
M  +8    -8    src/activities/memory-enumerate/resource/6/Data.qml
M  +9    -9    src/activities/memory-enumerate/resource/7/Data.qml
M  +10   -10   src/activities/memory-enumerate/resource/8/Data.qml
M  +3    -1    src/activities/memory/memory.js

https://invent.kde.org/education/gcompris/-/commit/7bbe87196491bd2f04124b33dd7127b3e6e2b341
Comment 3 Jazeix Johnny 2025-04-30 13:12:43 UTC
Thanks for reporting.
The issue is because we have the getAudioFilePath("audio") directly in the Data.qml inside of having it in the activity, and it's only computed once at start.