/**************************************************************************** ** ** Copyright (C) 2011 Nokia Institute of Technology. ** All rights reserved. ** Contact: Manager (renato.chencarek@openbossa.org) ** ** This file is part of the Incredible Circus project. ** ** GNU Lesser General Public License Usage ** ** This file may be used under the terms of the GNU Lesser General Public ** License version 2.1 as published by the Free Software Foundation and ** appearing in the file LICENSE.LGPL included in the packaging of this ** file. Please review the following information to ensure the GNU Lesser ** General Public License version 2.1 requirements will be met: ** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. ** ****************************************************************************/ import QtQuick 1.1 Item { id: intro anchors.fill: parent opacity: 0.0 visible: false signal finished() Image { source: "image://cache/_intro/applause/bg.png" } Image { source: "image://cache/_intro/applause/player.png" anchors.horizontalCenter: parent.horizontalCenter anchors.bottom: parent.bottom anchors.bottomMargin: 138 * scaleFactor Image { id: highlight opacity: 0.0 source: "image://cache/_intro/applause/highlight_player.png" } } Image { id: leftCurtain anchors.right: parent.horizontalCenter anchors.rightMargin: -10 * scaleFactor source: "image://cache/_intro/applause/curtain.png" } Image { id: rightCurtain anchors.left: parent.horizontalCenter anchors.leftMargin: -10 * scaleFactor transform: Scale { xScale: -1 origin.x: rightCurtain.width / 2 } source: "image://cache/_intro/applause/curtain.png" } Image { id: clown anchors.top: parent.top anchors.horizontalCenter: parent.horizontalCenter source: "image://cache/_intro/applause/clown.png" } Image { id: face anchors { left: parent.left bottom: parent.bottom leftMargin: -face.width bottomMargin: -face.height } source: "image://cache/_intro/applause/face.png" } Image { id: hands anchors { right: parent.right bottom: parent.bottom rightMargin: -hands.width bottomMargin: -hands.height } source: "image://cache/_intro/applause/hands.png" } states: State { name: "final" PropertyChanges { target: intro; opacity: 1.0; visible: true; } PropertyChanges { target: highlight; opacity: 1.0; } PropertyChanges { target: clown; anchors.topMargin: -130; } PropertyChanges { target: leftCurtain; anchors.rightMargin: 120; } PropertyChanges { target: rightCurtain; anchors.leftMargin: 120; } PropertyChanges { target: face; anchors.leftMargin: 0; anchors.bottomMargin: 0; } PropertyChanges { target: hands; anchors.rightMargin: 0; anchors.bottomMargin: 0; } } transitions: Transition { to: "final" SequentialAnimation { NumberAnimation { target: intro; duration: 600; properties: "opacity"; } PauseAnimation { duration: 1000; } NumberAnimation { target: clown; duration: 1500; properties: "anchors.topMargin"; } ParallelAnimation { NumberAnimation { target: leftCurtain; duration: 1200; easing.type: Easing.OutQuart; properties: "anchors.rightMargin"; } NumberAnimation { target: rightCurtain; duration: 1200; easing.type: Easing.OutQuart; properties: "anchors.leftMargin"; } } NumberAnimation { target: highlight; duration: 100; properties: "opacity"; from: 0.0; to: 0.6; } NumberAnimation { target: highlight; duration: 100; properties: "opacity"; from: 0.6; to: 0.0; } NumberAnimation { target: highlight; duration: 100; properties: "opacity"; from: 0.0; to: 0.8; } NumberAnimation { target: highlight; duration: 100; properties: "opacity"; from: 0.8; to: 0.0; } NumberAnimation { target: highlight; duration: 100; properties: "opacity"; from: 0.0; to: 1.0; } ParallelAnimation { NumberAnimation { target: face; duration: 400; properties: "anchors.leftMargin,anchors.bottomMargin"; } NumberAnimation { target: hands; duration: 400; properties: "anchors.rightMargin,anchors.bottomMargin"; } } PauseAnimation { duration: 2500; } ScriptAction { script: intro.finished(); } } } Component.onCompleted: intro.state = "final"; }