Seems we don't need to unset portraitBackground and landscapeBackground to show our...
[harmattan/cameraplus] / qml / PreviewImage.qml
1 // -*- qml -*-
2 import QtQuick 1.1
3 import com.nokia.meego 1.1
4 import QtCamera 1.0
5
6 Image {
7         id: image
8         anchors.fill: parent
9         property alias animationRunning: animation.running
10
11         visible: false
12         cache: false
13         fillMode: Image.PreserveAspectFit
14
15         SequentialAnimation {
16                 id: animation
17                 PauseAnimation { duration: 500; alwaysRunToEnd: true }
18                 NumberAnimation { target: preview; property: "opacity"; from: 1; to: 0; duration: 250; alwaysRunToEnd: true }
19         }
20
21         function setPreview(preview) {
22                 animation.start();
23                 image.source = preview;
24                 image.visible = true;
25         }
26 }