diff --git a/src/activities/nine_men_morris/NineMenMorris.qml b/src/activities/nine_men_morris/NineMenMorris.qml --- a/src/activities/nine_men_morris/NineMenMorris.qml +++ b/src/activities/nine_men_morris/NineMenMorris.qml @@ -98,7 +98,6 @@ source: Activity.url + "board.svg" sourceSize.width: Math.min(background.height - 1.4 * player1score.height - 1.2 * bar.height, background.width - 2.2 * firstInitial.width) - visible: !items.isTutorial anchors { verticalCenter: parent.verticalCenter horizontalCenter: parent.horizontalCenter @@ -136,7 +135,7 @@ } width: player1score.width * 1.2 height: player1score.height * 1.2 - visible: !items.isTutorial && items.firstPhase + visible: items.firstPhase opacity: 0.8 radius: 10 border.width: 2 @@ -198,7 +197,7 @@ } width: firstInitial.width height: firstInitial.height - visible: !items.isTutorial && items.firstPhase + visible: items.firstPhase opacity: 0.8 radius: 10 border.width: 2 @@ -266,7 +265,6 @@ horizontalAlignment: Text.AlignHLeft width: implicitWidth height: implicitHeight - visible: !items.isTutorial z: 2 } @@ -280,7 +278,6 @@ radius: 10 border.width: 2 border.color: "black" - visible: !items.isTutorial gradient: Gradient { GradientStop { position: 0.0; color: "#000" } GradientStop { position: 0.9; color: "#666" } @@ -301,7 +298,6 @@ right: background.right rightMargin: 5 } - visible: !items.isTutorial playerImageSource: Activity.url + "TuxBlack.svg" backgroundImageSource: Activity.url + "score_2.svg" playerScaleOriginX: player2score.width @@ -318,7 +314,6 @@ left: background.left leftMargin: 5 } - visible: !items.isTutorial playerImageSource: Activity.url + "KonqiWhite.svg" backgroundImageSource: Activity.url + "score_1.svg" } @@ -349,8 +344,9 @@ Bar { id: bar - content: BarEnumContent { value: twoPlayer ? (help | home | reload) : items.isTutorial ? - (help | home) : (help | home | level | reload)} + content: BarEnumContent { value: twoPlayer ? (help | home | reload) + : tutorialImage.visible ? (help | home) + : (help | home | level | reload) } onHelpClicked: { displayDialog(dialogHelp) } diff --git a/src/activities/nine_men_morris/nine_men_morris.js b/src/activities/nine_men_morris/nine_men_morris.js --- a/src/activities/nine_men_morris/nine_men_morris.js +++ b/src/activities/nine_men_morris/nine_men_morris.js @@ -37,26 +37,26 @@ var depthMax var tutorialInstructions = [ { - "instruction": qsTr("You and Tux start with 9 pieces each, and take turns to place your pieces on to the empty spots (by clicking on the spots) on the board."), - "instructionImage" : "qrc:/gcompris/src/activities/nine_men_morris/resource/tutorial1.svg" + "instruction": qsTr("You and Tux start with 9 pieces each, and take turns to place your pieces on to the empty spots (by clicking on the spots) on the board."), + "instructionImage" : "qrc:/gcompris/src/activities/nine_men_morris/resource/tutorial1.svg" }, { "instruction": qsTr("If you form a mill (line of 3 pieces), then select a piece of Tux, and remove it. Pieces of formed mill can not be removed unless no other pieces are left on board."), "instructionImage": "qrc:/gcompris/src/activities/nine_men_morris/resource/tutorial2.svg" }, { - "instruction": qsTr("After all the pieces are placed, you and Tux will take turns to move them. Click on one of your pieces, and then on the adjacent empty spot to move it there. Green color spot indicates where you can move."), - "instructionImage": "qrc:/gcompris/src/activities/nine_men_morris/resource/tutorial3.svg" - }, - { - "instruction": qsTr("If you are left with 3 pieces, your pieces will gain the ability to 'fly' and can be moved to any vacant spot on the board."), - "instructionImage": "qrc:/gcompris/src/activities/nine_men_morris/resource/tutorial4.svg" - }, - { - "instruction": qsTr("If you immobilize the computer or leave it with less than 3 pieces, then you win the game."), - "instructionImage": "qrc:/gcompris/src/activities/nine_men_morris/resource/tutorial5.svg" - } - ] + "instruction": qsTr("After all the pieces are placed, you and Tux will take turns to move them. Click on one of your pieces, and then on the adjacent empty spot to move it there. Green color spot indicates where you can move."), + "instructionImage": "qrc:/gcompris/src/activities/nine_men_morris/resource/tutorial3.svg" + }, + { + "instruction": qsTr("If you are left with 3 pieces, your pieces will gain the ability to 'fly' and can be moved to any vacant spot on the board."), + "instructionImage": "qrc:/gcompris/src/activities/nine_men_morris/resource/tutorial4.svg" + }, + { + "instruction": qsTr("If you immobilize the computer or leave it with less than 3 pieces, then you win the game."), + "instructionImage": "qrc:/gcompris/src/activities/nine_men_morris/resource/tutorial5.svg" + } + ] function start(items_, twoPlayer_) { items = items_