4 * This file is part of CameraPlus.
6 * Copyright (C) 2012 Mohammed Sameer <msameer@foolab.org>
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public
10 * License as published by the Free Software Foundation; either
11 * version 2.1 of the License, or (at your option) any later version.
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with this library; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
24 import com.nokia.meego 1.1
27 import "data.js" as Data
32 policyMode: CameraResources.Video
34 controlsVisible: cam.running && !videoMode.recording && videoMode.canCapture && !cameraMode.animationRunning && !previewAnimationRunning && !standbyWidget.visible
35 orientationLock: PageOrientation.LockLandscape
37 function startRecording() {
38 if (!fileSystem.available) {
39 showError(qsTr("Camera cannot record videos in mass storage mode."));
43 if (!checkBattery()) {
44 showError(qsTr("Not enough battery to record video."));
48 if (!checkDiskSpace()) {
49 showError(qsTr("Not enough space to record video."));
53 openFileNow("RecordingPage.qml");
58 anchors.right: parent.right
59 anchors.rightMargin: 20
60 anchors.verticalCenter: parent.verticalCenter
61 iconSource: "image://theme/icon-m-camera-video-record"
66 onClicked: startRecording();
68 visible: controlsVisible
75 if (!standbyWidget.visible) {
76 page.setPreview(preview);
84 visible: controlsVisible
85 anchors.top: parent.top
86 anchors.left: parent.left
88 anchors.leftMargin: 20
94 visible: controlsVisible
95 anchors.top: torch.bottom
96 anchors.left: parent.left
98 anchors.leftMargin: 20
103 visible: controlsVisible
104 anchors.top: scene.bottom
105 anchors.left: parent.left
106 anchors.topMargin: 10
107 anchors.leftMargin: 20
112 anchors.bottom: parent.bottom
113 anchors.bottomMargin: 20
114 anchors.left: parent.left
115 anchors.leftMargin: 20
118 onClicked: openFile("VideoSettingsPage.qml");
119 visible: controlsVisible
125 source: indicators.pressed ? "image://theme/meegotouch-camera-settings-indicators-background-pressed" : "image://theme/meegotouch-camera-settings-indicators-background"
134 id: resolutionIndicator
135 source: "image://theme/" + Data.videoIcon(settings.videoResolution);
140 source: visible ? "image://theme/" + Data.wbIcon(settings.videoWhiteBalance) + "-screen" : ""
141 visible: settings.videoWhiteBalance != WhiteBalance.Auto
146 source: "image://theme/" + Data.cfIcon(settings.videoColorFilter) + "-screen"
147 visible: settings.videoColorFilter != ColorTone.Normal
152 visible: settings.useGps
153 source: "image://theme/icon-m-camera-location"
155 PropertyAnimation on opacity {
156 easing.type: Easing.OutSine
157 loops: Animation.Infinite
161 running: settings.useGps && !positionSource.position.longitudeValid
170 anchors.top: parent.top
171 anchors.right: parent.right
172 anchors.topMargin: 20
173 anchors.rightMargin: 20
178 iconSource: "image://theme/icon-m-camera-roll"
179 onClicked: openFile("PostCapturePage.qml");
180 visible: controlsVisible