Please let me know if a button would be better suited visually as a switch. I couldn't find appropriate .svg files for it.
- Group Reviewers
GCompris GCompris: Improvements
- Maniphest Tasks
- T5937: letter_in_word: Easy mode for preschool children
you should use a GCDialogCheckBox instead of directly a GCText
no need to change the text color
qsTr needs to be used for translatable texts.
it should only be changed when clicking on the cross (so in onSaveData).
you should not change the text directly
do you need to have both mode and reduceWords?
you shouldn't change anything on checking/unchecking the box, it should only be done when the user clicks on the Cross to go back to the activity (onSaveData).
you should use ExclusiveGroup (https://doc.qt.io/qt-5/qml-qtquick-controls-exclusivegroup.html)
if I'm not wrong, you never restore the reduceWords when starting the activity
Couldn't remove QtQuickControls, else the ExclusiveOptions isn't working. Using a second variable to save the checked state of the dialogCheckBoxes. Let me know if this is what was intended to be done.
qrc:/gcompris/src/activities/letter-in-word/LetterInWord.qml:163: TypeError: Cannot read property 'locale' of undefined
save configuration for: "letter-in-word"
This is what I get and I didn't see any change with change in config.
why do you keep two variables? You keep mode and two booleans easy normal mode, they both do the same work?
the names can be better what is easy mode should be signigicant from the variable name.
I am not getting this error. I changed the names to easyModeConfig and normalModeConfig. The mode is to save the mode as a string., the easyMode and normalMode are the id for GCDIalogCheckBoxes.
comments from Timothée:
- the default option with all words should be first in the list.
- the options could be named "All words" and "Only 5 words".
why not directly store the number of words as int? It would have more sense than a string "easy", "normal"and would be directly be useable in the js file
you can rename it to be more precise on what it does
"modes" can be renamed to be more precise