Commit 03149e50 authored by Timothée Giet's avatar Timothée Giet
Browse files

chess, fix capturing piece by clicking on it

parent 00c9317e
......@@ -428,9 +428,9 @@ ActivityBase {
MouseArea {
id: dragArea
anchors.fill: parent
enabled: !items.gameOver && ((items.blackTurn && !parent.isWhite) || (!items.blackTurn && parent.isWhite))
&& !items.trigComputerMove.running
drag.target: parent
enabled: !items.gameOver && !items.trigComputerMove.running
drag.target: ((items.blackTurn && !parent.isWhite) || (!items.blackTurn && parent.isWhite)) ?
parent : null
onPressed: {
piece.Drag.keys = ['acceptMe']
parent.z = 100
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment