Details
- Reviewers
jjazeix - Group Reviewers
GCompris: Improvements - Maniphest Tasks
- T8491: Memory activities, implement keyboard controls.
Diff Detail
- Repository
- R2 GCompris
- Lint
Lint Skipped - Unit
Unit Tests Skipped
Hi, thank you for the patch.
I see 4 issues:
- there should be more spaces between the cards (and the last ones should not override with the menu bar)
- when I select 2 cards with the mouse, I have the following error: qrc:/gcompris/src/activities/memory/memory.js:157: Error: Insufficient arguments
And I can't select cards anymore.
- we should be able to select only 2 cars at same time, don't allow to turn cards when it's the opponent turn (like it's done with the mouse)
- if you keep on the same card "Return" key pressed, at some point it will self validate the card with itself.
Bugs fixed.
- Spaces between the cards
- Eliminated possibility of the third selection
- Eliminated possibility of self-validation
Thank you, the bugs are fixed.
There is still one: if you play a game with Tux (the icons have a 2 between the cards), there is the error: "qrc:/gcompris/src/activities/memory/memory.js:157: Error: Insufficient arguments" after I play (so when it's the computer turn)
src/activities/memory/MemoryCommon.qml | ||
---|---|---|
213 | I don't understand this condition, can you help me understand what it does? |
src/activities/memory/MemoryCommon.qml | ||
---|---|---|
213 | The program would skip the completed blocks in order to prevent selecting void not only applying. |
src/activities/memory/MemoryCommon.qml | ||
---|---|---|
213 | Thanks, can you add a comment in the code, telling it's to skip the highlight on the already found cards? |
- Added a comment in the code, telling it's to skip the highlight on the already found cards
- Failed to work out by fixing surface issues in memory.js
src/activities/memory/memory.js | ||
---|---|---|
158 | I changed the implementation here because there is only itemAt(x, y) in grid objects. |
src/activities/memory/memory.js | ||
---|---|---|
158 | sure, I'll take a look in one hour |
src/activities/memory/memory.js | ||
---|---|---|
158 | var x = (i % columns) * items.grid.cellWidth + items.grid.anchors.margins seems to be working (it has to be changed in getShownPair too at least). |
- The activity can no longer freeze if you keep pressing an arrow while you or Tux is winning a level
- Tux card position issue is fixed
Commited in https://commits.kde.org/gcompris/561753ee00aa35cbdcacbf1467d048a8a95f6e8d.
Thank you!